Guest User

fanim console

a guest
Jun 1st, 2022
116
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 113.80 KB | None | 0 0
  1. #! /usr/bin/env python
  2.   File "<input>", line 1
  3.     usr/bin/env python
  4.                      ^
  5. SyntaxError: invalid syntax
  6. >>> # -*- coding: utf-8 -*-
  7. >>>
  8. >>> """
  9. ...   Copyright (C) 2016-2018, Douglas Vinicius
  10. ...   douglvini@gmail.com
  11. ...
  12. ...   Distributed under the terms of GNU GPL v3 (or lesser GPL) license.
  13. ...
  14. ... Fanim is an extention for GIMP thats implements a simple timeline that can
  15. ... be used to play in sequence and manipulate layers that works as each frame of an
  16. ... frame by frame animation.
  17. ...
  18. ... """
  19. '\n  Copyright (C) 2016-2018, Douglas Vinicius\n  douglvini@gmail.com\n\n  Distributed under the terms of GNU GPL v3 (or lesser GPL) license.\n\nFanim is an extention for GIMP thats implements a simple timeline that can\nbe used to play in sequence and manipulate layers that works as each frame of an \nframe by frame animation.\n\n'
  20. >>> from gimpfu import register, main, gimp, pdb, \
  21.   File "<input>", line 1
  22. SyntaxError: trailing comma not allowed without surrounding parentheses
  23. >>>         TRANSPARENT_FILL, RGBA_IMAGE, NORMAL_MODE
  24.   File "<input>", line 1
  25.     TRANSPARENT_FILL, RGBA_IMAGE, NORMAL_MODE
  26.     ^
  27. IndentationError: unexpected indent
  28. >>>
  29. >>> import pygtk
  30. >>> pygtk.require('2.0')
  31. >>> import gtk, array, time, os, json
  32. >>>
  33. >>> # general info
  34. >>> VERSION = 1.16
  35. >>> AUTHORS = ["Douglas Vinicius <douglvini@gmail.com>"]
  36. >>> NAME = "FAnim Timeline " + str(VERSION)
  37. >>> WINDOW_TITLE = ("GIMP %s "%NAME)+ "[%s]"
  38. >>> COPYRIGHT = "Copyright (C) 2016-2019 \nDouglas Vinicius"
  39. >>> WEBSITE = "https://github.com/douglasvini/gimp-fanim"
  40. >>> YEAR = "2016-2019"
  41. >>> DESCRIPTION = "Timeline to edit frames and play animations with some aditional functionality."
  42. >>> GIMP_LOCATION = "<Image>/FAnim/FAnim Timeline"
  43. >>>
  44. >>> # fixed frames prefix in the end to store visibility fix for the playback understand.
  45. >>> PREFIX="_fix"
  46. >>>
  47. >>> # playback macros
  48. >>> NEXT = 1
  49. >>> PREV = 2
  50. >>> END = 3
  51. >>> START = 4
  52. >>> NOWHERE = 5
  53. >>> POS = 6
  54. >>> GIMP_ACTIVE = 7
  55. >>>
  56. >>> # settings constant macros
  57. >>> WIN_WIDTH = "win_width"
  58. >>> WIN_HEIGHT = "win_height"
  59. >>> WIN_POSX = "win_posx"
  60. >>> WIN_POSY = "win_posy"
  61. >>> FRAMERATE = "framerate"
  62. >>> OSKIN_DEPTH = "oskin_depth"
  63. >>> OSKIN_ONPLAY = "oskin_onplay"
  64. >>> OSKIN_FORWARD = "oskin_forward"
  65. >>> OSKIN_BACKWARD = "oskin_backward"
  66. >>>
  67. >>> # state to disable the buttons
  68. >>> PLAYING = 1
  69. >>> NO_FRAMES = 2
  70. >>>
  71. >>> # onionskin constants
  72. >>> OSKIN_MAX_DEPTH = 6
  73. >>> OSKIN_MAX_OPACITY = 50.0
  74. >>>
  75. >>> CONF_FILENAME = "conf.json"
  76. >>>
  77. >>> class Utils:
  78. ...
  79. ...     @staticmethod
  80. ...     def add_fixed_prefix(layer):
  81. ...         """
  82. ...         add the prefix at the end of the layer name to store if the frae is
  83. ...         visibly fixed or not.
  84. ...         """
  85. ...         if Utils.is_frame_fixed(layer): return
  86. ...         layer.name = layer.name + PREFIX
  87. ...
  88. >>>     @staticmethod
  89.   File "<input>", line 1
  90.     @staticmethod
  91.     ^
  92. IndentationError: unexpected indent
  93. >>>     def rem_fixed_prefix(layer):
  94.   File "<input>", line 1
  95.     def rem_fixed_prefix(layer):
  96.     ^
  97. IndentationError: unexpected indent
  98. >>>         """
  99.  File "<input>", line 1
  100.    """
  101.     ^
  102. IndentationError: unexpected indent
  103. >>>         remove the prefix at the end of the layer name to store if the frae is
  104.   File "<input>", line 1
  105.     remove the prefix at the end of the layer name to store if the frae is
  106.     ^
  107. IndentationError: unexpected indent
  108. >>>         visibly fixed or not.
  109.   File "<input>", line 1
  110.     visibly fixed or not.
  111.     ^
  112. IndentationError: unexpected indent
  113. >>>         """
  114.  File "<input>", line 1
  115.    """
  116.     ^
  117. IndentationError: unexpected indent
  118. >>>         if not Utils.is_frame_fixed(layer): return
  119.   File "<input>", line 1
  120.     if not Utils.is_frame_fixed(layer): return
  121.     ^
  122. IndentationError: unexpected indent
  123. >>>         layer.name = layer.name[:-4]
  124.   File "<input>", line 1
  125.     layer.name = layer.name[:-4]
  126.     ^
  127. IndentationError: unexpected indent
  128. >>>
  129. >>>     @staticmethod
  130.   File "<input>", line 1
  131.     @staticmethod
  132.     ^
  133. IndentationError: unexpected indent
  134. >>>     def is_frame_fixed(layer):
  135.   File "<input>", line 1
  136.     def is_frame_fixed(layer):
  137.     ^
  138. IndentationError: unexpected indent
  139. >>>         """
  140.  File "<input>", line 1
  141.    """
  142.     ^
  143. IndentationError: unexpected indent
  144. >>>         get if the frame is visibly fixed or not based on the name of the layer.
  145.   File "<input>", line 1
  146.     get if the frame is visibly fixed or not based on the name of the layer.
  147.     ^
  148. IndentationError: unexpected indent
  149. >>>         """
  150.  File "<input>", line 1
  151.    """
  152.     ^
  153. IndentationError: unexpected indent
  154. >>>         name = layer.name
  155.   File "<input>", line 1
  156.     name = layer.name
  157.     ^
  158. IndentationError: unexpected indent
  159. >>>         return name[-4:] == PREFIX
  160.   File "<input>", line 1
  161.     return name[-4:] == PREFIX
  162.     ^
  163. IndentationError: unexpected indent
  164. >>>
  165. >>>     @staticmethod
  166.   File "<input>", line 1
  167.     @staticmethod
  168.     ^
  169. IndentationError: unexpected indent
  170. >>>     def button_stock(stock,size):
  171.   File "<input>", line 1
  172.     def button_stock(stock,size):
  173.     ^
  174. IndentationError: unexpected indent
  175. >>>         """
  176.  File "<input>", line 1
  177.    """
  178.     ^
  179. IndentationError: unexpected indent
  180. >>>         Return a button with a image from stock items.
  181.   File "<input>", line 1
  182.     Return a button with a image from stock items.
  183.     ^
  184. IndentationError: unexpected indent
  185. >>>         """
  186.  File "<input>", line 1
  187.    """
  188.     ^
  189. IndentationError: unexpected indent
  190. >>>         b = gtk.Button()
  191.   File "<input>", line 1
  192.     b = gtk.Button()
  193.     ^
  194. IndentationError: unexpected indent
  195. >>>         img = gtk.Image()
  196.   File "<input>", line 1
  197.     img = gtk.Image()
  198.     ^
  199. IndentationError: unexpected indent
  200. >>>         img.set_from_stock(stock,size)
  201.   File "<input>", line 1
  202.     img.set_from_stock(stock,size)
  203.     ^
  204. IndentationError: unexpected indent
  205. >>>         b.set_image(img)
  206.   File "<input>", line 1
  207.     b.set_image(img)
  208.     ^
  209. IndentationError: unexpected indent
  210. >>>         return b
  211.   File "<input>", line 1
  212.     return b
  213.     ^
  214. IndentationError: unexpected indent
  215. >>>
  216. >>>     @staticmethod
  217.   File "<input>", line 1
  218.     @staticmethod
  219.     ^
  220. IndentationError: unexpected indent
  221. >>>     def toggle_button_stock(stock,size):
  222.   File "<input>", line 1
  223.     def toggle_button_stock(stock,size):
  224.     ^
  225. IndentationError: unexpected indent
  226. >>>         """
  227.  File "<input>", line 1
  228.    """
  229.     ^
  230. IndentationError: unexpected indent
  231. >>>         Return a button with a image from stock items
  232.   File "<input>", line 1
  233.     Return a button with a image from stock items
  234.     ^
  235. IndentationError: unexpected indent
  236. >>>         """
  237.  File "<input>", line 1
  238.    """
  239.     ^
  240. IndentationError: unexpected indent
  241. >>>         b = gtk.ToggleButton()
  242.   File "<input>", line 1
  243.     b = gtk.ToggleButton()
  244.     ^
  245. IndentationError: unexpected indent
  246. >>>         img = gtk.Image()
  247.   File "<input>", line 1
  248.     img = gtk.Image()
  249.     ^
  250. IndentationError: unexpected indent
  251. >>>         img.set_from_stock(stock,size)
  252.   File "<input>", line 1
  253.     img.set_from_stock(stock,size)
  254.     ^
  255. IndentationError: unexpected indent
  256. >>>         b.set_image(img)
  257.   File "<input>", line 1
  258.     b.set_image(img)
  259.     ^
  260. IndentationError: unexpected indent
  261. >>>         return b
  262.   File "<input>", line 1
  263.     return b
  264.     ^
  265. IndentationError: unexpected indent
  266. >>>
  267. >>>     @staticmethod
  268.   File "<input>", line 1
  269.     @staticmethod
  270.     ^
  271. IndentationError: unexpected indent
  272. >>>     def spin_button(name="variable",number_type="int",value=0,min=1,max=100,advance=1):
  273.   File "<input>", line 1
  274.     def spin_button(name="variable",number_type="int",value=0,min=1,max=100,advance=1):
  275.     ^
  276. IndentationError: unexpected indent
  277. >>>         adjustment = gtk.Adjustment(value,min,max,advance,advance)
  278.   File "<input>", line 1
  279.     adjustment = gtk.Adjustment(value,min,max,advance,advance)
  280.     ^
  281. IndentationError: unexpected indent
  282. >>>         digits = 0
  283.   File "<input>", line 1
  284.     digits = 0
  285.     ^
  286. IndentationError: unexpected indent
  287. >>>         if number_type != "int":
  288.   File "<input>", line 1
  289.     if number_type != "int":
  290.     ^
  291. IndentationError: unexpected indent
  292. >>>             digits = 3
  293.   File "<input>", line 1
  294.     digits = 3
  295.     ^
  296. IndentationError: unexpected indent
  297. >>>         l = gtk.Label(name)
  298.   File "<input>", line 1
  299.     l = gtk.Label(name)
  300.     ^
  301. IndentationError: unexpected indent
  302. >>>         b = gtk.SpinButton(adjustment,0,digits)
  303.   File "<input>", line 1
  304.     b = gtk.SpinButton(adjustment,0,digits)
  305.     ^
  306. IndentationError: unexpected indent
  307. >>>
  308. >>>         h = gtk.HBox()
  309.   File "<input>", line 1
  310.     h = gtk.HBox()
  311.     ^
  312. IndentationError: unexpected indent
  313. >>>         h.pack_start(l)
  314.   File "<input>", line 1
  315.     h.pack_start(l)
  316.     ^
  317. IndentationError: unexpected indent
  318. >>>         h.pack_start(b)
  319.   File "<input>", line 1
  320.     h.pack_start(b)
  321.     ^
  322. IndentationError: unexpected indent
  323. >>>         return h,adjustment
  324.   File "<input>", line 1
  325.     return h,adjustment
  326.     ^
  327. IndentationError: unexpected indent
  328. >>>
  329. >>>     @staticmethod
  330.   File "<input>", line 1
  331.     @staticmethod
  332.     ^
  333. IndentationError: unexpected indent
  334. >>>     def load_conffile(filename):
  335.   File "<input>", line 1
  336.     def load_conffile(filename):
  337.     ^
  338. IndentationError: unexpected indent
  339. >>>         """
  340.  File "<input>", line 1
  341.    """
  342.     ^
  343. IndentationError: unexpected indent
  344. >>>         Load configuration from a file stored in gimp user folder.
  345.   File "<input>", line 1
  346.     Load configuration from a file stored in gimp user folder.
  347.     ^
  348. IndentationError: unexpected indent
  349. >>>         """
  350.  File "<input>", line 1
  351.    """
  352.     ^
  353. IndentationError: unexpected indent
  354. >>>         directory = gimp.directory + "/fanim"
  355.   File "<input>", line 1
  356.     directory = gimp.directory + "/fanim"
  357.     ^
  358. IndentationError: unexpected indent
  359. >>>         if not os.path.exists(directory):
  360.   File "<input>", line 1
  361.     if not os.path.exists(directory):
  362.     ^
  363. IndentationError: unexpected indent
  364. >>>             os.mkdir(directory)
  365.   File "<input>", line 1
  366.     os.mkdir(directory)
  367.     ^
  368. IndentationError: unexpected indent
  369. >>>
  370. >>>         filepath = directory + "/" + filename
  371.   File "<input>", line 1
  372.     filepath = directory + "/" + filename
  373.     ^
  374. IndentationError: unexpected indent
  375. >>>         if os.path.exists(filepath):
  376.   File "<input>", line 1
  377.     if os.path.exists(filepath):
  378.     ^
  379. IndentationError: unexpected indent
  380. >>>             f = open(filepath,'r')
  381.   File "<input>", line 1
  382.     f = open(filepath,'r')
  383.     ^
  384. IndentationError: unexpected indent
  385. >>>             dic = json.load(f)
  386.   File "<input>", line 1
  387.     dic = json.load(f)
  388.     ^
  389. IndentationError: unexpected indent
  390. >>>             f.close()
  391.   File "<input>", line 1
  392.     f.close()
  393.     ^
  394. IndentationError: unexpected indent
  395. >>>             return dic
  396.   File "<input>", line 1
  397.     return dic
  398.     ^
  399. IndentationError: unexpected indent
  400. >>>
  401. >>>         else:
  402.   File "<input>", line 1
  403.     else:
  404.     ^
  405. IndentationError: unexpected indent
  406. >>>             return None
  407.   File "<input>", line 1
  408.     return None
  409.     ^
  410. IndentationError: unexpected indent
  411. >>>
  412. >>>     @staticmethod
  413.   File "<input>", line 1
  414.     @staticmethod
  415.     ^
  416. IndentationError: unexpected indent
  417. >>>     def save_conffile(filename,conf={}):
  418.   File "<input>", line 1
  419.     def save_conffile(filename,conf={}):
  420.     ^
  421. IndentationError: unexpected indent
  422. >>>         """
  423.  File "<input>", line 1
  424.    """
  425.     ^
  426. IndentationError: unexpected indent
  427. >>>         Save a configuration dictionary in a json file on user folder.
  428.   File "<input>", line 1
  429.     Save a configuration dictionary in a json file on user folder.
  430.     ^
  431. IndentationError: unexpected indent
  432. >>>         """
  433.  File "<input>", line 1
  434.    """
  435.     ^
  436. IndentationError: unexpected indent
  437. >>>         directory = gimp.directory + "/fanim"
  438.   File "<input>", line 1
  439.     directory = gimp.directory + "/fanim"
  440.     ^
  441. IndentationError: unexpected indent
  442. >>>         if not os.path.exists(directory):
  443.   File "<input>", line 1
  444.     if not os.path.exists(directory):
  445.     ^
  446. IndentationError: unexpected indent
  447. >>>             os.mkdir(directory)
  448.   File "<input>", line 1
  449.     os.mkdir(directory)
  450.     ^
  451. IndentationError: unexpected indent
  452. >>>
  453. >>>         filepath = directory + "/" + filename
  454.   File "<input>", line 1
  455.     filepath = directory + "/" + filename
  456.     ^
  457. IndentationError: unexpected indent
  458. >>>         f = open(filepath,'w')
  459.   File "<input>", line 1
  460.     f = open(filepath,'w')
  461.     ^
  462. IndentationError: unexpected indent
  463. >>>         json.dump(conf,f)
  464.   File "<input>", line 1
  465.     json.dump(conf,f)
  466.     ^
  467. IndentationError: unexpected indent
  468. >>>         f.close()
  469.   File "<input>", line 1
  470.     f.close()
  471.     ^
  472. IndentationError: unexpected indent
  473. >>>        
  474. >>>
  475. >>>
  476. >>> class ConfDialog(gtk.Dialog):
  477. ...     """
  478. ...     Create a configuration dialog to the user change the variables.
  479. ...     """
  480. ...     def __init__(self,title="Config",parent=None,config = None):
  481. ...         gtk.Dialog.__init__(self,title,parent, gtk.DIALOG_DESTROY_WITH_PARENT,
  482. ...                 ('Apply',gtk.RESPONSE_APPLY,'Cancel',gtk.RESPONSE_CANCEL))
  483. ...
  484. >>>         self.set_keep_above(True)
  485.   File "<input>", line 1
  486.     self.set_keep_above(True)
  487.     ^
  488. IndentationError: unexpected indent
  489. >>>         self.set_position(gtk.WIN_POS_CENTER)
  490.   File "<input>", line 1
  491.     self.set_position(gtk.WIN_POS_CENTER)
  492.     ^
  493. IndentationError: unexpected indent
  494. >>>
  495. >>>         self.last_config= config # settings
  496.   File "<input>", line 1
  497.     self.last_config= config # settings
  498.     ^
  499. IndentationError: unexpected indent
  500. >>>         self.atual_config = config
  501.   File "<input>", line 1
  502.     self.atual_config = config
  503.     ^
  504. IndentationError: unexpected indent
  505. >>>
  506. >>>         # setup all widgets
  507. >>>         self._setup_widgets()
  508.   File "<input>", line 1
  509.     self._setup_widgets()
  510.     ^
  511. IndentationError: unexpected indent
  512. >>>
  513. >>>     def update_config(self,widget,var_type=None):
  514.   File "<input>", line 1
  515.     def update_config(self,widget,var_type=None):
  516.     ^
  517. IndentationError: unexpected indent
  518. >>>         if isinstance(widget,gtk.Adjustment):
  519.   File "<input>", line 1
  520.     if isinstance(widget,gtk.Adjustment):
  521.     ^
  522. IndentationError: unexpected indent
  523. >>>             value = widget.get_value()
  524.   File "<input>", line 1
  525.     value = widget.get_value()
  526.     ^
  527. IndentationError: unexpected indent
  528. >>>         elif isinstance(widget,gtk.CheckButton):
  529.   File "<input>", line 1
  530.     elif isinstance(widget,gtk.CheckButton):
  531.     ^
  532. IndentationError: unexpected indent
  533. >>>             value = widget.get_active()
  534.   File "<input>", line 1
  535.     value = widget.get_active()
  536.     ^
  537. IndentationError: unexpected indent
  538. >>>         self.atual_config[var_type] = value
  539.   File "<input>", line 1
  540.     self.atual_config[var_type] = value
  541.     ^
  542. IndentationError: unexpected indent
  543. >>>
  544. >>>     def _setup_widgets(self):
  545.   File "<input>", line 1
  546.     def _setup_widgets(self):
  547.     ^
  548. IndentationError: unexpected indent
  549. >>>
  550. >>>         h_space = 4 # horizontal space
  551.   File "<input>", line 1
  552.     h_space = 4 # horizontal space
  553.     ^
  554. IndentationError: unexpected indent
  555. >>>
  556. >>>         # create the frames to contein the diferent settings.
  557. >>>         f_time = gtk.Frame(label="Time")
  558.   File "<input>", line 1
  559.     f_time = gtk.Frame(label="Time")
  560.     ^
  561. IndentationError: unexpected indent
  562. >>>         f_oskin = gtk.Frame(label="Onion Skin")
  563.   File "<input>", line 1
  564.     f_oskin = gtk.Frame(label="Onion Skin")
  565.     ^
  566. IndentationError: unexpected indent
  567. >>>         self.set_size_request(300,-1)
  568.   File "<input>", line 1
  569.     self.set_size_request(300,-1)
  570.     ^
  571. IndentationError: unexpected indent
  572. >>>         self.vbox.pack_start(f_time,True,True,h_space)
  573.   File "<input>", line 1
  574.     self.vbox.pack_start(f_time,True,True,h_space)
  575.     ^
  576. IndentationError: unexpected indent
  577. >>>         self.vbox.pack_start(f_oskin,True,True,h_space)
  578.   File "<input>", line 1
  579.     self.vbox.pack_start(f_oskin,True,True,h_space)
  580.     ^
  581. IndentationError: unexpected indent
  582. >>>
  583. >>>         # create the time settings.
  584. >>>         th = gtk.HBox()
  585.   File "<input>", line 1
  586.     th = gtk.HBox()
  587.     ^
  588. IndentationError: unexpected indent
  589. >>>         fps,fps_spin = Utils.spin_button("Framerate",'int',self.last_config[FRAMERATE],1,100) #conf fps
  590.   File "<input>", line 1
  591.     fps,fps_spin = Utils.spin_button("Framerate",'int',self.last_config[FRAMERATE],1,100) #conf fps
  592.     ^
  593. IndentationError: unexpected indent
  594. >>>
  595. >>>         th.pack_start(fps,True,True,h_space)
  596.   File "<input>", line 1
  597.     th.pack_start(fps,True,True,h_space)
  598.     ^
  599. IndentationError: unexpected indent
  600. >>>
  601. >>>         f_time.add(th)
  602.   File "<input>", line 1
  603.     f_time.add(th)
  604.     ^
  605. IndentationError: unexpected indent
  606. >>>         # create onion skin settings
  607. >>>         ov = gtk.VBox()
  608.   File "<input>", line 1
  609.     ov = gtk.VBox()
  610.     ^
  611. IndentationError: unexpected indent
  612. >>>         f_oskin.add(ov)
  613.   File "<input>", line 1
  614.     f_oskin.add(ov)
  615.     ^
  616. IndentationError: unexpected indent
  617. >>>        
  618. >>>         # fist line
  619. >>>         oh1 = gtk.HBox()
  620.   File "<input>", line 1
  621.     oh1 = gtk.HBox()
  622.     ^
  623. IndentationError: unexpected indent
  624. >>>         #conf depth
  625. >>>         depth,depth_spin=Utils.spin_button("Depth",'int',
  626.   File "<input>", line 1
  627.     depth,depth_spin=Utils.spin_button("Depth",'int',
  628.     ^
  629. IndentationError: unexpected indent
  630. >>>                 self.last_config[OSKIN_DEPTH],1,OSKIN_MAX_DEPTH,1)
  631.   File "<input>", line 1
  632.     self.last_config[OSKIN_DEPTH],1,OSKIN_MAX_DEPTH,1)
  633.     ^
  634. IndentationError: unexpected indent
  635. >>>
  636. >>>         on_play = gtk.CheckButton("On Play")
  637.   File "<input>", line 1
  638.     on_play = gtk.CheckButton("On Play")
  639.     ^
  640. IndentationError: unexpected indent
  641. >>>         on_play.set_active(self.last_config[OSKIN_ONPLAY])
  642.   File "<input>", line 1
  643.     on_play.set_active(self.last_config[OSKIN_ONPLAY])
  644.     ^
  645. IndentationError: unexpected indent
  646. >>>
  647. >>>         oh1.pack_start(depth,True,True,h_space)
  648.   File "<input>", line 1
  649.     oh1.pack_start(depth,True,True,h_space)
  650.     ^
  651. IndentationError: unexpected indent
  652. >>>         oh1.pack_start(on_play,True,True,h_space)
  653.   File "<input>", line 1
  654.     oh1.pack_start(on_play,True,True,h_space)
  655.     ^
  656. IndentationError: unexpected indent
  657. >>>         ov.pack_start(oh1)
  658.   File "<input>", line 1
  659.     ov.pack_start(oh1)
  660.     ^
  661. IndentationError: unexpected indent
  662. >>>         # second line
  663. >>>         oh2 = gtk.HBox()
  664.   File "<input>", line 1
  665.     oh2 = gtk.HBox()
  666.     ^
  667. IndentationError: unexpected indent
  668. >>>         forward = gtk.CheckButton("Forward")
  669.   File "<input>", line 1
  670.     forward = gtk.CheckButton("Forward")
  671.     ^
  672. IndentationError: unexpected indent
  673. >>>         forward.set_active(self.last_config[OSKIN_FORWARD])
  674.   File "<input>", line 1
  675.     forward.set_active(self.last_config[OSKIN_FORWARD])
  676.     ^
  677. IndentationError: unexpected indent
  678. >>>
  679. >>>         backward = gtk.CheckButton("Backward")
  680.   File "<input>", line 1
  681.     backward = gtk.CheckButton("Backward")
  682.     ^
  683. IndentationError: unexpected indent
  684. >>>         backward.set_active(self.last_config[OSKIN_BACKWARD])
  685.   File "<input>", line 1
  686.     backward.set_active(self.last_config[OSKIN_BACKWARD])
  687.     ^
  688. IndentationError: unexpected indent
  689. >>>
  690. >>>         oh2.pack_start(forward,True,True,h_space)
  691.   File "<input>", line 1
  692.     oh2.pack_start(forward,True,True,h_space)
  693.     ^
  694. IndentationError: unexpected indent
  695. >>>         oh2.pack_start(backward,True,True,h_space)
  696.   File "<input>", line 1
  697.     oh2.pack_start(backward,True,True,h_space)
  698.     ^
  699. IndentationError: unexpected indent
  700. >>>
  701. >>>         ov.pack_start(oh2)
  702.   File "<input>", line 1
  703.     ov.pack_start(oh2)
  704.     ^
  705. IndentationError: unexpected indent
  706. >>>         # last line
  707. >>>
  708. >>>         # connect a callback to all
  709. >>>        
  710. >>>         fps_spin.connect("value_changed",self.update_config,FRAMERATE)
  711.   File "<input>", line 1
  712.     fps_spin.connect("value_changed",self.update_config,FRAMERATE)
  713.     ^
  714. IndentationError: unexpected indent
  715. >>>         depth_spin.connect("value_changed",self.update_config,OSKIN_DEPTH)
  716.   File "<input>", line 1
  717.     depth_spin.connect("value_changed",self.update_config,OSKIN_DEPTH)
  718.     ^
  719. IndentationError: unexpected indent
  720. >>>         on_play.connect("toggled",self.update_config,OSKIN_ONPLAY)
  721.   File "<input>", line 1
  722.     on_play.connect("toggled",self.update_config,OSKIN_ONPLAY)
  723.     ^
  724. IndentationError: unexpected indent
  725. >>>         forward.connect("toggled",self.update_config,OSKIN_FORWARD)
  726.   File "<input>", line 1
  727.     forward.connect("toggled",self.update_config,OSKIN_FORWARD)
  728.     ^
  729. IndentationError: unexpected indent
  730. >>>         backward.connect("toggled",self.update_config,OSKIN_BACKWARD)
  731.   File "<input>", line 1
  732.     backward.connect("toggled",self.update_config,OSKIN_BACKWARD)
  733.     ^
  734. IndentationError: unexpected indent
  735. >>>
  736. >>>         # show all
  737. >>>         self.show_all()
  738.   File "<input>", line 1
  739.     self.show_all()
  740.     ^
  741. IndentationError: unexpected indent
  742. >>>
  743. >>>     def run(self):
  744.   File "<input>", line 1
  745.     def run(self):
  746.     ^
  747. IndentationError: unexpected indent
  748. >>>         result = super(ConfDialog,self).run()
  749.   File "<input>", line 1
  750.     result = super(ConfDialog,self).run()
  751.     ^
  752. IndentationError: unexpected indent
  753. >>>         conf = self.last_config
  754.   File "<input>", line 1
  755.     conf = self.last_config
  756.     ^
  757. IndentationError: unexpected indent
  758. >>>
  759. >>>         if result == gtk.RESPONSE_APPLY:
  760.   File "<input>", line 1
  761.     if result == gtk.RESPONSE_APPLY:
  762.     ^
  763. IndentationError: unexpected indent
  764. >>>             conf = self.atual_config
  765.   File "<input>", line 1
  766.     conf = self.atual_config
  767.     ^
  768. IndentationError: unexpected indent
  769. >>>
  770. >>>         return result, conf
  771.   File "<input>", line 1
  772.     return result, conf
  773.     ^
  774. IndentationError: unexpected indent
  775. >>>
  776. >>> class Player():
  777. ...     """
  778. ...     This class will implement a loop to play the frames through time, after
  779. ...     play each frame, a gtk event handler is called to not freaze the UI.
  780. ...     """
  781. ...     def __init__(self,timeline,play_button):
  782. ...
  783. ...         self.timeline = timeline
  784. ...         self.play_button = play_button
  785. ...         self.cnt = 0
  786. ...
  787. >>>     def start(self):
  788.   File "<input>", line 1
  789.     def start(self):
  790.     ^
  791. IndentationError: unexpected indent
  792. >>>        
  793. >>>         while  self.timeline.is_playing:
  794.   File "<input>", line 1
  795.     while  self.timeline.is_playing:
  796.     ^
  797. IndentationError: unexpected indent
  798. >>>
  799. >>>             self.timeline.on_goto(None,NEXT)
  800.   File "<input>", line 1
  801.     self.timeline.on_goto(None,NEXT)
  802.     ^
  803. IndentationError: unexpected indent
  804. >>>
  805. >>>             # while has fixed frames jump to the next
  806. >>>             while self.timeline.frames[self.timeline.active].fixed \
  807.   File "<input>", line 1
  808.     while self.timeline.frames[self.timeline.active].fixed \
  809.     ^
  810. IndentationError: unexpected indent
  811. >>>                     and self.timeline.active < len(self.timeline.frames):
  812.   File "<input>", line 1
  813.     and self.timeline.active < len(self.timeline.frames):
  814.     ^
  815. IndentationError: unexpected indent
  816. >>>                 self.timeline.on_goto(None,NEXT)
  817.   File "<input>", line 1
  818.     self.timeline.on_goto(None,NEXT)
  819.     ^
  820. IndentationError: unexpected indent
  821. >>>
  822. >>>             # see if is the end of the timeline when theres no replay.
  823. >>>             if not self.timeline.is_replay and self.timeline.active == \
  824.   File "<input>", line 1
  825.     if not self.timeline.is_replay and self.timeline.active == \
  826.     ^
  827. IndentationError: unexpected indent
  828. >>>                     len(self.timeline.frames)-1:
  829.   File "<input>", line 1
  830.     len(self.timeline.frames)-1:
  831.     ^
  832. IndentationError: unexpected indent
  833. >>>                 self.timeline.on_toggle_play(self.play_button)
  834.   File "<input>", line 1
  835.     self.timeline.on_toggle_play(self.play_button)
  836.     ^
  837. IndentationError: unexpected indent
  838. >>>
  839. >>>             # wait some time to emulate framerate choose by the user.
  840. >>>             time.sleep(1.0/self.timeline.framerate)
  841.   File "<input>", line 1
  842.     time.sleep(1.0/self.timeline.framerate)
  843.     ^
  844. IndentationError: unexpected indent
  845. >>>
  846. >>>             # call gtk event handler.
  847. >>>             while gtk.events_pending():
  848.   File "<input>", line 1
  849.     while gtk.events_pending():
  850.     ^
  851. IndentationError: unexpected indent
  852. >>>                 gtk.main_iteration()
  853.   File "<input>", line 1
  854.     gtk.main_iteration()
  855.     ^
  856. IndentationError: unexpected indent
  857. >>>
  858. >>>
  859. >>> class AnimFrame(gtk.EventBox):
  860. ...     """
  861. ...     A Frame representation for gtk.
  862. ...     """
  863. ...     def __init__(self,layer,width=100,height=120):
  864. ...         gtk.EventBox.__init__(self)
  865. ...         self.set_size_request(width,height)
  866. ...         #variables
  867. ...         self.thumbnail = None
  868. ...         self.label = None
  869. ...         self.layer = layer
  870. ...         self.fixed = False
  871. ...
  872. >>>         self._fix_button_images = []
  873.   File "<input>", line 1
  874.     self._fix_button_images = []
  875.     ^
  876. IndentationError: unexpected indent
  877. >>>         self._fix_button = None
  878.   File "<input>", line 1
  879.     self._fix_button = None
  880.     ^
  881. IndentationError: unexpected indent
  882. >>>         self._setup()
  883.   File "<input>", line 1
  884.     self._setup()
  885.     ^
  886. IndentationError: unexpected indent
  887. >>>
  888. >>>     def highlight(self,state):
  889.   File "<input>", line 1
  890.     def highlight(self,state):
  891.     ^
  892. IndentationError: unexpected indent
  893. >>>         if state:
  894.   File "<input>", line 1
  895.     if state:
  896.     ^
  897. IndentationError: unexpected indent
  898. >>>             self.set_state(gtk.STATE_SELECTED)
  899.   File "<input>", line 1
  900.     self.set_state(gtk.STATE_SELECTED)
  901.     ^
  902. IndentationError: unexpected indent
  903. >>>         else :
  904.   File "<input>", line 1
  905.     else :
  906.     ^
  907. IndentationError: unexpected indent
  908. >>>             self.set_state(gtk.STATE_NORMAL)
  909.   File "<input>", line 1
  910.     self.set_state(gtk.STATE_NORMAL)
  911.     ^
  912. IndentationError: unexpected indent
  913. >>>
  914. >>>     def on_toggle_fix(self,widget):
  915.   File "<input>", line 1
  916.     def on_toggle_fix(self,widget):
  917.     ^
  918. IndentationError: unexpected indent
  919. >>>         self.fixed = widget.get_active()
  920.   File "<input>", line 1
  921.     self.fixed = widget.get_active()
  922.     ^
  923. IndentationError: unexpected indent
  924. >>>         if widget.get_active():
  925.   File "<input>", line 1
  926.     if widget.get_active():
  927.     ^
  928. IndentationError: unexpected indent
  929. >>>             Utils.add_fixed_prefix(self.layer)
  930.   File "<input>", line 1
  931.     Utils.add_fixed_prefix(self.layer)
  932.     ^
  933. IndentationError: unexpected indent
  934. >>>             self._fix_button.set_image(self._fix_button_images[0])
  935.   File "<input>", line 1
  936.     self._fix_button.set_image(self._fix_button_images[0])
  937.     ^
  938. IndentationError: unexpected indent
  939. >>>         else:
  940.   File "<input>", line 1
  941.     else:
  942.     ^
  943. IndentationError: unexpected indent
  944. >>>             Utils.rem_fixed_prefix(self.layer)
  945.   File "<input>", line 1
  946.     Utils.rem_fixed_prefix(self.layer)
  947.     ^
  948. IndentationError: unexpected indent
  949. >>>             self._fix_button.set_image(self._fix_button_images[1])
  950.   File "<input>", line 1
  951.     self._fix_button.set_image(self._fix_button_images[1])
  952.     ^
  953. IndentationError: unexpected indent
  954. >>>
  955. >>>     def _setup(self):
  956.   File "<input>", line 1
  957.     def _setup(self):
  958.     ^
  959. IndentationError: unexpected indent
  960. >>>         self.thumbnail = gtk.Image()
  961.   File "<input>", line 1
  962.     self.thumbnail = gtk.Image()
  963.     ^
  964. IndentationError: unexpected indent
  965. >>>         self.label = gtk.Label(self.layer.name)
  966.   File "<input>", line 1
  967.     self.label = gtk.Label(self.layer.name)
  968.     ^
  969. IndentationError: unexpected indent
  970. >>>         # creating the fix button, to anchor background frames.
  971. >>>         icon_size = gtk.ICON_SIZE_MENU
  972.   File "<input>", line 1
  973.     icon_size = gtk.ICON_SIZE_MENU
  974.     ^
  975. IndentationError: unexpected indent
  976. >>>         self._fix_button = Utils.toggle_button_stock(gtk.STOCK_NO, icon_size)
  977.   File "<input>", line 1
  978.     self._fix_button = Utils.toggle_button_stock(gtk.STOCK_NO, icon_size)
  979.     ^
  980. IndentationError: unexpected indent
  981. >>>         self._fix_button.set_tooltip_text("toggle fixed visibility.")
  982.   File "<input>", line 1
  983.     self._fix_button.set_tooltip_text("toggle fixed visibility.")
  984.     ^
  985. IndentationError: unexpected indent
  986. >>>
  987. >>>         # update fixed variable
  988. >>>         self.fixed = Utils.is_frame_fixed(self.layer)
  989.   File "<input>", line 1
  990.     self.fixed = Utils.is_frame_fixed(self.layer)
  991.     ^
  992. IndentationError: unexpected indent
  993. >>>         #images
  994. >>>         self._fix_button_images = [gtk.Image(), gtk.Image()]
  995.   File "<input>", line 1
  996.     self._fix_button_images = [gtk.Image(), gtk.Image()]
  997.     ^
  998. IndentationError: unexpected indent
  999. >>>         self._fix_button_images[0].set_from_stock(gtk.STOCK_YES, icon_size)
  1000.   File "<input>", line 1
  1001.     self._fix_button_images[0].set_from_stock(gtk.STOCK_YES, icon_size)
  1002.     ^
  1003. IndentationError: unexpected indent
  1004. >>>         self._fix_button_images[1].set_from_stock(gtk.STOCK_NO, icon_size)
  1005.   File "<input>", line 1
  1006.     self._fix_button_images[1].set_from_stock(gtk.STOCK_NO, icon_size)
  1007.     ^
  1008. IndentationError: unexpected indent
  1009. >>>
  1010. >>>         ## connect
  1011. >>>         self._fix_button.connect('clicked',self.on_toggle_fix)
  1012.   File "<input>", line 1
  1013.     self._fix_button.connect('clicked',self.on_toggle_fix)
  1014.     ^
  1015. IndentationError: unexpected indent
  1016. >>>
  1017. >>>         if self.fixed:
  1018.   File "<input>", line 1
  1019.     if self.fixed:
  1020.     ^
  1021. IndentationError: unexpected indent
  1022. >>>             self._fix_button.set_image(self._fix_button_images[0])
  1023.   File "<input>", line 1
  1024.     self._fix_button.set_image(self._fix_button_images[0])
  1025.     ^
  1026. IndentationError: unexpected indent
  1027. >>>             self._fix_button.set_active(True)
  1028.   File "<input>", line 1
  1029.     self._fix_button.set_active(True)
  1030.     ^
  1031. IndentationError: unexpected indent
  1032. >>>         else :
  1033.   File "<input>", line 1
  1034.     else :
  1035.     ^
  1036. IndentationError: unexpected indent
  1037. >>>             self._fix_button.set_image(self._fix_button_images[1])
  1038.   File "<input>", line 1
  1039.     self._fix_button.set_image(self._fix_button_images[1])
  1040.     ^
  1041. IndentationError: unexpected indent
  1042. >>>             self._fix_button.set_active(False)
  1043.   File "<input>", line 1
  1044.     self._fix_button.set_active(False)
  1045.     ^
  1046. IndentationError: unexpected indent
  1047. >>>
  1048. >>>         frame = gtk.Frame()
  1049.   File "<input>", line 1
  1050.     frame = gtk.Frame()
  1051.     ^
  1052. IndentationError: unexpected indent
  1053. >>>         layout = gtk.VBox()
  1054.   File "<input>", line 1
  1055.     layout = gtk.VBox()
  1056.     ^
  1057. IndentationError: unexpected indent
  1058. >>>         # add frame to this widget
  1059. >>>         self.add(frame)
  1060.   File "<input>", line 1
  1061.     self.add(frame)
  1062.     ^
  1063. IndentationError: unexpected indent
  1064. >>>
  1065. >>>         # add layout manager to the frame
  1066. >>>         frame.add(layout)
  1067.   File "<input>", line 1
  1068.     frame.add(layout)
  1069.     ^
  1070. IndentationError: unexpected indent
  1071. >>>
  1072. >>>         layout.pack_start(self.label)
  1073.   File "<input>", line 1
  1074.     layout.pack_start(self.label)
  1075.     ^
  1076. IndentationError: unexpected indent
  1077. >>>         layout.pack_start(self.thumbnail)
  1078.   File "<input>", line 1
  1079.     layout.pack_start(self.thumbnail)
  1080.     ^
  1081. IndentationError: unexpected indent
  1082. >>>         layout.pack_start(self._fix_button)
  1083.   File "<input>", line 1
  1084.     layout.pack_start(self._fix_button)
  1085.     ^
  1086. IndentationError: unexpected indent
  1087. >>>         self._get_thumb_image()
  1088.   File "<input>", line 1
  1089.     self._get_thumb_image()
  1090.     ^
  1091. IndentationError: unexpected indent
  1092. >>>
  1093. >>>     def _get_thumb_image(self):
  1094.   File "<input>", line 1
  1095.     def _get_thumb_image(self):
  1096.     ^
  1097. IndentationError: unexpected indent
  1098. >>>         """
  1099.  File "<input>", line 1
  1100.    """
  1101.     ^
  1102. IndentationError: unexpected indent
  1103. >>>         convert the pixel info returned by python into a gtk image to be
  1104.   File "<input>", line 1
  1105.     convert the pixel info returned by python into a gtk image to be
  1106.     ^
  1107. IndentationError: unexpected indent
  1108. >>>         showed.
  1109.   File "<input>", line 1
  1110.     showed.
  1111.     ^
  1112. IndentationError: unexpected indent
  1113. >>>         """
  1114.  File "<input>", line 1
  1115.    """
  1116.     ^
  1117. IndentationError: unexpected indent
  1118. >>>         width = 100
  1119.   File "<input>", line 1
  1120.     width = 100
  1121.     ^
  1122. IndentationError: unexpected indent
  1123. >>>         height = 100
  1124.   File "<input>", line 1
  1125.     height = 100
  1126.     ^
  1127. IndentationError: unexpected indent
  1128. >>>         image_data = pdb.gimp_drawable_thumbnail(self.layer,width,height)
  1129.   File "<input>", line 1
  1130.     image_data = pdb.gimp_drawable_thumbnail(self.layer,width,height)
  1131.     ^
  1132. IndentationError: unexpected indent
  1133. >>>
  1134. >>>         w,h,c,data = image_data[0],image_data[1],image_data[2],image_data[4]
  1135.   File "<input>", line 1
  1136.     w,h,c,data = image_data[0],image_data[1],image_data[2],image_data[4]
  1137.     ^
  1138. IndentationError: unexpected indent
  1139. >>>
  1140. >>>         # create a array of unsigned 8bit data.
  1141. >>>         image_array = array.array('B',data)
  1142.   File "<input>", line 1
  1143.     image_array = array.array('B',data)
  1144.     ^
  1145. IndentationError: unexpected indent
  1146. >>>
  1147. >>>         pixbuf = gtk.gdk.pixbuf_new_from_data(image_array,gtk.gdk.COLORSPACE_RGB,c>3,8,w,h,w*c)
  1148.   File "<input>", line 1
  1149.     pixbuf = gtk.gdk.pixbuf_new_from_data(image_array,gtk.gdk.COLORSPACE_RGB,c>3,8,w,h,w*c)
  1150.     ^
  1151. IndentationError: unexpected indent
  1152. >>>         self.thumbnail.set_from_pixbuf(pixbuf)
  1153.   File "<input>", line 1
  1154.     self.thumbnail.set_from_pixbuf(pixbuf)
  1155.     ^
  1156. IndentationError: unexpected indent
  1157. >>>
  1158. >>>     def update_layer_info(self):
  1159.   File "<input>", line 1
  1160.     def update_layer_info(self):
  1161.     ^
  1162. IndentationError: unexpected indent
  1163. >>>         self._get_thumb_image()
  1164.   File "<input>", line 1
  1165.     self._get_thumb_image()
  1166.     ^
  1167. IndentationError: unexpected indent
  1168. >>>
  1169. >>> class Timeline(gtk.Window):
  1170. ...     def __init__(self,title,image):
  1171. ...         gtk.Window.__init__(self,gtk.WINDOW_TOPLEVEL)
  1172. ...
  1173. >>>         self.set_title(title)
  1174.   File "<input>", line 1
  1175.     self.set_title(title)
  1176.     ^
  1177. IndentationError: unexpected indent
  1178. >>>         self.image = image
  1179.   File "<input>", line 1
  1180.     self.image = image
  1181.     ^
  1182. IndentationError: unexpected indent
  1183. >>>         self.frame_bar = None
  1184.   File "<input>", line 1
  1185.     self.frame_bar = None
  1186.     ^
  1187. IndentationError: unexpected indent
  1188. >>>         # variables
  1189. >>>         self.is_playing = False
  1190.   File "<input>", line 1
  1191.     self.is_playing = False
  1192.     ^
  1193. IndentationError: unexpected indent
  1194. >>>         self.is_replay = False
  1195.   File "<input>", line 1
  1196.     self.is_replay = False
  1197.     ^
  1198. IndentationError: unexpected indent
  1199. >>>         # modifiable widgets
  1200. >>>         self.play_button_images = []
  1201.   File "<input>", line 1
  1202.     self.play_button_images = []
  1203.     ^
  1204. IndentationError: unexpected indent
  1205. >>>         self.widgets_to_disable = [] # widgets to disable when playing
  1206.   File "<input>", line 1
  1207.     self.widgets_to_disable = [] # widgets to disable when playing
  1208.     ^
  1209. IndentationError: unexpected indent
  1210. >>>         self.play_bar = None
  1211.   File "<input>", line 1
  1212.     self.play_bar = None
  1213.     ^
  1214. IndentationError: unexpected indent
  1215. >>>        
  1216. >>>         # frames
  1217. >>>         self.frames = [] # all frame widgets
  1218.   File "<input>", line 1
  1219.     self.frames = [] # all frame widgets
  1220.     ^
  1221. IndentationError: unexpected indent
  1222. >>>         self.active = None  # active frame / gimp layer
  1223.   File "<input>", line 1
  1224.     self.active = None  # active frame / gimp layer
  1225.     ^
  1226. IndentationError: unexpected indent
  1227. >>>         self.before_play = None # active frame before play
  1228.   File "<input>", line 1
  1229.     self.before_play = None # active frame before play
  1230.     ^
  1231. IndentationError: unexpected indent
  1232. >>>
  1233. >>>         self.framerate = 30
  1234.   File "<input>", line 1
  1235.     self.framerate = 30
  1236.     ^
  1237. IndentationError: unexpected indent
  1238. >>>
  1239. >>>         # new frame.
  1240. >>>         self.new_layer_type = TRANSPARENT_FILL
  1241.   File "<input>", line 1
  1242.     self.new_layer_type = TRANSPARENT_FILL
  1243.     ^
  1244. IndentationError: unexpected indent
  1245. >>>
  1246. >>>         # onionskin variables
  1247. >>>         self.oskin = False
  1248.   File "<input>", line 1
  1249.     self.oskin = False
  1250.     ^
  1251. IndentationError: unexpected indent
  1252. >>>         self.oskin_depth = 2
  1253.   File "<input>", line 1
  1254.     self.oskin_depth = 2
  1255.     ^
  1256. IndentationError: unexpected indent
  1257. >>>         self.oskin_backward = True
  1258.   File "<input>", line 1
  1259.     self.oskin_backward = True
  1260.     ^
  1261. IndentationError: unexpected indent
  1262. >>>         self.oskin_forward = False
  1263.   File "<input>", line 1
  1264.     self.oskin_forward = False
  1265.     ^
  1266. IndentationError: unexpected indent
  1267. >>>         self.oskin_max_opacity = OSKIN_MAX_OPACITY
  1268.   File "<input>", line 1
  1269.     self.oskin_max_opacity = OSKIN_MAX_OPACITY
  1270.     ^
  1271. IndentationError: unexpected indent
  1272. >>>         self.oskin_onplay= True
  1273.   File "<input>", line 1
  1274.     self.oskin_onplay= True
  1275.     ^
  1276. IndentationError: unexpected indent
  1277. >>>
  1278. >>>         self.player = None
  1279.   File "<input>", line 1
  1280.     self.player = None
  1281.     ^
  1282. IndentationError: unexpected indent
  1283. >>>
  1284. >>>         # gtk window
  1285. >>>         self.win_pos = (20,20)
  1286.   File "<input>", line 1
  1287.     self.win_pos = (20,20)
  1288.     ^
  1289. IndentationError: unexpected indent
  1290. >>>         self.win_size = (200,200)
  1291.   File "<input>", line 1
  1292.     self.win_size = (200,200)
  1293.     ^
  1294. IndentationError: unexpected indent
  1295. >>>         # create all widgets
  1296. >>>         self._setup_widgets()
  1297.   File "<input>", line 1
  1298.     self._setup_widgets()
  1299.     ^
  1300. IndentationError: unexpected indent
  1301. >>>     def undo(self, state):
  1302.   File "<input>", line 1
  1303.     def undo(self, state):
  1304.     ^
  1305. IndentationError: unexpected indent
  1306. >>>         if state:
  1307.   File "<input>", line 1
  1308.     if state:
  1309.     ^
  1310. IndentationError: unexpected indent
  1311. >>>             self.image.undo_thaw()
  1312.   File "<input>", line 1
  1313.     self.image.undo_thaw()
  1314.     ^
  1315. IndentationError: unexpected indent
  1316. >>>         else:
  1317.   File "<input>", line 1
  1318.     else:
  1319.     ^
  1320. IndentationError: unexpected indent
  1321. >>>             self.image.undo_freeze()
  1322.   File "<input>", line 1
  1323.     self.image.undo_freeze()
  1324.     ^
  1325. IndentationError: unexpected indent
  1326. >>>
  1327. >>>     def destroy(self,widget):
  1328.   File "<input>", line 1
  1329.     def destroy(self,widget):
  1330.     ^
  1331. IndentationError: unexpected indent
  1332. >>>         # if is closing and still playing try to stop and send a message with info.
  1333. >>>         if self.is_playing:
  1334.   File "<input>", line 1
  1335.     if self.is_playing:
  1336.     ^
  1337. IndentationError: unexpected indent
  1338. >>>             self.is_playing = False
  1339.   File "<input>", line 1
  1340.     self.is_playing = False
  1341.     ^
  1342. IndentationError: unexpected indent
  1343. >>>             gimp.message("Please do not close the image with FAnim playing the animation.")
  1344.   File "<input>", line 1
  1345.     gimp.message("Please do not close the image with FAnim playing the animation.")
  1346.     ^
  1347. IndentationError: unexpected indent
  1348. >>>         if widget != False:# for when this function is called without valid image variable.
  1349.   File "<input>", line 1
  1350.     if widget != False:# for when this function is called without valid image variable.
  1351.     ^
  1352. IndentationError: unexpected indent
  1353. >>>             # return to the normal layers order.
  1354. >>>             pdb.script_fu_reverse_layers(self.image,None)
  1355.   File "<input>", line 1
  1356.     pdb.script_fu_reverse_layers(self.image,None)
  1357.     ^
  1358. IndentationError: unexpected indent
  1359. >>>             self.on_goto(None,START)
  1360.   File "<input>", line 1
  1361.     self.on_goto(None,START)
  1362.     ^
  1363. IndentationError: unexpected indent
  1364. >>>
  1365. >>>         #save the settings before quit.
  1366. >>>         Utils.save_conffile(CONF_FILENAME,self.get_settings())
  1367.   File "<input>", line 1
  1368.     Utils.save_conffile(CONF_FILENAME,self.get_settings())
  1369.     ^
  1370. IndentationError: unexpected indent
  1371. >>>
  1372. >>>         gtk.main_quit()
  1373.   File "<input>", line 1
  1374.     gtk.main_quit()
  1375.     ^
  1376. IndentationError: unexpected indent
  1377. >>>
  1378. >>>     def start(self):
  1379.   File "<input>", line 1
  1380.     def start(self):
  1381.     ^
  1382. IndentationError: unexpected indent
  1383. >>>         gtk.main()
  1384.   File "<input>", line 1
  1385.     gtk.main()
  1386.     ^
  1387. IndentationError: unexpected indent
  1388. >>>
  1389. >>>     def _get_theme_gtkrc(self,themerc):
  1390.   File "<input>", line 1
  1391.     def _get_theme_gtkrc(self,themerc):
  1392.     ^
  1393. IndentationError: unexpected indent
  1394. >>>         rcpath = ""
  1395.   File "<input>", line 1
  1396.     rcpath = ""
  1397.     ^
  1398. IndentationError: unexpected indent
  1399. >>>         with  open(themerc,'r') as trc:
  1400.   File "<input>", line 1
  1401.     with  open(themerc,'r') as trc:
  1402.     ^
  1403. IndentationError: unexpected indent
  1404. >>>             for l in trc.readlines():
  1405.   File "<input>", line 1
  1406.     for l in trc.readlines():
  1407.     ^
  1408. IndentationError: unexpected indent
  1409. >>>                 if l[:7] == "include":
  1410.   File "<input>", line 1
  1411.     if l[:7] == "include":
  1412.     ^
  1413. IndentationError: unexpected indent
  1414. >>>                     rcpath = l[9:-2]
  1415.   File "<input>", line 1
  1416.     rcpath = l[9:-2]
  1417.     ^
  1418. IndentationError: unexpected indent
  1419. >>>                     break
  1420.   File "<input>", line 1
  1421.     break
  1422.     ^
  1423. IndentationError: unexpected indent
  1424. >>>         return rcpath
  1425.   File "<input>", line 1
  1426.     return rcpath
  1427.     ^
  1428. IndentationError: unexpected indent
  1429. >>>
  1430. >>>     def on_window_resize(self,*args):
  1431.   File "<input>", line 1
  1432.     def on_window_resize(self,*args):
  1433.     ^
  1434. IndentationError: unexpected indent
  1435. >>>         # update the window position  to save later on.
  1436. >>>         self.win_pos = self.get_position()
  1437.   File "<input>", line 1
  1438.     self.win_pos = self.get_position()
  1439.     ^
  1440. IndentationError: unexpected indent
  1441. >>>
  1442. >>>     def _setup_widgets(self):
  1443.   File "<input>", line 1
  1444.     def _setup_widgets(self):
  1445.     ^
  1446. IndentationError: unexpected indent
  1447. >>>         """
  1448.  File "<input>", line 1
  1449.    """
  1450.     ^
  1451. IndentationError: unexpected indent
  1452. >>>         create all the window staticaly placed widgets.
  1453.   File "<input>", line 1
  1454.     create all the window staticaly placed widgets.
  1455.     ^
  1456. IndentationError: unexpected indent
  1457. >>>         """
  1458.  File "<input>", line 1
  1459.    """
  1460.     ^
  1461. IndentationError: unexpected indent
  1462. >>>         #load the saved setting before start.
  1463. >>>         self.set_settings(Utils.load_conffile(CONF_FILENAME))
  1464.   File "<input>", line 1
  1465.     self.set_settings(Utils.load_conffile(CONF_FILENAME))
  1466.     ^
  1467. IndentationError: unexpected indent
  1468. >>>
  1469. >>>         # basic window definitions
  1470. >>>         self.connect("destroy",self.destroy)
  1471.   File "<input>", line 1
  1472.     self.connect("destroy",self.destroy)
  1473.     ^
  1474. IndentationError: unexpected indent
  1475. >>>         self.connect("focus_in_event",self.on_window_focus)
  1476.   File "<input>", line 1
  1477.     self.connect("focus_in_event",self.on_window_focus)
  1478.     ^
  1479. IndentationError: unexpected indent
  1480. >>>         self.connect("configure_event",self.on_window_resize)
  1481.   File "<input>", line 1
  1482.     self.connect("configure_event",self.on_window_resize)
  1483.     ^
  1484. IndentationError: unexpected indent
  1485. >>>
  1486. >>>         self.set_default_size(self.win_size[0],self.win_size[1])
  1487.   File "<input>", line 1
  1488.     self.set_default_size(self.win_size[0],self.win_size[1])
  1489.     ^
  1490. IndentationError: unexpected indent
  1491. >>>         self.set_keep_above(True)
  1492.   File "<input>", line 1
  1493.     self.set_keep_above(True)
  1494.     ^
  1495. IndentationError: unexpected indent
  1496. >>>        
  1497. >>>         #self.set_position(gtk.WIN_POS_CENTER_ON_PARENT)
  1498. >>>         self.move(self.win_pos[0],self.win_pos[1])
  1499.   File "<input>", line 1
  1500.     self.move(self.win_pos[0],self.win_pos[1])
  1501.     ^
  1502. IndentationError: unexpected indent
  1503. >>>
  1504. >>>         # parse gimp theme gtkrc
  1505. >>>         gtkrc_path  = self._get_theme_gtkrc(gimp.personal_rc_file('themerc'))
  1506.   File "<input>", line 1
  1507.     gtkrc_path  = self._get_theme_gtkrc(gimp.personal_rc_file('themerc'))
  1508.     ^
  1509. IndentationError: unexpected indent
  1510. >>>
  1511. >>>         if  os.name != 'nt':# try apply the theme by parse a gtkrc file if is not a windows system.
  1512.   File "<input>", line 1
  1513.     if  os.name != 'nt':# try apply the theme by parse a gtkrc file if is not a windows system.
  1514.     ^
  1515. IndentationError: unexpected indent
  1516. >>>             gtk.rc_parse(gtkrc_path)
  1517.   File "<input>", line 1
  1518.     gtk.rc_parse(gtkrc_path)
  1519.     ^
  1520. IndentationError: unexpected indent
  1521. >>>         else: # if error occur them parse the file in another way.
  1522.   File "<input>", line 1
  1523.     else: # if error occur them parse the file in another way.
  1524.     ^
  1525. IndentationError: unexpected indent
  1526. >>>             gtk.rc_add_default_file(gtkrc_path)
  1527.   File "<input>", line 1
  1528.     gtk.rc_add_default_file(gtkrc_path)
  1529.     ^
  1530. IndentationError: unexpected indent
  1531. >>>             gtk.rc_reparse_all()
  1532.   File "<input>", line 1
  1533.     gtk.rc_reparse_all()
  1534.     ^
  1535. IndentationError: unexpected indent
  1536. >>>
  1537. >>>         # start creating basic layout
  1538. >>>         base = gtk.VBox()
  1539.   File "<input>", line 1
  1540.     base = gtk.VBox()
  1541.     ^
  1542. IndentationError: unexpected indent
  1543. >>>
  1544. >>>         # commands bar widgets
  1545. >>>         cbar = gtk.HBox()
  1546.   File "<input>", line 1
  1547.     cbar = gtk.HBox()
  1548.     ^
  1549. IndentationError: unexpected indent
  1550. >>>         cbar.pack_start(self._setup_playbackbar(),False,False,10)
  1551.   File "<input>", line 1
  1552.     cbar.pack_start(self._setup_playbackbar(),False,False,10)
  1553.     ^
  1554. IndentationError: unexpected indent
  1555. >>>         cbar.pack_start(self._setup_editbar(),False,False,10)
  1556.   File "<input>", line 1
  1557.     cbar.pack_start(self._setup_editbar(),False,False,10)
  1558.     ^
  1559. IndentationError: unexpected indent
  1560. >>>         cbar.pack_start(self._setup_onionskin(),False,False,10)
  1561.   File "<input>", line 1
  1562.     cbar.pack_start(self._setup_onionskin(),False,False,10)
  1563.     ^
  1564. IndentationError: unexpected indent
  1565. >>>         cbar.pack_start(self._setup_config(),False,False,10)
  1566.   File "<input>", line 1
  1567.     cbar.pack_start(self._setup_config(),False,False,10)
  1568.     ^
  1569. IndentationError: unexpected indent
  1570. >>>         cbar.pack_start(self._setup_generalbar(),False,False,10)
  1571.   File "<input>", line 1
  1572.     cbar.pack_start(self._setup_generalbar(),False,False,10)
  1573.     ^
  1574. IndentationError: unexpected indent
  1575. >>>
  1576. >>>         # frames bar widgets
  1577. >>>         self.frame_bar = gtk.HBox()
  1578.   File "<input>", line 1
  1579.     self.frame_bar = gtk.HBox()
  1580.     ^
  1581. IndentationError: unexpected indent
  1582. >>>         scroll_window = gtk.ScrolledWindow()
  1583.   File "<input>", line 1
  1584.     scroll_window = gtk.ScrolledWindow()
  1585.     ^
  1586. IndentationError: unexpected indent
  1587. >>>         scroll_window.set_policy(gtk.POLICY_AUTOMATIC,gtk.POLICY_AUTOMATIC)
  1588.   File "<input>", line 1
  1589.     scroll_window.set_policy(gtk.POLICY_AUTOMATIC,gtk.POLICY_AUTOMATIC)
  1590.     ^
  1591. IndentationError: unexpected indent
  1592. >>>         scroll_window.add_with_viewport(self.frame_bar)
  1593.   File "<input>", line 1
  1594.     scroll_window.add_with_viewport(self.frame_bar)
  1595.     ^
  1596. IndentationError: unexpected indent
  1597. >>>         scroll_window.set_size_request(-1,140)
  1598.   File "<input>", line 1
  1599.     scroll_window.set_size_request(-1,140)
  1600.     ^
  1601. IndentationError: unexpected indent
  1602. >>>
  1603. >>>         # mount the widgets together
  1604. >>>         base.pack_start(cbar,False,False,0)
  1605.   File "<input>", line 1
  1606.     base.pack_start(cbar,False,False,0)
  1607.     ^
  1608. IndentationError: unexpected indent
  1609. >>>         base.pack_start(scroll_window,True,True,0)
  1610.   File "<input>", line 1
  1611.     base.pack_start(scroll_window,True,True,0)
  1612.     ^
  1613. IndentationError: unexpected indent
  1614. >>>         self.add(base)
  1615.   File "<input>", line 1
  1616.     self.add(base)
  1617.     ^
  1618. IndentationError: unexpected indent
  1619. >>>        
  1620. >>>         # invert the image so onionskin can be used propely, with backward frames be
  1621. >>>         # above the actual frame, sinse GIMP upper layers are firstly visible they cant
  1622. >>>         # be backward frames.
  1623. >>>         pdb.script_fu_reverse_layers(self.image,None)
  1624.   File "<input>", line 1
  1625.     pdb.script_fu_reverse_layers(self.image,None)
  1626.     ^
  1627. IndentationError: unexpected indent
  1628. >>>         # scan all layers
  1629. >>>         self._scan_image_layers()
  1630.   File "<input>", line 1
  1631.     self._scan_image_layers()
  1632.     ^
  1633. IndentationError: unexpected indent
  1634. >>>         self.active = 0
  1635.   File "<input>", line 1
  1636.     self.active = 0
  1637.     ^
  1638. IndentationError: unexpected indent
  1639. >>>         self.on_goto(None,GIMP_ACTIVE)
  1640.   File "<input>", line 1
  1641.     self.on_goto(None,GIMP_ACTIVE)
  1642.     ^
  1643. IndentationError: unexpected indent
  1644. >>>
  1645. >>>         # finalize showing all widgets
  1646. >>>         self.show_all()
  1647.   File "<input>", line 1
  1648.     self.show_all()
  1649.     ^
  1650. IndentationError: unexpected indent
  1651. >>>
  1652. >>>     def _scan_image_layers(self):
  1653.   File "<input>", line 1
  1654.     def _scan_image_layers(self):
  1655.     ^
  1656. IndentationError: unexpected indent
  1657. >>>         """
  1658.  File "<input>", line 1
  1659.    """
  1660.     ^
  1661. IndentationError: unexpected indent
  1662. >>>         If exists frames this function destroys all, after that the image layers
  1663.   File "<input>", line 1
  1664.     If exists frames this function destroys all, after that the image layers
  1665.     ^
  1666. IndentationError: unexpected indent
  1667. >>>         is scanned and the frames are recreated.
  1668.   File "<input>", line 1
  1669.     is scanned and the frames are recreated.
  1670.     ^
  1671. IndentationError: unexpected indent
  1672. >>>         """
  1673.  File "<input>", line 1
  1674.    """
  1675.     ^
  1676. IndentationError: unexpected indent
  1677. >>>         self.undo(False)
  1678.   File "<input>", line 1
  1679.     self.undo(False)
  1680.     ^
  1681. IndentationError: unexpected indent
  1682. >>>
  1683. >>>         layers = self.image.layers
  1684.   File "<input>", line 1
  1685.     layers = self.image.layers
  1686.     ^
  1687. IndentationError: unexpected indent
  1688. >>>
  1689. >>>         if self.frames:
  1690.   File "<input>", line 1
  1691.     if self.frames:
  1692.     ^
  1693. IndentationError: unexpected indent
  1694. >>>             for frame in self.frames:
  1695.   File "<input>", line 1
  1696.     for frame in self.frames:
  1697.     ^
  1698. IndentationError: unexpected indent
  1699. >>>                 self.frame_bar.remove(frame)
  1700.   File "<input>", line 1
  1701.     self.frame_bar.remove(frame)
  1702.     ^
  1703. IndentationError: unexpected indent
  1704. >>>                 frame.destroy()
  1705.   File "<input>", line 1
  1706.     frame.destroy()
  1707.     ^
  1708. IndentationError: unexpected indent
  1709. >>>             self.frames = []
  1710.   File "<input>", line 1
  1711.     self.frames = []
  1712.     ^
  1713. IndentationError: unexpected indent
  1714. >>>
  1715. >>>         # here we get back the layers orders just in the timeline so the user can have
  1716. >>>         # a right interface.
  1717. >>>         for layer in reversed(layers):
  1718.   File "<input>", line 1
  1719.     for layer in reversed(layers):
  1720.     ^
  1721. IndentationError: unexpected indent
  1722. >>>             # start properties
  1723. >>>             layer.mode = NORMAL_MODE
  1724.   File "<input>", line 1
  1725.     layer.mode = NORMAL_MODE
  1726.     ^
  1727. IndentationError: unexpected indent
  1728. >>>             layer.opacity = 100.0
  1729.   File "<input>", line 1
  1730.     layer.opacity = 100.0
  1731.     ^
  1732. IndentationError: unexpected indent
  1733. >>>
  1734. >>>             # creating frame
  1735. >>>             f = AnimFrame(layer)
  1736.   File "<input>", line 1
  1737.     f = AnimFrame(layer)
  1738.     ^
  1739. IndentationError: unexpected indent
  1740. >>>             f.connect("button_press_event",self.on_click_goto)
  1741.   File "<input>", line 1
  1742.     f.connect("button_press_event",self.on_click_goto)
  1743.     ^
  1744. IndentationError: unexpected indent
  1745. >>>             self.frame_bar.pack_start(f,False,True,2)
  1746.   File "<input>", line 1
  1747.     self.frame_bar.pack_start(f,False,True,2)
  1748.     ^
  1749. IndentationError: unexpected indent
  1750. >>>             self.frames.append(f)
  1751.   File "<input>", line 1
  1752.     self.frames.append(f)
  1753.     ^
  1754. IndentationError: unexpected indent
  1755. >>>             f.show_all()
  1756.   File "<input>", line 1
  1757.     f.show_all()
  1758.     ^
  1759. IndentationError: unexpected indent
  1760. >>>         self.undo(True)
  1761.   File "<input>", line 1
  1762.     self.undo(True)
  1763.     ^
  1764. IndentationError: unexpected indent
  1765. >>>
  1766. >>>     def _setup_playbackbar(self):
  1767.   File "<input>", line 1
  1768.     def _setup_playbackbar(self):
  1769.     ^
  1770. IndentationError: unexpected indent
  1771. >>>         playback_bar = gtk.HBox()
  1772.   File "<input>", line 1
  1773.     playback_bar = gtk.HBox()
  1774.     ^
  1775. IndentationError: unexpected indent
  1776. >>>         button_size = 30
  1777.   File "<input>", line 1
  1778.     button_size = 30
  1779.     ^
  1780. IndentationError: unexpected indent
  1781. >>>         stock_size = gtk.ICON_SIZE_BUTTON
  1782.   File "<input>", line 1
  1783.     stock_size = gtk.ICON_SIZE_BUTTON
  1784.     ^
  1785. IndentationError: unexpected indent
  1786. >>>
  1787. >>>         # play button
  1788. >>>         ## append the images to a list to be used later on
  1789. >>>         self.play_button_images = [gtk.Image(), gtk.Image()]
  1790.   File "<input>", line 1
  1791.     self.play_button_images = [gtk.Image(), gtk.Image()]
  1792.     ^
  1793. IndentationError: unexpected indent
  1794. >>>         self.play_button_images[0].set_from_stock(gtk.STOCK_MEDIA_PLAY,stock_size)
  1795.   File "<input>", line 1
  1796.     self.play_button_images[0].set_from_stock(gtk.STOCK_MEDIA_PLAY,stock_size)
  1797.     ^
  1798. IndentationError: unexpected indent
  1799. >>>         self.play_button_images[1].set_from_stock(gtk.STOCK_MEDIA_PAUSE,stock_size)
  1800.   File "<input>", line 1
  1801.     self.play_button_images[1].set_from_stock(gtk.STOCK_MEDIA_PAUSE,stock_size)
  1802.     ^
  1803. IndentationError: unexpected indent
  1804. >>>
  1805. >>>         ## button
  1806. >>>         b_play = gtk.Button()
  1807.   File "<input>", line 1
  1808.     b_play = gtk.Button()
  1809.     ^
  1810. IndentationError: unexpected indent
  1811. >>>         b_play.set_image(self.play_button_images[0])
  1812.   File "<input>", line 1
  1813.     b_play.set_image(self.play_button_images[0])
  1814.     ^
  1815. IndentationError: unexpected indent
  1816. >>>         b_play.set_size_request(button_size,button_size)
  1817.   File "<input>", line 1
  1818.     b_play.set_size_request(button_size,button_size)
  1819.     ^
  1820. IndentationError: unexpected indent
  1821. >>>
  1822. >>>         b_tostart = Utils.button_stock(gtk.STOCK_MEDIA_PREVIOUS,stock_size)
  1823.   File "<input>", line 1
  1824.     b_tostart = Utils.button_stock(gtk.STOCK_MEDIA_PREVIOUS,stock_size)
  1825.     ^
  1826. IndentationError: unexpected indent
  1827. >>>         b_toend = Utils.button_stock(gtk.STOCK_MEDIA_NEXT,stock_size)
  1828.   File "<input>", line 1
  1829.     b_toend = Utils.button_stock(gtk.STOCK_MEDIA_NEXT,stock_size)
  1830.     ^
  1831. IndentationError: unexpected indent
  1832. >>>         b_prev = Utils.button_stock(gtk.STOCK_MEDIA_REWIND,stock_size)
  1833.   File "<input>", line 1
  1834.     b_prev = Utils.button_stock(gtk.STOCK_MEDIA_REWIND,stock_size)
  1835.     ^
  1836. IndentationError: unexpected indent
  1837. >>>         b_next = Utils.button_stock(gtk.STOCK_MEDIA_FORWARD,stock_size)
  1838.   File "<input>", line 1
  1839.     b_next = Utils.button_stock(gtk.STOCK_MEDIA_FORWARD,stock_size)
  1840.     ^
  1841. IndentationError: unexpected indent
  1842. >>>
  1843. >>>         b_repeat = Utils.toggle_button_stock(gtk.STOCK_REFRESH,stock_size)
  1844.   File "<input>", line 1
  1845.     b_repeat = Utils.toggle_button_stock(gtk.STOCK_REFRESH,stock_size)
  1846.     ^
  1847. IndentationError: unexpected indent
  1848. >>>
  1849. >>>         # connecting the button with callback
  1850. >>>         b_play.connect('clicked',self.on_toggle_play)
  1851.   File "<input>", line 1
  1852.     b_play.connect('clicked',self.on_toggle_play)
  1853.     ^
  1854. IndentationError: unexpected indent
  1855. >>>         b_repeat.connect('toggled',self.on_replay)
  1856.   File "<input>", line 1
  1857.     b_repeat.connect('toggled',self.on_replay)
  1858.     ^
  1859. IndentationError: unexpected indent
  1860. >>>
  1861. >>>         b_next.connect('clicked',self.on_goto,NEXT,True)
  1862.   File "<input>", line 1
  1863.     b_next.connect('clicked',self.on_goto,NEXT,True)
  1864.     ^
  1865. IndentationError: unexpected indent
  1866. >>>         b_prev.connect('clicked',self.on_goto,PREV,True)
  1867.   File "<input>", line 1
  1868.     b_prev.connect('clicked',self.on_goto,PREV,True)
  1869.     ^
  1870. IndentationError: unexpected indent
  1871. >>>         b_toend.connect('clicked',self.on_goto,END,True)
  1872.   File "<input>", line 1
  1873.     b_toend.connect('clicked',self.on_goto,END,True)
  1874.     ^
  1875. IndentationError: unexpected indent
  1876. >>>         b_tostart.connect('clicked',self.on_goto,START,True)
  1877.   File "<input>", line 1
  1878.     b_tostart.connect('clicked',self.on_goto,START,True)
  1879.     ^
  1880. IndentationError: unexpected indent
  1881. >>>
  1882. >>>
  1883. >>>         # add to the disable on play list
  1884. >>>         w = [b_repeat,b_prev,b_next,b_tostart,b_toend]
  1885.   File "<input>", line 1
  1886.     w = [b_repeat,b_prev,b_next,b_tostart,b_toend]
  1887.     ^
  1888. IndentationError: unexpected indent
  1889. >>>         map(lambda x: self.widgets_to_disable.append(x),w)
  1890.   File "<input>", line 1
  1891.     map(lambda x: self.widgets_to_disable.append(x),w)
  1892.     ^
  1893. IndentationError: unexpected indent
  1894. >>>         self.play_bar = playback_bar
  1895.   File "<input>", line 1
  1896.     self.play_bar = playback_bar
  1897.     ^
  1898. IndentationError: unexpected indent
  1899. >>>
  1900. >>>         # set the tooltips
  1901. >>>         b_play.set_tooltip_text("Animation play/pause")
  1902.   File "<input>", line 1
  1903.     b_play.set_tooltip_text("Animation play/pause")
  1904.     ^
  1905. IndentationError: unexpected indent
  1906. >>>         b_repeat.set_tooltip_text("Animation replay active/deactive")
  1907.   File "<input>", line 1
  1908.     b_repeat.set_tooltip_text("Animation replay active/deactive")
  1909.     ^
  1910. IndentationError: unexpected indent
  1911. >>>         b_prev.set_tooltip_text("To the previous frame")
  1912.   File "<input>", line 1
  1913.     b_prev.set_tooltip_text("To the previous frame")
  1914.     ^
  1915. IndentationError: unexpected indent
  1916. >>>         b_next.set_tooltip_text("To the next frame")
  1917.   File "<input>", line 1
  1918.     b_next.set_tooltip_text("To the next frame")
  1919.     ^
  1920. IndentationError: unexpected indent
  1921. >>>         b_tostart.set_tooltip_text("To the start frame")
  1922.   File "<input>", line 1
  1923.     b_tostart.set_tooltip_text("To the start frame")
  1924.     ^
  1925. IndentationError: unexpected indent
  1926. >>>         b_toend.set_tooltip_text("To the end frame")
  1927.   File "<input>", line 1
  1928.     b_toend.set_tooltip_text("To the end frame")
  1929.     ^
  1930. IndentationError: unexpected indent
  1931. >>>
  1932. >>>         # packing everything in gbar
  1933. >>>         w = [b_tostart, b_prev, b_play, b_next, b_toend, b_repeat]
  1934.   File "<input>", line 1
  1935.     w = [b_tostart, b_prev, b_play, b_next, b_toend, b_repeat]
  1936.     ^
  1937. IndentationError: unexpected indent
  1938. >>>         map(lambda x: playback_bar.pack_start(x,False,False,0), w)
  1939.   File "<input>", line 1
  1940.     map(lambda x: playback_bar.pack_start(x,False,False,0), w)
  1941.     ^
  1942. IndentationError: unexpected indent
  1943. >>>         return playback_bar
  1944.   File "<input>", line 1
  1945.     return playback_bar
  1946.     ^
  1947. IndentationError: unexpected indent
  1948. >>>
  1949. >>>     def _setup_editbar(self):
  1950.   File "<input>", line 1
  1951.     def _setup_editbar(self):
  1952.     ^
  1953. IndentationError: unexpected indent
  1954. >>>         stock_size = gtk.ICON_SIZE_BUTTON
  1955.   File "<input>", line 1
  1956.     stock_size = gtk.ICON_SIZE_BUTTON
  1957.     ^
  1958. IndentationError: unexpected indent
  1959. >>>         edit_bar = gtk.HBox()
  1960.   File "<input>", line 1
  1961.     edit_bar = gtk.HBox()
  1962.     ^
  1963. IndentationError: unexpected indent
  1964. >>>        
  1965. >>>         b_back = Utils.button_stock(gtk.STOCK_GO_BACK,stock_size)
  1966.   File "<input>", line 1
  1967.     b_back = Utils.button_stock(gtk.STOCK_GO_BACK,stock_size)
  1968.     ^
  1969. IndentationError: unexpected indent
  1970. >>>         b_forward = Utils.button_stock(gtk.STOCK_GO_FORWARD,stock_size)
  1971.   File "<input>", line 1
  1972.     b_forward = Utils.button_stock(gtk.STOCK_GO_FORWARD,stock_size)
  1973.     ^
  1974. IndentationError: unexpected indent
  1975. >>>         b_rem = Utils.button_stock(gtk.STOCK_REMOVE,stock_size)
  1976.   File "<input>", line 1
  1977.     b_rem = Utils.button_stock(gtk.STOCK_REMOVE,stock_size)
  1978.     ^
  1979. IndentationError: unexpected indent
  1980. >>>         b_add = Utils.button_stock(gtk.STOCK_ADD,stock_size)
  1981.   File "<input>", line 1
  1982.     b_add = Utils.button_stock(gtk.STOCK_ADD,stock_size)
  1983.     ^
  1984. IndentationError: unexpected indent
  1985. >>>         b_copy = Utils.button_stock(gtk.STOCK_COPY,stock_size)
  1986.   File "<input>", line 1
  1987.     b_copy = Utils.button_stock(gtk.STOCK_COPY,stock_size)
  1988.     ^
  1989. IndentationError: unexpected indent
  1990. >>>
  1991. >>>         # add to the disable on play list
  1992. >>>         w = [b_back,b_forward,b_rem,b_add,b_copy]
  1993.   File "<input>", line 1
  1994.     w = [b_back,b_forward,b_rem,b_add,b_copy]
  1995.     ^
  1996. IndentationError: unexpected indent
  1997. >>>         map(lambda x: self.widgets_to_disable.append(x),w)
  1998.   File "<input>", line 1
  1999.     map(lambda x: self.widgets_to_disable.append(x),w)
  2000.     ^
  2001. IndentationError: unexpected indent
  2002. >>>
  2003. >>>         # connect callbacks:
  2004. >>>         b_rem.connect("clicked",self.on_remove) # remove frame
  2005.   File "<input>", line 1
  2006.     b_rem.connect("clicked",self.on_remove) # remove frame
  2007.     ^
  2008. IndentationError: unexpected indent
  2009. >>>         b_add.connect("clicked",self.on_add) # add frame
  2010.   File "<input>", line 1
  2011.     b_add.connect("clicked",self.on_add) # add frame
  2012.     ^
  2013. IndentationError: unexpected indent
  2014. >>>         b_copy.connect("clicked",self.on_add,True) # add frame
  2015.   File "<input>", line 1
  2016.     b_copy.connect("clicked",self.on_add,True) # add frame
  2017.     ^
  2018. IndentationError: unexpected indent
  2019. >>>         b_back.connect("clicked",self.on_move,PREV)
  2020.   File "<input>", line 1
  2021.     b_back.connect("clicked",self.on_move,PREV)
  2022.     ^
  2023. IndentationError: unexpected indent
  2024. >>>         b_forward.connect("clicked",self.on_move,NEXT)
  2025.   File "<input>", line 1
  2026.     b_forward.connect("clicked",self.on_move,NEXT)
  2027.     ^
  2028. IndentationError: unexpected indent
  2029. >>>
  2030. >>>         # tooltips
  2031. >>>         b_rem.set_tooltip_text("Remove a frame/layer")
  2032.   File "<input>", line 1
  2033.     b_rem.set_tooltip_text("Remove a frame/layer")
  2034.     ^
  2035. IndentationError: unexpected indent
  2036. >>>         b_add.set_tooltip_text("Add a frame/layer")
  2037.   File "<input>", line 1
  2038.     b_add.set_tooltip_text("Add a frame/layer")
  2039.     ^
  2040. IndentationError: unexpected indent
  2041. >>>         b_copy.set_tooltip_text("Duplicate the atual selected frame")
  2042.   File "<input>", line 1
  2043.     b_copy.set_tooltip_text("Duplicate the atual selected frame")
  2044.     ^
  2045. IndentationError: unexpected indent
  2046. >>>         b_back.set_tooltip_text("Move the atual selected frame backward")
  2047.   File "<input>", line 1
  2048.     b_back.set_tooltip_text("Move the atual selected frame backward")
  2049.     ^
  2050. IndentationError: unexpected indent
  2051. >>>         b_forward.set_tooltip_text("Move the atual selected frame forward")
  2052.   File "<input>", line 1
  2053.     b_forward.set_tooltip_text("Move the atual selected frame forward")
  2054.     ^
  2055. IndentationError: unexpected indent
  2056. >>>
  2057. >>>         # packing everything in gbar
  2058. >>>         map(lambda x: edit_bar.pack_start(x,False,False,0),w)
  2059.   File "<input>", line 1
  2060.     map(lambda x: edit_bar.pack_start(x,False,False,0),w)
  2061.     ^
  2062. IndentationError: unexpected indent
  2063. >>>         return edit_bar
  2064.   File "<input>", line 1
  2065.     return edit_bar
  2066.     ^
  2067. IndentationError: unexpected indent
  2068. >>>
  2069. >>>     def _setup_config(self):
  2070.   File "<input>", line 1
  2071.     def _setup_config(self):
  2072.     ^
  2073. IndentationError: unexpected indent
  2074. >>>         stock_size = gtk.ICON_SIZE_BUTTON
  2075.   File "<input>", line 1
  2076.     stock_size = gtk.ICON_SIZE_BUTTON
  2077.     ^
  2078. IndentationError: unexpected indent
  2079. >>>         config_bar = gtk.HBox()
  2080.   File "<input>", line 1
  2081.     config_bar = gtk.HBox()
  2082.     ^
  2083. IndentationError: unexpected indent
  2084. >>>
  2085. >>>         b_to_gif = Utils.button_stock(gtk.STOCK_CONVERT,stock_size)
  2086.   File "<input>", line 1
  2087.     b_to_gif = Utils.button_stock(gtk.STOCK_CONVERT,stock_size)
  2088.     ^
  2089. IndentationError: unexpected indent
  2090. >>>         b_to_sprite = Utils.button_stock(gtk.STOCK_CONVERT,stock_size)
  2091.   File "<input>", line 1
  2092.     b_to_sprite = Utils.button_stock(gtk.STOCK_CONVERT,stock_size)
  2093.     ^
  2094. IndentationError: unexpected indent
  2095. >>>         b_conf = Utils.button_stock(gtk.STOCK_PREFERENCES,stock_size)
  2096.   File "<input>", line 1
  2097.     b_conf = Utils.button_stock(gtk.STOCK_PREFERENCES,stock_size)
  2098.     ^
  2099. IndentationError: unexpected indent
  2100. >>>
  2101. >>>         # connect
  2102. >>>         b_conf.connect("clicked",self.on_config)
  2103.   File "<input>", line 1
  2104.     b_conf.connect("clicked",self.on_config)
  2105.     ^
  2106. IndentationError: unexpected indent
  2107. >>>         b_to_gif.connect('clicked',self.create_formated_version,'gif')
  2108.   File "<input>", line 1
  2109.     b_to_gif.connect('clicked',self.create_formated_version,'gif')
  2110.     ^
  2111. IndentationError: unexpected indent
  2112. >>>         b_to_sprite.connect('clicked',self.create_formated_version,'spritesheet')
  2113.   File "<input>", line 1
  2114.     b_to_sprite.connect('clicked',self.create_formated_version,'spritesheet')
  2115.     ^
  2116. IndentationError: unexpected indent
  2117. >>>
  2118. >>>         # tooltips
  2119. >>>         b_conf.set_tooltip_text("open configuration dialog")
  2120.   File "<input>", line 1
  2121.     b_conf.set_tooltip_text("open configuration dialog")
  2122.     ^
  2123. IndentationError: unexpected indent
  2124. >>>         b_to_gif.set_tooltip_text("Create a formated Image to export as gif animation")
  2125.   File "<input>", line 1
  2126.     b_to_gif.set_tooltip_text("Create a formated Image to export as gif animation")
  2127.     ^
  2128. IndentationError: unexpected indent
  2129. >>>         b_to_sprite.set_tooltip_text("Create a formated Image to export as spritesheet")
  2130.   File "<input>", line 1
  2131.     b_to_sprite.set_tooltip_text("Create a formated Image to export as spritesheet")
  2132.     ^
  2133. IndentationError: unexpected indent
  2134. >>>
  2135. >>>         # disable when is playing
  2136. >>>         w = [b_conf, b_to_gif,b_to_sprite]
  2137.   File "<input>", line 1
  2138.     w = [b_conf, b_to_gif,b_to_sprite]
  2139.     ^
  2140. IndentationError: unexpected indent
  2141. >>>         map(lambda x: self.widgets_to_disable.append(x),w)
  2142.   File "<input>", line 1
  2143.     map(lambda x: self.widgets_to_disable.append(x),w)
  2144.     ^
  2145. IndentationError: unexpected indent
  2146. >>>
  2147. >>>         # pack into config_bar
  2148. >>>         map(lambda x: config_bar.pack_start(x,False,False,0),w)
  2149.   File "<input>", line 1
  2150.     map(lambda x: config_bar.pack_start(x,False,False,0),w)
  2151.     ^
  2152. IndentationError: unexpected indent
  2153. >>>         return config_bar
  2154.   File "<input>", line 1
  2155.     return config_bar
  2156.     ^
  2157. IndentationError: unexpected indent
  2158. >>>
  2159. >>>     def _setup_onionskin(self):
  2160.   File "<input>", line 1
  2161.     def _setup_onionskin(self):
  2162.     ^
  2163. IndentationError: unexpected indent
  2164. >>>         stock_size = gtk.ICON_SIZE_BUTTON
  2165.   File "<input>", line 1
  2166.     stock_size = gtk.ICON_SIZE_BUTTON
  2167.     ^
  2168. IndentationError: unexpected indent
  2169. >>>         button_size = 30
  2170.   File "<input>", line 1
  2171.     button_size = 30
  2172.     ^
  2173. IndentationError: unexpected indent
  2174. >>>         onionskin_bar = gtk.HBox()
  2175.   File "<input>", line 1
  2176.     onionskin_bar = gtk.HBox()
  2177.     ^
  2178. IndentationError: unexpected indent
  2179. >>>
  2180. >>>         # active onionskin
  2181. >>>         b_active = Utils.toggle_button_stock(gtk.STOCK_DND_MULTIPLE,stock_size)
  2182.   File "<input>", line 1
  2183.     b_active = Utils.toggle_button_stock(gtk.STOCK_DND_MULTIPLE,stock_size)
  2184.     ^
  2185. IndentationError: unexpected indent
  2186. >>>
  2187. >>>         # connect widgets
  2188. >>>         b_active.connect("clicked",self.on_onionskin)
  2189.   File "<input>", line 1
  2190.     b_active.connect("clicked",self.on_onionskin)
  2191.     ^
  2192. IndentationError: unexpected indent
  2193. >>>
  2194. >>>         # tooltips
  2195. >>>         b_active.set_tooltip_text("enable/disable the onion skin effect")
  2196.   File "<input>", line 1
  2197.     b_active.set_tooltip_text("enable/disable the onion skin effect")
  2198.     ^
  2199. IndentationError: unexpected indent
  2200. >>>
  2201. >>>         # add to the disable on play list
  2202. >>>         w = [b_active]
  2203.   File "<input>", line 1
  2204.     w = [b_active]
  2205.     ^
  2206. IndentationError: unexpected indent
  2207. >>>         map(lambda x: self.widgets_to_disable.append(x),w)
  2208.   File "<input>", line 1
  2209.     map(lambda x: self.widgets_to_disable.append(x),w)
  2210.     ^
  2211. IndentationError: unexpected indent
  2212. >>>
  2213. >>>         # packing everything in gbar
  2214. >>>         map(lambda x: onionskin_bar.pack_start(x,False,False,0),w)
  2215.   File "<input>", line 1
  2216.     map(lambda x: onionskin_bar.pack_start(x,False,False,0),w)
  2217.     ^
  2218. IndentationError: unexpected indent
  2219. >>>         return onionskin_bar
  2220.   File "<input>", line 1
  2221.     return onionskin_bar
  2222.     ^
  2223. IndentationError: unexpected indent
  2224. >>>
  2225. >>>     def _setup_generalbar(self):
  2226.   File "<input>", line 1
  2227.     def _setup_generalbar(self):
  2228.     ^
  2229. IndentationError: unexpected indent
  2230. >>>         stock_size = gtk.ICON_SIZE_BUTTON
  2231.   File "<input>", line 1
  2232.     stock_size = gtk.ICON_SIZE_BUTTON
  2233.     ^
  2234. IndentationError: unexpected indent
  2235. >>>         general_bar = gtk.HBox()
  2236.   File "<input>", line 1
  2237.     general_bar = gtk.HBox()
  2238.     ^
  2239. IndentationError: unexpected indent
  2240. >>>
  2241. >>>         b_about = Utils.button_stock(gtk.STOCK_ABOUT,stock_size)
  2242.   File "<input>", line 1
  2243.     b_about = Utils.button_stock(gtk.STOCK_ABOUT,stock_size)
  2244.     ^
  2245. IndentationError: unexpected indent
  2246. >>>         b_quit = Utils.button_stock(gtk.STOCK_QUIT,stock_size)
  2247.   File "<input>", line 1
  2248.     b_quit = Utils.button_stock(gtk.STOCK_QUIT,stock_size)
  2249.     ^
  2250. IndentationError: unexpected indent
  2251. >>>
  2252. >>>         # callbacks
  2253. >>>         b_quit.connect('clicked',self.destroy)
  2254.   File "<input>", line 1
  2255.     b_quit.connect('clicked',self.destroy)
  2256.     ^
  2257. IndentationError: unexpected indent
  2258. >>>         b_about.connect('clicked',self.on_about)
  2259.   File "<input>", line 1
  2260.     b_about.connect('clicked',self.on_about)
  2261.     ^
  2262. IndentationError: unexpected indent
  2263. >>>
  2264. >>>         # tooltips
  2265. >>>         b_about.set_tooltip_text("About FAnim")
  2266.   File "<input>", line 1
  2267.     b_about.set_tooltip_text("About FAnim")
  2268.     ^
  2269. IndentationError: unexpected indent
  2270. >>>         b_quit.set_tooltip_text("Exit")
  2271.   File "<input>", line 1
  2272.     b_quit.set_tooltip_text("Exit")
  2273.     ^
  2274. IndentationError: unexpected indent
  2275. >>>
  2276. >>>         # add to the disable on play list
  2277. >>>         w = [b_about, b_quit]
  2278.   File "<input>", line 1
  2279.     w = [b_about, b_quit]
  2280.     ^
  2281. IndentationError: unexpected indent
  2282. >>>         map(lambda x: self.widgets_to_disable.append(x),w)
  2283.   File "<input>", line 1
  2284.     map(lambda x: self.widgets_to_disable.append(x),w)
  2285.     ^
  2286. IndentationError: unexpected indent
  2287. >>>
  2288. >>>         # packing everything in general_bar
  2289. >>>         map(lambda x: general_bar.pack_start(x,False,False,0),w)
  2290.   File "<input>", line 1
  2291.     map(lambda x: general_bar.pack_start(x,False,False,0),w)
  2292.     ^
  2293. IndentationError: unexpected indent
  2294. >>>         return general_bar
  2295.   File "<input>", line 1
  2296.     return general_bar
  2297.     ^
  2298. IndentationError: unexpected indent
  2299. >>>
  2300. >>>     def get_settings(self):
  2301.   File "<input>", line 1
  2302.     def get_settings(self):
  2303.     ^
  2304. IndentationError: unexpected indent
  2305. >>>         s = {}
  2306.   File "<input>", line 1
  2307.     s = {}
  2308.     ^
  2309. IndentationError: unexpected indent
  2310. >>>         s[FRAMERATE] = self.framerate
  2311.   File "<input>", line 1
  2312.     s[FRAMERATE] = self.framerate
  2313.     ^
  2314. IndentationError: unexpected indent
  2315. >>>         s[OSKIN_DEPTH] = self.oskin_depth
  2316.   File "<input>", line 1
  2317.     s[OSKIN_DEPTH] = self.oskin_depth
  2318.     ^
  2319. IndentationError: unexpected indent
  2320. >>>         s[OSKIN_FORWARD] = self.oskin_forward
  2321.   File "<input>", line 1
  2322.     s[OSKIN_FORWARD] = self.oskin_forward
  2323.     ^
  2324. IndentationError: unexpected indent
  2325. >>>         s[OSKIN_BACKWARD] = self.oskin_backward
  2326.   File "<input>", line 1
  2327.     s[OSKIN_BACKWARD] = self.oskin_backward
  2328.     ^
  2329. IndentationError: unexpected indent
  2330. >>>         s[OSKIN_ONPLAY] = self.oskin_onplay
  2331.   File "<input>", line 1
  2332.     s[OSKIN_ONPLAY] = self.oskin_onplay
  2333.     ^
  2334. IndentationError: unexpected indent
  2335. >>>
  2336. >>>         s[WIN_POSX] = self.win_pos[0]
  2337.   File "<input>", line 1
  2338.     s[WIN_POSX] = self.win_pos[0]
  2339.     ^
  2340. IndentationError: unexpected indent
  2341. >>>         s[WIN_POSY] = self.win_pos[1]
  2342.   File "<input>", line 1
  2343.     s[WIN_POSY] = self.win_pos[1]
  2344.     ^
  2345. IndentationError: unexpected indent
  2346. >>>         s[WIN_WIDTH] = self.get_allocation()[2]
  2347.   File "<input>", line 1
  2348.     s[WIN_WIDTH] = self.get_allocation()[2]
  2349.     ^
  2350. IndentationError: unexpected indent
  2351. >>>         s[WIN_HEIGHT] = self.get_allocation()[3]
  2352.   File "<input>", line 1
  2353.     s[WIN_HEIGHT] = self.get_allocation()[3]
  2354.     ^
  2355. IndentationError: unexpected indent
  2356. >>>         return s
  2357.   File "<input>", line 1
  2358.     return s
  2359.     ^
  2360. IndentationError: unexpected indent
  2361. >>>
  2362. >>>     def set_settings(self,conf):
  2363.   File "<input>", line 1
  2364.     def set_settings(self,conf):
  2365.     ^
  2366. IndentationError: unexpected indent
  2367. >>>         if conf == None:
  2368.   File "<input>", line 1
  2369.     if conf == None:
  2370.     ^
  2371. IndentationError: unexpected indent
  2372. >>>             return
  2373.   File "<input>", line 1
  2374.     return
  2375.     ^
  2376. IndentationError: unexpected indent
  2377. >>>
  2378. >>>         self.framerate = int(conf[FRAMERATE])
  2379.   File "<input>", line 1
  2380.     self.framerate = int(conf[FRAMERATE])
  2381.     ^
  2382. IndentationError: unexpected indent
  2383. >>>         self.oskin_depth = int(conf[OSKIN_DEPTH])
  2384.   File "<input>", line 1
  2385.     self.oskin_depth = int(conf[OSKIN_DEPTH])
  2386.     ^
  2387. IndentationError: unexpected indent
  2388. >>>         self.oskin_forward = conf[OSKIN_FORWARD]
  2389.   File "<input>", line 1
  2390.     self.oskin_forward = conf[OSKIN_FORWARD]
  2391.     ^
  2392. IndentationError: unexpected indent
  2393. >>>         self.oskin_backward = conf[OSKIN_BACKWARD]
  2394.   File "<input>", line 1
  2395.     self.oskin_backward = conf[OSKIN_BACKWARD]
  2396.     ^
  2397. IndentationError: unexpected indent
  2398. >>>         self.oskin_onplay = conf[OSKIN_ONPLAY]
  2399.   File "<input>", line 1
  2400.     self.oskin_onplay = conf[OSKIN_ONPLAY]
  2401.     ^
  2402. IndentationError: unexpected indent
  2403. >>>         self.win_size  = (conf[WIN_WIDTH],conf[WIN_HEIGHT])
  2404.   File "<input>", line 1
  2405.     self.win_size  = (conf[WIN_WIDTH],conf[WIN_HEIGHT])
  2406.     ^
  2407. IndentationError: unexpected indent
  2408. >>>         self.win_pos = (conf[WIN_POSX],conf[WIN_POSY])
  2409.   File "<input>", line 1
  2410.     self.win_pos = (conf[WIN_POSX],conf[WIN_POSY])
  2411.     ^
  2412. IndentationError: unexpected indent
  2413. >>>
  2414. >>>     def _toggle_enable_buttons(self,state):
  2415.   File "<input>", line 1
  2416.     def _toggle_enable_buttons(self,state):
  2417.     ^
  2418. IndentationError: unexpected indent
  2419. >>>         if state == PLAYING:
  2420.   File "<input>", line 1
  2421.     if state == PLAYING:
  2422.     ^
  2423. IndentationError: unexpected indent
  2424. >>>             for w in self.widgets_to_disable:
  2425.   File "<input>", line 1
  2426.     for w in self.widgets_to_disable:
  2427.     ^
  2428. IndentationError: unexpected indent
  2429. >>>                 w.set_sensitive(not self.is_playing)
  2430.   File "<input>", line 1
  2431.     w.set_sensitive(not self.is_playing)
  2432.     ^
  2433. IndentationError: unexpected indent
  2434. >>>         elif state == NO_FRAMES:
  2435.   File "<input>", line 1
  2436.     elif state == NO_FRAMES:
  2437.     ^
  2438. IndentationError: unexpected indent
  2439. >>>             self.play_bar.set_sensitive(not self.play_bar.get_sensitive())
  2440.   File "<input>", line 1
  2441.     self.play_bar.set_sensitive(not self.play_bar.get_sensitive())
  2442.     ^
  2443. IndentationError: unexpected indent
  2444. >>>
  2445. >>>
  2446. >>> #----------------------Callback Functions----------------#
  2447. >>>     def on_window_focus(self,widget,other):
  2448.   File "<input>", line 1
  2449.     def on_window_focus(self,widget,other):
  2450.     ^
  2451. IndentationError: unexpected indent
  2452. >>>         """
  2453.  File "<input>", line 1
  2454.    """
  2455.     ^
  2456. IndentationError: unexpected indent
  2457. >>>         Update all timeline thumbnails.
  2458.   File "<input>", line 1
  2459.     Update all timeline thumbnails.
  2460.     ^
  2461. IndentationError: unexpected indent
  2462. >>>         """
  2463.  File "<input>", line 1
  2464.    """
  2465.     ^
  2466. IndentationError: unexpected indent
  2467. >>>         # I discovered that gimp has a delay to update when the image are closed, putting
  2468. >>>         # a small delay here i make sure that my if will catch the lack of the image
  2469. >>>         # and close fanim correctly.
  2470. >>>         time.sleep(0.1)
  2471.   File "<input>", line 1
  2472.     time.sleep(0.1)
  2473.     ^
  2474. IndentationError: unexpected indent
  2475. >>>         if not(self.image in gimp.image_list()):
  2476.   File "<input>", line 1
  2477.     if not(self.image in gimp.image_list()):
  2478.     ^
  2479. IndentationError: unexpected indent
  2480. >>>             self.destroy(False)
  2481.   File "<input>", line 1
  2482.     self.destroy(False)
  2483.     ^
  2484. IndentationError: unexpected indent
  2485. >>>         else:
  2486.   File "<input>", line 1
  2487.     else:
  2488.     ^
  2489. IndentationError: unexpected indent
  2490. >>>             # fixing problem that happens after delete the last layer through gimp.
  2491. >>>             # and closing when theres no layers at all.
  2492. >>>             if not self.image.layers:
  2493.   File "<input>", line 1
  2494.     if not self.image.layers:
  2495.     ^
  2496. IndentationError: unexpected indent
  2497. >>>                 self.destroy(False)
  2498.   File "<input>", line 1
  2499.     self.destroy(False)
  2500.     ^
  2501. IndentationError: unexpected indent
  2502. >>>             else:
  2503.   File "<input>", line 1
  2504.     else:
  2505.     ^
  2506. IndentationError: unexpected indent
  2507. >>>                 if self.active >= len(self.image.layers):
  2508.   File "<input>", line 1
  2509.     if self.active >= len(self.image.layers):
  2510.     ^
  2511. IndentationError: unexpected indent
  2512. >>>                     self.active = len(self.image.layers)-1
  2513.   File "<input>", line 1
  2514.     self.active = len(self.image.layers)-1
  2515.     ^
  2516. IndentationError: unexpected indent
  2517. >>>                 self._scan_image_layers()
  2518.   File "<input>", line 1
  2519.     self._scan_image_layers()
  2520.     ^
  2521. IndentationError: unexpected indent
  2522. >>>                 self.on_goto(None,GIMP_ACTIVE)
  2523.   File "<input>", line 1
  2524.     self.on_goto(None,GIMP_ACTIVE)
  2525.     ^
  2526. IndentationError: unexpected indent
  2527. >>>
  2528. >>>     def on_about(self,widget):
  2529.   File "<input>", line 1
  2530.     def on_about(self,widget):
  2531.     ^
  2532. IndentationError: unexpected indent
  2533. >>>         about = gtk.AboutDialog()
  2534.   File "<input>", line 1
  2535.     about = gtk.AboutDialog()
  2536.     ^
  2537. IndentationError: unexpected indent
  2538. >>>
  2539. >>>         about.set_authors(AUTHORS)
  2540.   File "<input>", line 1
  2541.     about.set_authors(AUTHORS)
  2542.     ^
  2543. IndentationError: unexpected indent
  2544. >>>         about.set_program_name(NAME)
  2545.   File "<input>", line 1
  2546.     about.set_program_name(NAME)
  2547.     ^
  2548. IndentationError: unexpected indent
  2549. >>>         about.set_copyright(COPYRIGHT)
  2550.   File "<input>", line 1
  2551.     about.set_copyright(COPYRIGHT)
  2552.     ^
  2553. IndentationError: unexpected indent
  2554. >>>         about.set_website(WEBSITE)
  2555.   File "<input>", line 1
  2556.     about.set_website(WEBSITE)
  2557.     ^
  2558. IndentationError: unexpected indent
  2559. >>>
  2560. >>>         about.run()
  2561.   File "<input>", line 1
  2562.     about.run()
  2563.     ^
  2564. IndentationError: unexpected indent
  2565. >>>         about.destroy()
  2566.   File "<input>", line 1
  2567.     about.destroy()
  2568.     ^
  2569. IndentationError: unexpected indent
  2570. >>>
  2571. >>>     def create_formated_version(self,widget,format='gif'):
  2572.   File "<input>", line 1
  2573.     def create_formated_version(self,widget,format='gif'):
  2574.     ^
  2575. IndentationError: unexpected indent
  2576. >>>         """
  2577.  File "<input>", line 1
  2578.    """
  2579.     ^
  2580. IndentationError: unexpected indent
  2581. >>>         Create a formated version of the animation to export as a giff or as a spritesheet.
  2582.   File "<input>", line 1
  2583.     Create a formated version of the animation to export as a giff or as a spritesheet.
  2584.     ^
  2585. IndentationError: unexpected indent
  2586. >>>         """
  2587.  File "<input>", line 1
  2588.    """
  2589.     ^
  2590. IndentationError: unexpected indent
  2591. >>>         # disabling the onionskin temporaly if is activated
  2592. >>>         oskin_disabled = False
  2593.   File "<input>", line 1
  2594.     oskin_disabled = False
  2595.     ^
  2596. IndentationError: unexpected indent
  2597. >>>         if self.oskin:
  2598.   File "<input>", line 1
  2599.     if self.oskin:
  2600.     ^
  2601. IndentationError: unexpected indent
  2602. >>>             self.on_onionskin(None)
  2603.   File "<input>", line 1
  2604.     self.on_onionskin(None)
  2605.     ^
  2606. IndentationError: unexpected indent
  2607. >>>             oskin_disabled = True
  2608.   File "<input>", line 1
  2609.     oskin_disabled = True
  2610.     ^
  2611. IndentationError: unexpected indent
  2612. >>>
  2613. >>>         # get normal and visibly fixed frames.
  2614. >>>         normal_frames = filter(lambda x: x.fixed == False,self.frames)
  2615.   File "<input>", line 1
  2616.     normal_frames = filter(lambda x: x.fixed == False,self.frames)
  2617.     ^
  2618. IndentationError: unexpected indent
  2619. >>>         fixed_frames = filter(lambda x: x.fixed == True,self.frames)
  2620.   File "<input>", line 1
  2621.     fixed_frames = filter(lambda x: x.fixed == True,self.frames)
  2622.     ^
  2623. IndentationError: unexpected indent
  2624. >>>
  2625. >>>         new_image = gimp.Image(self.image.width,self.image.height,self.image.base_type)
  2626.   File "<input>", line 1
  2627.     new_image = gimp.Image(self.image.width,self.image.height,self.image.base_type)
  2628.     ^
  2629. IndentationError: unexpected indent
  2630. >>>
  2631. >>>
  2632. >>>         # reverse the normal frames.
  2633. >>>         normal_frames.reverse()
  2634.   File "<input>", line 1
  2635.     normal_frames.reverse()
  2636.     ^
  2637. IndentationError: unexpected indent
  2638. >>>
  2639. >>>         for fl in normal_frames:
  2640.   File "<input>", line 1
  2641.     for fl in normal_frames:
  2642.     ^
  2643. IndentationError: unexpected indent
  2644. >>>             # create a group to put the normal and the fixed frames.
  2645. >>>             group = gimp.GroupLayer(new_image,fl.layer.name)
  2646.   File "<input>", line 1
  2647.     group = gimp.GroupLayer(new_image,fl.layer.name)
  2648.     ^
  2649. IndentationError: unexpected indent
  2650. >>>            
  2651. >>>             # copy normal layer
  2652. >>>             lcopy = pdb.gimp_layer_new_from_drawable(fl.layer,new_image)
  2653.   File "<input>", line 1
  2654.     lcopy = pdb.gimp_layer_new_from_drawable(fl.layer,new_image)
  2655.     ^
  2656. IndentationError: unexpected indent
  2657. >>>             lcopy.visible = True
  2658.   File "<input>", line 1
  2659.     lcopy.visible = True
  2660.     ^
  2661. IndentationError: unexpected indent
  2662. >>>
  2663. >>>             new_image.add_layer(group,len(new_image.layers))
  2664.   File "<input>", line 1
  2665.     new_image.add_layer(group,len(new_image.layers))
  2666.     ^
  2667. IndentationError: unexpected indent
  2668. >>>             new_image.insert_layer(lcopy,group,0)
  2669.   File "<input>", line 1
  2670.     new_image.insert_layer(lcopy,group,0)
  2671.     ^
  2672. IndentationError: unexpected indent
  2673. >>>
  2674. >>>             # get the background and foreground frames.
  2675. >>>             up_fixed = filter(lambda x: self.frames.index(x) > self.frames.index(fl),fixed_frames)
  2676.   File "<input>", line 1
  2677.     up_fixed = filter(lambda x: self.frames.index(x) > self.frames.index(fl),fixed_frames)
  2678.     ^
  2679. IndentationError: unexpected indent
  2680. >>>             bottom_fixed = filter(lambda x: self.frames.index(x) < self.frames.index(fl),fixed_frames)
  2681.   File "<input>", line 1
  2682.     bottom_fixed = filter(lambda x: self.frames.index(x) < self.frames.index(fl),fixed_frames)
  2683.     ^
  2684. IndentationError: unexpected indent
  2685. >>>
  2686. >>>             # copy and insert the fixed visibility layers/frames
  2687. >>>             b =0
  2688.   File "<input>", line 1
  2689.     b =0
  2690.     ^
  2691. IndentationError: unexpected indent
  2692. >>>             for ff in fixed_frames:
  2693.   File "<input>", line 1
  2694.     for ff in fixed_frames:
  2695.     ^
  2696. IndentationError: unexpected indent
  2697. >>>                 copy = pdb.gimp_layer_new_from_drawable(ff.layer,new_image)
  2698.   File "<input>", line 1
  2699.     copy = pdb.gimp_layer_new_from_drawable(ff.layer,new_image)
  2700.     ^
  2701. IndentationError: unexpected indent
  2702. >>>                 if ff in bottom_fixed:
  2703.   File "<input>", line 1
  2704.     if ff in bottom_fixed:
  2705.     ^
  2706. IndentationError: unexpected indent
  2707. >>>                     new_image.insert_layer(copy,group,len(group.layers)-b)
  2708.   File "<input>", line 1
  2709.     new_image.insert_layer(copy,group,len(group.layers)-b)
  2710.     ^
  2711. IndentationError: unexpected indent
  2712. >>>                     b+= 1
  2713.   File "<input>", line 1
  2714.     b+= 1
  2715.     ^
  2716. IndentationError: unexpected indent
  2717. >>>                 elif ff in up_fixed:
  2718.   File "<input>", line 1
  2719.     elif ff in up_fixed:
  2720.     ^
  2721. IndentationError: unexpected indent
  2722. >>>                     new_image.insert_layer(copy,group,0)
  2723.   File "<input>", line 1
  2724.     new_image.insert_layer(copy,group,0)
  2725.     ^
  2726. IndentationError: unexpected indent
  2727. >>>
  2728. >>>         if format == 'gif':
  2729.   File "<input>", line 1
  2730.     if format == 'gif':
  2731.     ^
  2732. IndentationError: unexpected indent
  2733. >>>             # show the formated image to export as gif.
  2734. >>>             gimp.Display(new_image)
  2735.   File "<input>", line 1
  2736.     gimp.Display(new_image)
  2737.     ^
  2738. IndentationError: unexpected indent
  2739. >>>
  2740. >>>         elif format == 'spritesheet':
  2741.   File "<input>", line 1
  2742.     elif format == 'spritesheet':
  2743.     ^
  2744. IndentationError: unexpected indent
  2745. >>>             simg = gimp.Image(len(new_image.layers) * self.image.width,self.image.height,self.image.base_type)
  2746.   File "<input>", line 1
  2747.     simg = gimp.Image(len(new_image.layers) * self.image.width,self.image.height,self.image.base_type)
  2748.     ^
  2749. IndentationError: unexpected indent
  2750. >>>
  2751. >>>             cnt = 0
  2752.   File "<input>", line 1
  2753.     cnt = 0
  2754.     ^
  2755. IndentationError: unexpected indent
  2756. >>>             def novisible (x,state):
  2757.   File "<input>", line 1
  2758.     def novisible (x,state):
  2759.     ^
  2760. IndentationError: unexpected indent
  2761. >>>                 # change the visibility of the gimp layers.
  2762. >>>                  x.visible = state
  2763.   File "<input>", line 1
  2764.     x.visible = state
  2765.     ^
  2766. IndentationError: unexpected indent
  2767. >>>
  2768. >>>             # copy each frame and position it side by side.
  2769. >>>             # put the layers order back to normal.
  2770. >>>             n_img_layers = new_image.layers
  2771.   File "<input>", line 1
  2772.     n_img_layers = new_image.layers
  2773.     ^
  2774. IndentationError: unexpected indent
  2775. >>>             n_img_layers.reverse()
  2776.   File "<input>", line 1
  2777.     n_img_layers.reverse()
  2778.     ^
  2779. IndentationError: unexpected indent
  2780. >>>
  2781. >>>             for l in n_img_layers:
  2782.   File "<input>", line 1
  2783.     for l in n_img_layers:
  2784.     ^
  2785. IndentationError: unexpected indent
  2786. >>>                 cl = pdb.gimp_layer_new_from_drawable(l,simg)
  2787.   File "<input>", line 1
  2788.     cl = pdb.gimp_layer_new_from_drawable(l,simg)
  2789.     ^
  2790. IndentationError: unexpected indent
  2791. >>>                 simg.add_layer(cl,0)
  2792.   File "<input>", line 1
  2793.     simg.add_layer(cl,0)
  2794.     ^
  2795. IndentationError: unexpected indent
  2796. >>>
  2797. >>>                 cl.transform_2d(0,0,1,1,0,-cnt * new_image.width,0,1,0)
  2798.   File "<input>", line 1
  2799.     cl.transform_2d(0,0,1,1,0,-cnt * new_image.width,0,1,0)
  2800.     ^
  2801. IndentationError: unexpected indent
  2802. >>>                 cnt +=1
  2803.   File "<input>", line 1
  2804.     cnt +=1
  2805.     ^
  2806. IndentationError: unexpected indent
  2807. >>>                 # merge the group as flat image.
  2808. >>>                 map(lambda x:novisible(x,False),simg.layers)
  2809.   File "<input>", line 1
  2810.     map(lambda x:novisible(x,False),simg.layers)
  2811.     ^
  2812. IndentationError: unexpected indent
  2813. >>>                 cl.visible = True
  2814.   File "<input>", line 1
  2815.     cl.visible = True
  2816.     ^
  2817. IndentationError: unexpected indent
  2818. >>>                 simg.merge_visible_layers(1)
  2819.   File "<input>", line 1
  2820.     simg.merge_visible_layers(1)
  2821.     ^
  2822. IndentationError: unexpected indent
  2823. >>>
  2824. >>>             map(lambda x:novisible(x,True),simg.layers)
  2825.   File "<input>", line 1
  2826.     map(lambda x:novisible(x,True),simg.layers)
  2827.     ^
  2828. IndentationError: unexpected indent
  2829. >>>             # show the formated image to export as spritesheet.
  2830. >>>             gimp.Display(simg)
  2831.   File "<input>", line 1
  2832.     gimp.Display(simg)
  2833.     ^
  2834. IndentationError: unexpected indent
  2835. >>>         # return onionskin if was enabled
  2836. >>>         if oskin_disabled:
  2837.   File "<input>", line 1
  2838.     if oskin_disabled:
  2839.     ^
  2840. IndentationError: unexpected indent
  2841. >>>             self.on_onionskin(None)
  2842.   File "<input>", line 1
  2843.     self.on_onionskin(None)
  2844.     ^
  2845. IndentationError: unexpected indent
  2846. >>>
  2847. >>>     def on_toggle_play(self,widget):
  2848.   File "<input>", line 1
  2849.     def on_toggle_play(self,widget):
  2850.     ^
  2851. IndentationError: unexpected indent
  2852. >>>         """
  2853.  File "<input>", line 1
  2854.    """
  2855.     ^
  2856. IndentationError: unexpected indent
  2857. >>>         This method change the animation play state,
  2858.   File "<input>", line 1
  2859.     This method change the animation play state,
  2860.     ^
  2861. IndentationError: unexpected indent
  2862. >>>         change the button image and will disable/enable the other buttons
  2863.   File "<input>", line 1
  2864.     change the button image and will disable/enable the other buttons
  2865.     ^
  2866. IndentationError: unexpected indent
  2867. >>>         interation.
  2868.   File "<input>", line 1
  2869.     interation.
  2870.     ^
  2871. IndentationError: unexpected indent
  2872. >>>         for that they need 2 image which is stored in self.play_button_images
  2873.   File "<input>", line 1
  2874.     for that they need 2 image which is stored in self.play_button_images
  2875.     ^
  2876. IndentationError: unexpected indent
  2877. >>>         variable.
  2878.   File "<input>", line 1
  2879.     variable.
  2880.     ^
  2881. IndentationError: unexpected indent
  2882. >>>         """
  2883.  File "<input>", line 1
  2884.    """
  2885.     ^
  2886. IndentationError: unexpected indent
  2887. >>>         # if onionskin on play is disable then disable remaining frames
  2888. >>>         if self.oskin_onplay:
  2889.   File "<input>", line 1
  2890.     if self.oskin_onplay:
  2891.     ^
  2892. IndentationError: unexpected indent
  2893. >>>             self.layers_show(False)
  2894.   File "<input>", line 1
  2895.     self.layers_show(False)
  2896.     ^
  2897. IndentationError: unexpected indent
  2898. >>>
  2899. >>>         self.is_playing = not self.is_playing
  2900.   File "<input>", line 1
  2901.     self.is_playing = not self.is_playing
  2902.     ^
  2903. IndentationError: unexpected indent
  2904. >>>
  2905. >>>         if self.is_playing:
  2906.   File "<input>", line 1
  2907.     if self.is_playing:
  2908.     ^
  2909. IndentationError: unexpected indent
  2910. >>>             # saving the atual frame before start to play.
  2911. >>>             if self.before_play == None:
  2912.   File "<input>", line 1
  2913.     if self.before_play == None:
  2914.     ^
  2915. IndentationError: unexpected indent
  2916. >>>                 self.before_play = self.active
  2917.   File "<input>", line 1
  2918.     self.before_play = self.active
  2919.     ^
  2920. IndentationError: unexpected indent
  2921. >>>
  2922. >>>             widget.set_image(self.play_button_images[1]) # set pause image to the button
  2923.   File "<input>", line 1
  2924.     widget.set_image(self.play_button_images[1]) # set pause image to the button
  2925.     ^
  2926. IndentationError: unexpected indent
  2927. >>>
  2928. >>>             # start the player object to play the frames in a sequence.
  2929. >>>             if not self.player:
  2930.   File "<input>", line 1
  2931.     if not self.player:
  2932.     ^
  2933. IndentationError: unexpected indent
  2934. >>>                 self.player = Player(self,widget)
  2935.   File "<input>", line 1
  2936.     self.player = Player(self,widget)
  2937.     ^
  2938. IndentationError: unexpected indent
  2939. >>>             # block every other button than pause.
  2940. >>>             self._toggle_enable_buttons(PLAYING)
  2941.   File "<input>", line 1
  2942.     self._toggle_enable_buttons(PLAYING)
  2943.     ^
  2944. IndentationError: unexpected indent
  2945. >>>
  2946. >>>             # start the loop to play the frames.
  2947. >>>             self.player.start()
  2948.   File "<input>", line 1
  2949.     self.player.start()
  2950.     ^
  2951. IndentationError: unexpected indent
  2952. >>>
  2953. >>>         else :
  2954.   File "<input>", line 1
  2955.     else :
  2956.     ^
  2957. IndentationError: unexpected indent
  2958. >>>             # restore last frame before play.
  2959. >>>             if self.before_play != None:
  2960.   File "<input>", line 1
  2961.     if self.before_play != None:
  2962.     ^
  2963. IndentationError: unexpected indent
  2964. >>>                 self.on_goto(None,POS,index=self.before_play)
  2965.   File "<input>", line 1
  2966.     self.on_goto(None,POS,index=self.before_play)
  2967.     ^
  2968. IndentationError: unexpected indent
  2969. >>>                 self.before_play = None
  2970.   File "<input>", line 1
  2971.     self.before_play = None
  2972.     ^
  2973. IndentationError: unexpected indent
  2974. >>>
  2975. >>>             widget.set_image(self.play_button_images[0]) # set play image
  2976.   File "<input>", line 1
  2977.     widget.set_image(self.play_button_images[0]) # set play image
  2978.     ^
  2979. IndentationError: unexpected indent
  2980. >>>             self._toggle_enable_buttons(PLAYING)
  2981.   File "<input>", line 1
  2982.     self._toggle_enable_buttons(PLAYING)
  2983.     ^
  2984. IndentationError: unexpected indent
  2985. >>>             self.on_goto(None,NOWHERE) # update atual frame.
  2986.   File "<input>", line 1
  2987.     self.on_goto(None,NOWHERE) # update atual frame.
  2988.     ^
  2989. IndentationError: unexpected indent
  2990. >>>
  2991. >>>     def on_replay(self,widget):
  2992.   File "<input>", line 1
  2993.     def on_replay(self,widget):
  2994.     ^
  2995. IndentationError: unexpected indent
  2996. >>>         self.is_replay = widget.get_active()
  2997.   File "<input>", line 1
  2998.     self.is_replay = widget.get_active()
  2999.     ^
  3000. IndentationError: unexpected indent
  3001. >>>
  3002. >>>     def on_onionskin(self,widget):
  3003.   File "<input>", line 1
  3004.     def on_onionskin(self,widget):
  3005.     ^
  3006. IndentationError: unexpected indent
  3007. >>>         """
  3008.  File "<input>", line 1
  3009.    """
  3010.     ^
  3011. IndentationError: unexpected indent
  3012. >>>         Toggle onionskin.
  3013.   File "<input>", line 1
  3014.     Toggle onionskin.
  3015.     ^
  3016. IndentationError: unexpected indent
  3017. >>>         """
  3018.  File "<input>", line 1
  3019.    """
  3020.     ^
  3021. IndentationError: unexpected indent
  3022. >>>         self.layers_show(False) # clear remaining onionskin frames
  3023.   File "<input>", line 1
  3024.     self.layers_show(False) # clear remaining onionskin frames
  3025.     ^
  3026. IndentationError: unexpected indent
  3027. >>>         if widget == None:
  3028.   File "<input>", line 1
  3029.     if widget == None:
  3030.     ^
  3031. IndentationError: unexpected indent
  3032. >>>             self.oskin = not self.oskin
  3033.   File "<input>", line 1
  3034.     self.oskin = not self.oskin
  3035.     ^
  3036. IndentationError: unexpected indent
  3037. >>>         else: self.oskin = widget.get_active()
  3038.   File "<input>", line 1
  3039.     else: self.oskin = widget.get_active()
  3040.     ^
  3041. IndentationError: unexpected indent
  3042. >>>         self.on_goto(None,NOWHERE,True)
  3043.   File "<input>", line 1
  3044.     self.on_goto(None,NOWHERE,True)
  3045.     ^
  3046. IndentationError: unexpected indent
  3047. >>>
  3048. >>>     def on_config(self,widget):
  3049.   File "<input>", line 1
  3050.     def on_config(self,widget):
  3051.     ^
  3052. IndentationError: unexpected indent
  3053. >>>         """
  3054.  File "<input>", line 1
  3055.    """
  3056.     ^
  3057. IndentationError: unexpected indent
  3058. >>>         Open a dialog to set all the settings of the plugin.
  3059.   File "<input>", line 1
  3060.     Open a dialog to set all the settings of the plugin.
  3061.     ^
  3062. IndentationError: unexpected indent
  3063. >>>         """
  3064.  File "<input>", line 1
  3065.    """
  3066.     ^
  3067. IndentationError: unexpected indent
  3068. >>>         dialog = ConfDialog("FAnim Config",self,self.get_settings())
  3069.   File "<input>", line 1
  3070.     dialog = ConfDialog("FAnim Config",self,self.get_settings())
  3071.     ^
  3072. IndentationError: unexpected indent
  3073. >>>         result, config = dialog.run()
  3074.   File "<input>", line 1
  3075.     result, config = dialog.run()
  3076.     ^
  3077. IndentationError: unexpected indent
  3078. >>>
  3079. >>>         if result == gtk.RESPONSE_APPLY:
  3080.   File "<input>", line 1
  3081.     if result == gtk.RESPONSE_APPLY:
  3082.     ^
  3083. IndentationError: unexpected indent
  3084. >>>             self.set_settings(config)
  3085.   File "<input>", line 1
  3086.     self.set_settings(config)
  3087.     ^
  3088. IndentationError: unexpected indent
  3089. >>>         dialog.destroy()
  3090.   File "<input>", line 1
  3091.     dialog.destroy()
  3092.     ^
  3093. IndentationError: unexpected indent
  3094. >>>
  3095. >>>     def on_move(self,widget,direction):
  3096.   File "<input>", line 1
  3097.     def on_move(self,widget,direction):
  3098.     ^
  3099. IndentationError: unexpected indent
  3100. >>>         """
  3101.  File "<input>", line 1
  3102.    """
  3103.     ^
  3104. IndentationError: unexpected indent
  3105. >>>         Move the layer and the frame forward or backward.
  3106.   File "<input>", line 1
  3107.     Move the layer and the frame forward or backward.
  3108.     ^
  3109. IndentationError: unexpected indent
  3110. >>>         """
  3111.  File "<input>", line 1
  3112.    """
  3113.     ^
  3114. IndentationError: unexpected indent
  3115. >>>         # calculate next position
  3116. >>>         index = 0
  3117.   File "<input>", line 1
  3118.     index = 0
  3119.     ^
  3120. IndentationError: unexpected indent
  3121. >>>         if direction == NEXT:
  3122.   File "<input>", line 1
  3123.     if direction == NEXT:
  3124.     ^
  3125. IndentationError: unexpected indent
  3126. >>>             index = self.active+1
  3127.   File "<input>", line 1
  3128.     index = self.active+1
  3129.     ^
  3130. IndentationError: unexpected indent
  3131. >>>             if index == len(self.frames):
  3132.   File "<input>", line 1
  3133.     if index == len(self.frames):
  3134.     ^
  3135. IndentationError: unexpected indent
  3136. >>>                 return
  3137.   File "<input>", line 1
  3138.     return
  3139.     ^
  3140. IndentationError: unexpected indent
  3141. >>>
  3142. >>>         elif direction == PREV:
  3143.   File "<input>", line 1
  3144.     elif direction == PREV:
  3145.     ^
  3146. IndentationError: unexpected indent
  3147. >>>             index = self.active-1
  3148.   File "<input>", line 1
  3149.     index = self.active-1
  3150.     ^
  3151. IndentationError: unexpected indent
  3152. >>>             if self.active-1 < 0:
  3153.   File "<input>", line 1
  3154.     if self.active-1 < 0:
  3155.     ^
  3156. IndentationError: unexpected indent
  3157. >>>                 return
  3158.   File "<input>", line 1
  3159.     return
  3160.     ^
  3161. IndentationError: unexpected indent
  3162. >>>         # move layer.
  3163. >>>         if direction == NEXT:
  3164.   File "<input>", line 1
  3165.     if direction == NEXT:
  3166.     ^
  3167. IndentationError: unexpected indent
  3168. >>>             self.image.raise_layer(self.frames[self.active].layer)
  3169.   File "<input>", line 1
  3170.     self.image.raise_layer(self.frames[self.active].layer)
  3171.     ^
  3172. IndentationError: unexpected indent
  3173. >>>         elif direction == PREV:
  3174.   File "<input>", line 1
  3175.     elif direction == PREV:
  3176.     ^
  3177. IndentationError: unexpected indent
  3178. >>>             self.image.lower_layer(self.frames[self.active].layer)
  3179.   File "<input>", line 1
  3180.     self.image.lower_layer(self.frames[self.active].layer)
  3181.     ^
  3182. IndentationError: unexpected indent
  3183. >>>
  3184. >>>         # update Timeline
  3185. >>>         self._scan_image_layers()
  3186.   File "<input>", line 1
  3187.     self._scan_image_layers()
  3188.     ^
  3189. IndentationError: unexpected indent
  3190. >>>         self.active = index
  3191.   File "<input>", line 1
  3192.     self.active = index
  3193.     ^
  3194. IndentationError: unexpected indent
  3195. >>>         self.on_goto(None,NOWHERE)
  3196.   File "<input>", line 1
  3197.     self.on_goto(None,NOWHERE)
  3198.     ^
  3199. IndentationError: unexpected indent
  3200. >>>
  3201. >>>     def on_remove(self,widget):
  3202.   File "<input>", line 1
  3203.     def on_remove(self,widget):
  3204.     ^
  3205. IndentationError: unexpected indent
  3206. >>>         """
  3207.  File "<input>", line 1
  3208.    """
  3209.     ^
  3210. IndentationError: unexpected indent
  3211. >>>         Remove the atual selected frame, and his layer. and if the case his sublayers.
  3212.   File "<input>", line 1
  3213.     Remove the atual selected frame, and his layer. and if the case his sublayers.
  3214.     ^
  3215. IndentationError: unexpected indent
  3216. >>>         """
  3217.  File "<input>", line 1
  3218.    """
  3219.     ^
  3220. IndentationError: unexpected indent
  3221. >>>         if not self.frames:
  3222.   File "<input>", line 1
  3223.     if not self.frames:
  3224.     ^
  3225. IndentationError: unexpected indent
  3226. >>>             return
  3227.   File "<input>", line 1
  3228.     return
  3229.     ^
  3230. IndentationError: unexpected indent
  3231. >>>
  3232. >>>         index = 0
  3233.   File "<input>", line 1
  3234.     index = 0
  3235.     ^
  3236. IndentationError: unexpected indent
  3237. >>>         if self.active > 0:
  3238.   File "<input>", line 1
  3239.     if self.active > 0:
  3240.     ^
  3241. IndentationError: unexpected indent
  3242. >>>             self.on_goto(None,PREV,True)
  3243.   File "<input>", line 1
  3244.     self.on_goto(None,PREV,True)
  3245.     ^
  3246. IndentationError: unexpected indent
  3247. >>>             index = self.active + 1
  3248.   File "<input>", line 1
  3249.     index = self.active + 1
  3250.     ^
  3251. IndentationError: unexpected indent
  3252. >>>
  3253. >>>         self.image.remove_layer(self.frames[index].layer)
  3254.   File "<input>", line 1
  3255.     self.image.remove_layer(self.frames[index].layer)
  3256.     ^
  3257. IndentationError: unexpected indent
  3258. >>>         self.frame_bar.remove (self.frames[index])
  3259.   File "<input>", line 1
  3260.     self.frame_bar.remove (self.frames[index])
  3261.     ^
  3262. IndentationError: unexpected indent
  3263. >>>         self.frames[index].destroy()
  3264.   File "<input>", line 1
  3265.     self.frames[index].destroy()
  3266.     ^
  3267. IndentationError: unexpected indent
  3268. >>>         self.frames.remove(self.frames[index])
  3269.   File "<input>", line 1
  3270.     self.frames.remove(self.frames[index])
  3271.     ^
  3272. IndentationError: unexpected indent
  3273. >>>
  3274. >>>         if len(self.frames) == 0:
  3275.   File "<input>", line 1
  3276.     if len(self.frames) == 0:
  3277.     ^
  3278. IndentationError: unexpected indent
  3279. >>>             self._toggle_enable_buttons(NO_FRAMES)
  3280.   File "<input>", line 1
  3281.     self._toggle_enable_buttons(NO_FRAMES)
  3282.     ^
  3283. IndentationError: unexpected indent
  3284. >>>         else :
  3285.   File "<input>", line 1
  3286.     else :
  3287.     ^
  3288. IndentationError: unexpected indent
  3289. >>>             self.on_goto(None,None,True)
  3290.   File "<input>", line 1
  3291.     self.on_goto(None,None,True)
  3292.     ^
  3293. IndentationError: unexpected indent
  3294. >>>         # check if theres layers left.
  3295. >>>         self.on_window_focus(None,None);
  3296.   File "<input>", line 1
  3297.     self.on_window_focus(None,None);
  3298.     ^
  3299. IndentationError: unexpected indent
  3300. >>>
  3301. >>>     def on_add(self,widget,copy=False):
  3302.   File "<input>", line 1
  3303.     def on_add(self,widget,copy=False):
  3304.     ^
  3305. IndentationError: unexpected indent
  3306. >>>         """
  3307.  File "<input>", line 1
  3308.    """
  3309.     ^
  3310. IndentationError: unexpected indent
  3311. >>>         Add new layer to the image and a new frame to the Timeline.
  3312.   File "<input>", line 1
  3313.     Add new layer to the image and a new frame to the Timeline.
  3314.     ^
  3315. IndentationError: unexpected indent
  3316. >>>         if copy is true them the current layer will be copy.
  3317.   File "<input>", line 1
  3318.     if copy is true them the current layer will be copy.
  3319.     ^
  3320. IndentationError: unexpected indent
  3321. >>>         """
  3322.  File "<input>", line 1
  3323.    """
  3324.     ^
  3325. IndentationError: unexpected indent
  3326. >>>         # starting gimp undo group
  3327. >>>         self.image.undo_group_start()
  3328.   File "<input>", line 1
  3329.     self.image.undo_group_start()
  3330.     ^
  3331. IndentationError: unexpected indent
  3332. >>>
  3333. >>>         name = "Frame " + str(len(self.frames))
  3334.   File "<input>", line 1
  3335.     name = "Frame " + str(len(self.frames))
  3336.     ^
  3337. IndentationError: unexpected indent
  3338. >>>         # create the layer to add
  3339. >>>         l = None
  3340.   File "<input>", line 1
  3341.     l = None
  3342.     ^
  3343. IndentationError: unexpected indent
  3344. >>>         if not copy:
  3345.   File "<input>", line 1
  3346.     if not copy:
  3347.     ^
  3348. IndentationError: unexpected indent
  3349. >>>             l = gimp.Layer(self.image,name, self.image.width,self.image.height,RGBA_IMAGE,100,NORMAL_MODE)
  3350.   File "<input>", line 1
  3351.     l = gimp.Layer(self.image,name, self.image.width,self.image.height,RGBA_IMAGE,100,NORMAL_MODE)
  3352.     ^
  3353. IndentationError: unexpected indent
  3354. >>>
  3355. >>>         else: # copy current layer to add
  3356.   File "<input>", line 1
  3357.     else: # copy current layer to add
  3358.     ^
  3359. IndentationError: unexpected indent
  3360. >>>             l = self.frames[self.active].layer.copy()
  3361.   File "<input>", line 1
  3362.     l = self.frames[self.active].layer.copy()
  3363.     ^
  3364. IndentationError: unexpected indent
  3365. >>>             l.name = name
  3366.   File "<input>", line 1
  3367.     l.name = name
  3368.     ^
  3369. IndentationError: unexpected indent
  3370. >>>
  3371. >>>         # adding layer
  3372. >>>         self.image.add_layer(l,len(self.image.layers)-self.active-1)
  3373.   File "<input>", line 1
  3374.     self.image.add_layer(l,len(self.image.layers)-self.active-1)
  3375.     ^
  3376. IndentationError: unexpected indent
  3377. >>>         if self.new_layer_type == TRANSPARENT_FILL and not copy:
  3378.   File "<input>", line 1
  3379.     if self.new_layer_type == TRANSPARENT_FILL and not copy:
  3380.     ^
  3381. IndentationError: unexpected indent
  3382. >>>             pdb.gimp_edit_clear(l)
  3383.   File "<input>", line 1
  3384.     pdb.gimp_edit_clear(l)
  3385.     ^
  3386. IndentationError: unexpected indent
  3387. >>>
  3388. >>>         self._scan_image_layers()
  3389.   File "<input>", line 1
  3390.     self._scan_image_layers()
  3391.     ^
  3392. IndentationError: unexpected indent
  3393. >>>         self.on_goto(None,NEXT,True)
  3394.   File "<input>", line 1
  3395.     self.on_goto(None,NEXT,True)
  3396.     ^
  3397. IndentationError: unexpected indent
  3398. >>>
  3399. >>>         if len(self.frames) == 1 :
  3400.   File "<input>", line 1
  3401.     if len(self.frames) == 1 :
  3402.     ^
  3403. IndentationError: unexpected indent
  3404. >>>             self._toggle_enable_buttons(NO_FRAMES)
  3405.   File "<input>", line 1
  3406.     self._toggle_enable_buttons(NO_FRAMES)
  3407.     ^
  3408. IndentationError: unexpected indent
  3409. >>>
  3410. >>>         # ending gimp undo group
  3411. >>>         self.image.undo_group_end()
  3412.   File "<input>", line 1
  3413.     self.image.undo_group_end()
  3414.     ^
  3415. IndentationError: unexpected indent
  3416. >>>
  3417. >>>     def on_click_goto(self,widget,event):
  3418.   File "<input>", line 1
  3419.     def on_click_goto(self,widget,event):
  3420.     ^
  3421. IndentationError: unexpected indent
  3422. >>>         """
  3423.  File "<input>", line 1
  3424.    """
  3425.     ^
  3426. IndentationError: unexpected indent
  3427. >>>         handlers a click on frame widgets.
  3428.   File "<input>", line 1
  3429.     handlers a click on frame widgets.
  3430.     ^
  3431. IndentationError: unexpected indent
  3432. >>>         """
  3433.  File "<input>", line 1
  3434.    """
  3435.     ^
  3436. IndentationError: unexpected indent
  3437. >>>         i = self.frames.index(widget)
  3438.   File "<input>", line 1
  3439.     i = self.frames.index(widget)
  3440.     ^
  3441. IndentationError: unexpected indent
  3442. >>>         self.on_goto(None,POS,index=i)
  3443.   File "<input>", line 1
  3444.     self.on_goto(None,POS,index=i)
  3445.     ^
  3446. IndentationError: unexpected indent
  3447. >>>
  3448. >>>     def on_goto(self,widget,to,update=False,index=0):
  3449.   File "<input>", line 1
  3450.     def on_goto(self,widget,to,update=False,index=0):
  3451.     ^
  3452. IndentationError: unexpected indent
  3453. >>>         """
  3454.  File "<input>", line 1
  3455.    """
  3456.     ^
  3457. IndentationError: unexpected indent
  3458. >>>         This method change the atual active frame to where the variable
  3459.   File "<input>", line 1
  3460.     This method change the atual active frame to where the variable
  3461.     ^
  3462. IndentationError: unexpected indent
  3463. >>>         (to) indicate, the macros are (START, END, NEXT, PREV,POS,GIMP_ACTIVE)
  3464.   File "<input>", line 1
  3465.     (to) indicate, the macros are (START, END, NEXT, PREV,POS,GIMP_ACTIVE)
  3466.     ^
  3467. IndentationError: unexpected indent
  3468. >>>         - called once per frame when is_playing is enabled.
  3469.   File "<input>", line 1
  3470.     - called once per frame when is_playing is enabled.
  3471.     ^
  3472. IndentationError: unexpected indent
  3473. >>>         """
  3474.  File "<input>", line 1
  3475.    """
  3476.     ^
  3477. IndentationError: unexpected indent
  3478. >>>         self.layers_show(False)
  3479.   File "<input>", line 1
  3480.     self.layers_show(False)
  3481.     ^
  3482. IndentationError: unexpected indent
  3483. >>>
  3484. >>>         if update:
  3485.   File "<input>", line 1
  3486.     if update:
  3487.     ^
  3488. IndentationError: unexpected indent
  3489. >>>             self.frames[self.active].update_layer_info()
  3490.   File "<input>", line 1
  3491.     self.frames[self.active].update_layer_info()
  3492.     ^
  3493. IndentationError: unexpected indent
  3494. >>>
  3495. >>>         if to == START:
  3496.   File "<input>", line 1
  3497.     if to == START:
  3498.     ^
  3499. IndentationError: unexpected indent
  3500. >>>             self.active = 0
  3501.   File "<input>", line 1
  3502.     self.active = 0
  3503.     ^
  3504. IndentationError: unexpected indent
  3505. >>>
  3506. >>>         elif to == END:
  3507.   File "<input>", line 1
  3508.     elif to == END:
  3509.     ^
  3510. IndentationError: unexpected indent
  3511. >>>             self.active = len(self.frames)-1
  3512.   File "<input>", line 1
  3513.     self.active = len(self.frames)-1
  3514.     ^
  3515. IndentationError: unexpected indent
  3516. >>>
  3517. >>>         elif to == NEXT:
  3518.   File "<input>", line 1
  3519.     elif to == NEXT:
  3520.     ^
  3521. IndentationError: unexpected indent
  3522. >>>             i = self.active + 1
  3523.   File "<input>", line 1
  3524.     i = self.active + 1
  3525.     ^
  3526. IndentationError: unexpected indent
  3527. >>>             if i > len(self.frames)-1:
  3528.   File "<input>", line 1
  3529.     if i > len(self.frames)-1:
  3530.     ^
  3531. IndentationError: unexpected indent
  3532. >>>                 i = 0
  3533.   File "<input>", line 1
  3534.     i = 0
  3535.     ^
  3536. IndentationError: unexpected indent
  3537. >>>             self.active = i
  3538.   File "<input>", line 1
  3539.     self.active = i
  3540.     ^
  3541. IndentationError: unexpected indent
  3542. >>>
  3543. >>>         elif to == PREV:
  3544.   File "<input>", line 1
  3545.     elif to == PREV:
  3546.     ^
  3547. IndentationError: unexpected indent
  3548. >>>             i = self.active - 1
  3549.   File "<input>", line 1
  3550.     i = self.active - 1
  3551.     ^
  3552. IndentationError: unexpected indent
  3553. >>>             if i < 0:
  3554.   File "<input>", line 1
  3555.     if i < 0:
  3556.     ^
  3557. IndentationError: unexpected indent
  3558. >>>                 i= len(self.frames)-1
  3559.   File "<input>", line 1
  3560.     i= len(self.frames)-1
  3561.     ^
  3562. IndentationError: unexpected indent
  3563. >>>             self.active = i
  3564.   File "<input>", line 1
  3565.     self.active = i
  3566.     ^
  3567. IndentationError: unexpected indent
  3568. >>>         elif to == POS:
  3569.   File "<input>", line 1
  3570.     elif to == POS:
  3571.     ^
  3572. IndentationError: unexpected indent
  3573. >>>             self.active = index
  3574.   File "<input>", line 1
  3575.     self.active = index
  3576.     ^
  3577. IndentationError: unexpected indent
  3578. >>>
  3579. >>>         elif to == GIMP_ACTIVE:
  3580.   File "<input>", line 1
  3581.     elif to == GIMP_ACTIVE:
  3582.     ^
  3583. IndentationError: unexpected indent
  3584. >>>             if self.image.active_layer in self.image.layers:
  3585.   File "<input>", line 1
  3586.     if self.image.active_layer in self.image.layers:
  3587.     ^
  3588. IndentationError: unexpected indent
  3589. >>>                 self.active = self.image.layers.index(self.image.active_layer)
  3590.   File "<input>", line 1
  3591.     self.active = self.image.layers.index(self.image.active_layer)
  3592.     ^
  3593. IndentationError: unexpected indent
  3594. >>>                 self.active = len(self.image.layers)-1-self.active
  3595.   File "<input>", line 1
  3596.     self.active = len(self.image.layers)-1-self.active
  3597.     ^
  3598. IndentationError: unexpected indent
  3599. >>>             else :self.active = 0
  3600.   File "<input>", line 1
  3601.     else :self.active = 0
  3602.     ^
  3603. IndentationError: unexpected indent
  3604. >>>
  3605. >>>         self.layers_show(True)
  3606.   File "<input>", line 1
  3607.     self.layers_show(True)
  3608.     ^
  3609. IndentationError: unexpected indent
  3610. >>>         self.image.active_layer = self.frames[self.active].layer
  3611.   File "<input>", line 1
  3612.     self.image.active_layer = self.frames[self.active].layer
  3613.     ^
  3614. IndentationError: unexpected indent
  3615. >>>
  3616. >>>         gimp.displays_flush() # update the gimp GUI
  3617.   File "<input>", line 1
  3618.     gimp.displays_flush() # update the gimp GUI
  3619.     ^
  3620. IndentationError: unexpected indent
  3621. >>>
  3622. >>>
  3623. >>>     def layers_show(self,state):
  3624.   File "<input>", line 1
  3625.     def layers_show(self,state):
  3626.     ^
  3627. IndentationError: unexpected indent
  3628. >>>         """
  3629.  File "<input>", line 1
  3630.    """
  3631.     ^
  3632. IndentationError: unexpected indent
  3633. >>>         Util function to hide the old frames and show the next.
  3634.   File "<input>", line 1
  3635.     Util function to hide the old frames and show the next.
  3636.     ^
  3637. IndentationError: unexpected indent
  3638. >>>         """
  3639.  File "<input>", line 1
  3640.    """
  3641.     ^
  3642. IndentationError: unexpected indent
  3643. >>>         self.undo(False)
  3644.   File "<input>", line 1
  3645.     self.undo(False)
  3646.     ^
  3647. IndentationError: unexpected indent
  3648. >>>
  3649. >>>         opacity = 0
  3650.   File "<input>", line 1
  3651.     opacity = 0
  3652.     ^
  3653. IndentationError: unexpected indent
  3654. >>>
  3655. >>>         self.frames[self.active].layer.opacity = 100.0
  3656.   File "<input>", line 1
  3657.     self.frames[self.active].layer.opacity = 100.0
  3658.     ^
  3659. IndentationError: unexpected indent
  3660. >>>
  3661. >>>         if not state:
  3662.   File "<input>", line 1
  3663.     if not state:
  3664.     ^
  3665. IndentationError: unexpected indent
  3666. >>>             opacity = 100.0
  3667.   File "<input>", line 1
  3668.     opacity = 100.0
  3669.     ^
  3670. IndentationError: unexpected indent
  3671. >>>         else :
  3672.   File "<input>", line 1
  3673.     else :
  3674.     ^
  3675. IndentationError: unexpected indent
  3676. >>>             opacity = self.oskin_max_opacity
  3677.   File "<input>", line 1
  3678.     opacity = self.oskin_max_opacity
  3679.     ^
  3680. IndentationError: unexpected indent
  3681. >>>
  3682. >>>         self.frames[self.active].layer.visible = state # show or hide the frame
  3683.   File "<input>", line 1
  3684.     self.frames[self.active].layer.visible = state # show or hide the frame
  3685.     ^
  3686. IndentationError: unexpected indent
  3687. >>>         self.frames[self.active].highlight(state) # highlight or not the frame
  3688.   File "<input>", line 1
  3689.     self.frames[self.active].highlight(state) # highlight or not the frame
  3690.     ^
  3691. IndentationError: unexpected indent
  3692. >>>
  3693. >>>         is_fixed = self.frames[self.active].fixed # if actual frame is fixed
  3694.   File "<input>", line 1
  3695.     is_fixed = self.frames[self.active].fixed # if actual frame is fixed
  3696.     ^
  3697. IndentationError: unexpected indent
  3698. >>>
  3699. >>>         if (self.oskin and not is_fixed) and not(self.is_playing and not self.oskin_onplay):
  3700.   File "<input>", line 1
  3701.     if (self.oskin and not is_fixed) and not(self.is_playing and not self.oskin_onplay):
  3702.     ^
  3703. IndentationError: unexpected indent
  3704. >>>             # calculating the onionskin backward and forward
  3705. >>>             for i in range(1,self.oskin_depth +1):
  3706.   File "<input>", line 1
  3707.     for i in range(1,self.oskin_depth +1):
  3708.     ^
  3709. IndentationError: unexpected indent
  3710. >>>                 # calculating opacity level
  3711. >>>                 o = opacity
  3712.   File "<input>", line 1
  3713.     o = opacity
  3714.     ^
  3715. IndentationError: unexpected indent
  3716. >>>                 if i > 1 and state: o = opacity / i-1 * 2
  3717.   File "<input>", line 1
  3718.     if i > 1 and state: o = opacity / i-1 * 2
  3719.     ^
  3720. IndentationError: unexpected indent
  3721. >>>
  3722. >>>                 pos = self.active - i
  3723.   File "<input>", line 1
  3724.     pos = self.active - i
  3725.     ^
  3726. IndentationError: unexpected indent
  3727. >>>                 if self.oskin_backward and pos >= 0:
  3728.   File "<input>", line 1
  3729.     if self.oskin_backward and pos >= 0:
  3730.     ^
  3731. IndentationError: unexpected indent
  3732. >>>                     is_fixed = self.frames[pos].fixed
  3733.   File "<input>", line 1
  3734.     is_fixed = self.frames[pos].fixed
  3735.     ^
  3736. IndentationError: unexpected indent
  3737. >>>                     if not is_fixed: # discard fixed frames
  3738.   File "<input>", line 1
  3739.     if not is_fixed: # discard fixed frames
  3740.     ^
  3741. IndentationError: unexpected indent
  3742. >>>                         # calculate onionskin depth opacity decay.
  3743. >>>                         self.frames[pos].layer.visible = state
  3744.   File "<input>", line 1
  3745.     self.frames[pos].layer.visible = state
  3746.     ^
  3747. IndentationError: unexpected indent
  3748. >>>                         self.frames[pos].layer.opacity = o
  3749.   File "<input>", line 1
  3750.     self.frames[pos].layer.opacity = o
  3751.     ^
  3752. IndentationError: unexpected indent
  3753. >>>
  3754. >>>                 pos = self.active +i
  3755.   File "<input>", line 1
  3756.     pos = self.active +i
  3757.     ^
  3758. IndentationError: unexpected indent
  3759. >>>                 if self.oskin_forward and pos <= len(self.frames)-1:
  3760.   File "<input>", line 1
  3761.     if self.oskin_forward and pos <= len(self.frames)-1:
  3762.     ^
  3763. IndentationError: unexpected indent
  3764. >>>                     is_fixed = self.frames[pos].fixed
  3765.   File "<input>", line 1
  3766.     is_fixed = self.frames[pos].fixed
  3767.     ^
  3768. IndentationError: unexpected indent
  3769. >>>                     #self.frames[self.active].layer.opacity = min(100.0, 1.5*opacity)
  3770. >>>
  3771. >>>                     if not is_fixed:# discard fixed frames
  3772.   File "<input>", line 1
  3773.     if not is_fixed:# discard fixed frames
  3774.     ^
  3775. IndentationError: unexpected indent
  3776. >>>                         # calculate onionskin depth opacity decay.
  3777. >>>                         self.frames[pos].layer.visible = state
  3778.   File "<input>", line 1
  3779.     self.frames[pos].layer.visible = state
  3780.     ^
  3781. IndentationError: unexpected indent
  3782. >>>                         self.frames[pos].layer.opacity = o
  3783.   File "<input>", line 1
  3784.     self.frames[pos].layer.opacity = o
  3785.     ^
  3786. IndentationError: unexpected indent
  3787. >>>
  3788. >>>         if self.frames[self.active].fixed and state == False:
  3789.   File "<input>", line 1
  3790.     if self.frames[self.active].fixed and state == False:
  3791.     ^
  3792. IndentationError: unexpected indent
  3793. >>>             self.frames[self.active].layer.visible = True
  3794.   File "<input>", line 1
  3795.     self.frames[self.active].layer.visible = True
  3796.     ^
  3797. IndentationError: unexpected indent
  3798. >>>
  3799. >>>         self.undo(True)
  3800.   File "<input>", line 1
  3801.     self.undo(True)
  3802.     ^
  3803. IndentationError: unexpected indent
  3804. >>>
  3805. >>>
  3806. >>> def timeline_main(image,drawable):
  3807. ...     """
  3808. ...     gimp call initial function, created the main timeline window.
  3809. ...     """
  3810. ...     global WINDOW_TITLE
  3811. ...     WINDOW_TITLE = WINDOW_TITLE % (image.name)
  3812. ...     win = Timeline(WINDOW_TITLE,image)
  3813. ...     win.start()
  3814. ...
  3815. >>> # register the script on GIMP
  3816. >>> register(
  3817. ...         "fanim_timeline",
  3818. ...         DESCRIPTION,
  3819. ...         DESCRIPTION,
  3820. ...         AUTHORS[0],
  3821. ...         AUTHORS[0],
  3822. ...         YEAR,
  3823. ...         GIMP_LOCATION,
  3824. ...         "*",
  3825. ...         [],[],timeline_main)
  3826. Traceback (most recent call last):
  3827.   File "<input>", line 1, in <module>
  3828. NameError: name 'register' is not defined
  3829. >>> main()
Add Comment
Please, Sign In to add comment