From 3a3c4bca3a17137bec5d7960560934b91ef4146e Mon Sep 17 00:00:00 2001 From: darco Date: Thu, 24 Mar 2005 21:38:25 +0000 Subject: [PATCH] initial version git-svn-id: http://svn.voria.com/code@8 1f10aa63-cdf2-0310-b900-c93c546f37ac --- synfig-studio/trunk/ChangeLog | 0 synfig-studio/trunk/INSTALL | 3 + synfig-studio/trunk/Makefile.am | 87 + synfig-studio/trunk/NEWS | 336 ++ synfig-studio/trunk/README | 4 + synfig-studio/trunk/alphalicense.txt | 17 + synfig-studio/trunk/bootstrap | 240 + synfig-studio/trunk/config/ETL.m4 | 75 + synfig-studio/trunk/config/build.cfg | 13 + synfig-studio/trunk/config/configure.ac | 186 + synfig-studio/trunk/config/cxx_macros.m4 | 88 + synfig-studio/trunk/config/gnome.m4 | 407 ++ synfig-studio/trunk/config/libxml.m4 | 389 ++ synfig-studio/trunk/config/project.spec.in | 47 + synfig-studio/trunk/config/sinfg.m4 | 51 + synfig-studio/trunk/config/subs.m4 | 276 ++ synfig-studio/trunk/debugcrash | 2 + synfig-studio/trunk/fixer | 10 + synfig-studio/trunk/images/Makefile.am | 75 + synfig-studio/trunk/images/Makefile.inc | 35 + synfig-studio/trunk/images/about_dialog.sif | 1704 ++++++++ synfig-studio/trunk/images/about_icon.sif | 65 + synfig-studio/trunk/images/angle_icon.sif | 65 + synfig-studio/trunk/images/bline_icon.sif | 540 +++ synfig-studio/trunk/images/blinepoint_icon.sif | 66 + synfig-studio/trunk/images/bool_icon.sif | 266 ++ synfig-studio/trunk/images/canvas_icon.sif | 332 ++ synfig-studio/trunk/images/canvas_pointer_icon.sif | 193 + synfig-studio/trunk/images/children_icon.sif | 80 + synfig-studio/trunk/images/circle_icon.sif | 445 ++ synfig-studio/trunk/images/clear_redo_icon.sif | 1834 ++++++++ synfig-studio/trunk/images/clear_undo_icon.sif | 1834 ++++++++ synfig-studio/trunk/images/color_icon.sif | 391 ++ synfig-studio/trunk/images/draw_icon.sif | 199 + synfig-studio/trunk/images/duplicate_icon.sif | 366 ++ synfig-studio/trunk/images/eyedrop_icon.sif | 1386 ++++++ synfig-studio/trunk/images/fill_icon.sif | 3130 +++++++++++++ synfig-studio/trunk/images/gradient_icon.sif | 182 + synfig-studio/trunk/images/group_icon.sif | 2065 +++++++++ synfig-studio/trunk/images/info_icon.sif | 106 + synfig-studio/trunk/images/integer_icon.sif | 66 + synfig-studio/trunk/images/keyframe_icon.sif | 331 ++ synfig-studio/trunk/images/keyframe_lock_icon.sif | 2407 ++++++++++ synfig-studio/trunk/images/layer_icon.sif | 332 ++ synfig-studio/trunk/images/list_icon.sif | 65 + synfig-studio/trunk/images/logo.sif | 3062 +++++++++++++ synfig-studio/trunk/images/meta_data_icon.sif | 80 + synfig-studio/trunk/images/mirror_icon.sif | 202 + synfig-studio/trunk/images/navigator_icon.sif | 451 ++ synfig-studio/trunk/images/normal_icon.sif | 310 ++ synfig-studio/trunk/images/pastecanvas_icon.sif | 2065 +++++++++ synfig-studio/trunk/images/polygon_icon.sif | 288 ++ synfig-studio/trunk/images/real_icon.sif | 281 ++ synfig-studio/trunk/images/rectangle_icon.sif | 310 ++ synfig-studio/trunk/images/rotate_icon.sif | 398 ++ synfig-studio/trunk/images/saveall_icon.sif | 66 + synfig-studio/trunk/images/scale_icon.sif | 199 + synfig-studio/trunk/images/segment_icon.sif | 65 + synfig-studio/trunk/images/sif_icon.sif | 1236 ++++++ synfig-studio/trunk/images/sinfg_icon.sif | 65 + synfig-studio/trunk/images/sketch_icon.sif | 199 + synfig-studio/trunk/images/smooth_move_icon.sif | 199 + synfig-studio/trunk/images/string_icon.sif | 65 + synfig-studio/trunk/images/swap_colors_icon.sif | 308 ++ synfig-studio/trunk/images/time_track_icon.sif | 242 ++ synfig-studio/trunk/images/valuenode_icon.sif | 240 + synfig-studio/trunk/images/vector_icon.sif | 250 ++ synfig-studio/trunk/images/wallpaper.sif | 687 +++ synfig-studio/trunk/images/width_icon.sif | 153 + synfig-studio/trunk/images/zoom_icon.sif | 1976 +++++++++ synfig-studio/trunk/sinfgstudio.desktop.in | 11 + synfig-studio/trunk/sinfgstudio.keys.in | 23 + synfig-studio/trunk/sinfgstudio.mime.in | 7 + synfig-studio/trunk/src/Makefile.am | 20 + synfig-studio/trunk/src/gtkmm/Makefile.am | 53 + synfig-studio/trunk/src/gtkmm/about.cpp | 289 ++ synfig-studio/trunk/src/gtkmm/about.h | 77 + synfig-studio/trunk/src/gtkmm/adjust_window.cpp | 166 + synfig-studio/trunk/src/gtkmm/adjust_window.h | 93 + synfig-studio/trunk/src/gtkmm/app.cpp | 2084 +++++++++ synfig-studio/trunk/src/gtkmm/app.h | 330 ++ synfig-studio/trunk/src/gtkmm/asyncrenderer.cpp | 486 +++ synfig-studio/trunk/src/gtkmm/asyncrenderer.h | 109 + synfig-studio/trunk/src/gtkmm/audiocontainer.cpp | 1393 ++++++ synfig-studio/trunk/src/gtkmm/audiocontainer.h | 138 + synfig-studio/trunk/src/gtkmm/autorecover.cpp | 320 ++ synfig-studio/trunk/src/gtkmm/autorecover.h | 73 + synfig-studio/trunk/src/gtkmm/canvasoptions.cpp | 182 + synfig-studio/trunk/src/gtkmm/canvasoptions.h | 81 + synfig-studio/trunk/src/gtkmm/canvasproperties.cpp | 229 + synfig-studio/trunk/src/gtkmm/canvasproperties.h | 86 + synfig-studio/trunk/src/gtkmm/canvastreestore.cpp | 617 +++ synfig-studio/trunk/src/gtkmm/canvastreestore.h | 194 + synfig-studio/trunk/src/gtkmm/canvasview.cpp | 3552 +++++++++++++++ synfig-studio/trunk/src/gtkmm/canvasview.h | 697 +++ .../trunk/src/gtkmm/cellrenderer_gradient.cpp | 96 + .../trunk/src/gtkmm/cellrenderer_gradient.h | 87 + .../trunk/src/gtkmm/cellrenderer_time.cpp | 132 + synfig-studio/trunk/src/gtkmm/cellrenderer_time.h | 93 + .../trunk/src/gtkmm/cellrenderer_timetrack.cpp | 993 +++++ .../trunk/src/gtkmm/cellrenderer_timetrack.h | 214 + .../trunk/src/gtkmm/cellrenderer_value.cpp | 588 +++ synfig-studio/trunk/src/gtkmm/cellrenderer_value.h | 134 + synfig-studio/trunk/src/gtkmm/childrentree.cpp | 381 ++ synfig-studio/trunk/src/gtkmm/childrentree.h | 176 + .../trunk/src/gtkmm/childrentreestore.cpp | 380 ++ synfig-studio/trunk/src/gtkmm/childrentreestore.h | 140 + synfig-studio/trunk/src/gtkmm/compview.cpp | 608 +++ synfig-studio/trunk/src/gtkmm/compview.h | 124 + synfig-studio/trunk/src/gtkmm/devicetracker.cpp | 76 + synfig-studio/trunk/src/gtkmm/devicetracker.h | 49 + synfig-studio/trunk/src/gtkmm/dialog_color.cpp | 136 + synfig-studio/trunk/src/gtkmm/dialog_color.h | 103 + synfig-studio/trunk/src/gtkmm/dialog_gradient.cpp | 194 + synfig-studio/trunk/src/gtkmm/dialog_gradient.h | 112 + synfig-studio/trunk/src/gtkmm/dialog_keyframe.cpp | 145 + synfig-studio/trunk/src/gtkmm/dialog_keyframe.h | 78 + synfig-studio/trunk/src/gtkmm/dialog_preview.cpp | 156 + synfig-studio/trunk/src/gtkmm/dialog_preview.h | 130 + synfig-studio/trunk/src/gtkmm/dialog_setup.cpp | 619 +++ synfig-studio/trunk/src/gtkmm/dialog_setup.h | 186 + .../trunk/src/gtkmm/dialog_soundselect.cpp | 97 + synfig-studio/trunk/src/gtkmm/dialog_soundselect.h | 84 + .../trunk/src/gtkmm/dialog_tooloptions.cpp | 98 + synfig-studio/trunk/src/gtkmm/dialog_tooloptions.h | 62 + synfig-studio/trunk/src/gtkmm/dialog_waypoint.cpp | 138 + synfig-studio/trunk/src/gtkmm/dialog_waypoint.h | 109 + synfig-studio/trunk/src/gtkmm/dialogsettings.cpp | 185 + synfig-studio/trunk/src/gtkmm/dialogsettings.h | 57 + synfig-studio/trunk/src/gtkmm/dock_canvases.cpp | 248 ++ synfig-studio/trunk/src/gtkmm/dock_canvases.h | 87 + .../trunk/src/gtkmm/dock_canvasspecific.cpp | 172 + .../trunk/src/gtkmm/dock_canvasspecific.h | 72 + synfig-studio/trunk/src/gtkmm/dock_children.cpp | 112 + synfig-studio/trunk/src/gtkmm/dock_children.h | 59 + synfig-studio/trunk/src/gtkmm/dock_curves.cpp | 195 + synfig-studio/trunk/src/gtkmm/dock_curves.h | 73 + synfig-studio/trunk/src/gtkmm/dock_history.cpp | 405 ++ synfig-studio/trunk/src/gtkmm/dock_history.h | 83 + synfig-studio/trunk/src/gtkmm/dock_info.cpp | 143 + synfig-studio/trunk/src/gtkmm/dock_info.h | 64 + synfig-studio/trunk/src/gtkmm/dock_keyframes.cpp | 187 + synfig-studio/trunk/src/gtkmm/dock_keyframes.h | 78 + synfig-studio/trunk/src/gtkmm/dock_layergroups.cpp | 133 + synfig-studio/trunk/src/gtkmm/dock_layergroups.h | 70 + synfig-studio/trunk/src/gtkmm/dock_layers.cpp | 275 ++ synfig-studio/trunk/src/gtkmm/dock_layers.h | 78 + synfig-studio/trunk/src/gtkmm/dock_metadata.cpp | 141 + synfig-studio/trunk/src/gtkmm/dock_metadata.h | 70 + synfig-studio/trunk/src/gtkmm/dock_navigator.cpp | 512 +++ synfig-studio/trunk/src/gtkmm/dock_navigator.h | 120 + synfig-studio/trunk/src/gtkmm/dock_params.cpp | 138 + synfig-studio/trunk/src/gtkmm/dock_params.h | 63 + synfig-studio/trunk/src/gtkmm/dock_timetrack.cpp | 500 +++ synfig-studio/trunk/src/gtkmm/dock_timetrack.h | 67 + synfig-studio/trunk/src/gtkmm/dockable.cpp | 399 ++ synfig-studio/trunk/src/gtkmm/dockable.h | 145 + synfig-studio/trunk/src/gtkmm/dockbook.cpp | 252 ++ synfig-studio/trunk/src/gtkmm/dockbook.h | 88 + synfig-studio/trunk/src/gtkmm/dockdialog.cpp | 536 +++ synfig-studio/trunk/src/gtkmm/dockdialog.h | 127 + synfig-studio/trunk/src/gtkmm/dockmanager.cpp | 308 ++ synfig-studio/trunk/src/gtkmm/dockmanager.h | 81 + synfig-studio/trunk/src/gtkmm/duck.cpp | 193 + synfig-studio/trunk/src/gtkmm/duck.h | 266 ++ synfig-studio/trunk/src/gtkmm/duckmatic.cpp | 1801 ++++++++ synfig-studio/trunk/src/gtkmm/duckmatic.h | 439 ++ .../trunk/src/gtkmm/ducktransform_rotate.h | 73 + .../trunk/src/gtkmm/ducktransform_scale.h | 54 + .../trunk/src/gtkmm/ducktransform_translate.h | 54 + synfig-studio/trunk/src/gtkmm/event_layerclick.h | 63 + synfig-studio/trunk/src/gtkmm/event_mouse.h | 105 + synfig-studio/trunk/src/gtkmm/eventkey.h | 73 + .../trunk/src/gtkmm/groupactionmanager.cpp | 272 ++ synfig-studio/trunk/src/gtkmm/groupactionmanager.h | 84 + synfig-studio/trunk/src/gtkmm/historytreestore.cpp | 214 + synfig-studio/trunk/src/gtkmm/historytreestore.h | 152 + synfig-studio/trunk/src/gtkmm/iconcontroler.cpp | 374 ++ synfig-studio/trunk/src/gtkmm/iconcontroler.h | 72 + synfig-studio/trunk/src/gtkmm/instance.cpp | 1167 +++++ synfig-studio/trunk/src/gtkmm/instance.h | 223 + synfig-studio/trunk/src/gtkmm/ipc.cpp | 324 ++ synfig-studio/trunk/src/gtkmm/ipc.h | 64 + .../trunk/src/gtkmm/keyframeactionmanager.cpp | 246 ++ .../trunk/src/gtkmm/keyframeactionmanager.h | 90 + synfig-studio/trunk/src/gtkmm/keyframetree.cpp | 299 ++ synfig-studio/trunk/src/gtkmm/keyframetree.h | 148 + .../trunk/src/gtkmm/keyframetreestore.cpp | 945 ++++ synfig-studio/trunk/src/gtkmm/keyframetreestore.h | 221 + synfig-studio/trunk/src/gtkmm/keymapsettings.cpp | 110 + synfig-studio/trunk/src/gtkmm/keymapsettings.h | 82 + .../trunk/src/gtkmm/layeractionmanager.cpp | 464 ++ synfig-studio/trunk/src/gtkmm/layeractionmanager.h | 107 + synfig-studio/trunk/src/gtkmm/layergrouptree.cpp | 329 ++ synfig-studio/trunk/src/gtkmm/layergrouptree.h | 126 + .../trunk/src/gtkmm/layergrouptreestore.cpp | 1038 +++++ .../trunk/src/gtkmm/layergrouptreestore.h | 201 + .../trunk/src/gtkmm/layerparamtreestore.cpp | 559 +++ .../trunk/src/gtkmm/layerparamtreestore.h | 163 + synfig-studio/trunk/src/gtkmm/layertree.cpp | 1231 ++++++ synfig-studio/trunk/src/gtkmm/layertree.h | 254 ++ synfig-studio/trunk/src/gtkmm/layertreestore.cpp | 1080 +++++ synfig-studio/trunk/src/gtkmm/layertreestore.h | 218 + synfig-studio/trunk/src/gtkmm/main.cpp | 121 + .../trunk/src/gtkmm/metadatatreestore.cpp | 148 + synfig-studio/trunk/src/gtkmm/metadatatreestore.h | 132 + .../trunk/src/gtkmm/mod_mirror/mod_mirror.cpp | 65 + .../trunk/src/gtkmm/mod_mirror/mod_mirror.h | 58 + .../trunk/src/gtkmm/mod_mirror/state_mirror.cpp | 310 ++ .../trunk/src/gtkmm/mod_mirror/state_mirror.h | 54 + .../trunk/src/gtkmm/mod_palette/dock_palbrowse.cpp | 59 + .../trunk/src/gtkmm/mod_palette/dock_palbrowse.h | 55 + .../trunk/src/gtkmm/mod_palette/dock_paledit.cpp | 380 ++ .../trunk/src/gtkmm/mod_palette/dock_paledit.h | 112 + .../trunk/src/gtkmm/mod_palette/mod_palette.cpp | 77 + .../trunk/src/gtkmm/mod_palette/mod_palette.h | 63 + synfig-studio/trunk/src/gtkmm/module.cpp | 82 + synfig-studio/trunk/src/gtkmm/module.h | 66 + synfig-studio/trunk/src/gtkmm/onemoment.cpp | 114 + synfig-studio/trunk/src/gtkmm/onemoment.h | 52 + synfig-studio/trunk/src/gtkmm/preview.cpp | 876 ++++ synfig-studio/trunk/src/gtkmm/preview.h | 257 ++ synfig-studio/trunk/src/gtkmm/renddesc.cpp | 477 ++ synfig-studio/trunk/src/gtkmm/renddesc.h | 150 + synfig-studio/trunk/src/gtkmm/render.cpp | 283 ++ synfig-studio/trunk/src/gtkmm/render.h | 101 + synfig-studio/trunk/src/gtkmm/renderer_bbox.cpp | 141 + synfig-studio/trunk/src/gtkmm/renderer_bbox.h | 62 + synfig-studio/trunk/src/gtkmm/renderer_canvas.cpp | 212 + synfig-studio/trunk/src/gtkmm/renderer_canvas.h | 62 + synfig-studio/trunk/src/gtkmm/renderer_dragbox.cpp | 151 + synfig-studio/trunk/src/gtkmm/renderer_dragbox.h | 60 + synfig-studio/trunk/src/gtkmm/renderer_ducks.cpp | 452 ++ synfig-studio/trunk/src/gtkmm/renderer_ducks.h | 56 + synfig-studio/trunk/src/gtkmm/renderer_grid.cpp | 170 + synfig-studio/trunk/src/gtkmm/renderer_grid.h | 58 + synfig-studio/trunk/src/gtkmm/renderer_guides.cpp | 281 ++ synfig-studio/trunk/src/gtkmm/renderer_guides.h | 61 + .../trunk/src/gtkmm/renderer_timecode.cpp | 156 + synfig-studio/trunk/src/gtkmm/renderer_timecode.h | 58 + synfig-studio/trunk/src/gtkmm/smach.h | 48 + synfig-studio/trunk/src/gtkmm/state_bline.cpp | 1220 ++++++ synfig-studio/trunk/src/gtkmm/state_bline.h | 54 + synfig-studio/trunk/src/gtkmm/state_circle.cpp | 500 +++ synfig-studio/trunk/src/gtkmm/state_circle.h | 55 + synfig-studio/trunk/src/gtkmm/state_draw.cpp | 1327 ++++++ synfig-studio/trunk/src/gtkmm/state_draw.h | 55 + synfig-studio/trunk/src/gtkmm/state_eyedrop.cpp | 140 + synfig-studio/trunk/src/gtkmm/state_eyedrop.h | 55 + synfig-studio/trunk/src/gtkmm/state_fill.cpp | 176 + synfig-studio/trunk/src/gtkmm/state_fill.h | 55 + synfig-studio/trunk/src/gtkmm/state_gradient.cpp | 492 +++ synfig-studio/trunk/src/gtkmm/state_gradient.h | 55 + synfig-studio/trunk/src/gtkmm/state_normal.cpp | 419 ++ synfig-studio/trunk/src/gtkmm/state_normal.h | 55 + synfig-studio/trunk/src/gtkmm/state_polygon.cpp | 479 ++ synfig-studio/trunk/src/gtkmm/state_polygon.h | 54 + synfig-studio/trunk/src/gtkmm/state_rectangle.cpp | 446 ++ synfig-studio/trunk/src/gtkmm/state_rectangle.h | 55 + synfig-studio/trunk/src/gtkmm/state_rotate.cpp | 383 ++ synfig-studio/trunk/src/gtkmm/state_rotate.h | 55 + synfig-studio/trunk/src/gtkmm/state_scale.cpp | 373 ++ synfig-studio/trunk/src/gtkmm/state_scale.h | 54 + synfig-studio/trunk/src/gtkmm/state_sketch.cpp | 491 +++ synfig-studio/trunk/src/gtkmm/state_sketch.h | 54 + synfig-studio/trunk/src/gtkmm/state_smoothmove.cpp | 322 ++ synfig-studio/trunk/src/gtkmm/state_smoothmove.h | 55 + synfig-studio/trunk/src/gtkmm/state_stroke.cpp | 203 + synfig-studio/trunk/src/gtkmm/state_stroke.h | 79 + synfig-studio/trunk/src/gtkmm/state_width.cpp | 603 +++ synfig-studio/trunk/src/gtkmm/state_width.h | 55 + synfig-studio/trunk/src/gtkmm/state_zoom.cpp | 331 ++ synfig-studio/trunk/src/gtkmm/state_zoom.h | 54 + synfig-studio/trunk/src/gtkmm/statemanager.cpp | 121 + synfig-studio/trunk/src/gtkmm/statemanager.h | 68 + synfig-studio/trunk/src/gtkmm/toolbox.cpp | 627 +++ synfig-studio/trunk/src/gtkmm/toolbox.h | 104 + synfig-studio/trunk/src/gtkmm/valuelink.cpp | 168 + synfig-studio/trunk/src/gtkmm/valuelink.h | 81 + .../trunk/src/gtkmm/widget_canvaschooser.cpp | 148 + .../trunk/src/gtkmm/widget_canvaschooser.h | 66 + synfig-studio/trunk/src/gtkmm/widget_color.cpp | 197 + synfig-studio/trunk/src/gtkmm/widget_color.h | 77 + synfig-studio/trunk/src/gtkmm/widget_coloredit.cpp | 550 +++ synfig-studio/trunk/src/gtkmm/widget_coloredit.h | 183 + .../trunk/src/gtkmm/widget_compselect.cpp | 170 + synfig-studio/trunk/src/gtkmm/widget_compselect.h | 73 + synfig-studio/trunk/src/gtkmm/widget_curves.cpp | 542 +++ synfig-studio/trunk/src/gtkmm/widget_curves.h | 80 + synfig-studio/trunk/src/gtkmm/widget_defaults.cpp | 599 +++ synfig-studio/trunk/src/gtkmm/widget_defaults.h | 98 + synfig-studio/trunk/src/gtkmm/widget_distance.cpp | 100 + synfig-studio/trunk/src/gtkmm/widget_distance.h | 71 + synfig-studio/trunk/src/gtkmm/widget_enum.cpp | 112 + synfig-studio/trunk/src/gtkmm/widget_enum.h | 66 + synfig-studio/trunk/src/gtkmm/widget_filename.cpp | 116 + synfig-studio/trunk/src/gtkmm/widget_filename.h | 71 + synfig-studio/trunk/src/gtkmm/widget_gradient.cpp | 363 ++ synfig-studio/trunk/src/gtkmm/widget_gradient.h | 101 + synfig-studio/trunk/src/gtkmm/widget_sound.cpp | 320 ++ synfig-studio/trunk/src/gtkmm/widget_sound.h | 98 + synfig-studio/trunk/src/gtkmm/widget_time.cpp | 157 + synfig-studio/trunk/src/gtkmm/widget_time.h | 83 + .../trunk/src/gtkmm/widget_timeslider.cpp | 853 ++++ synfig-studio/trunk/src/gtkmm/widget_timeslider.h | 131 + synfig-studio/trunk/src/gtkmm/widget_value.cpp | 484 +++ synfig-studio/trunk/src/gtkmm/widget_value.h | 136 + synfig-studio/trunk/src/gtkmm/widget_vector.cpp | 238 + synfig-studio/trunk/src/gtkmm/widget_vector.h | 95 + synfig-studio/trunk/src/gtkmm/widget_waypoint.cpp | 198 + synfig-studio/trunk/src/gtkmm/widget_waypoint.h | 96 + .../trunk/src/gtkmm/widget_waypointmodel.cpp | 187 + .../trunk/src/gtkmm/widget_waypointmodel.h | 95 + synfig-studio/trunk/src/gtkmm/workarea.cpp | 2521 +++++++++++ synfig-studio/trunk/src/gtkmm/workarea.h | 490 +++ synfig-studio/trunk/src/gtkmm/workarearenderer.cpp | 131 + synfig-studio/trunk/src/gtkmm/workarearenderer.h | 115 + synfig-studio/trunk/src/gtkmm/zoomdial.cpp | 47 + synfig-studio/trunk/src/gtkmm/zoomdial.h | 93 + synfig-studio/trunk/src/sinfgapp/Makefile.am | 50 + synfig-studio/trunk/src/sinfgapp/action.cpp | 449 ++ synfig-studio/trunk/src/sinfgapp/action.h | 387 ++ synfig-studio/trunk/src/sinfgapp/action_param.cpp | 515 +++ synfig-studio/trunk/src/sinfgapp/action_param.h | 236 + synfig-studio/trunk/src/sinfgapp/action_system.cpp | 711 +++ synfig-studio/trunk/src/sinfgapp/action_system.h | 249 ++ .../trunk/src/sinfgapp/actions/activepointadd.cpp | 204 + .../trunk/src/sinfgapp/actions/activepointadd.h | 80 + .../src/sinfgapp/actions/activepointremove.cpp | 176 + .../trunk/src/sinfgapp/actions/activepointremove.h | 76 + .../trunk/src/sinfgapp/actions/activepointset.cpp | 289 ++ .../trunk/src/sinfgapp/actions/activepointset.h | 80 + .../src/sinfgapp/actions/activepointsetoff.cpp | 212 + .../trunk/src/sinfgapp/actions/activepointsetoff.h | 79 + .../src/sinfgapp/actions/activepointseton.cpp | 212 + .../trunk/src/sinfgapp/actions/activepointseton.h | 79 + .../src/sinfgapp/actions/activepointsetsmart.cpp | 364 ++ .../src/sinfgapp/actions/activepointsetsmart.h | 82 + .../src/sinfgapp/actions/activepointsimpleadd.cpp | 182 + .../src/sinfgapp/actions/activepointsimpleadd.h | 80 + .../sinfgapp/actions/blinepointtangentmerge.cpp | 179 + .../src/sinfgapp/actions/blinepointtangentmerge.h | 72 + .../sinfgapp/actions/blinepointtangentsplit.cpp | 179 + .../src/sinfgapp/actions/blinepointtangentsplit.h | 72 + .../trunk/src/sinfgapp/actions/canvasadd.cpp | 150 + .../trunk/src/sinfgapp/actions/canvasadd.h | 76 + .../trunk/src/sinfgapp/actions/canvasremove.cpp | 133 + .../trunk/src/sinfgapp/actions/canvasremove.h | 72 + .../src/sinfgapp/actions/canvasrenddescset.cpp | 125 + .../trunk/src/sinfgapp/actions/canvasrenddescset.h | 74 + .../trunk/src/sinfgapp/actions/colorset.cpp | 145 + .../trunk/src/sinfgapp/actions/colorset.h | 72 + .../trunk/src/sinfgapp/actions/editmodeset.cpp | 128 + .../trunk/src/sinfgapp/actions/editmodeset.h | 71 + .../trunk/src/sinfgapp/actions/gradientset.cpp | 145 + .../trunk/src/sinfgapp/actions/gradientset.h | 73 + .../trunk/src/sinfgapp/actions/groupaddlayers.cpp | 144 + .../trunk/src/sinfgapp/actions/groupaddlayers.h | 78 + .../trunk/src/sinfgapp/actions/groupremove.cpp | 133 + .../trunk/src/sinfgapp/actions/groupremove.h | 78 + .../src/sinfgapp/actions/groupremovelayers.cpp | 142 + .../trunk/src/sinfgapp/actions/groupremovelayers.h | 78 + .../trunk/src/sinfgapp/actions/grouprename.cpp | 129 + .../trunk/src/sinfgapp/actions/grouprename.h | 80 + .../trunk/src/sinfgapp/actions/keyframeadd.cpp | 136 + .../trunk/src/sinfgapp/actions/keyframeadd.h | 73 + .../src/sinfgapp/actions/keyframeduplicate.cpp | 243 ++ .../trunk/src/sinfgapp/actions/keyframeduplicate.h | 76 + .../trunk/src/sinfgapp/actions/keyframeremove.cpp | 231 + .../trunk/src/sinfgapp/actions/keyframeremove.h | 75 + .../trunk/src/sinfgapp/actions/keyframeset.cpp | 429 ++ .../trunk/src/sinfgapp/actions/keyframeset.h | 88 + .../src/sinfgapp/actions/keyframesetdelta.cpp | 259 ++ .../trunk/src/sinfgapp/actions/keyframesetdelta.h | 83 + .../src/sinfgapp/actions/keyframewaypointset.cpp | 176 + .../src/sinfgapp/actions/keyframewaypointset.h | 76 + .../trunk/src/sinfgapp/actions/layeractivate.cpp | 198 + .../trunk/src/sinfgapp/actions/layeractivate.h | 75 + .../trunk/src/sinfgapp/actions/layeradd.cpp | 145 + .../trunk/src/sinfgapp/actions/layeradd.h | 73 + .../trunk/src/sinfgapp/actions/layerduplicate.cpp | 154 + .../trunk/src/sinfgapp/actions/layerduplicate.h | 72 + .../src/sinfgapp/actions/layerencapsulate.cpp | 216 + .../trunk/src/sinfgapp/actions/layerencapsulate.h | 73 + .../trunk/src/sinfgapp/actions/layerlower.cpp | 155 + .../trunk/src/sinfgapp/actions/layerlower.h | 70 + .../trunk/src/sinfgapp/actions/layermove.cpp | 260 ++ .../trunk/src/sinfgapp/actions/layermove.h | 78 + .../src/sinfgapp/actions/layerparamconnect.cpp | 187 + .../trunk/src/sinfgapp/actions/layerparamconnect.h | 78 + .../src/sinfgapp/actions/layerparamdisconnect.cpp | 176 + .../src/sinfgapp/actions/layerparamdisconnect.h | 77 + .../trunk/src/sinfgapp/actions/layerparamset.cpp | 170 + .../trunk/src/sinfgapp/actions/layerparamset.h | 77 + .../trunk/src/sinfgapp/actions/layerraise.cpp | 151 + .../trunk/src/sinfgapp/actions/layerraise.h | 70 + .../trunk/src/sinfgapp/actions/layerremove.cpp | 180 + .../trunk/src/sinfgapp/actions/layerremove.h | 77 + .../trunk/src/sinfgapp/actions/layersetdesc.cpp | 141 + .../trunk/src/sinfgapp/actions/layersetdesc.h | 75 + .../trunk/src/sinfgapp/actions/timepointscopy.cpp | 322 ++ .../trunk/src/sinfgapp/actions/timepointscopy.h | 81 + .../src/sinfgapp/actions/timepointsdelete.cpp | 285 ++ .../trunk/src/sinfgapp/actions/timepointsdelete.h | 79 + .../trunk/src/sinfgapp/actions/timepointsmove.cpp | 327 ++ .../trunk/src/sinfgapp/actions/timepointsmove.h | 84 + .../src/sinfgapp/actions/valuedescconnect.cpp | 216 + .../trunk/src/sinfgapp/actions/valuedescconnect.h | 72 + .../src/sinfgapp/actions/valuedescconvert.cpp | 224 + .../trunk/src/sinfgapp/actions/valuedescconvert.h | 71 + .../src/sinfgapp/actions/valuedescdisconnect.cpp | 193 + .../src/sinfgapp/actions/valuedescdisconnect.h | 71 + .../trunk/src/sinfgapp/actions/valuedescexport.cpp | 199 + .../trunk/src/sinfgapp/actions/valuedescexport.h | 71 + .../trunk/src/sinfgapp/actions/valuedesclink.cpp | 244 ++ .../trunk/src/sinfgapp/actions/valuedesclink.h | 72 + .../trunk/src/sinfgapp/actions/valuedescset.cpp | 532 +++ .../trunk/src/sinfgapp/actions/valuedescset.h | 74 + .../trunk/src/sinfgapp/actions/valuenodeadd.cpp | 162 + .../trunk/src/sinfgapp/actions/valuenodeadd.h | 74 + .../src/sinfgapp/actions/valuenodeconstset.cpp | 147 + .../trunk/src/sinfgapp/actions/valuenodeconstset.h | 76 + .../actions/valuenodedynamiclistinsert.cpp | 196 + .../sinfgapp/actions/valuenodedynamiclistinsert.h | 82 + .../actions/valuenodedynamiclistinsertsmart.cpp | 269 ++ .../actions/valuenodedynamiclistinsertsmart.h | 77 + .../sinfgapp/actions/valuenodedynamiclistloop.cpp | 152 + .../sinfgapp/actions/valuenodedynamiclistloop.h | 77 + .../actions/valuenodedynamiclistremove.cpp | 152 + .../sinfgapp/actions/valuenodedynamiclistremove.h | 77 + .../actions/valuenodedynamiclistremovesmart.cpp | 187 + .../actions/valuenodedynamiclistremovesmart.h | 77 + .../actions/valuenodedynamiclistrotateorder.cpp | 163 + .../actions/valuenodedynamiclistrotateorder.h | 75 + .../actions/valuenodedynamiclistunloop.cpp | 154 + .../sinfgapp/actions/valuenodedynamiclistunloop.h | 77 + .../src/sinfgapp/actions/valuenodelinkconnect.cpp | 159 + .../src/sinfgapp/actions/valuenodelinkconnect.h | 77 + .../sinfgapp/actions/valuenodelinkdisconnect.cpp | 170 + .../src/sinfgapp/actions/valuenodelinkdisconnect.h | 76 + .../trunk/src/sinfgapp/actions/valuenoderemove.cpp | 176 + .../trunk/src/sinfgapp/actions/valuenoderemove.h | 77 + .../trunk/src/sinfgapp/actions/valuenoderename.cpp | 164 + .../trunk/src/sinfgapp/actions/valuenoderename.h | 76 + .../src/sinfgapp/actions/valuenodereplace.cpp | 222 + .../trunk/src/sinfgapp/actions/valuenodereplace.h | 75 + .../trunk/src/sinfgapp/actions/waypointadd.cpp | 213 + .../trunk/src/sinfgapp/actions/waypointadd.h | 82 + .../trunk/src/sinfgapp/actions/waypointremove.cpp | 188 + .../trunk/src/sinfgapp/actions/waypointremove.h | 77 + .../trunk/src/sinfgapp/actions/waypointset.cpp | 266 ++ .../trunk/src/sinfgapp/actions/waypointset.h | 79 + .../src/sinfgapp/actions/waypointsetsmart.cpp | 467 ++ .../trunk/src/sinfgapp/actions/waypointsetsmart.h | 81 + .../src/sinfgapp/actions/waypointsimpleadd.cpp | 156 + .../trunk/src/sinfgapp/actions/waypointsimpleadd.h | 79 + synfig-studio/trunk/src/sinfgapp/blineconvert.cpp | 835 ++++ synfig-studio/trunk/src/sinfgapp/blineconvert.h | 115 + .../trunk/src/sinfgapp/canvasinterface.cpp | 857 ++++ synfig-studio/trunk/src/sinfgapp/canvasinterface.h | 308 ++ synfig-studio/trunk/src/sinfgapp/cvs.cpp | 375 ++ synfig-studio/trunk/src/sinfgapp/cvs.h | 103 + synfig-studio/trunk/src/sinfgapp/editmode.h | 83 + synfig-studio/trunk/src/sinfgapp/inputdevice.cpp | 195 + synfig-studio/trunk/src/sinfgapp/inputdevice.h | 101 + synfig-studio/trunk/src/sinfgapp/instance.cpp | 186 + synfig-studio/trunk/src/sinfgapp/instance.h | 140 + synfig-studio/trunk/src/sinfgapp/main.cpp | 401 ++ synfig-studio/trunk/src/sinfgapp/main.h | 112 + .../trunk/src/sinfgapp/selectionmanager.h | 146 + synfig-studio/trunk/src/sinfgapp/settings.cpp | 237 + synfig-studio/trunk/src/sinfgapp/settings.h | 78 + synfig-studio/trunk/src/sinfgapp/timegather.cpp | 311 ++ synfig-studio/trunk/src/sinfgapp/timegather.h | 135 + synfig-studio/trunk/src/sinfgapp/uimanager.cpp | 157 + synfig-studio/trunk/src/sinfgapp/uimanager.h | 115 + synfig-studio/trunk/src/sinfgapp/value_desc.h | 182 + synfig-studio/trunk/src/template.cpp | 53 + synfig-studio/trunk/src/template.h | 41 + synfig-studio/trunk/studio.kdevprj | 395 ++ synfig-studio/trunk/studio.pbproj/project.pbxproj | 4588 ++++++++++++++++++++ synfig-studio/trunk/studio.prj | 166 + synfig-studio/trunk/win32build.sh | 10 + synfig-studio/trunk/win32inst.nsi.in | 192 + 484 files changed, 130422 insertions(+) create mode 100644 synfig-studio/trunk/ChangeLog create mode 100644 synfig-studio/trunk/INSTALL create mode 100644 synfig-studio/trunk/Makefile.am create mode 100644 synfig-studio/trunk/NEWS create mode 100644 synfig-studio/trunk/README create mode 100644 synfig-studio/trunk/alphalicense.txt create mode 100755 synfig-studio/trunk/bootstrap create mode 100755 synfig-studio/trunk/config/ETL.m4 create mode 100644 synfig-studio/trunk/config/build.cfg create mode 100755 synfig-studio/trunk/config/configure.ac create mode 100755 synfig-studio/trunk/config/cxx_macros.m4 create mode 100755 synfig-studio/trunk/config/gnome.m4 create mode 100755 synfig-studio/trunk/config/libxml.m4 create mode 100755 synfig-studio/trunk/config/project.spec.in create mode 100755 synfig-studio/trunk/config/sinfg.m4 create mode 100755 synfig-studio/trunk/config/subs.m4 create mode 100755 synfig-studio/trunk/debugcrash create mode 100755 synfig-studio/trunk/fixer create mode 100644 synfig-studio/trunk/images/Makefile.am create mode 100644 synfig-studio/trunk/images/Makefile.inc create mode 100644 synfig-studio/trunk/images/about_dialog.sif create mode 100644 synfig-studio/trunk/images/about_icon.sif create mode 100644 synfig-studio/trunk/images/angle_icon.sif create mode 100644 synfig-studio/trunk/images/bline_icon.sif create mode 100644 synfig-studio/trunk/images/blinepoint_icon.sif create mode 100644 synfig-studio/trunk/images/bool_icon.sif create mode 100644 synfig-studio/trunk/images/canvas_icon.sif create mode 100644 synfig-studio/trunk/images/canvas_pointer_icon.sif create mode 100644 synfig-studio/trunk/images/children_icon.sif create mode 100644 synfig-studio/trunk/images/circle_icon.sif create mode 100644 synfig-studio/trunk/images/clear_redo_icon.sif create mode 100644 synfig-studio/trunk/images/clear_undo_icon.sif create mode 100644 synfig-studio/trunk/images/color_icon.sif create mode 100644 synfig-studio/trunk/images/draw_icon.sif create mode 100644 synfig-studio/trunk/images/duplicate_icon.sif create mode 100644 synfig-studio/trunk/images/eyedrop_icon.sif create mode 100644 synfig-studio/trunk/images/fill_icon.sif create mode 100644 synfig-studio/trunk/images/gradient_icon.sif create mode 100644 synfig-studio/trunk/images/group_icon.sif create mode 100644 synfig-studio/trunk/images/info_icon.sif create mode 100644 synfig-studio/trunk/images/integer_icon.sif create mode 100644 synfig-studio/trunk/images/keyframe_icon.sif create mode 100644 synfig-studio/trunk/images/keyframe_lock_icon.sif create mode 100644 synfig-studio/trunk/images/layer_icon.sif create mode 100644 synfig-studio/trunk/images/list_icon.sif create mode 100644 synfig-studio/trunk/images/logo.sif create mode 100644 synfig-studio/trunk/images/meta_data_icon.sif create mode 100644 synfig-studio/trunk/images/mirror_icon.sif create mode 100644 synfig-studio/trunk/images/navigator_icon.sif create mode 100644 synfig-studio/trunk/images/normal_icon.sif create mode 100644 synfig-studio/trunk/images/pastecanvas_icon.sif create mode 100644 synfig-studio/trunk/images/polygon_icon.sif create mode 100644 synfig-studio/trunk/images/real_icon.sif create mode 100644 synfig-studio/trunk/images/rectangle_icon.sif create mode 100644 synfig-studio/trunk/images/rotate_icon.sif create mode 100644 synfig-studio/trunk/images/saveall_icon.sif create mode 100644 synfig-studio/trunk/images/scale_icon.sif create mode 100644 synfig-studio/trunk/images/segment_icon.sif create mode 100644 synfig-studio/trunk/images/sif_icon.sif create mode 100644 synfig-studio/trunk/images/sinfg_icon.sif create mode 100644 synfig-studio/trunk/images/sketch_icon.sif create mode 100644 synfig-studio/trunk/images/smooth_move_icon.sif create mode 100644 synfig-studio/trunk/images/string_icon.sif create mode 100644 synfig-studio/trunk/images/swap_colors_icon.sif create mode 100644 synfig-studio/trunk/images/time_track_icon.sif create mode 100644 synfig-studio/trunk/images/valuenode_icon.sif create mode 100644 synfig-studio/trunk/images/vector_icon.sif create mode 100644 synfig-studio/trunk/images/wallpaper.sif create mode 100644 synfig-studio/trunk/images/width_icon.sif create mode 100644 synfig-studio/trunk/images/zoom_icon.sif create mode 100644 synfig-studio/trunk/sinfgstudio.desktop.in create mode 100644 synfig-studio/trunk/sinfgstudio.keys.in create mode 100644 synfig-studio/trunk/sinfgstudio.mime.in create mode 100644 synfig-studio/trunk/src/Makefile.am create mode 100644 synfig-studio/trunk/src/gtkmm/Makefile.am create mode 100644 synfig-studio/trunk/src/gtkmm/about.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/about.h create mode 100644 synfig-studio/trunk/src/gtkmm/adjust_window.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/adjust_window.h create mode 100644 synfig-studio/trunk/src/gtkmm/app.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/app.h create mode 100644 synfig-studio/trunk/src/gtkmm/asyncrenderer.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/asyncrenderer.h create mode 100644 synfig-studio/trunk/src/gtkmm/audiocontainer.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/audiocontainer.h create mode 100644 synfig-studio/trunk/src/gtkmm/autorecover.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/autorecover.h create mode 100644 synfig-studio/trunk/src/gtkmm/canvasoptions.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/canvasoptions.h create mode 100644 synfig-studio/trunk/src/gtkmm/canvasproperties.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/canvasproperties.h create mode 100644 synfig-studio/trunk/src/gtkmm/canvastreestore.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/canvastreestore.h create mode 100644 synfig-studio/trunk/src/gtkmm/canvasview.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/canvasview.h create mode 100644 synfig-studio/trunk/src/gtkmm/cellrenderer_gradient.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/cellrenderer_gradient.h create mode 100644 synfig-studio/trunk/src/gtkmm/cellrenderer_time.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/cellrenderer_time.h create mode 100644 synfig-studio/trunk/src/gtkmm/cellrenderer_timetrack.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/cellrenderer_timetrack.h create mode 100644 synfig-studio/trunk/src/gtkmm/cellrenderer_value.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/cellrenderer_value.h create mode 100644 synfig-studio/trunk/src/gtkmm/childrentree.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/childrentree.h create mode 100644 synfig-studio/trunk/src/gtkmm/childrentreestore.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/childrentreestore.h create mode 100644 synfig-studio/trunk/src/gtkmm/compview.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/compview.h create mode 100644 synfig-studio/trunk/src/gtkmm/devicetracker.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/devicetracker.h create mode 100644 synfig-studio/trunk/src/gtkmm/dialog_color.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/dialog_color.h create mode 100644 synfig-studio/trunk/src/gtkmm/dialog_gradient.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/dialog_gradient.h create mode 100644 synfig-studio/trunk/src/gtkmm/dialog_keyframe.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/dialog_keyframe.h create mode 100644 synfig-studio/trunk/src/gtkmm/dialog_preview.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/dialog_preview.h create mode 100644 synfig-studio/trunk/src/gtkmm/dialog_setup.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/dialog_setup.h create mode 100644 synfig-studio/trunk/src/gtkmm/dialog_soundselect.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/dialog_soundselect.h create mode 100644 synfig-studio/trunk/src/gtkmm/dialog_tooloptions.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/dialog_tooloptions.h create mode 100644 synfig-studio/trunk/src/gtkmm/dialog_waypoint.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/dialog_waypoint.h create mode 100644 synfig-studio/trunk/src/gtkmm/dialogsettings.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/dialogsettings.h create mode 100644 synfig-studio/trunk/src/gtkmm/dock_canvases.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/dock_canvases.h create mode 100644 synfig-studio/trunk/src/gtkmm/dock_canvasspecific.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/dock_canvasspecific.h create mode 100644 synfig-studio/trunk/src/gtkmm/dock_children.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/dock_children.h create mode 100644 synfig-studio/trunk/src/gtkmm/dock_curves.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/dock_curves.h create mode 100644 synfig-studio/trunk/src/gtkmm/dock_history.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/dock_history.h create mode 100644 synfig-studio/trunk/src/gtkmm/dock_info.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/dock_info.h create mode 100644 synfig-studio/trunk/src/gtkmm/dock_keyframes.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/dock_keyframes.h create mode 100644 synfig-studio/trunk/src/gtkmm/dock_layergroups.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/dock_layergroups.h create mode 100644 synfig-studio/trunk/src/gtkmm/dock_layers.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/dock_layers.h create mode 100644 synfig-studio/trunk/src/gtkmm/dock_metadata.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/dock_metadata.h create mode 100644 synfig-studio/trunk/src/gtkmm/dock_navigator.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/dock_navigator.h create mode 100644 synfig-studio/trunk/src/gtkmm/dock_params.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/dock_params.h create mode 100644 synfig-studio/trunk/src/gtkmm/dock_timetrack.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/dock_timetrack.h create mode 100644 synfig-studio/trunk/src/gtkmm/dockable.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/dockable.h create mode 100644 synfig-studio/trunk/src/gtkmm/dockbook.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/dockbook.h create mode 100644 synfig-studio/trunk/src/gtkmm/dockdialog.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/dockdialog.h create mode 100644 synfig-studio/trunk/src/gtkmm/dockmanager.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/dockmanager.h create mode 100644 synfig-studio/trunk/src/gtkmm/duck.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/duck.h create mode 100644 synfig-studio/trunk/src/gtkmm/duckmatic.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/duckmatic.h create mode 100644 synfig-studio/trunk/src/gtkmm/ducktransform_rotate.h create mode 100644 synfig-studio/trunk/src/gtkmm/ducktransform_scale.h create mode 100644 synfig-studio/trunk/src/gtkmm/ducktransform_translate.h create mode 100644 synfig-studio/trunk/src/gtkmm/event_layerclick.h create mode 100644 synfig-studio/trunk/src/gtkmm/event_mouse.h create mode 100644 synfig-studio/trunk/src/gtkmm/eventkey.h create mode 100644 synfig-studio/trunk/src/gtkmm/groupactionmanager.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/groupactionmanager.h create mode 100644 synfig-studio/trunk/src/gtkmm/historytreestore.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/historytreestore.h create mode 100644 synfig-studio/trunk/src/gtkmm/iconcontroler.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/iconcontroler.h create mode 100644 synfig-studio/trunk/src/gtkmm/instance.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/instance.h create mode 100644 synfig-studio/trunk/src/gtkmm/ipc.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/ipc.h create mode 100644 synfig-studio/trunk/src/gtkmm/keyframeactionmanager.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/keyframeactionmanager.h create mode 100644 synfig-studio/trunk/src/gtkmm/keyframetree.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/keyframetree.h create mode 100644 synfig-studio/trunk/src/gtkmm/keyframetreestore.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/keyframetreestore.h create mode 100644 synfig-studio/trunk/src/gtkmm/keymapsettings.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/keymapsettings.h create mode 100644 synfig-studio/trunk/src/gtkmm/layeractionmanager.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/layeractionmanager.h create mode 100644 synfig-studio/trunk/src/gtkmm/layergrouptree.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/layergrouptree.h create mode 100644 synfig-studio/trunk/src/gtkmm/layergrouptreestore.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/layergrouptreestore.h create mode 100644 synfig-studio/trunk/src/gtkmm/layerparamtreestore.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/layerparamtreestore.h create mode 100644 synfig-studio/trunk/src/gtkmm/layertree.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/layertree.h create mode 100644 synfig-studio/trunk/src/gtkmm/layertreestore.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/layertreestore.h create mode 100644 synfig-studio/trunk/src/gtkmm/main.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/metadatatreestore.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/metadatatreestore.h create mode 100644 synfig-studio/trunk/src/gtkmm/mod_mirror/mod_mirror.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/mod_mirror/mod_mirror.h create mode 100644 synfig-studio/trunk/src/gtkmm/mod_mirror/state_mirror.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/mod_mirror/state_mirror.h create mode 100644 synfig-studio/trunk/src/gtkmm/mod_palette/dock_palbrowse.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/mod_palette/dock_palbrowse.h create mode 100644 synfig-studio/trunk/src/gtkmm/mod_palette/dock_paledit.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/mod_palette/dock_paledit.h create mode 100644 synfig-studio/trunk/src/gtkmm/mod_palette/mod_palette.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/mod_palette/mod_palette.h create mode 100644 synfig-studio/trunk/src/gtkmm/module.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/module.h create mode 100644 synfig-studio/trunk/src/gtkmm/onemoment.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/onemoment.h create mode 100644 synfig-studio/trunk/src/gtkmm/preview.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/preview.h create mode 100644 synfig-studio/trunk/src/gtkmm/renddesc.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/renddesc.h create mode 100644 synfig-studio/trunk/src/gtkmm/render.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/render.h create mode 100644 synfig-studio/trunk/src/gtkmm/renderer_bbox.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/renderer_bbox.h create mode 100644 synfig-studio/trunk/src/gtkmm/renderer_canvas.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/renderer_canvas.h create mode 100644 synfig-studio/trunk/src/gtkmm/renderer_dragbox.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/renderer_dragbox.h create mode 100644 synfig-studio/trunk/src/gtkmm/renderer_ducks.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/renderer_ducks.h create mode 100644 synfig-studio/trunk/src/gtkmm/renderer_grid.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/renderer_grid.h create mode 100644 synfig-studio/trunk/src/gtkmm/renderer_guides.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/renderer_guides.h create mode 100644 synfig-studio/trunk/src/gtkmm/renderer_timecode.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/renderer_timecode.h create mode 100644 synfig-studio/trunk/src/gtkmm/smach.h create mode 100644 synfig-studio/trunk/src/gtkmm/state_bline.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/state_bline.h create mode 100644 synfig-studio/trunk/src/gtkmm/state_circle.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/state_circle.h create mode 100644 synfig-studio/trunk/src/gtkmm/state_draw.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/state_draw.h create mode 100644 synfig-studio/trunk/src/gtkmm/state_eyedrop.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/state_eyedrop.h create mode 100644 synfig-studio/trunk/src/gtkmm/state_fill.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/state_fill.h create mode 100644 synfig-studio/trunk/src/gtkmm/state_gradient.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/state_gradient.h create mode 100644 synfig-studio/trunk/src/gtkmm/state_normal.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/state_normal.h create mode 100644 synfig-studio/trunk/src/gtkmm/state_polygon.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/state_polygon.h create mode 100644 synfig-studio/trunk/src/gtkmm/state_rectangle.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/state_rectangle.h create mode 100644 synfig-studio/trunk/src/gtkmm/state_rotate.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/state_rotate.h create mode 100644 synfig-studio/trunk/src/gtkmm/state_scale.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/state_scale.h create mode 100644 synfig-studio/trunk/src/gtkmm/state_sketch.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/state_sketch.h create mode 100644 synfig-studio/trunk/src/gtkmm/state_smoothmove.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/state_smoothmove.h create mode 100644 synfig-studio/trunk/src/gtkmm/state_stroke.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/state_stroke.h create mode 100644 synfig-studio/trunk/src/gtkmm/state_width.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/state_width.h create mode 100644 synfig-studio/trunk/src/gtkmm/state_zoom.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/state_zoom.h create mode 100644 synfig-studio/trunk/src/gtkmm/statemanager.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/statemanager.h create mode 100644 synfig-studio/trunk/src/gtkmm/toolbox.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/toolbox.h create mode 100644 synfig-studio/trunk/src/gtkmm/valuelink.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/valuelink.h create mode 100644 synfig-studio/trunk/src/gtkmm/widget_canvaschooser.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/widget_canvaschooser.h create mode 100644 synfig-studio/trunk/src/gtkmm/widget_color.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/widget_color.h create mode 100644 synfig-studio/trunk/src/gtkmm/widget_coloredit.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/widget_coloredit.h create mode 100644 synfig-studio/trunk/src/gtkmm/widget_compselect.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/widget_compselect.h create mode 100644 synfig-studio/trunk/src/gtkmm/widget_curves.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/widget_curves.h create mode 100644 synfig-studio/trunk/src/gtkmm/widget_defaults.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/widget_defaults.h create mode 100644 synfig-studio/trunk/src/gtkmm/widget_distance.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/widget_distance.h create mode 100644 synfig-studio/trunk/src/gtkmm/widget_enum.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/widget_enum.h create mode 100644 synfig-studio/trunk/src/gtkmm/widget_filename.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/widget_filename.h create mode 100644 synfig-studio/trunk/src/gtkmm/widget_gradient.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/widget_gradient.h create mode 100644 synfig-studio/trunk/src/gtkmm/widget_sound.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/widget_sound.h create mode 100644 synfig-studio/trunk/src/gtkmm/widget_time.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/widget_time.h create mode 100644 synfig-studio/trunk/src/gtkmm/widget_timeslider.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/widget_timeslider.h create mode 100644 synfig-studio/trunk/src/gtkmm/widget_value.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/widget_value.h create mode 100644 synfig-studio/trunk/src/gtkmm/widget_vector.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/widget_vector.h create mode 100644 synfig-studio/trunk/src/gtkmm/widget_waypoint.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/widget_waypoint.h create mode 100644 synfig-studio/trunk/src/gtkmm/widget_waypointmodel.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/widget_waypointmodel.h create mode 100644 synfig-studio/trunk/src/gtkmm/workarea.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/workarea.h create mode 100644 synfig-studio/trunk/src/gtkmm/workarearenderer.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/workarearenderer.h create mode 100644 synfig-studio/trunk/src/gtkmm/zoomdial.cpp create mode 100644 synfig-studio/trunk/src/gtkmm/zoomdial.h create mode 100644 synfig-studio/trunk/src/sinfgapp/Makefile.am create mode 100644 synfig-studio/trunk/src/sinfgapp/action.cpp create mode 100644 synfig-studio/trunk/src/sinfgapp/action.h create mode 100644 synfig-studio/trunk/src/sinfgapp/action_param.cpp create mode 100644 synfig-studio/trunk/src/sinfgapp/action_param.h create mode 100644 synfig-studio/trunk/src/sinfgapp/action_system.cpp create mode 100644 synfig-studio/trunk/src/sinfgapp/action_system.h create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/activepointadd.cpp create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/activepointadd.h create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/activepointremove.cpp create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/activepointremove.h create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/activepointset.cpp create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/activepointset.h create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/activepointsetoff.cpp create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/activepointsetoff.h create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/activepointseton.cpp create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/activepointseton.h create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/activepointsetsmart.cpp create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/activepointsetsmart.h create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/activepointsimpleadd.cpp create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/activepointsimpleadd.h create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/blinepointtangentmerge.cpp create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/blinepointtangentmerge.h create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/blinepointtangentsplit.cpp create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/blinepointtangentsplit.h create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/canvasadd.cpp create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/canvasadd.h create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/canvasremove.cpp create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/canvasremove.h create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/canvasrenddescset.cpp create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/canvasrenddescset.h create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/colorset.cpp create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/colorset.h create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/editmodeset.cpp create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/editmodeset.h create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/gradientset.cpp create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/gradientset.h create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/groupaddlayers.cpp create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/groupaddlayers.h create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/groupremove.cpp create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/groupremove.h create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/groupremovelayers.cpp create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/groupremovelayers.h create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/grouprename.cpp create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/grouprename.h create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/keyframeadd.cpp create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/keyframeadd.h create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/keyframeduplicate.cpp create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/keyframeduplicate.h create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/keyframeremove.cpp create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/keyframeremove.h create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/keyframeset.cpp create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/keyframeset.h create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/keyframesetdelta.cpp create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/keyframesetdelta.h create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/keyframewaypointset.cpp create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/keyframewaypointset.h create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/layeractivate.cpp create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/layeractivate.h create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/layeradd.cpp create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/layeradd.h create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/layerduplicate.cpp create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/layerduplicate.h create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/layerencapsulate.cpp create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/layerencapsulate.h create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/layerlower.cpp create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/layerlower.h create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/layermove.cpp create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/layermove.h create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/layerparamconnect.cpp create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/layerparamconnect.h create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/layerparamdisconnect.cpp create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/layerparamdisconnect.h create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/layerparamset.cpp create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/layerparamset.h create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/layerraise.cpp create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/layerraise.h create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/layerremove.cpp create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/layerremove.h create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/layersetdesc.cpp create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/layersetdesc.h create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/timepointscopy.cpp create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/timepointscopy.h create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/timepointsdelete.cpp create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/timepointsdelete.h create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/timepointsmove.cpp create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/timepointsmove.h create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/valuedescconnect.cpp create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/valuedescconnect.h create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/valuedescconvert.cpp create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/valuedescconvert.h create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/valuedescdisconnect.cpp create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/valuedescdisconnect.h create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/valuedescexport.cpp create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/valuedescexport.h create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/valuedesclink.cpp create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/valuedesclink.h create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/valuedescset.cpp create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/valuedescset.h create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/valuenodeadd.cpp create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/valuenodeadd.h create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/valuenodeconstset.cpp create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/valuenodeconstset.h create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/valuenodedynamiclistinsert.cpp create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/valuenodedynamiclistinsert.h create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/valuenodedynamiclistinsertsmart.cpp create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/valuenodedynamiclistinsertsmart.h create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/valuenodedynamiclistloop.cpp create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/valuenodedynamiclistloop.h create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/valuenodedynamiclistremove.cpp create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/valuenodedynamiclistremove.h create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/valuenodedynamiclistremovesmart.cpp create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/valuenodedynamiclistremovesmart.h create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/valuenodedynamiclistrotateorder.cpp create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/valuenodedynamiclistrotateorder.h create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/valuenodedynamiclistunloop.cpp create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/valuenodedynamiclistunloop.h create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/valuenodelinkconnect.cpp create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/valuenodelinkconnect.h create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/valuenodelinkdisconnect.cpp create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/valuenodelinkdisconnect.h create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/valuenoderemove.cpp create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/valuenoderemove.h create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/valuenoderename.cpp create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/valuenoderename.h create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/valuenodereplace.cpp create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/valuenodereplace.h create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/waypointadd.cpp create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/waypointadd.h create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/waypointremove.cpp create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/waypointremove.h create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/waypointset.cpp create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/waypointset.h create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/waypointsetsmart.cpp create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/waypointsetsmart.h create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/waypointsimpleadd.cpp create mode 100644 synfig-studio/trunk/src/sinfgapp/actions/waypointsimpleadd.h create mode 100644 synfig-studio/trunk/src/sinfgapp/blineconvert.cpp create mode 100644 synfig-studio/trunk/src/sinfgapp/blineconvert.h create mode 100644 synfig-studio/trunk/src/sinfgapp/canvasinterface.cpp create mode 100644 synfig-studio/trunk/src/sinfgapp/canvasinterface.h create mode 100644 synfig-studio/trunk/src/sinfgapp/cvs.cpp create mode 100644 synfig-studio/trunk/src/sinfgapp/cvs.h create mode 100644 synfig-studio/trunk/src/sinfgapp/editmode.h create mode 100644 synfig-studio/trunk/src/sinfgapp/inputdevice.cpp create mode 100644 synfig-studio/trunk/src/sinfgapp/inputdevice.h create mode 100644 synfig-studio/trunk/src/sinfgapp/instance.cpp create mode 100644 synfig-studio/trunk/src/sinfgapp/instance.h create mode 100644 synfig-studio/trunk/src/sinfgapp/main.cpp create mode 100644 synfig-studio/trunk/src/sinfgapp/main.h create mode 100644 synfig-studio/trunk/src/sinfgapp/selectionmanager.h create mode 100644 synfig-studio/trunk/src/sinfgapp/settings.cpp create mode 100644 synfig-studio/trunk/src/sinfgapp/settings.h create mode 100644 synfig-studio/trunk/src/sinfgapp/timegather.cpp create mode 100644 synfig-studio/trunk/src/sinfgapp/timegather.h create mode 100644 synfig-studio/trunk/src/sinfgapp/uimanager.cpp create mode 100644 synfig-studio/trunk/src/sinfgapp/uimanager.h create mode 100644 synfig-studio/trunk/src/sinfgapp/value_desc.h create mode 100644 synfig-studio/trunk/src/template.cpp create mode 100644 synfig-studio/trunk/src/template.h create mode 100644 synfig-studio/trunk/studio.kdevprj create mode 100755 synfig-studio/trunk/studio.pbproj/project.pbxproj create mode 100644 synfig-studio/trunk/studio.prj create mode 100755 synfig-studio/trunk/win32build.sh create mode 100644 synfig-studio/trunk/win32inst.nsi.in diff --git a/synfig-studio/trunk/ChangeLog b/synfig-studio/trunk/ChangeLog new file mode 100644 index 0000000..e69de29 diff --git a/synfig-studio/trunk/INSTALL b/synfig-studio/trunk/INSTALL new file mode 100644 index 0000000..abd5c1b --- /dev/null +++ b/synfig-studio/trunk/INSTALL @@ -0,0 +1,3 @@ +$Id: INSTALL,v 1.1.1.1 2005/01/07 03:34:35 darco Exp $ +Just a placeholder for now. + diff --git a/synfig-studio/trunk/Makefile.am b/synfig-studio/trunk/Makefile.am new file mode 100644 index 0000000..4fdd09f --- /dev/null +++ b/synfig-studio/trunk/Makefile.am @@ -0,0 +1,87 @@ +# $Header: /opt/voria/cvs/studio/Makefile.am,v 1.2 2005/01/17 06:25:42 darco Exp $ + +AUTOMAKE_OPTIONS=dist-zip dist-shar dist-bzip2 + +MAINTAINERCLEANFILES=config/config.guess config/config.sub config/ltmain.sh config/install-sh config/mkinstalldirs config/aclocal.m4 config/missing config/texinfo.tex config/depcomp aclocal.m4 config.h.in configure stamp-h.in Makefile.in config.log config.status .doc_stamp .DS_Store @PACKAGE_TARNAME@-@VERSION@.spec + +SUBDIRS=images src + +EXTRA_DIST=bootstrap config/depcomp config/cxx_macros.m4 @PACKAGE_TARNAME@-@VERSION@.spec config/project.spec.in config/build.cfg sinfg.kdevprj config/ETL.m4 + +# Desktop entry +#desktopdir = $(datadir)/gnome/apps/Graphics +desktopdir = $(prefix)/share/applications +desktop_DATA = sinfgstudio.desktop +#desktop_in_files = sinfgstudio.desktop.in +#desktop_DATA = $(desktop_in_files:.desktop.in=.desktop) + +# @INTLTOOL_DESKTOP_RULE@ + +mimedir = $(prefix)/share/mime-info +mime_DATA = sinfgstudio.keys sinfgstudio.mime + +# Icon +icondir = $(datadir)/pixmaps +icon_DATA = images/sinfg_icon.png images/sif_icon.png + + +CVS=cvs +GREP=grep +PRINTF=printf +SH=sh +DOXYGEN=doxygen + +stats: + -@echo + -@echo -- Stats + -@echo + -@$(PRINTF) "Total lines: " + -@wc -l $(shell find $(top_srcdir)/src -name '*.[ch]*' | $(GREP) -v libavcodec) | $(GREP) total + -@$(PRINTF) "Total size: " + -@du -hcs $(shell find $(top_srcdir)/src -name '*.[ch]*' | $(GREP) -v libavcodec) | $(GREP) total + -@echo + +tagstable: + $(CVS) tag -F stable + +tagrelease: + $(CVS) tag -F @PACKAGE_TARNAME@_@VERSION_MAJ@_@VERSION_MIN@_@VERSION_REV@ + +listfixmes: + -@echo + -@echo -- List of pending FIXMEs + -@echo + -@$(GREP) FIXME -n $(shell find $(top_srcdir) -name '*.[ch]*') + -@echo + +listhacks: + -@echo + -@echo -- List of pending HACKs + -@echo + -@$(GREP) HACK -n $(shell find $(top_srcdir) -name '*.[ch]*') + -@echo + +run: check + +$(srcdir)/configure: $(srcdir)/configure.in $(ACLOCAL_M4) $(CONFIGURE_DEPENDENCIES) + $(srcdir)/bootstrap + +.doc_stamp: doxygen.cfg + $(DOXYGEN) doxygen.cfg + touch .doc_stamp + +win32inst.nsi: win32inst.nsi.in + ./config.status win32inst.nsi + +installer: all win32inst.nsi + convert images/about_dialog.png images/about_dialog.bmp + make -C images sif_icon.ico + makensis win32inst.nsi + +html: .doc_stamp + +rtf: .doc_stamp + +docs: pdf html + +.PHONY: stats tagstable tagrelease listfixmes listhacks check docs pdf html rtf diff --git a/synfig-studio/trunk/NEWS b/synfig-studio/trunk/NEWS new file mode 100644 index 0000000..7209de9 --- /dev/null +++ b/synfig-studio/trunk/NEWS @@ -0,0 +1,336 @@ +2004-04-26 (darco): Delete button now deletes layers +2004-04-21 (darco): Various improvements to the dock/dialog system +2004-04-19 (adruab): Added Zoom out to the zoom tool using the Ctrl key +2004-04-16 (adruab): Added basic zoom tool +2004-04-15 (darco): Added meta data stuff to properties dialog +2004-04-12 (darco): Dockable Dialog madness! +2004-04-08 (darco): Changed "Select All Ducks" from CTRL-F to CTRL-G +2004-04-08 (darco): Added search capability to layer tree. (Ctrl-F) +2004-04-08 (darco): The order of the layers is now accurate for a given moment in time +2004-04-07 (darco): Foldy... Powers? +2004-04-07 (darco): Added the length field to keyframe tab +2004-04-02 (adruab): Added a preview thing... it's cool +2004-04-02 (darco): The rulers now adhere to the default unit system +2004-04-02 (darco): Improved defaults display +2004-04-01 (darco): Different units now supported +2004-03-31 (darco): Tweaks now preserved! +2004-03-30 (darco): Checkerboard pattern now used to convey alpha +2004-03-30 (darco): got rid of stupid negative zero thing in color selection dialog +2004-03-30 (darco): Adjustments to color dialog to reduce crashes (hopefully) +2004-03-30 (darco): Changed default frame rate from 30 to 24 FPS +2004-03-30 (darco): Fixed keyframe weirdness +2004-03-25 (darco): fixed the zillion dialog box bug +2004-03-25 (darco): Minor improvements to parameter view +2004-03-25 (darco): Added "Select all children" option for layers +2004-03-24 (darco): Added hack to make connecting and disconnecting BLinePoints(vertices) easier +2004-03-22 (darco): Improved grid snap +2004-03-18 (darco): You can now rotate the order of the items in a list! +2004-03-17 (darco): Linking! +2004-03-16 (darco): You can now rename layers with a single click +2004-03-16 (darco): You can now edit parameters even when you have multiple layers selected (Useful!) +2004-03-15 (darco): Added the ability to jump around on the history tab +2004-03-15 (darco): You can now right-click on ducks to edit waypoints! Group selection even! +2004-03-08 (darco): Improved vertex addition/removal +2004-03-05 (darco): Fixed weird tangent bug in BLine tool +2004-03-05 (darco): You can now change all of the waypoints in a keyframe rather easily by right clicking on the keyframe in the keyframe tab and selecting "Properties". +2004-03-05 (darco): Keyframe manipulation now much faster +2004-03-04 (darco): BLine tool will now automaticly create if you leave the tool with something in it +2004-03-04 (darco): You can now close polygons in the polygon tool by clicking on the first point in the polygon +2004-03-04 (darco): Improved grid snap stuff +2004-03-02 (darco): Fixed weird selection box when using fill tool +2004-03-02 (darco): Fixed crash on undo stroke from sketch tool +2004-03-02 (darco): Added Rotate Tool +2004-03-02 (darco): Improved the performance of the duck manipulation tools +2004-03-01 (darco): minor adjustment for deleting waypoints +2004-03-01 (darco): Fixed a crash bug on waypoint manipulation +2004-02-20 (darco): Changed the way the BLine tool operates +2004-02-20 (darco): Added "Clear History" button to the "history" tab +2004-02-18 (darco): Added palette dialog +2004-02-18 (darco): Menus no longer activate the first item in the menu when you click to open it +2004-02-16 (darco): slight improvement to the way gradients are handled +2004-02-16 (darco): Added "Apply Deafult Gradient" action for gradient parameters. (just right click on them) +2004-02-16 (darco): The mouse pointer will now change depending on the currently selected tool. +2004-02-16 (darco): Moved icons around +2004-02-16 (darco): File selection dialog box now remembers previous path +2004-02-13 (darco): Added box select +2004-02-12 (darco): Added Scale tool! +2004-02-12 (darco): Added SmoothMove tool! +2004-02-11 (darco): You can now drag sketch files into canvases to load the sketch +2004-02-11 (adruab): Added rect tool and futzed with the tool options for the draw tool. +2004-02-11 (darco) : Fixed crash-on-exit bug +2004-02-11 (darco) : Added "File->Revert" menu option +2004-02-10 (darco) : Crash on "CVS-Update" bug fixed +2004-02-10 (darco) : Fixed layer-click problem after using the gradient tool +2004-02-10 (darco) : Added "Grab" button +2004-02-10 (darco) : Draw, Gradient, and BLine tool now add layers "in place" +2004-02-09 (darco) : Added preliminary gradient support +2004-02-09 (darco) : Added "CTRL-D" to unselect all layers +2004-02-09 (darco) : Added feather option to the draw and bline tools. +2004-02-09 (darco) : Polygon tool is now implemented correctly +2004-02-09 (darco) : Increased the size of the "One moment please..." font. +2004-02-09 (darco) : Negative color values are now clamped off. +2004-02-07 (darco) : Auto recovery now no longer saves the recovery files in the same directory, which should lead to a more tidy filesystem. +2004-02-06 (darco) : You can now move multiple layers at once +2004-02-06 (darco) : Layer heirarchies are now less likely to collapse when moving layers. +2004-02-06 (darco) : Raising multiple layers at the same time now works correctly +2004-02-06 (darco) : Encapsulating no longer puts the encapsulated layer at the top +2004-02-06 (darco) : Gradient previews are now antialiased +2004-02-06 (darco) : Fixed odd positioning of dialogs +2004-02-06 (darco) : Changed the BLine tool to have a more consistant user interface +2004-02-05 (darco) : Fixed a bug in the text layer regarding the size duck +2004-01-27 (darco) : Strokes in the draw tool should now draw better and undo better. +2004-01-27 (darco) : Added "fill last stroke" button to draw tool options +2004-01-27 (darco) : Auto crash-recovery feature now implemented! +2004-01-27 (darco) : Canvas should now only redraw when a value is truly changed. (ie: just opening a parameter and not changing it will now no longer force a redraw, or add a new action) +2004-01-24 (darco) : Improved consistancy of tool options dialog when working with several canvases at the same time +2004-01-24 (darco) : Fixed a bug with loading sketches where the loaded sketch would dissapear. +2004-01-23 (darco) : Fixed width duck size bug +2004-01-23 (darco) : Improved existing icons +2004-01-23 (darco) : Added new icons +2004-01-23 (darco) : Fixed bug where studio would ask you to commit file not in repository or sandbox +2004-01-22 (darco) : Initial version of the split layer tab +2004-01-21 (darco) : Changed the "default width" to "0.01" and the default increment to "0.005" +2004-01-21 (darco) : SINFG Studio will now ask you to commit your file to CVS upon exit if you haven't already. +2004-01-21 (darco) : Fixed bug where the color sliders in the gradient editor didn't work. +2004-01-21 (darco) : You can now load and save sketches +2004-01-19 (darco) : Minor fix for remembering settings +2004-01-19 (darco) : Added "Auto Loop" and "Auto Connect" toggles to the tool options for the draw tool. +2004-01-19 (darco) : Tool options for the draw tool are now retained between sessions. Tool options can also be customized for specific input devices.(that last part may be slightly buggy) +2004-01-19 (darco) : Added a "show sketch" toggle to the tool options for the scribble tool. This allows you to temporarily hide the sketch. +2004-01-19 (darco) : changed default grid size from 0.2,0.2 to 0.25,0.25 +2004-01-17 (darco) : Individual input devices should now remember their associated settings +2004-01-17 (darco) : Dialogs should now remember their positions +2004-01-17 (darco) : Added some tool options for draw tool +2004-01-16 (darco) : Tool Options dialog has been implemented. Currently the only tool that supports it is the sketch tool +2004-01-16 (darco) : You can now clear the sketch area via the tool options dialog when the sketch tool is selected +2004-01-16 (darco) : Changes in the color dialog are now immediately reflected in whatever is in context. (As opposed to having to always hit "apply") +2004-01-16 (darco) : Sketch tool is now persistant. Still needs some work--as it stands, you can't undo or turn off the sketch without closing the file and opening it up again. +2004-01-15 (darco) : Added preliminary version of the sketch tool. This version doesn't suport colors, or persist across different tools yet. This support is on the way. +2004-01-15 (darco) : Renamed tools +2004-01-14 (darco) : Updates for supporting new BLines +2004-01-14 (darco) : Import tool now respects the width and height of a bitmap when placing it +2004-01-13 (darco) : Added support for multiple-line strings (for layers such as the Text layer) +2004-01-13 (darco) : Added low-resolution mode to work area to speed up render times. You can toggle it on and off via the View->ToggleLow-Res menu item. (Low-res mode is ON by default) +2004-01-09 (darco) : drawing onto the start or end of an existing BLine will now extend it rather than creating a new BLine +2004-01-09 (darco) : You can now delete canvases from the canvas browser. +2004-01-07 (adruab) : Pen sample grouping, gets rid of small errors in line, but also tends to cause breaking to occur at lower curvatures than it should +2004-01-06 (darco) : Preliminary support for creating regions now implemented. It is EXTREMELY buggy, but it gives you an idea of what you can do with it. +2004-01-06 (darco) : I fixed an error that is probably the source for many of the random crashes that seem to occur. +2004-01-05 (darco) : Individual input devices (mouse, wacom tablet, etc) will now remember their associated tool, color, and BLine width. These settings are not yet saved on program exit--this will be implemented in the future. +2004-01-05 (darco) : You can now adjust the default BLine size by directly clicking up the upper or lower part of the BLine size indicator. +2004-01-05 (darco) : You can now draw looped blines in the sketch tool. +2004-01-02 (adruab) : Fixed weird reversing tangents bug +2004-01-01 (adruab) : Added tangent breaking to the curve input tool (first post of 2004 :P) +2003-12-28 (adruab) : Fixed the dumb adaptive tesselator, and put pressure sensitivity back in +2003-12-28 (adruab) : Finished the "dumb" adaptive curve tesselator (-bugs) +2003-12-28 (darco) : Added physical dimensions to properties and render dialogs +2003-12-24 (darco) : The clicking-too-fast bug should be fixed +2003-12-24 (darco) : Added Fill Tool +2003-12-23 (darco) : Preliminary support for automatic vertex connection when scribbiling in the new rotoscope tool +2003-12-19 (darco) : Fix for last vertex width being wrong when drawing +2003-12-18 (darco) : The zero-tangent bug with the new rotoscope should also be fixed +2003-12-18 (darco) : Tangent handles are now turned off when rotoscoping +2003-12-18 (darco) : Improved pressure sensitivity. +2003-12-18 (darco) : Pressure sensitivity... :) +2003-12-18 (darco) : Preliminary tablet support now implemented +2003-12-17 (darco) : A handful of under-the-hood tweaks that should make using the program a tad more friendly. +2003-12-17 (darco) : Improvements to the new rotoscope +2003-12-17 (darco) : Creating a new layer will now insert it at the depth of the currently selected layer +2003-12-03 (darco) : The place-holder for the new rotoscope now creates blines +2003-12-03 (darco) : Fixed minor bug with disconnecting value nodes +2003-12-02 (darco) : Improved about dialog graphic +2003-12-02 (darco) : When you open a really big canvas, it is now auto-zoomed out to fit the window. +2003-12-01 (darco) : Tool buttons can now show you which tool is currently active. +2003-11-29 (darco) : Changed default aspect ratio of new composition from 4:3 to 16:9 +2003-11-29 (darco) : Changed default resolution of new composition from 75dpi to 72dpi +2003-11-29 (darco) : Added locks&links to properties dialog. +2003-11-29 (darco) : Converted resolution in Properties from Dots-per-meter to Dots-per-inch +2003-11-29 (darco) : Added stub for new rotoscope tool. It doesn't do much at the moment other than let you temporarily draw over the window. +2003-11-25 (darco) : Removed the useless red-blue selection +2003-11-18 (darco) : Fixed weird crash-bug when importing compositions +2003-11-13 (darco) : Fixed bug where encapsulating might re-order the layers +2003-11-12 (darco) : Opening a new large composition will no longer result in un-weildly large canvas windows. +2003-11-12 (darco) : Improved all of the CVS command. +2003-11-12 (darco) : "CVS Add" will no longer ask you for a log entry. You enter the log entry when you "commit" +2003-11-12 (darco) : Using "saveas" will now append ".sif" to the filename if you didn't specify an extension. +2003-11-10 (darco) : The default value increment/decrement for the Waypoint Dialog has been changed from 1.0(which is fairly useless) to 0.1. (This is mostly for the TCB controls) +2003-11-10 (darco) : Ducks now (for the most part) are always accurate with respect to what they are visually representing. They are now context-sensitive. :) +2003-11-06 (darco) : You can now import other SINFG compositions in the exact same way you would import any other image. +2003-11-06 (darco) : Added "remove" to waypoint right-click menu. +2003-11-05 (darco) : Fixed a refresh bug with the time window and the children tab +2003-11-05 (darco) : Added the ability to duplicate waypoints +2003-10-31 (darco) : Grid snap now works again +2003-10-31 (darco) : Added "Jump" column to keyframe tab +2003-10-31 (darco) : MUCH IMPROVED support for selecting and moving multiple ducks +2003-10-30 (darco) : Preliminary support for selecting and moving multiple ducks +2003-10-28 (darco) : Fixed CVS-MODIFIED bug due to daylight-saving time +2003-10-22 (darco) : Added some CVS features (Although their usefulness is limited in windows) +2003-10-22 (darco) : Fixed some weirdness with undo/redo/refresh +2003-10-21 (darco) : Fixed some rotoscope weirdness +2003-10-21 (darco) : Minor improvement for confusing behavior of progress bar when rendering +2003-10-21 (darco) : A dialog box will now pop up whenever it is unable to open a composition +2003-10-21 (darco) : Added placeholders for icons +2003-10-21 (darco) : Fixed most (all?) of the crazy Gtk/Glib errors. +2003-10-19 (darco) : Fixed a bug where the "Use Current Frame" option in the Render Dialog was not being checked properly (meaning you couldn't render animatons) +2003-10-15 (darco) : Added eyedrop tool icon +2003-10-15 (darco) : Improved scrolling of work area +2003-10-15 (darco) : Added Eyedrop tool +2003-10-11 (darco) : Changed default undo/redo behavior to NOT clear the "redo" stack when a new action is performed. (the previous action was to clear the redo stack) +2003-10-11 (darco) : Fixed some weirdness with the children tab +2003-10-11 (darco) : Several speed improvements for the tables. This will greatly speed up loading files, editing values, and adjustments to keyframes. +2003-10-10 (darco) : The "Zoom to 100%" feature can now be accessed by pressing the "`" key. (This is the that has the "~" on it) +2003-10-10 (darco) : The "Zoom to 100%" feature will not "toggle", meaning that if you are alreay at a "100%" zoom level, then it will return to the previous zoom amount. +2003-10-08 (darco) : Fixed first/last point on looped bline not being splitable from the work area duck. +2003-10-07 (darco) : Fixed weird idle->rendering->idle->rendering switching bug +2003-10-07 (darco) : Added blend_method option to layer tab +2003-10-07 (darco) : Added amount slider to Layer tab +2003-10-07 (darco) : Layers are now categorized +2003-10-06 (darco) : Added red-blue gamma adjustment to setup dialog +2003-10-06 (darco) : Implemented Image Import Tool. (CTRL-I) +2003-10-06 (darco) : The Ducks in the Work Area are now more percisely placed. (Especially obvious for radiuses) +2003-10-06 (darco) : Implemented adjustable default BLine width. To adjust it, use the scroll wheel on your mouse. +2003-10-06 (darco) : Fixed bug where changing parameters may not always refresh the work area. (AGAIN) +2003-10-06 (darco) : Fixed dragging-layer-into-inline-canvas crash bug. +2003-10-06 (darco) : Removed activepoint-specific actions for non-animated canvases +2003-10-04 (darco) : Fixed bug where when dragging a layer below it ends up being one off. +2003-10-04 (darco) : Added button to toolbox for quickly displaying the color dialog +2003-10-04 (darco) : Fixed some minor consistancy issues regarding the layer tab. (ie: disconnections not being visible...) +2003-10-04 (darco) : You can now sort the ValueNodes in the Children tab +2003-10-04 (darco) : Fixed bug where changing parameters may not always refresh the work area. +2003-10-04 (darco) : Hopefuly fixed "dissapearing new layer menu" bug +2003-10-03 (darco) : Preliminary support for editing layer descriptions +2003-09-30 (darco) : Changing a canvas parameter now no longer requires you to click elsewhere before it takes effect. +2003-09-30 (darco) : Changing an Enum parameter now no longer requires you to click elsewhere before it takes effect. +2003-09-30 (darco) : The Keyframe tab and the TimeTrack columns are now hidden when the canvas's start and end times are equal (ie: if it isn't animated) +2003-09-30 (darco) : Added hotkey for toggling grid snap -- CONTROL-L +2003-09-30 (darco) : Added hotkey for toggling the grid -- CONTROL-G +2003-09-30 (darco) : Right clicking on the default colors (in the toolbox) will swap the FG and BG colors. +2003-09-30 (darco) : Right clicking on the default gradient (in the toolbox) will revert it back to being the FG->BG gradient. +2003-09-30 (darco) : Added several keyboard accelerators. F8="Properties Dialog", F9="Render", F12="Options" +2003-09-30 (darco) : Added "SaveAs..." to CanvasView "File" menu. +2003-09-30 (darco) : The "Escape" key is now bound to the stop button. +2003-09-30 (darco) : Added red-border visual queue for when we are in animate mode. +2003-09-30 (darco) : You can now right click on layers inside of the work area and raise/lower them +2003-09-30 (darco) : Added the ability to change the render quality of the work area. (View->PreviewQuality) +2003-09-30 (darco) : You can now loop/unloop BLines and DynamicLists by right clicking on them. +2003-09-30 (darco) : You can now halt rendering by pressing the stop button +2003-09-30 (darco) : Improved BLine editing via BLine Rotoscope tool. You now insert points by right clicking on the curve rather than the vertex. +2003-09-29 (darco) : Improved layer Drag-N-Drop +2003-09-25 (darco) : Layers can now be rearanged via Drag-N-Drop +2003-09-25 (darco) : The BLine Rotoscope tool now automaticly uses more reasonable tangents +2003-09-24 (darco) : You can now select layers from the work area that are inside inline canvases by just clicking on them. +2003-09-24 (darco) : Selecting a layer from the work area will now cause the layer tab to scroll to make that layer visible. +2003-09-24 (darco) : Improved in-line canvas editing (now it doesn't collapse ever time you make a change) +2003-09-24 (darco) : Fixed the bug where the canvas wouldn't refresh if values were edited too quickly +2003-09-24 (darco) : Added some icons to dynamicly generated menus +2003-09-24 (darco) : Added jump-to-(next/prev)-keyframe feature (Press '[' and ']') +2003-09-24 (darco) : Added time-zoom feature (Hold down shift and press '-' and '=') +2003-09-24 (darco) : Fixed lagging duck bug +2003-09-23 (darco) : Color editor will now intelegently clamp values if necessary +2003-09-23 (darco) : Added "selected color" box to color editing dialog +2003-09-23 (darco) : Implemented keyboard accelerators for zoom. (GIMP style -- '-' for zoom out and '=' for zoom in) +2003-09-23 (darco) : Implemented keyboard accelerators for Duck Hiding. (press ALT-1...6) +2003-09-23 (darco) : Angles can now be visually edited +2003-09-23 (darco) : Added "Split Tangents" action for BLinePoints +2003-09-23 (darco) : Added "Merge Tangents" action for BLinePoints +2003-09-23 (darco) : Added visual BLine width adjustment +2003-09-23 (darco) : Added smart dynamic list item remove and smart dynamic list item insert (works for BLines, too) +2003-09-22 (darco) : Implemented Duck Masking (see menu View->DuckMask from canvasview menu) +2003-09-22 (darco) : Implemented key accelerators in CanvasView... (eg: Ctrl-Z=Undo, Ctrl-S=Save, etc) +2003-09-22 (darco) : Added "Keyframe Lock" button +2003-09-17 (darco) : Added "Duplicate Keyframe" feature +2003-09-17 (darco) : Added "Remove Keyframe" feature +2003-09-17 (darco) : Finished SINFGApp re-write. +2003-09-05 (darco) : Added default foreground/background colors, as well as a default gradient. +2003-09-03 (darco) : Version Increment +2003-09-01 (darco) : If a given layer has a color parameter, then you can now edit the color of a layer by just selecting the layer and adjusting it's color in the color dialog. You can also adjust the color of all selected layers in this way. +2003-08-31 (darco) : Added color-selection dialog, improving the ease and intuitiveness of color selection. +2003-08-18 (darco) : Preliminary support for dynamic point removal. +2003-08-18 (darco) : Improved support for adding points dynamicly. +2003-08-14 (darco) : Preliminary support for animating the addition and removal of points +2003-08-12 (darco) : You can now right click on segments! To add a point ot a bline, right click on the segment where you want to add the point, and then select "add point". +2003-08-12 (darco) : You can now click on a layer in the work area and it will be selected. (Not yet supported for all layers) +2003-08-12 (darco) : Gradient editor now works. Right click on the gradient in the editor to display a menu for adding and removing CPoints. +2003-08-11 (darco) : You can now see ducks appear as you select children. This greatly improves the ability to edit and work with complex images. +2003-08-06 (darco) : The canvas browser is now hidden by default. When you first load a canvas, it will pop up automaticlly. +2003-08-06 (darco) : Added blacklevel test pattern to the gamma tab of the setup dialog. As with the other patterns, try to make the middle of the square match the outside of the square. The goal is to have the highest blacklevel setting where the blacklevel pattern looks solid black. +2003-08-06 (darco) : I am currently working on adding support for the color gradient editor. It isn't done yet, but if you double click on a gradient, you can bring up what will be the gradient editor. +2003-08-06 (darco) : Added "Visually Linear Color Selection" checkbox to the setup. This adjusts all color values that you see so that they are more linear in scale. The default is ON. +2003-08-05 (darco) : The "insert point" option in the rotoscope (bline) is being implemented. It currently only works for adding points to the start of the BLine. +2003-08-05 (darco) : The "delete point" option in the rotoscope (bline) now works. (Although, it seems to crash when you try to delete the most recent point. Investigating...) +2003-08-04 (darco) : The setup dialog now saves your changes to disk immediately. This makes is so that if the program crashes, then we don't loose our recently-updated changes +2003-08-04 (darco) : The setup dialog is now broken down into tabs. +2003-08-04 (darco) : Improved the speed of the gamma adjustments in the setup dialog. +2003-08-01 (darco) : Changes made to the setup dialog are now saved to disk, and will be automaticly reloaded upon restarting the program. +2003-08-01 (darco) : Setup dialog is now implemented, with visual gamma adjustments and the ability to choose the type of timestamp you want +2003-07-28 (darco) : Added gradients as viewable parameters. (the gradient editor isn't ready yet though) +2003-07-23 (darco) : Added buttons to the toolbar for poly and bline rotoscope +2003-07-21 (darco) : Faster window scrolling, and better tiling +2003-07-15 (darco) : For canvas parameters, you can now select canvases that are outside of the current canvas, even in other files +2003-07-14 (darco) : TCB controls now implemented +2003-05-22 (darco) : The time code in the canvas view work area will turn turn "red" if you are on a keyframe +2003-05-22 (darco) : Activepoint keyframe stuff was more broken than I realized, but it should work now.. +2003-05-22 (darco) : Activepoints can now be viewed in the track view. You can select them, but not much else. Red lines are "off" and green lines are "on" +2003-05-19 (darco) : Fixed a crashing bug that would sneak up while animating stuff. +2003-05-19 (darco) : Improved keyframe editing even more. +2003-05-08 (darco) : Improved keyframe editing. One step closer to "just working". *sigh* Ahh... Automagick... +2003-05-08 (darco) : Many, Many under the hood updates and cleanups +2003-04-27 (darco) : Adding a new layer now inserts it at the selected depth in the stack +2003-04-27 (darco) : Duplicating a layer now puts the clone layer next to the original layer +2003-04-24 (darco) : Preliminary support for keyframes/dope-sheet has now been implemented! +2003-04-23 (darco) : Fixed bug where new canvases would have weird time +2003-04-23 (darco) : You can now import image files into a canvas by dragging them onto the canvas window +2003-04-22 (darco) : Raising and lowering layers is now faster +2003-04-22 (darco) : Added some convenience buttons for raising and lowering the layers +2003-04-19 (darco) : Added timecode readout on keyframe view. (still rather non-functional) +2003-04-17 (darco) : PasteCanvas layers will now display the name of the canvas it is pasting instead of just "PasteCanvas" +2003-04-17 (darco) : You can now view and edit the contents of an inline canvas +2003-04-13 (darco) : Fixed crash bug when pressing render button on render dialog with empty filename +2003-04-13 (darco) : The render dialog now has a default file name. +2003-04-13 (darco) : On the Canvas Browser -- renamed "Undo/Redo" tab to "History" +2003-04-13 (darco) : The layer and children tables now do a better job of keeping in sync with the scene -- meaning that you don't have to hit "refresh" as often. +2003-04-13 (darco) : Fixed the bug where you could not see the polygon as you were rotoscoping it. +2003-04-11 (darco) : Fixed a bug in the time widget which would crash the program if you pressed "enter" and the de-focused it. +2003-04-11 (darco) : Start of significant under-the-hood updates +2003-04-11 (darco) : "Time Bar" now only appears when start time and end time are not equal. +2003-04-11 (darco) : Implemented the "move to top" and "move to bottom" +2003-04-07 (darco) : Changes to properties window of canvas is now undoable +2003-04-07 (darco) : Creation of Canvases is now undoable +2003-04-04 (darco) : Improved path rotoscope +2003-04-03 (darco) : Added "encapsulate" option to layer menu +2003-04-03 (darco) : All references to time now use the time code format. +2003-04-02 (darco) : Using the rotoscope tool to create a path is now WYSIWYG (Instead of just showing lines, you now see the curve and the control points) +2003-04-01 (darco) : Set the default frame-rate for new compositions to 30. +2003-03-31 (darco) : Tons of under-the-hood changes. +2003-03-31 (darco) : Added the ability to delete, raise, and lower items on a dynamic list +2003-03-31 (darco) : Added dialog box to path rotoscope +2003-03-26 (darco) : Removed the "ID" entrybox from the Canvas Properties when the canvas is root. +2003-03-26 (darco) : Set the default end-time for new compositions to ZERO. +2003-03-26 (darco) : Set the default frame-rate for new compositions to 15. +2003-03-22 (darco) : Added canvas options dialog +2003-03-22 (darco) : Added ability to adjust grid size + +2003-03-21 (darco) : Added "Delete" button to waypoint dialog + +2003-03-20 (darco) : Version Increment (0.60.03) +2003-03-20 (darco) : Added Waypoint dialog for editing waypoints + +2003-03-20 (darco) : Version Increment (0.60.02) +2003-03-20 (darco) : Names of DataNode parameters are now more readable +2003-03-20 (darco) : Removed "Rotoscope", added "Rotoscope Path" and "Rotoscope Poly" + +2003-03-19 (darco) : Added "Find" button to parameters that represent filenames + +2003-03-17 (darco) : Fixed a bug where the "Open Recent" list is reversed when restarting the program +2003-03-17 (darco) : Added an "Open Recent" option to the file menu on the toolbox. It remembers the last 10 files opened or saved. +2003-03-17 (darco) : Added target selection box to render dialog. +2003-03-17 (darco) : Added "Use current frame" checkbox to render dialog. + +2003-03-04 (darco) : Implemented Render Functionality. +2003-03-04 (darco) : Added support for "angle" type. +2003-03-04 (darco) : Deselecting a parameter-edit popup will now make it dissapear immediately, rather than after the refresh. + +2003-03-01 (darco) : The root canvas on a new composition is now clean, instead of having a mandelbrot set. + +2003-02-26 (darco) : Changed the file dialogs to use the native Win32 file open/save dialogs when built for Win32 rather than the nasty looking Gtk+ file dialogs. +2003-02-26 (darco) : Fixed Bug 0000007 (http://dev.sinfg.com/mantis/view_bug_page.php?f_id=0000007) diff --git a/synfig-studio/trunk/README b/synfig-studio/trunk/README new file mode 100644 index 0000000..2e9dd47 --- /dev/null +++ b/synfig-studio/trunk/README @@ -0,0 +1,4 @@ +$Id: README,v 1.1.1.1 2005/01/07 03:34:35 darco Exp $ +Just a placeholder for now. + + diff --git a/synfig-studio/trunk/alphalicense.txt b/synfig-studio/trunk/alphalicense.txt new file mode 100644 index 0000000..2419786 --- /dev/null +++ b/synfig-studio/trunk/alphalicense.txt @@ -0,0 +1,17 @@ +Alpha Test License Agreement - Synfig Core and Synfig Studio +Last Changed: 1-14-2004 + +* By continuing to install this software, you agree to be bound by the terms of this agreement. READ IT CAREFULLY. + +* This software is owned by Voria Software, hereafter known as "the Company" + +* This software is a part of a closed alpha test, and is licensed for use only to those who are participating in the alpha test (Hereafter referred to as "testers"). Use of this software by anyone who is not a tester is strictly prohibited. + +* At the end of the alpha test, testers must cease the use and discard of all copies of this software and associated materials (ie: software documentation) + +* The tester maintains full ownership of any still images and/or animations that has been created by the tester with this software. + +* Copies of the software, screenshots of the software, and all documentation associated with this software and this alpha test should be considered confidential. Do not distribute any of these materials to anyone not participating in this alpha test without written authorization. + +* DISCLAIMER: THIS SOFTWARE COMES WITH NO WARRANTY OF ANY KIND. THE TESTER AGREES THAT THE COMPANY WILL NOT BE HELD LIABLE FOR ANY DAMAGES, DIRECT OR INDIRECT, RESULTING FROM THE USE, MISUSE, OR MALFUNCTION OF THIS SOFTWARE. + diff --git a/synfig-studio/trunk/bootstrap b/synfig-studio/trunk/bootstrap new file mode 100755 index 0000000..fe60751 --- /dev/null +++ b/synfig-studio/trunk/bootstrap @@ -0,0 +1,240 @@ +#! /bin/sh +# +# Sinfg Studio Bootstrap Script +# $Id: bootstrap,v 1.2 2005/01/10 08:13:44 darco Exp $ +# +# This script creates the configure script and Makefile.in files, +# and also fixes a few things in both to ensure a smooth build +# on all compilers and platforms. +# + +# Grab the current directory and move to our own +CURR_DIR=$(pwd) +cd $(dirname $0) + +# Environment Variables +BOOTSTRAP_NAME=$(basename $0) +CONFIG_DIR=$(pwd)/config + +. $CONFIG_DIR/build.cfg + +SED_SCRIPT=" +s/@PACKAGE@/$PACKAGE/g; +s/@PACKAGE_NAME@/$PACKAGE_NAME/g; +s/@PACKAGE_BUGREPORT@/$PACKAGE_BUGREPORT/g; +s/@PACKAGE_TARNAME@/$PACKAGE_TARNAME/g; +s/@PACKAGE_VERSION@/$PACKAGE_VERSION/g; +s/@VERSION@/$VERSION/g; +s/@VERSION_MAJ@/$VERSION_MAJ/g; +s/@VERSION_MIN@/$VERSION_MIN/g; +s/@VERSION_REV@/$VERSION_REV/g; +s/@VERSION_REL@/$VERSION_REL/g; +s/@CFLAGS@//g; +" + +# Required automake and autoconf versions +#AUTOCONF_VERSION=2.5 +#AUTOMAKE_VERSION=1.6 +#LIBTOOL_VERSION=1.4 +export WANT_AUTOMAKE=1.8 +export WANT_AUTOCONF_2_5=1 + +LIBTOOLIZE=libtoolize +INTLTOOLIZE=intltoolize +AUTOCONF=autoconf +AUTOMAKE=automake +ACLOCAL=aclocal +AUTOHEADER=autoheader + +# Define the output function +output () { + echo $BOOTSTRAP_NAME: $* +} + +# Define the cleanup function +cleanup () { + output Cleaning up... + rm -fr config.cache autom4te*.cache configure.in $TEMPFILE +} + +output Prepairing build environment for $PACKAGE-$VERSION... + +# Look for the CVS directory. If we don't find it, we need to +# ask the user if they know what they are doing. +test -d CVS || +{ + echo " +$BOOTSTRAP_NAME: warning: This shell script is intended for those +$BOOTSTRAP_NAME: warning: who either know what they are doing or +$BOOTSTRAP_NAME: warning: or downloaded this program from the CVS +$BOOTSTRAP_NAME: warning: repository. See README for more details. +$BOOTSTRAP_NAME: warning: To avoid seeing this message in the future, +$BOOTSTRAP_NAME: warning: create an empty directory called 'CVS'." + echo Waiting for 15 seconds... + sleep 15 +} + +# Create the temporary file +output Creating temporary file... +TEMPFILE=`mktemp /tmp/$BOOTSTRAP_NAME.XXXXXX` || +{ + output ERROR: Unable to create temporary file! + exit 1 +} + +# Check for autoconf +(which autoconf > /dev/null 2>&1 ) || +{ + output error: 'Could not find GNU autoconf!' + output You need to download and install GNU autoconf v2.52 or higher. + output '' + cleanup; + exit 1 +} + +# Check autoconf version +output Using $(autoconf --version | grep utoconf) +autoconf --version | grep -q "$AUTOCONF_VERSION" || echo \ +"$BOOTSTRAP_NAME: warning: Unexpected version of GNU Autoconf (expected $AUTOCONF_VERSION) +$BOOTSTRAP_NAME: warning: *** Bootstrap process may fail!" + +# Check for automake +(which automake > /dev/null 2>&1 ) || +{ + output error: 'Could not find GNU automake!' + output You need to download and install GNU automake v1.5 or higher. + output '' + cleanup; + exit 1 +} + +# Check automake version +output Using $(automake --version | grep utomake) +automake --version | grep -q "$AUTOMAKE_VERSION" || echo \ +"$BOOTSTRAP_NAME: warning: Unexpected version of GNU Automake (expected $AUTOMAKE_VERSION) +$BOOTSTRAP_NAME: warning: *** Bootstrap process may fail!" + +# Check for libtool +(which libtool > /dev/null 2>&1 ) || +{ + output error: 'Could not find GNU libtool!' + output You need to download and install GNU libtool v1.4 or higher. + output '' + exit 1 +} + +# Check libtool version +output Using $(libtoolize --version | grep ibtool) +libtoolize --version | grep -q "$LIBTOOL_VERSION" || echo \ +"$BOOTSTRAP_NAME: warning: Unexpected version of GNU Libtool (expected $LIBTOOL_VERSION) +$BOOTSTRAP_NAME: warning: *** Bootstrap process may fail!" + + +aclocalfix () { +sed ' +s:${srcdir}/intltool:${ac_aux_dir}/intltool:g; +s.printf ("\\t%s @ %ld ;\\n", erva+name_rva, 1+ i);.printf ("\\t\\"%s\\" @ %ld ;\\n", erva+name_rva, 1+ i);.; +' < aclocal.m4 > $TEMPFILE && +rm aclocal.m4 && +mv $TEMPFILE aclocal.m4 +} + +for FILENAME in project.spec ; do { +output Creating $FILENAME... +sed "$SED_SCRIPT" < $CONFIG_DIR/$FILENAME.in > $FILENAME; +} ; done + +output Renaming project.spec to $PACKAGE-$VERSION.spec... +mv project.spec "$PACKAGE-$VERSION.spec" + +output Finishing up $PACKAGE-$VERSION.spec... +echo %changelog >> "$PACKAGE-$VERSION.spec" +cat ChangeLog >> "$PACKAGE-$VERSION.spec" + +output Creating configure.in from configure.ac... +sed "$SED_SCRIPT" < $CONFIG_DIR/configure.ac > configure.in; + +output Setting up build environment... + +# Set the shell to output what we are doing +set -x + +# Create all of the build environment files +( +# $INTLTOOLIZE -c && + $LIBTOOLIZE -c -f && + $ACLOCAL -I $CONFIG_DIR $ACLOCAL_FLAGS && + aclocalfix && + $AUTOHEADER && + $AUTOMAKE --foreign --add-missing --copy --include-deps && + $AUTOCONF -o configure && + true +) || +{ + # Something went wrong... + set +x + output Failure. + cleanup; + exit 1 +} + +# Turn off echoing of commands +set +x + +#output Patching configure script to look for gcc3... +#sed " +#s/g++ c++/g++3 g++ c++/; +#s/gcc cc/gcc3 gcc cc/; +#s:"'${prefix}/include'":"'${prefix}/include/sinfg'":; +#s:PREFIX/include:PREFIX/include/ETL:; +#" < configure > $TEMPFILE +#cp $TEMPFILE configure + +# Patch the Makefile.in files +for filename in $(find Makefile.in src -name Makefile.in) ; do { + echo $BOOTSTRAP_NAME: Patching $filename + ( + cp $filename $TEMPFILE && + sed " + s;-I. ;; + s;-I"'$(srcdir)'" ;-I"'$(top_srcdir)'" ; + s;configure.in;config/configure.ac; + " < $TEMPFILE > $filename + ) || + { + # Patch failure + output Failure. Unable to patch $filename. + cleanup; + exit 1 + } +}; done + +output Creating Makefile... +( echo " +all: + ./configure --enable-maintainer-mode + make all + +install: + ./configure --enable-maintainer-mode + make install + +check: + ./configure --enable-maintainer-mode + make check + +distcheck: + ./configure --enable-maintainer-mode + make check + +dist: + ./configure --enable-maintainer-mode + make dist +" ) > Makefile + +echo $BOOTSTRAP_NAME: Complete. + +cleanup; + +# Move back to the current directory +cd $CURR_DIR diff --git a/synfig-studio/trunk/config/ETL.m4 b/synfig-studio/trunk/config/ETL.m4 new file mode 100755 index 0000000..f614a5b --- /dev/null +++ b/synfig-studio/trunk/config/ETL.m4 @@ -0,0 +1,75 @@ +# ETL M4 Macro +# For GNU Autotools +# $Id: ETL.m4,v 1.1.1.1 2005/01/07 03:34:35 darco Exp $ +# +# By Robert B. Quattlebaum Jr. +# + +AC_DEFUN([ETL_DEPS], +[ + AC_C_BIGENDIAN + + AC_CHECK_LIB(user32, main) + AC_CHECK_LIB(kernel32, main) + AC_CHECK_LIB(pthread, main) + + AC_HEADER_STDC + + AC_CHECK_HEADERS(pthread.h) + AC_CHECK_HEADERS(sched.h) + AC_CHECK_HEADERS(sys/times.h) + AC_CHECK_HEADERS(sys/time.h) + AC_CHECK_HEADERS(unistd.h) + AC_CHECK_HEADERS(windows.h) + AC_CHECK_FUNCS([pthread_create]) + AC_CHECK_FUNCS([pthread_rwlock_init]) + AC_CHECK_FUNCS([pthread_yield]) + AC_CHECK_FUNCS([sched_yield]) + AC_CHECK_FUNCS([CreateThread]) + AC_CHECK_FUNCS([__clone]) + AC_CHECK_FUNCS([QueryPerformanceCounter]) + + AC_CHECK_FUNCS([gettimeofday]) + AC_CHECK_FUNCS([vsscanf]) + AC_CHECK_FUNCS([vsprintf]) + AC_CHECK_FUNCS([vasprintf]) + AC_CHECK_FUNCS([vsnprintf],[],[ + AC_CHECK_FUNC([_vsnprintf],[ + AC_DEFINE(vsnprintf,_vsnprintf,[define if the vsnprintf function is mangled]) + AC_DEFINE(HAVE_VSNPRINTF,1) + ]) + ]) + + $1 +]) + +AC_DEFUN([USING_ETL], +[ + AC_ARG_WITH(ETL-includes, + [ --with-ETL-includes Specify location of ETL headers],[ + CXXFLAGS="$CXXFLAGS -I$withval" + ]) + + AC_PATH_PROG(ETL_CONFIG,ETL-config,no) + + if test "$ETL_CONFIG" = "no"; then + no_ETL_config="yes" + $2 + else + AC_MSG_CHECKING([if $ETL_CONFIG works]) + if $ETL_CONFIG --libs >/dev/null 2>&1; then + ETL_VERSION="`$ETL_CONFIG --version`" + AC_MSG_RESULT([yes, $ETL_VERSION]) + CXXFLAGS="$CXXFLAGS `$ETL_CONFIG --cxxflags`" + $1 + else + AC_MSG_RESULT(no) + no_ETL_config="yes" + $2 + fi + fi + + ETL_DEPS($1,$2) +]) + + diff --git a/synfig-studio/trunk/config/build.cfg b/synfig-studio/trunk/config/build.cfg new file mode 100644 index 0000000..f9ce723 --- /dev/null +++ b/synfig-studio/trunk/config/build.cfg @@ -0,0 +1,13 @@ + +PACKAGE_NAME="Synfg Studio" +PACKAGE_BUGREPORT="darco@voria.com" +PACKAGE_TARNAME=synfigstudio +VERSION_MAJ="0" +VERSION_MIN="61" +VERSION_REV="00" +VERSION_REL="1" + +VERSION=$VERSION_MAJ.$VERSION_MIN.$VERSION_REV + +PACKAGE_VERSION=$VERSION +PACKAGE=$PACKAGE_TARNAME diff --git a/synfig-studio/trunk/config/configure.ac b/synfig-studio/trunk/config/configure.ac new file mode 100755 index 0000000..5281339 --- /dev/null +++ b/synfig-studio/trunk/config/configure.ac @@ -0,0 +1,186 @@ +# $Header: /opt/voria/cvs/studio/config/configure.ac,v 1.3 2005/01/17 05:20:08 darco Exp $ + +# -- I N I T -------------------------------------------------- + +. $srcdir/config/build.cfg + +AC_INIT(@PACKAGE_NAME@,@PACKAGE_VERSION@,@PACKAGE_BUGREPORT@,@PACKAGE_TARNAME@) +AC_REVISION + +AC_CONFIG_AUX_DIR(config) +AM_CONFIG_HEADER(config.h) +AC_CANONICAL_HOST +dnl AC_CANONICAL_TARGET + +AM_INIT_AUTOMAKE +AM_MAINTAINER_MODE + + +# -- V A R I A B L E S ---------------------------------------- + +# -- P R O G R A M S ------------------------------------------ + +AC_PROG_CC +AC_PROG_CXX +AC_PROG_CPP +AC_PROG_CXXCPP +AC_PROG_INSTALL + +AC_LANG_CPLUSPLUS + + +AC_ARG_DEBUG +AC_ARG_OPTIMIZATION +AC_ARG_WARNINGS +AC_ARG_PROFILE_ARCS +AC_ARG_BRANCH_PROBABILITIES +AC_ARG_PROFILING +AC_ARG_LICENSE_KEY + +AC_ARG_ENABLE(g5opt,[ + --enable-g5opt enable optimizations specific to G5 proc],[ + G5OPTFLAGS="-mpowerpc-gpopt -mno-multiple -mno-update -mcpu=970 -mtune=970 -falign-loops=16 -falign-functions=16" +], +[ + G5OPTFLAGS= +]) + +AC_WIN32_QUIRKS + +AC_LIBTOOL_WIN32_DLL +AC_LIBTOOL_DLOPEN +AC_DISABLE_STATIC +AC_ENABLE_SHARED +AC_PROG_LIBTOOL +AC_SUBST(LIBTOOL_DEPS) +AC_LIBTOOL_PATCH + + + + + +dnl AC_PROG_INTLTOOL(0.11) + +# -- L I B R A R I E S ---------------------------------------- + +PKG_CHECK_MODULES(GTKMM, gtkmm-2.4 gthread-2.0,[],[ + AC_MSG_ERROR([ ** Gtkmm-2.4 Is a required library, aborting.]) +]) +AC_SUBST(GTKMM_CFLAGS) +AC_SUBST(GTKMM_LIBS) + +PKG_CHECK_MODULES(SINFG, synfig ETL sigc++-2.0,,[ + AC_MSG_ERROR([ ** Unable to set up dependent libraries]) +]) +AC_SUBST(SINFG_CFLAGS) +AC_SUBST(SINFG_LIBS) + +windowsys="gtkmm" +AC_DEFINE(STUDIO_WINSYS_H,"gtkmm/winsys.h",[blah]) +AM_CONDITIONAL(WINDOWSYS_GTKMM,true) + + +# --- FMOD CHECK ------------- +AC_ARG_WITH(libfmod,[ + --with-libfmod Enable support for FMOD],[ +],[ + AC_CHECK_LIB(fmod, FSOUND_Init,[ + with_libfmod="yes" + ],[ + with_libfmod="no" + ]) +]) +if test $with_libfmod = "yes" ; then { + AM_CONDITIONAL(WITH_FMOD,true) + FMOD_LIBS="/usr/lib/libfmod.so" + AC_DEFINE(WITH_FMOD,"I'm here damnit",[blah]) +} else { + AM_CONDITIONAL(WITH_FMOD,false) + FMOD_LIBS= +} ; fi + +# -- H E A D E R S -------------------------------------------- + +AC_CHECK_HEADERS([unistd.h signal.h fcntl.h]) +AC_CHECK_HEADERS([sys/types.h sys/wait.h sys/stat.h sys/time.h sys/resource.h]) + +# -- T Y P E S & S T R U C T S -------------------------------- + +# -- F U N C T I O N S ---------------------------------------- + +AC_CHECK_FUNCS([fork]) +AC_CHECK_FUNCS([kill]) +AC_CHECK_FUNCS([pipe]) +AC_CHECK_FUNCS([setpriority mkfifo stat]) + +# -- A R G U M E N T S ---------------------------------------- + +# -- O U T P U T ---------------------------------------------- + +AC_SUBST(CFLAGS) +AC_SUBST(CPPFLAGS) +AC_SUBST(CXXFLAGS) +AC_SUBST(LDFLAGS) + +VERSION_MAJ=@VERSION_MAJ@ +VERSION_MIN=@VERSION_MIN@ +VERSION_REV=@VERSION_REV@ +AC_SUBST(VERSION_MAJ) +AC_SUBST(VERSION_MIN) +AC_SUBST(VERSION_REV) + +# fmod stuff... +AC_SUBST(FMOD_LIBS) + +imagedir=$datadir/pixmaps + +imageext=png + +AC_SUBST(imageext) +AC_SUBST(imagedir) + + + +AC_DEFINE_UNQUOTED(IMAGE_EXT,"$imageext", [ Describes the file extension for images ] ) + +[[ $prefix = NONE ]] && prefix=$ac_default_prefix +export prefix +AC_DEFINE_UNQUOTED(IMAGE_DIR,"`echo echo $imagedir | sh`", [ Describes where the icons and stuff will be ] ) + +AC_OUTPUT( +Makefile +sinfgstudio.desktop +sinfgstudio.mime +sinfgstudio.keys +src/Makefile +src/gtkmm/Makefile +src/sinfgapp/Makefile +images/Makefile +win32inst.nsi +) + +# -- S U M M A R Y -------------------------------------------- + +echo " +$PACKAGE_NAME v.$VERSION +Configuration Summary +- - - - - - + +Install Prefix -------------------> $prefix +Data Prefix ----------------------> $datadir +Host Platform --------------------> $host +Icon Format ----------------------> $imageext +Debug Mode -----------------------> $debug +Profiling Mode -------------------> $profiling +Optimizations --------------------> $optimization +Window System --------------------> $windowsys +FMOD Enabled ---------------------> $with_libfmod + +"'$'"CXX ------------------------------> '$CXX' +"'$'"CXXFLAGS -------------------------> '$CXXFLAGS' +"'$'"LDFLAGS --------------------------> '$LDFLAGS' +"'$'"SINFG_CFLAGS ---------------------> '$SINFG_CFLAGS' +"'$'"SINFG_LIBS -----------------------> '$SINFG_LIBS' +"'$'"GTKMM_CFLAGS ---------------------> '$GTKMM_CFLAGS' +"'$'"GTKMM_LIBS -----------------------> '$GTKMM_LIBS' +" diff --git a/synfig-studio/trunk/config/cxx_macros.m4 b/synfig-studio/trunk/config/cxx_macros.m4 new file mode 100755 index 0000000..8fc247a --- /dev/null +++ b/synfig-studio/trunk/config/cxx_macros.m4 @@ -0,0 +1,88 @@ +AC_DEFUN([AC_CXX_FUNCTION_NONTYPE_PARAMETERS], +[AC_CACHE_CHECK(whether the compiler supports function templates with non-type parameters, +ac_cv_cxx_function_nontype_parameters, +[AC_LANG_SAVE + AC_LANG_CPLUSPLUS + AC_TRY_COMPILE([ +template class A {}; +template int f(const A& x) { return 0; } +],[A z; return f(z);], + ac_cv_cxx_function_nontype_parameters=yes, ac_cv_cxx_function_nontype_parameters=no) + AC_LANG_RESTORE +]) +if test "$ac_cv_cxx_function_nontype_parameters" = yes; then + AC_DEFINE(HAVE_FUNCTION_NONTYPE_PARAMETERS,, + [define if the compiler supports function templates with non-type parameters]) +fi +]) + +AC_DEFUN([AC_CXX_NAMESPACES], +[AC_CACHE_CHECK(whether the compiler implements namespaces, +ac_cv_cxx_namespaces, +[AC_LANG_SAVE + AC_LANG_CPLUSPLUS + AC_TRY_COMPILE([namespace Outer { namespace Inner { int i = 0; }}], + [using namespace Outer::Inner; return i;], + ac_cv_cxx_namespaces=yes, ac_cv_cxx_namespaces=no) + AC_LANG_RESTORE +]) +if test "$ac_cv_cxx_namespaces" = yes; then + AC_DEFINE(HAVE_NAMESPACES,,[define if the compiler implements namespaces]) +fi +]) + +AC_DEFUN([AC_CXX_HAVE_COMPLEX], +[AC_CACHE_CHECK(whether the compiler has complex, +ac_cv_cxx_have_complex, +[AC_REQUIRE([AC_CXX_NAMESPACES]) + AC_LANG_SAVE + AC_LANG_CPLUSPLUS + AC_TRY_COMPILE([#include +#ifdef HAVE_NAMESPACES +using namespace std; +#endif],[complex a; complex b; return 0;], + ac_cv_cxx_have_complex=yes, ac_cv_cxx_have_complex=no) + AC_LANG_RESTORE +]) +if test "$ac_cv_cxx_have_complex" = yes; then + AC_DEFINE(HAVE_COMPLEX,,[define if the compiler has complex]) +fi +]) + +AC_DEFUN([AC_CXX_HAVE_SSTREAM], +[AC_CACHE_CHECK(whether the compiler has stringstream, +ac_cv_cxx_have_sstream, +[AC_REQUIRE([AC_CXX_NAMESPACES]) + AC_LANG_SAVE + AC_LANG_CPLUSPLUS + AC_TRY_COMPILE([#include +#ifdef HAVE_NAMESPACES +using namespace std; +#endif],[stringstream message; message << "Hello"; return 0;], + ac_cv_cxx_have_sstream=yes, ac_cv_cxx_have_sstream=no) + AC_LANG_RESTORE +]) +if test "$ac_cv_cxx_have_sstream" = yes; then + AC_DEFINE(HAVE_SSTREAM,,[define if the compiler has stringstream]) +fi +]) + +AC_DEFUN([AC_CXX_MUTABLE], +[AC_CACHE_CHECK(whether the compiler supports the mutable keyword, +ac_cv_cxx_mutable, +[AC_LANG_SAVE + AC_LANG_CPLUSPLUS + AC_TRY_COMPILE([ +class A { mutable int i; + public: + int f (int n) const { i = n; return i; } + }; +],[A a; return a.f (1);], + ac_cv_cxx_mutable=yes, ac_cv_cxx_mutable=no) + AC_LANG_RESTORE +]) +if test "$ac_cv_cxx_mutable" = yes; then + AC_DEFINE(HAVE_MUTABLE,,[define if the compiler supports the mutable keyword]) +fi +]) + diff --git a/synfig-studio/trunk/config/gnome.m4 b/synfig-studio/trunk/config/gnome.m4 new file mode 100755 index 0000000..a496df6 --- /dev/null +++ b/synfig-studio/trunk/config/gnome.m4 @@ -0,0 +1,407 @@ +# gnome-common.m4 +# + +dnl GNOME_COMMON_INIT + +AC_DEFUN([GNOME_COMMON_INIT], +[ + AC_CACHE_VAL(ac_cv_gnome_aclocal_dir, + [ac_cv_gnome_aclocal_dir="$GNOME_COMMON_MACROS_DIR"]) + AC_CACHE_VAL(ac_cv_gnome_aclocal_flags, + [ac_cv_gnome_aclocal_flags="$ACLOCAL_FLAGS"]) + GNOME_ACLOCAL_DIR="$ac_cv_gnome_aclocal_dir" + GNOME_ACLOCAL_FLAGS="$ac_cv_gnome_aclocal_flags" + AC_SUBST(GNOME_ACLOCAL_DIR) + AC_SUBST(GNOME_ACLOCAL_FLAGS) + + ACLOCAL="$ACLOCAL $GNOME_ACLOCAL_FLAGS" + + AM_CONDITIONAL(INSIDE_GNOME_DOCU, false) +]) + +AC_DEFUN([GNOME_GTKDOC_CHECK], +[ + AC_CHECK_PROG(GTKDOC, gtkdoc-mkdb, true, false) + AM_CONDITIONAL(HAVE_GTK_DOC, $GTKDOC) + AC_SUBST(HAVE_GTK_DOC) + + dnl Let people disable the gtk-doc stuff. + AC_ARG_ENABLE(gtk-doc, [ --enable-gtk-doc Use gtk-doc to build documentation [default=auto]], enable_gtk_doc="$enableval", enable_gtk_doc=auto) + + if test x$enable_gtk_doc = xauto ; then + if test x$GTKDOC = xtrue ; then + enable_gtk_doc=yes + else + enable_gtk_doc=no + fi + fi + + dnl NOTE: We need to use a separate automake conditional for this + dnl to make this work with the tarballs. + AM_CONDITIONAL(ENABLE_GTK_DOC, test x$enable_gtk_doc = xyes) +]) + +AC_DEFUN([GNOME_DEBUG_CHECK], +[ + AC_ARG_ENABLE(debug, [ --enable-debug turn on debugging [default=no]], enable_debug="$enableval", enable_debug=no) + + if test x$enable_debug = xyes ; then + AC_DEFINE(GNOME_ENABLE_DEBUG) + fi +]) + +# Define a conditional. + +AC_DEFUN([AM_CONDITIONAL], +[AC_SUBST($1_TRUE) +AC_SUBST($1_FALSE) +if $2; then + $1_TRUE= + $1_FALSE='#' +else + $1_TRUE='#' + $1_FALSE= +fi]) + + +dnl PKG_CHECK_MODULES(GSTUFF, gtk+-2.0 >= 1.3 glib = 1.3.4, action-if, action-not) +dnl defines GSTUFF_LIBS, GSTUFF_CFLAGS, see pkg-config man page +dnl also defines GSTUFF_PKG_ERRORS on error +AC_DEFUN(PKG_CHECK_MODULES, [ + succeeded=no + + if test -z "$PKG_CONFIG"; then + AC_PATH_PROG(PKG_CONFIG, pkg-config, no) + fi + + if test "$PKG_CONFIG" = "no" ; then + echo "*** The pkg-config script could not be found. Make sure it is" + echo "*** in your path, or set the PKG_CONFIG environment variable" + echo "*** to the full path to pkg-config." + echo "*** Or see http://www.freedesktop.org/software/pkgconfig to get pkg-config." + else + PKG_CONFIG_MIN_VERSION=0.9.0 + if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then + AC_MSG_CHECKING(for $2) + + if $PKG_CONFIG --exists "$2" ; then + AC_MSG_RESULT(yes) + succeeded=yes + + AC_MSG_CHECKING($1_CFLAGS) + $1_CFLAGS=`$PKG_CONFIG --cflags "$2"` + AC_MSG_RESULT($$1_CFLAGS) + + AC_MSG_CHECKING($1_LIBS) + $1_LIBS=`$PKG_CONFIG --libs "$2"` + AC_MSG_RESULT($$1_LIBS) + else + $1_CFLAGS="" + $1_LIBS="" + ## If we have a custom action on failure, don't print errors, but + ## do set a variable so people can do so. + $1_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "$2"` + ifelse([$4], ,echo $$1_PKG_ERRORS,) + fi + + AC_SUBST($1_CFLAGS) + AC_SUBST($1_LIBS) + else + echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer." + echo "*** See http://www.freedesktop.org/software/pkgconfig" + fi + fi + + if test $succeeded = yes; then + ifelse([$3], , :, [$3]) + else + ifelse([$4], , AC_MSG_ERROR([Library requirements ($2) not met; consider adjusting the PKG_CONFIG_PATH environment variable if your libraries are in a nonstandard prefix so pkg-config can find them.]), [$4]) + fi +]) + + + +# Macro to add for using GNU gettext. +# Ulrich Drepper , 1995, 1996 +# +# Modified to never use included libintl. +# Owen Taylor , 12/15/1998 +# +# +# This file can be copied and used freely without restrictions. It can +# be used in projects which are not available under the GNU Public License +# but which still want to provide support for the GNU gettext functionality. +# Please note that the actual code is *not* freely available. +# +# +# If you make changes to this file, you MUST update the copy in +# acinclude.m4. [ aclocal dies on duplicate macros, so if +# we run 'aclocal -I macros/' then we'll run into problems +# once we've installed glib-gettext.m4 :-( ] +# + +AC_DEFUN([AM_GLIB_LC_MESSAGES], + [if test $ac_cv_header_locale_h = yes; then + AC_CACHE_CHECK([for LC_MESSAGES], am_cv_val_LC_MESSAGES, + [AC_TRY_LINK([#include ], [return LC_MESSAGES], + am_cv_val_LC_MESSAGES=yes, am_cv_val_LC_MESSAGES=no)]) + if test $am_cv_val_LC_MESSAGES = yes; then + AC_DEFINE(HAVE_LC_MESSAGES, 1, + [Define if your file defines LC_MESSAGES.]) + fi + fi]) + +dnl AM_GLIB_PATH_PROG_WITH_TEST(VARIABLE, PROG-TO-CHECK-FOR, +dnl TEST-PERFORMED-ON-FOUND_PROGRAM [, VALUE-IF-NOT-FOUND [, PATH]]) +AC_DEFUN([AM_GLIB_PATH_PROG_WITH_TEST], +[# Extract the first word of "$2", so it can be a program name with args. +set dummy $2; ac_word=[$]2 +AC_MSG_CHECKING([for $ac_word]) +AC_CACHE_VAL(ac_cv_path_$1, +[case "[$]$1" in + /*) + ac_cv_path_$1="[$]$1" # Let the user override the test with a path. + ;; + *) + IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:" + for ac_dir in ifelse([$5], , $PATH, [$5]); do + test -z "$ac_dir" && ac_dir=. + if test -f $ac_dir/$ac_word; then + if [$3]; then + ac_cv_path_$1="$ac_dir/$ac_word" + break + fi + fi + done + IFS="$ac_save_ifs" +dnl If no 4th arg is given, leave the cache variable unset, +dnl so AC_PATH_PROGS will keep looking. +ifelse([$4], , , [ test -z "[$]ac_cv_path_$1" && ac_cv_path_$1="$4" +])dnl + ;; +esac])dnl +$1="$ac_cv_path_$1" +if test ifelse([$4], , [-n "[$]$1"], ["[$]$1" != "$4"]); then + AC_MSG_RESULT([$]$1) +else + AC_MSG_RESULT(no) +fi +AC_SUBST($1)dnl +]) + +# serial 5 + +AC_DEFUN(AM_GLIB_WITH_NLS, + dnl NLS is obligatory + [USE_NLS=yes + AC_SUBST(USE_NLS) + + dnl Figure out what method + nls_cv_force_use_gnu_gettext="no" + + nls_cv_use_gnu_gettext="$nls_cv_force_use_gnu_gettext" + if test "$nls_cv_force_use_gnu_gettext" != "yes"; then + dnl User does not insist on using GNU NLS library. Figure out what + dnl to use. If gettext or catgets are available (in this order) we + dnl use this. Else we have to fall back to GNU NLS library. + dnl catgets is only used if permitted by option --with-catgets. + nls_cv_header_intl= + nls_cv_header_libgt= + CATOBJEXT=NONE + XGETTEXT=: + + AC_CHECK_HEADER(libintl.h, + [AC_CACHE_CHECK([for dgettext in libc], gt_cv_func_dgettext_libc, + [AC_TRY_LINK([#include ], [return (int) dgettext ("","")], + gt_cv_func_dgettext_libc=yes, gt_cv_func_dgettext_libc=no)]) + + gt_cv_func_dgettext_libintl="no" + libintl_extra_libs="" + + if test "$gt_cv_func_dgettext_libc" != "yes" ; then + AC_CHECK_LIB(intl, bindtextdomain, + [AC_CHECK_LIB(intl, dgettext, + gt_cv_func_dgettext_libintl=yes)]) + + if test "$gt_cv_func_dgettext_libc" != "yes" ; then + AC_MSG_CHECKING([if -liconv is needed to use gettext]) + AC_MSG_RESULT([]) + AC_CHECK_LIB(intl, dcgettext, + [gt_cv_func_dgettext_libintl=yes + libintl_extra_libs=-liconv], + :,-liconv) + fi + fi + + if test "$gt_cv_func_dgettext_libintl" = "yes"; then + LIBS="$LIBS -lintl $libintl_extra_libs"; + fi + + if test "$gt_cv_func_dgettext_libc" = "yes" \ + || test "$gt_cv_func_dgettext_libintl" = "yes"; then + AC_DEFINE(HAVE_GETTEXT,1, + [Define if the GNU gettext() function is already present or preinstalled.]) + AM_GLIB_PATH_PROG_WITH_TEST(MSGFMT, msgfmt, + [test -z "`$ac_dir/$ac_word -h 2>&1 | grep 'dv '`"], no)dnl + if test "$MSGFMT" != "no"; then + AC_CHECK_FUNCS(dcgettext) + AC_PATH_PROG(GMSGFMT, gmsgfmt, $MSGFMT) + AM_GLIB_PATH_PROG_WITH_TEST(XGETTEXT, xgettext, + [test -z "`$ac_dir/$ac_word -h 2>&1 | grep '(HELP)'`"], :) + AC_TRY_LINK(, [extern int _nl_msg_cat_cntr; + return _nl_msg_cat_cntr], + [CATOBJEXT=.gmo + DATADIRNAME=share], + [CATOBJEXT=.mo + DATADIRNAME=lib]) + INSTOBJEXT=.mo + fi + fi + + # Added by Martin Baulig 12/15/98 for libc5 systems + if test "$gt_cv_func_dgettext_libc" != "yes" \ + && test "$gt_cv_func_dgettext_libintl" = "yes"; then + INTLLIBS="-lintl $libintl_extra_libs" + LIBS=`echo $LIBS | sed -e 's/-lintl//'` + fi + ]) + + if test "$CATOBJEXT" = "NONE"; then + dnl Neither gettext nor catgets in included in the C library. + dnl Fall back on GNU gettext library. + nls_cv_use_gnu_gettext=yes + fi + fi + + if test "$nls_cv_use_gnu_gettext" != "yes"; then + AC_DEFINE(ENABLE_NLS, 1, + [always defined to indicate that i18n is enabled]) + else + dnl Unset this variable since we use the non-zero value as a flag. + CATOBJEXT= + fi + + dnl Test whether we really found GNU xgettext. + if test "$XGETTEXT" != ":"; then + dnl If it is no GNU xgettext we define it as : so that the + dnl Makefiles still can work. + if $XGETTEXT --omit-header /dev/null 2> /dev/null; then + : ; + else + AC_MSG_RESULT( + [found xgettext program is not GNU xgettext; ignore it]) + XGETTEXT=":" + fi + fi + + # We need to process the po/ directory. + POSUB=po + + AC_OUTPUT_COMMANDS( + [case "$CONFIG_FILES" in *po/Makefile.in*) + sed -e "/POTFILES =/r po/POTFILES" po/Makefile.in > po/Makefile + esac]) + + dnl These rules are solely for the distribution goal. While doing this + dnl we only have to keep exactly one list of the available catalogs + dnl in configure.in. + for lang in $ALL_LINGUAS; do + GMOFILES="$GMOFILES $lang.gmo" + POFILES="$POFILES $lang.po" + done + + dnl Make all variables we use known to autoconf. + AC_SUBST(CATALOGS) + AC_SUBST(CATOBJEXT) + AC_SUBST(DATADIRNAME) + AC_SUBST(GMOFILES) + AC_SUBST(INSTOBJEXT) + AC_SUBST(INTLDEPS) + AC_SUBST(INTLLIBS) + AC_SUBST(INTLOBJS) + AC_SUBST(POFILES) + AC_SUBST(POSUB) + ]) + +AC_DEFUN(AM_GLIB_GNU_GETTEXT, + [AC_REQUIRE([AC_PROG_MAKE_SET])dnl + AC_REQUIRE([AC_PROG_CC])dnl + AC_REQUIRE([AC_PROG_RANLIB])dnl + AC_REQUIRE([AC_HEADER_STDC])dnl + AC_REQUIRE([AC_C_CONST])dnl + AC_REQUIRE([AC_C_INLINE])dnl + AC_REQUIRE([AC_TYPE_OFF_T])dnl + AC_REQUIRE([AC_TYPE_SIZE_T])dnl + AC_REQUIRE([AC_FUNC_ALLOCA])dnl + AC_REQUIRE([AC_FUNC_MMAP])dnl + + AC_CHECK_HEADERS([argz.h limits.h locale.h nl_types.h malloc.h string.h \ +unistd.h sys/param.h]) + AC_CHECK_FUNCS([getcwd munmap putenv setenv setlocale strchr strcasecmp \ +strdup __argz_count __argz_stringify __argz_next]) + + AM_GLIB_LC_MESSAGES + AM_GLIB_WITH_NLS + + if test "x$CATOBJEXT" != "x"; then + if test "x$ALL_LINGUAS" = "x"; then + LINGUAS= + else + AC_MSG_CHECKING(for catalogs to be installed) + NEW_LINGUAS= + for lang in ${LINGUAS=$ALL_LINGUAS}; do + case "$ALL_LINGUAS" in + *$lang*) NEW_LINGUAS="$NEW_LINGUAS $lang" ;; + esac + done + LINGUAS=$NEW_LINGUAS + AC_MSG_RESULT($LINGUAS) + fi + + dnl Construct list of names of catalog files to be constructed. + if test -n "$LINGUAS"; then + for lang in $LINGUAS; do CATALOGS="$CATALOGS $lang$CATOBJEXT"; done + fi + fi + + dnl Determine which catalog format we have (if any is needed) + dnl For now we know about two different formats: + dnl Linux libc-5 and the normal X/Open format + test -d po || mkdir po + if test "$CATOBJEXT" = ".cat"; then + AC_CHECK_HEADER(linux/version.h, msgformat=linux, msgformat=xopen) + + dnl Transform the SED scripts while copying because some dumb SEDs + dnl cannot handle comments. + sed -e '/^#/d' $srcdir/po/$msgformat-msg.sed > po/po2msg.sed + fi + + dnl If the AC_CONFIG_AUX_DIR macro for autoconf is used we possibly + dnl find the mkinstalldirs script in another subdir but ($top_srcdir). + dnl Try to locate is. + MKINSTALLDIRS= + if test -n "$ac_aux_dir"; then + MKINSTALLDIRS="$ac_aux_dir/mkinstalldirs" + fi + if test -z "$MKINSTALLDIRS"; then + MKINSTALLDIRS="\$(top_srcdir)/mkinstalldirs" + fi + AC_SUBST(MKINSTALLDIRS) + + dnl Generate list of files to be processed by xgettext which will + dnl be included in po/Makefile. + test -d po || mkdir po + if test "x$srcdir" != "x."; then + if test "x`echo $srcdir | sed 's@/.*@@'`" = "x"; then + posrcprefix="$srcdir/" + else + posrcprefix="../$srcdir/" + fi + else + posrcprefix="../" + fi + rm -f po/POTFILES + sed -e "/^#/d" -e "/^\$/d" -e "s,.*, $posrcprefix& \\\\," -e "\$s/\(.*\) \\\\/\1/" \ + < $srcdir/po/POTFILES.in > po/POTFILES + ]) + diff --git a/synfig-studio/trunk/config/libxml.m4 b/synfig-studio/trunk/config/libxml.m4 new file mode 100755 index 0000000..f6bd51f --- /dev/null +++ b/synfig-studio/trunk/config/libxml.m4 @@ -0,0 +1,389 @@ +# Configure paths for LIBXML2 +# Toshio Kuratomi 2001-04-21 +# Adapted from: +# Configure paths for GLIB +# Owen Taylor 97-11-3 + +dnl AM_PATH_XML([MINIMUM-VERSION, [ACTION-IF-FOUND [, ACTION-IF-NOT-FOUND]]]) +dnl Test for XML, and define XML_CFLAGS and XML_LIBS +dnl +AC_DEFUN(AM_PATH_XML,[ +AC_ARG_WITH(xml-prefix, + [ --with-xml-prefix=PFX Prefix where libxml is installed (optional)], + xml_config_prefix="$withval", xml_config_prefix="") +AC_ARG_WITH(xml-exec-prefix, + [ --with-xml-exec-prefix=PFX Exec prefix where libxml is installed (optional)], + xml_config_exec_prefix="$withval", xml_config_exec_prefix="") +AC_ARG_ENABLE(xmltest, + [ --disable-xmltest Do not try to compile and run a test LIBXML program],, + enable_xmltest=yes) + + if test x$xml_config_exec_prefix != x ; then + xml_config_args="$xml_config_args --exec-prefix=$xml_config_exec_prefix" + if test x${XML_CONFIG+set} != xset ; then + XML_CONFIG=$xml_config_exec_prefix/bin/xml-config + fi + fi + if test x$xml_config_prefix != x ; then + xml_config_args="$xml_config_args --prefix=$xml_config_prefix" + if test x${XML_CONFIG+set} != xset ; then + XML_CONFIG=$xml_config_prefix/bin/xml-config + fi + fi + + AC_PATH_PROG(XML_CONFIG, xml-config, no) + min_xml_version=ifelse([$1], ,1.0.0,[$1]) + AC_MSG_CHECKING(for libxml - version >= $min_xml_version) + no_xml="" + if test "$XML_CONFIG" = "no" ; then + no_xml=yes + else + XML_CFLAGS=`$XML_CONFIG $xml_config_args --cflags` + XML_LIBS=`$XML_CONFIG $xml_config_args --libs` + xml_config_major_version=`$XML_CONFIG $xml_config_args --version | \ + sed 's/\([[0-9]]*\).\([[0-9]]*\).\([[0-9]]*\)/\1/'` + xml_config_minor_version=`$XML_CONFIG $xml_config_args --version | \ + sed 's/\([[0-9]]*\).\([[0-9]]*\).\([[0-9]]*\)/\2/'` + xml_config_micro_version=`$XML_CONFIG $xml_config_args --version | \ + sed 's/\([[0-9]]*\).\([[0-9]]*\).\([[0-9]]*\)/\3/'` + if test "x$enable_xmltest" = "xyes" ; then + ac_save_CFLAGS="$CFLAGS" + ac_save_LIBS="$LIBS" + CFLAGS="$CFLAGS $XML_CFLAGS" + LIBS="$XML_LIBS $LIBS" +dnl +dnl Now check if the installed libxml is sufficiently new. +dnl (Also sanity checks the results of xml-config to some extent) +dnl + rm -f conf.xmltest + AC_TRY_RUN([ +#include +#include +#include +#include + +int +main() +{ + int xml_major_version, xml_minor_version, xml_micro_version; + int major, minor, micro; + char *tmp_version; + int tmp_int_version; + + system("touch conf.xmltest"); + + /* Capture xml-config output via autoconf/configure variables */ + /* HP/UX 9 (%@#!) writes to sscanf strings */ + tmp_version = (char *)strdup("$min_xml_version"); + if (sscanf(tmp_version, "%d.%d.%d", &major, &minor, µ) != 3) { + printf("%s, bad version string from xml-config\n", "$min_xml_version"); + exit(1); + } + free(tmp_version); + + /* Capture the version information from the header files */ + tmp_int_version = LIBXML_VERSION; + xml_major_version=tmp_int_version / 10000; + xml_minor_version=(tmp_int_version - xml_major_version * 10000) / 100; + xml_micro_version=(tmp_int_version - xml_minor_version * 100 - xml_major_version * 10000); + + /* Compare xml-config output to the libxml headers */ + if ((xml_major_version != $xml_config_major_version) || + (xml_minor_version != $xml_config_minor_version) +#if 0 + || +/* The last released version of libxml-1.x has an incorrect micro version in + * the header file so neither the includes nor the library will match the + * micro_version to the output of xml-config + */ + (xml_micro_version != $xml_config_micro_version) +#endif + ) + + { + printf("*** libxml header files (version %d.%d.%d) do not match\n", + xml_major_version, xml_minor_version, xml_micro_version); + printf("*** xml-config (version %d.%d.%d)\n", + $xml_config_major_version, $xml_config_minor_version, $xml_config_micro_version); + return 1; + } +/* Compare the headers to the library to make sure we match */ + /* Less than ideal -- doesn't provide us with return value feedback, + * only exits if there's a serious mismatch between header and library. + */ + LIBXML_TEST_VERSION; + + /* Test that the library is greater than our minimum version */ + if (($xml_config_major_version > major) || + (($xml_config_major_version == major) && ($xml_config_minor_version > minor)) || + (($xml_config_major_version == major) && ($xml_config_minor_version == minor) && + ($xml_config_micro_version >= micro))) + { + return 0; + } + else + { + printf("\n*** An old version of libxml (%d.%d.%d) was found.\n", + xml_major_version, xml_minor_version, xml_micro_version); + printf("*** You need a version of libxml newer than %d.%d.%d. The latest version of\n", + major, minor, micro); + printf("*** libxml is always available from ftp://ftp.xmlsoft.org.\n"); + printf("***\n"); + printf("*** If you have already installed a sufficiently new version, this error\n"); + printf("*** probably means that the wrong copy of the xml-config shell script is\n"); + printf("*** being found. The easiest way to fix this is to remove the old version\n"); + printf("*** of LIBXML, but you can also set the XML_CONFIG environment to point to the\n"); + printf("*** correct copy of xml-config. (In this case, you will have to\n"); + printf("*** modify your LD_LIBRARY_PATH enviroment variable, or edit /etc/ld.so.conf\n"); + printf("*** so that the correct libraries are found at run-time))\n"); + } + return 1; +} +],, no_xml=yes,[echo $ac_n "cross compiling; assumed OK... $ac_c"]) + CFLAGS="$ac_save_CFLAGS" + LIBS="$ac_save_LIBS" + fi + fi + + if test "x$no_xml" = x ; then + AC_MSG_RESULT(yes (version $xml_config_major_version.$xml_config_minor_version.$xml_config_micro_version)) + ifelse([$2], , :, [$2]) + else + AC_MSG_RESULT(no) + if test "$XML_CONFIG" = "no" ; then + echo "*** The xml-config script installed by LIBXML could not be found" + echo "*** If libxml was installed in PREFIX, make sure PREFIX/bin is in" + echo "*** your path, or set the XML_CONFIG environment variable to the" + echo "*** full path to xml-config." + else + if test -f conf.xmltest ; then + : + else + echo "*** Could not run libxml test program, checking why..." + CFLAGS="$CFLAGS $XML_CFLAGS" + LIBS="$LIBS $XML_LIBS" + AC_TRY_LINK([ +#include +#include +], [ LIBXML_TEST_VERSION; return 0;], + [ echo "*** The test program compiled, but did not run. This usually means" + echo "*** that the run-time linker is not finding LIBXML or finding the wrong" + echo "*** version of LIBXML. If it is not finding LIBXML, you'll need to set your" + echo "*** LD_LIBRARY_PATH environment variable, or edit /etc/ld.so.conf to point" + echo "*** to the installed location Also, make sure you have run ldconfig if that" + echo "*** is required on your system" + echo "***" + echo "*** If you have an old version installed, it is best to remove it, although" + echo "*** you may also be able to get things to work by modifying LD_LIBRARY_PATH" ], + [ echo "*** The test program failed to compile or link. See the file config.log for the" + echo "*** exact error that occured. This usually means LIBXML was incorrectly installed" + echo "*** or that you have moved LIBXML since it was installed. In the latter case, you" + echo "*** may want to edit the xml-config script: $XML_CONFIG" ]) + CFLAGS="$ac_save_CFLAGS" + LIBS="$ac_save_LIBS" + fi + fi + + XML_CFLAGS="" + XML_LIBS="" + ifelse([$3], , :, [$3]) + fi + AC_SUBST(XML_CFLAGS) + AC_SUBST(XML_LIBS) + rm -f conf.xmltest +]) + +# Configure paths for LIBXML2 +# Toshio Kuratomi 2001-04-21 +# Adapted from: +# Configure paths for GLIB +# Owen Taylor 97-11-3 + +dnl AM_PATH_XML2([MINIMUM-VERSION, [ACTION-IF-FOUND [, ACTION-IF-NOT-FOUND]]]) +dnl Test for XML, and define XML_CFLAGS and XML_LIBS +dnl +AC_DEFUN(AM_PATH_XML2,[ +AC_ARG_WITH(xml-prefix, + [ --with-xml-prefix=PFX Prefix where libxml is installed (optional)], + xml_config_prefix="$withval", xml_config_prefix="") +AC_ARG_WITH(xml-exec-prefix, + [ --with-xml-exec-prefix=PFX Exec prefix where libxml is installed (optional)], + xml_config_exec_prefix="$withval", xml_config_exec_prefix="") +AC_ARG_ENABLE(xmltest, + [ --disable-xmltest Do not try to compile and run a test LIBXML program],, + enable_xmltest=yes) + + if test x$xml_config_exec_prefix != x ; then + xml_config_args="$xml_config_args --exec-prefix=$xml_config_exec_prefix" + if test x${XML2_CONFIG+set} != xset ; then + XML2_CONFIG=$xml_config_exec_prefix/bin/xml2-config + fi + fi + if test x$xml_config_prefix != x ; then + xml_config_args="$xml_config_args --prefix=$xml_config_prefix" + if test x${XML2_CONFIG+set} != xset ; then + XML2_CONFIG=$xml_config_prefix/bin/xml2-config + fi + fi + + AC_PATH_PROG(XML2_CONFIG, xml2-config, no) + min_xml_version=ifelse([$1], ,2.0.0,[$1]) + AC_MSG_CHECKING(for libxml - version >= $min_xml_version) + no_xml="" + if test "$XML2_CONFIG" = "no" ; then + no_xml=yes + else + XML_CFLAGS=`$XML2_CONFIG $xml_config_args --cflags` + XML_LIBS=`$XML2_CONFIG $xml_config_args --libs` + xml_config_major_version=`$XML2_CONFIG $xml_config_args --version | \ + sed 's/\([[0-9]]*\).\([[0-9]]*\).\([[0-9]]*\)/\1/'` + xml_config_minor_version=`$XML2_CONFIG $xml_config_args --version | \ + sed 's/\([[0-9]]*\).\([[0-9]]*\).\([[0-9]]*\)/\2/'` + xml_config_micro_version=`$XML2_CONFIG $xml_config_args --version | \ + sed 's/\([[0-9]]*\).\([[0-9]]*\).\([[0-9]]*\)/\3/'` + if test "x$enable_xmltest" = "xyes" ; then + ac_save_CFLAGS="$CFLAGS" + ac_save_CXXFLAGS="$CXXFLAGS" + ac_save_LIBS="$LIBS" + CFLAGS="$CFLAGS $XML_CFLAGS" + CXXFLAGS="$CXXFLAGS $XML_CFLAGS" + LIBS="$XML_LIBS $LIBS" +dnl +dnl Now check if the installed libxml is sufficiently new. +dnl (Also sanity checks the results of xml2-config to some extent) +dnl + rm -f conf.xmltest + AC_TRY_RUN([ +#include +#include +#include +#include + +int +main() +{ + int xml_major_version, xml_minor_version, xml_micro_version; + int major, minor, micro; + char *tmp_version; + + system("touch conf.xmltest"); + + /* Capture xml2-config output via autoconf/configure variables */ + /* HP/UX 9 (%@#!) writes to sscanf strings */ + tmp_version = (char *)strdup("$min_xml_version"); + if (sscanf(tmp_version, "%d.%d.%d", &major, &minor, µ) != 3) { + printf("%s, bad version string from xml2-config\n", "$min_xml_version"); + exit(1); + } + free(tmp_version); + + /* Capture the version information from the header files */ + tmp_version = (char *)strdup(LIBXML_DOTTED_VERSION); + if (sscanf(tmp_version, "%d.%d.%d", &xml_major_version, &xml_minor_version, &xml_micro_version) != 3) { + printf("%s, bad version string from libxml includes\n", "LIBXML_DOTTED_VERSION"); + exit(1); + } + free(tmp_version); + + /* Compare xml2-config output to the libxml headers */ + if ((xml_major_version != $xml_config_major_version) || + (xml_minor_version != $xml_config_minor_version) || + (xml_micro_version != $xml_config_micro_version)) + { + printf("*** libxml header files (version %d.%d.%d) do not match\n", + xml_major_version, xml_minor_version, xml_micro_version); + printf("*** xml2-config (version %d.%d.%d)\n", + $xml_config_major_version, $xml_config_minor_version, $xml_config_micro_version); + return 1; + } +/* Compare the headers to the library to make sure we match */ + /* Less than ideal -- doesn't provide us with return value feedback, + * only exits if there's a serious mismatch between header and library. + */ + LIBXML_TEST_VERSION; + + /* Test that the library is greater than our minimum version */ + if ((xml_major_version > major) || + ((xml_major_version == major) && (xml_minor_version > minor)) || + ((xml_major_version == major) && (xml_minor_version == minor) && + (xml_micro_version >= micro))) + { + return 0; + } + else + { + printf("\n*** An old version of libxml (%d.%d.%d) was found.\n", + xml_major_version, xml_minor_version, xml_micro_version); + printf("*** You need a version of libxml newer than %d.%d.%d. The latest version of\n", + major, minor, micro); + printf("*** libxml is always available from ftp://ftp.xmlsoft.org.\n"); + printf("***\n"); + printf("*** If you have already installed a sufficiently new version, this error\n"); + printf("*** probably means that the wrong copy of the xml2-config shell script is\n"); + printf("*** being found. The easiest way to fix this is to remove the old version\n"); + printf("*** of LIBXML, but you can also set the XML2_CONFIG environment to point to the\n"); + printf("*** correct copy of xml2-config. (In this case, you will have to\n"); + printf("*** modify your LD_LIBRARY_PATH enviroment variable, or edit /etc/ld.so.conf\n"); + printf("*** so that the correct libraries are found at run-time))\n"); + } + return 1; +} +],, no_xml=yes,[echo $ac_n "cross compiling; assumed OK... $ac_c"]) + CFLAGS="$ac_save_CFLAGS" + CXXFLAGS="$ac_save_CXXFLAGS" + LIBS="$ac_save_LIBS" + fi + fi + + if test "x$no_xml" = x ; then + AC_MSG_RESULT(yes (version $xml_config_major_version.$xml_config_minor_version.$xml_config_micro_version)) + ifelse([$2], , :, [$2]) + else + AC_MSG_RESULT(no) + if test "$XML2_CONFIG" = "no" ; then + echo "*** The xml2-config script installed by LIBXML could not be found" + echo "*** If libxml was installed in PREFIX, make sure PREFIX/bin is in" + echo "*** your path, or set the XML2_CONFIG environment variable to the" + echo "*** full path to xml2-config." + else + if test -f conf.xmltest ; then + : + else + echo "*** Could not run libxml test program, checking why..." + CFLAGS="$CFLAGS $XML_CFLAGS" + CXXFLAGS="$CXXFLAGS $XML_CFLAGS" + LIBS="$LIBS $XML_LIBS" + AC_TRY_LINK([ +#include +#include +], [ LIBXML_TEST_VERSION; return 0;], + [ echo "*** The test program compiled, but did not run. This usually means" + echo "*** that the run-time linker is not finding LIBXML or finding the wrong" + echo "*** version of LIBXML. If it is not finding LIBXML, you'll need to set your" + echo "*** LD_LIBRARY_PATH environment variable, or edit /etc/ld.so.conf to point" + echo "*** to the installed location Also, make sure you have run ldconfig if that" + echo "*** is required on your system" + echo "***" + echo "*** If you have an old version installed, it is best to remove it, although" + echo "*** you may also be able to get things to work by modifying LD_LIBRARY_PATH" ], + [ echo "*** The test program failed to compile or link. See the file config.log for the" + echo "*** exact error that occured. This usually means LIBXML was incorrectly installed" + echo "*** or that you have moved LIBXML since it was installed. In the latter case, you" + echo "*** may want to edit the xml2-config script: $XML2_CONFIG" ]) + CFLAGS="$ac_save_CFLAGS" + CXXFLAGS="$ac_save_CXXFLAGS" + LIBS="$ac_save_LIBS" + fi + fi + + XML_CFLAGS="" + XML_LIBS="" + $3 + + + ifelse([$3], , :, [$3]) + fi + AC_SUBST(XML_CFLAGS) + AC_SUBST(XML_LIBS) + rm -f conf.xmltest +]) diff --git a/synfig-studio/trunk/config/project.spec.in b/synfig-studio/trunk/config/project.spec.in new file mode 100755 index 0000000..2826101 --- /dev/null +++ b/synfig-studio/trunk/config/project.spec.in @@ -0,0 +1,47 @@ + +Summary: Voria Extented Template Library +Name: @PACKAGE_TARNAME@-devel +Version: @VERSION_MAJ@.@VERSION_MIN@.@VERSION_REV@ +Release: @VERSION_REL@ +Copyright: free (see license), see /usr/share/doc/%{name}-%{version}/license.html +URL: http://www.voria.com/ +Packager: Robert B. Quattlebaum Jr. +Group: Development/Languages +Icon: config/logo.gif +#Source0: http://www.stlport.org/archive/%{name}-%{version}.tar.gz +#Patch0: STLport-rename.patch +#Patch1: STLport-rules.patch +#Patch2: STLport-install-dir.patch +Buildroot: %{_tmppath}/%{name}-%{version}-%(id -u -n) + +%description +VoriaETL is a multiplatform class and template library +designed to complement and supplement the C++ STL. + +%prep +%setup +#%patch0 -p1 +#%patch1 -p1 +#%patch2 -p1 + +%build +./configure --prefix=$RPM_BUILD_ROOT +make + +%install +make install + +%clean +make clean + +%post -n @PACKAGE@-devel +/sbin/ldconfig + +%postun -n @PACKAGE@-devel +/sbin/ldconfig + +%files +%defattr(-,root,root) +%doc INSTALL README doc test +/usr/include/* + diff --git a/synfig-studio/trunk/config/sinfg.m4 b/synfig-studio/trunk/config/sinfg.m4 new file mode 100755 index 0000000..b4df86f --- /dev/null +++ b/synfig-studio/trunk/config/sinfg.m4 @@ -0,0 +1,51 @@ +# SINFG M4 Macro +# For GNU Autotools +# $Id: sinfg.m4,v 1.1.1.1 2005/01/07 03:34:35 darco Exp $ +# +# By Robert B. Quattlebaum Jr. +# + +AC_DEFUN([SINFG_DEPS], +[ + USING_ETL(,$2) + AM_PATH_XML2(,,$2) + AC_CHECK_FUNCS([floor pow sqrt],,$2) + $1 +]) + +AC_DEFUN([USING_SINFG], +[ + AC_ARG_WITH(sinfg-includes, + [ --with-sinfg-includes Specify location of sinfg headers],[ + CXXFLAGS="$CXXFLAGS -I$withval" + ]) + + AC_PATH_PROG(SINFG_CONFIG,sinfg-config,no) + + if test "$SINFG_CONFIG" = "no"; then + no_SINFG_config="yes" + $2 + else + AC_MSG_CHECKING([if $SINFG_CONFIG works]) + if $SINFG_CONFIG --libs >/dev/null 2>&1; then + SINFG_VERSION="`$SINFG_CONFIG --version`" + AC_MSG_RESULT([yes, $SINFG_VERSION]) + SINFG_CXXFLAGS="`$SINFG_CONFIG --cxxflags`" + SINFG_CFLAGS="`$SINFG_CONFIG --cflags`" + SINFG_LIBS="`$SINFG_CONFIG --libs`" + CXXFLAGS="$CXXFLAGS $SINFG_CXXFLAGS" + AC_SUBST(SINFG_CXXFLAGS) + AC_SUBST(SINFG_LIBS) + AC_SUBST(SINFG_CFLAGS) + $1 + else + AC_MSG_RESULT(no) + no_SINFG_config="yes" + $2 + fi + fi + + SINFG_DEPS($1,$2) +]) + + diff --git a/synfig-studio/trunk/config/subs.m4 b/synfig-studio/trunk/config/subs.m4 new file mode 100755 index 0000000..e7bab1c --- /dev/null +++ b/synfig-studio/trunk/config/subs.m4 @@ -0,0 +1,276 @@ + +## AC_ARG_WARNINGS() +## +## Provide the --enable-warnings configure argument, set to 'minimum' +## by default. +## +AC_DEFUN([AC_ARG_WARNINGS], +[ + AC_ARG_ENABLE([warnings], + [ --enable-warnings=[[none|minimum|maximum|hardcore]] + Control compiler pickyness. [[default=maximum]]], + [gtkmm_enable_warnings="$enableval"], + gtkmm_enable_warnings="maximum") + + AC_MSG_CHECKING([for compiler warning flags to use]) + + gtkmm_warning_flags='' + + case "$gtkmm_enable_warnings" in + none|no) gtkmm_warning_flags='';; + minimum|yes) gtkmm_warning_flags='-Wall -Wno-unused-parameter';; + maximum) gtkmm_warning_flags='-W -Wall -Wno-unused-parameter';; + hardcore) gtkmm_warning_flags='-W -Wall -Werror -Wno-unused-parameter';; + esac + + gtkmm_use_flags='' + + if test "x$gtkmm_warning_flags" != "x" + then + echo 'int foo() { return 0; }' > conftest.cc + + for flag in $gtkmm_warning_flags + do + # Test whether the compiler accepts the flag. GCC doesn't bail + # out when given an unsupported flag but prints a warning, so + # check the compiler output instead. + gtkmm_cxx_out="`$CXX $flag -c conftest.cc 2>&1`" + rm -f conftest.$OBJEXT + test "x${gtkmm_cxx_out}" = "x" && \ + gtkmm_use_flags="${gtkmm_use_flags:+$gtkmm_use_flags }$flag" + done + + rm -f conftest.cc + gtkmm_cxx_out='' + fi + + if test "x$gtkmm_use_flags" != "x" + then + for flag in $gtkmm_use_flags + do + case " $CXXFLAGS " in + *" $flag "*) ;; # don't add flags twice + *) CXXFLAGS="${CXXFLAGS:+$CXXFLAGS }$flag";; + esac + done + else + gtkmm_use_flags='none' + fi + + AC_MSG_RESULT([$gtkmm_use_flags]) +]) + + + + +AC_DEFUN([AC_ARG_DEBUG], +[ + AC_MSG_CHECKING([for debug flags]) + + AC_ARG_ENABLE(debug,[ --enable-debug Build in debugging mode],[ + debug=$enableval + ],[ + debug="no" + ]) + debug_flags='' + + case "$debug" in + yes) + debug_flags="-D_DEBUG -g" + ;; + half) + debug_flags="-DNDEBUG -g" + ;; + no|*) + debug_flags="-DNDEBUG -Wno-deprecated" + ;; + esac + + + CXXFLAGS="`echo $CXXFLAGS | sed s:-g::` $debug_flags" + CFLAGS="`echo $CFLAGS | sed s:-g::` $debug_flags" + + AC_MSG_RESULT([$debug_flags]) +]) + + + + +AC_DEFUN([AC_ARG_OPTIMIZATION], +[ + AC_MSG_CHECKING([for optimization flags]) + + AC_ARG_ENABLE(optimization,[ --enable-optimization=[[0,1,2,3,4]] Select optimization level (default=2)],[ + optimization=$enableval + ],[ + optimization="2" + ]) + optimization_flags='' + case "$optimization" in + 0|no) optimization_flags="-O0";; + 1) optimization_flags="-O1 -ffast-math";; + 2|yes) optimization_flags="-O2 -ffast-math";; + pass1) optimization_flags="-O2 -ffast-math -fprofile-arcs";; + pass2) optimization_flags="-O2 -ffast-math -fbranch-probabilities";; + 3) optimization_flags="-O3 -ffast-math";; + *) optimization_flags="-O4 -ffast-math";; + esac + CXXFLAGS="`echo $CXXFLAGS | sed 's:-O.::g'` $optimization_flags" + CFLAGS="`echo $CFLAGS | sed 's:-O.::g'` $optimization_flags" + AC_MSG_RESULT([$optimization_flags]) +]) + +AC_DEFUN([AC_ARG_PROFILE_ARCS], +[ + AC_MSG_CHECKING([for arc profiling]) + + AC_ARG_ENABLE(profile-arcs,[ --enable-profile-arcs Enable arc profiling],[ + profile_arcs=$enableval + ],[ + profile_arcs=no + ]) + + if test $profile_arcs = "yes" ; then { + CXXFLAGS="$CXXFLAGS -fprofile-arcs"; + CFLAGS="$CFLAGS -fprofile-arcs"; + } ; fi + + AC_MSG_RESULT([$profile_arcs]) +]) + +AC_DEFUN([AC_ARG_BRANCH_PROBABILITIES], +[ + AC_MSG_CHECKING([for branch-probabilities]) + + AC_ARG_ENABLE(branch-probabilities,[ --enable-branch-probabilities Enable branch-probabilities],[ + branch_probabilities=$enableval + ],[ + branch_probabilities=no + ]) + + if test $branch_probabilities = "yes" ; then { + CXXFLAGS="$CXXFLAGS -fbranch-probabilities"; + CFLAGS="$CFLAGS -fbranch-probabilities"; + } ; fi + + AC_MSG_RESULT([$branch_probabilities]) +]) + +AC_DEFUN([AC_ARG_PROFILING], +[ + AC_MSG_CHECKING([for profiling]) + + AC_ARG_ENABLE(profiling,[ --enable-profiling Enable profiling using gprof],[ + profiling=$enableval + ],[ + profiling=no + ]) + + if test $profiling = "yes" ; then { + CFLAGS="$CFLAGS -pg"; + CXXFLAGS="$CXXFLAGS -pg"; + LDFLAGS="$LDFLAGS -pg"; + LIBS="$LIBS"; + } ; fi + + AC_MSG_RESULT([$profiling]) +]) + +AC_DEFUN([AC_ARG_TIMELIMIT], +[ + AC_ARG_ENABLE(timelimit,[ --enable-timelimit=[[days]] Set number of usable days(default=forever)],[ + death_time=$((`date +%s`+$enableval*60*60*24)) + AC_DEFINE_UNQUOTED(DEATH_TIME,$death_time, [ Describes the time at which the library will stop working ] ) + ], + [ + death_time="no" + ]) +]) + +AC_DEFUN([AC_ARG_LICENSE_KEY], +[ + AC_ARG_ENABLE(license_key,[ --enable-license-key Turn on license key requirement],[ + AC_DEFINE(LICENSE_KEY_REQUIRED,, [ Enables license key checks ] ) + ], + [ + license_key="no" + ]) +]) + +AC_DEFUN([AC_ARG_TIMELIMIT], +[ + AC_ARG_ENABLE(timelimit,[ --enable-timelimit=[[days]] Set number of usable days(default=forever)],[ + death_time=$((`date +%s`+$enableval*60*60*24)) + AC_DEFINE_UNQUOTED(DEATH_TIME,$death_time, [ Describes the time at which the library will stop working ] ) + ], + [ + death_time="no" + ]) +]) + +MINGW_FLAGS="-mno-cygwin" + + +AC_DEFUN([AC_WIN32_QUIRKS], +[ + +case "$host" in + *mingw*) + AC_MSG_CHECKING([the flavor of the compiler]) + if ( $CC --version | grep -q mingw ) ; then { + AC_MSG_RESULT([compiler is mingw special]) + LIBTOOL_PATCH_SED=" + s/dir=\"\$absdir\"/dir=\`cygpath -d -m \"\$absdir\"\`/; + s/absdir=\`cd \"\$dir\" && pwd\`/absdir=\`cygpath -d -m \"\$dir\"\`/; + s/# We need an absolute path/dir=\`cygpath -d -m \"\$dir\"\` # We need an absolute path/; + s- /usr/lib- C:/mingw/lib-g; + s-\"/lib -\"C:/mingw/lib -g; + s- /lib/ - -g; + "; + sys_lib_dlsearch_path_spec="C:/mingw/lib" + ac_default_prefix=`cygpath -d -m "$ac_default_prefix"`; + } else { + AC_MSG_RESULT([compiler is cygwin stock, adding -mno-cygwin]) + CPP="$CPP $MINGW_FLAGS" + CC="$CC $MINGW_FLAGS" + CXX="$CXX $MINGW_FLAGS -L/usr/$host/lib -I/usr/include/c++/3.3.3/$host" + CXXCPP="$CXXCPP $MINGW_FLAGS" + + +} ; fi + + LTCC="gcc" + CXXFLAGS="$CXXFLAGS -LC:/GTK/lib" + CFLAGS="$CFLAGS -LC:/GTK/lib" + LDFLAGS="$LDFLAGS -lole32 -no-undefined -Wl,--export-all-symbols -Wl,--subsystem=console -Wl,--enable-runtime-pseudo-reloc" +dnl LDFLAGS="$LDFLAGS -lole32 -no-undefined -Wl,--export-all-symbols -Wl,--enable-auto-import -Wl,--subsystem=console -Wl,--enable-runtime-pseudo-reloc" + ;; + *cygwin*) + LDFLAGS="$LDFLAGS -lole32 -no-undefined -Wl,--export-all-symbols" +dnl LDFLAGS="$LDFLAGS -lole32 -no-undefined -Wl,--export-all-symbols -Wl,--enable-auto-import -Wl,--subsystem=console" + CXXFLAGS="$CXXFLAGS -I/target/include" + CFLAGS="$CFLAGS -I/target/include" + ;; + powerpc-apple*) + echo Adding mac-specific optimization flags. . . + CXXFLAGS="$CXXFLAGS $G5OPTFLAGS" + ;; +esac + + +]) + +AC_DEFUN([AC_LIBTOOL_PATCH], +[ + +if [[ "$LIBTOOL_PATCH_SED""x" != "x" ]] ; then { + printf "Patching libtool... " + cat libtool | sed "$LIBTOOL_PATCH_SED" > libtool2 + rm libtool + mv libtool2 libtool + chmod +x libtool + AC_MSG_RESULT([patched]) +} fi ; + + +]) diff --git a/synfig-studio/trunk/debugcrash b/synfig-studio/trunk/debugcrash new file mode 100755 index 0000000..b305d37 --- /dev/null +++ b/synfig-studio/trunk/debugcrash @@ -0,0 +1,2 @@ +#!/bin/sh +gdb -nw --core=~/core src/gtkmm/.libs/lt-sinfgstudio diff --git a/synfig-studio/trunk/fixer b/synfig-studio/trunk/fixer new file mode 100755 index 0000000..4bb7098 --- /dev/null +++ b/synfig-studio/trunk/fixer @@ -0,0 +1,10 @@ +#!/bin/bash + +TEMPFILENAME=~/deleteme.tmp + +for filename in `find . -name '*.[ch]*'` ; do { + sed ' +s/SigC::Signal./sigc::signal/g; + +' < $filename > $TEMPFILENAME && ( diff -q $TEMPFILENAME $filename || cp $TEMPFILENAME $filename ) +} ; done diff --git a/synfig-studio/trunk/images/Makefile.am b/synfig-studio/trunk/images/Makefile.am new file mode 100644 index 0000000..523a6e4 --- /dev/null +++ b/synfig-studio/trunk/images/Makefile.am @@ -0,0 +1,75 @@ + +SINFG=sinfg +EXT=@imageext@ + +EXTRA_DIST=studio_about.sif +IMAGES=mirror_icon.$(EXT) time_track_icon.$(EXT) pastecanvas_icon.$(EXT) group_icon.$(EXT) clear_redo_icon.$(EXT) clear_undo_icon.$(EXT) navigator_icon.$(EXT) info_icon.$(EXT) zoom_icon.$(EXT) meta_data_icon.$(EXT) children_icon.$(EXT) keyframe_icon.$(EXT) swap_colors_icon.$(EXT) rotate_icon.$(EXT) scale_icon.$(EXT) smooth_move_icon.$(EXT) width_icon.$(EXT) rectangle_icon.$(EXT) circle_icon.$(EXT) draw_icon.$(EXT) sketch_icon.$(EXT) fill_icon.$(EXT) normal_icon.$(EXT) sif_icon.$(EXT) sinfg_icon.$(EXT) saveall_icon.$(EXT) bool_icon.$(EXT) integer_icon.$(EXT) angle_icon.$(EXT) segment_icon.$(EXT) blinepoint_icon.$(EXT) list_icon.$(EXT) canvas_pointer_icon.$(EXT) string_icon.$(EXT) eyedrop_icon.$(EXT) about_icon.$(EXT) about_dialog.$(EXT) canvas_icon.$(EXT) vector_icon.$(EXT) real_icon.$(EXT) color_icon.$(EXT) valuenode_icon.$(EXT) polygon_icon.$(EXT) bline_icon.$(EXT) layer_icon.$(EXT) duplicate_icon.$(EXT) gradient_icon.$(EXT) keyframe_lock_all.$(EXT) keyframe_lock_past.$(EXT) keyframe_lock_future.$(EXT) keyframe_lock_none.$(EXT) + +CLEANFILES=$(IMAGES) + +imagedir=@imagedir@ + +image_DATA=$(IMAGES) + + +all: $(IMAGES) + +SUFFIXES=.sif .tif .png + +#.SUFFIXES: $(SUFFIXES) + +PNGTOICO=pngtoico +CONVERT=convert + +sif_icon.ico: + $(SINFG) sif_icon.sif -w 16 -h 16 -o sif_icon_16.gif sif_icon.sif -w 32 -h 32 -o sif_icon_32.gif sif_icon.sif -w 64 -h 64 -o sif_icon_64.gif + $(CONVERT) sif_icon_16.gif sif_icon_16.png + $(CONVERT) sif_icon_32.gif sif_icon_32.png + $(CONVERT) sif_icon_64.gif sif_icon_64.png + $(PNGTOICO) sif_icon_64.png > sif_icon.ico +# $(PNGTOICO) sif_icon_16.png sif_icon_32.png sif_icon_64.png > sif_icon.ico + +clean: + $(RM) $(CLEANFILES) + +.sif.bmp: + $(SINFG) -q $< -o $@ --time 0 + +.sif.$(EXT): + $(SINFG) -q $< -o $@ --time 0 + +keyframe_lock_all.$(EXT): keyframe_lock_icon.sif + $(SINFG) -q $< -o $@ --time 0 + +keyframe_lock_past.$(EXT): keyframe_lock_icon.sif + $(SINFG) -q $< -o $@ --time 0 -c PastOnly + +keyframe_lock_future.$(EXT): keyframe_lock_icon.sif + $(SINFG) -q $< -o $@ --time 0 -c FutureOnly + +keyframe_lock_none.$(EXT): keyframe_lock_icon.sif + $(SINFG) -q $< -o $@ --time 0 -c Disabled + +#.sif.png: +# $(SINFG) -q $< -o $@ --time 0 + +#datanode_icon.$(EXT): datanode_icon.sif +# $(SINFG) -q datanode_icon.sif -o datanode_icon.$(EXT) -w 128 -h 128 --time 0 + +#color_icon.$(EXT): color_icon.sif +# $(SINFG) -q color_icon.sif -o color_icon.$(EXT) -w 128 -h 128 --time 0 + +#real_icon.$(EXT): real_icon.sif +# $(SINFG) -q real_icon.sif -o real_icon.$(EXT) -w 128 -h 128 --time 0 + +#vector_icon.$(EXT): vector_icon.sif +# $(SINFG) -q vector_icon.sif -o vector_icon.$(EXT) -w 128 -h 128 --time 0 + +#about_dialog.$(EXT): about_dialog.sif +# $(SINFG) -q about_dialog.sif -o about_dialog.$(EXT) --time 0 + +#about_icon.$(EXT): about_icon.sif +# $(SINFG) -q about_icon.sif -o about_icon.$(EXT) -w 128 -h 128 --time 0 + +#canvas_icon.$(EXT): canvas_icon.sif +# $(SINFG) -q canvas_icon.sif -o canvas_icon.$(EXT) -w 128 -h 128 --time 0 diff --git a/synfig-studio/trunk/images/Makefile.inc b/synfig-studio/trunk/images/Makefile.inc new file mode 100644 index 0000000..7bea629 --- /dev/null +++ b/synfig-studio/trunk/images/Makefile.inc @@ -0,0 +1,35 @@ + +EXT=png +SINFG=sinfg + +EXTRA_DIST=studio_about.sif +IMAGES=fill_icon.$(EXT) normal_icon.$(EXT) sif_icon.$(EXT) sinfg_icon.$(EXT) saveall_icon.$(EXT) bool_icon.$(EXT) integer_icon.$(EXT) angle_icon.$(EXT) segment_icon.$(EXT) blinepoint_icon.$(EXT) list_icon.$(EXT) canvas_pointer_icon.$(EXT) string_icon.$(EXT) eyedrop_icon.$(EXT) about_icon.$(EXT) about_dialog.$(EXT) canvas_icon.$(EXT) vector_icon.$(EXT) real_icon.$(EXT) color_icon.$(EXT) valuenode_icon.$(EXT) polygon_icon.$(EXT) bline_icon.$(EXT) layer_icon.$(EXT) duplicate_icon.$(EXT) gradient_icon.$(EXT) keyframe_lock_all.$(EXT) keyframe_lock_past.$(EXT) keyframe_lock_future.$(EXT) keyframe_lock_none.$(EXT) + +CLEANFILES=$(IMAGES) + + +all: $(IMAGES) + +.SUFFIXES:.sif .tif .png + +clean: + $(RM) $(CLEANFILES) + +.sif.tif: + $(SINFG) -q $< -o $@ --time 0 + +.sif.png: + $(SINFG) -q $< -o $@ --time 0 + +keyframe_lock_all.$(EXT): keyframe_lock_icon.sif + $(SINFG) -q $< -o $@ --time 0 + +keyframe_lock_past.$(EXT): keyframe_lock_icon.sif + $(SINFG) -q $< -o $@ --time 0 -c PastOnly + +keyframe_lock_future.$(EXT): keyframe_lock_icon.sif + $(SINFG) -q $< -o $@ --time 0 -c FutureOnly + +keyframe_lock_none.$(EXT): keyframe_lock_icon.sif + $(SINFG) -q $< -o $@ --time 0 -c Disabled + diff --git a/synfig-studio/trunk/images/about_dialog.sif b/synfig-studio/trunk/images/about_dialog.sif new file mode 100644 index 0000000..b6add27 --- /dev/null +++ b/synfig-studio/trunk/images/about_dialog.sif @@ -0,0 +1,1704 @@ + + + About Dialog Graphic + + + + + + + + + Aqua Sphere + This aqua-colored sphere reminds me of something from MacOS X. + + + + + + + + + + + + + 0.000000 + 0.744518 + 0.825040 + 1.000000 + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + + + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + + 0.587045 + 0.941024 + 1.000000 + 1.000000 + + + + + + + + + + + 0.0000000000 + 0.7500000000 + + + + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + + + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + + 1.000000 + 1.000000 + 1.000000 + 1.000000 + + + + + + + + + + + -0.1500000060 + -0.3499999940 + + + + + + + + + + + + + + + + + + + + + + 0.2000000030 + 0.2000000030 + + + + + + + + + + + + + + + + + + + 0.000000 + 0.762890 + 1.000000 + 1.000000 + + + + + + + + + + + + + + + + 1.000000 + 1.000000 + 1.000000 + 0.000000 + + + + + + + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + + + SINFG Studio + + + + 1.000000 + 1.000000 + 1.000000 + 1.000000 + + + + luxisr + + + + + + + + + + + + + + + + 0.1899999976 + 0.2000000030 + + + + + 1.0000000000 + 1.0000000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + + + + + 0.0500000007 + 0.0500000007 + + + + + + + + + + + + + + + + + + SINFG Studio + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + luxisr + + + + + + + + + + + + + + + + 0.1899999976 + 0.2000000030 + + + + + 1.0000000000 + 1.0000000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + 1.000000 + 1.000000 + 1.000000 + 1.000000 + + + + + + + + + + + + + + + + 0.0000000000 + 0.2500000000 + + + + + 0.0000000000 + 2.7500000000 + + + + + + 0.000000 + 0.000000 + 0.000000 + 0.000000 + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + + + + + + + + + + + + + + + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + -1.7500000000 + 2.5000000000 + + + + + 1.7500000000 + 2.2500703335 + + + + + + + + + + + + + + + + + + + + + + -1.5000000000 + 2.5000000000 + + + + + -1.2500000000 + 2.2500000000 + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 0.000000 + + + 1.000000 + 1.000000 + 0.000000 + 1.000000 + + + 1.000000 + 1.000000 + 0.000000 + 1.000000 + + + 0.000000 + 0.000000 + 0.000000 + 0.000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + A L P H A + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + Arial Black + + + + + + + + + + + + + + + + 0.0937500000 + 0.0773138478 + + + + + 0.5000000000 + 0.5000000000 + + + + + 0.0000000000 + 2.3665711880 + + + + + + + + + + + + + + + + -1.5000000000 + 2.3711292744 + + + + + + + + + + + + + + + + + + + + + + + + + + + + 1.5000000000 + 2.5000000000 + + + + + 1.5000000000 + 2.2500000000 + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + 0.483334 + 0.483334 + 0.483334 + 1.000000 + + + 0.801383 + 0.801383 + 0.801384 + 1.000000 + + + 0.546153 + 0.546153 + 0.546153 + 1.000000 + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.0416666679 + -0.0416666679 + + + + + 0.0416666679 + 0.0416666679 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.0000000000 + 1.2500000000 + + + + + + + + + + + + + + + + + + 0.920368 + 0.920368 + 0.920368 + 0.000000 + + + 0.934270 + 0.934270 + 0.934270 + 0.820503 + + + 0.929226 + 0.929226 + 0.929226 + 0.404875 + + + 1.000000 + 1.000000 + 1.000000 + 0.425000 + + + 0.876978 + 0.876978 + 0.876978 + 0.064816 + + + 0.940432 + 0.940432 + 0.940432 + 0.353949 + + + 0.976427 + 0.976427 + 0.976427 + 0.252097 + + + 1.000000 + 1.000000 + 1.000000 + 0.800000 + + + -0.000000 + -0.000000 + -0.000000 + 0.008584 + + + 1.000000 + 1.000000 + 1.000000 + 0.655000 + + + -0.000000 + -0.000000 + -0.000000 + 0.008584 + + + 0.997147 + 0.997147 + 0.997147 + 0.752147 + + + -0.000000 + -0.000000 + -0.000000 + 0.008584 + + + 1.000000 + 1.000000 + 1.000000 + 0.697727 + + + 1.000000 + 1.000000 + 1.000000 + 1.000000 + + + 0.958579 + 0.958579 + 0.958579 + 0.150345 + + + 0.930914 + 0.930914 + 0.930914 + 1.000000 + + + -0.000000 + -0.000000 + -0.000000 + 0.008584 + + + 0.992545 + 0.992545 + 0.992545 + 0.537339 + + + -0.000000 + -0.000000 + -0.000000 + 0.008584 + + + 1.000000 + 1.000000 + 1.000000 + 1.000000 + + + 1.000000 + 1.000000 + 1.000000 + 0.000000 + + + 1.000000 + 1.000000 + 1.000000 + 0.525000 + + + -0.000000 + -0.000000 + -0.000000 + 0.008584 + + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + + 1.493478 + 1.439264 + 1.000000 + 1.000000 + + + + + + + + + + + + + + + + 0.0374999978 + 0.0374999978 + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + + + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + 0.0000000000 + 1.2500000000 + + + + + + + + + + + + + + + + + + + + + 0.013829 + 0.013829 + 0.013829 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + 0.1041666642 + 0.1041666642 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.0099999998 + 0.1424999982 + + + + + + + + + + + + + + + + + -0.0990606323 + 0.4690153301 + + + + + -0.0990606323 + -0.0307283755 + + + + + + 0.000000 + 0.000000 + 0.000000 + 0.000000 + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + + + + + + + + + + + + + + + + + + S T U D I O + + + + 0.000000 + 0.000000 + 0.000000 + 0.000000 + + + + times + + + + + + + + + + + + + + + + 0.5000000000 + 0.5000000000 + + + + + 0.5000000000 + 1.0000000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + -2.0734415054 + 0.6111532450 + + + + + 2.1833333969 + -0.0333333351 + + + + + -2.5265016556 + -0.3445624709 + + + + + 2.6473100185 + -0.3445624709 + + + + + 2.1666667461 + 0.0170713197 + + + + + -2.0499999523 + 0.0170713197 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.1000000015 + 0.0000000000 + + + + + + + + + + + + + + + + + + S T U D I O + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + times + + + + + + + + + + + + + + + + 0.5000000000 + 0.4500000179 + + + + + 0.5000000000 + 1.0000000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 0.000000 + + + + + -2.5000000000 + 0.7500000000 + + + + + 2.5000000000 + -0.5000000000 + + + + + + + + + + + + + + + + + + + + + S Y N F I G + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + arialbd + + + + + + + + + + + + + + + + 0.3000000119 + 0.2166666687 + + + + + 0.5000000000 + 1.0000000000 + + + + + 0.0000000000 + 0.5666666627 + + + + + + + + + + + + + + + + + + + + + + + + + 1.000000 + 1.000000 + 1.000000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + 0.1000000015 + 0.1000000015 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + 0.0000000000 + -0.5000000000 + + + + + 0.0000000000 + 2.5000000000 + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + 1.000000 + 1.000000 + 1.000000 + 0.000000 + + + + + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 0.000000 + + + + + -1.5000000000 + 2.5000000000 + + + + + 1.5000000000 + -1.0000000000 + + + + + + + + + + + + + + + + + diff --git a/synfig-studio/trunk/images/about_icon.sif b/synfig-studio/trunk/images/about_icon.sif new file mode 100644 index 0000000..aff3ee3 --- /dev/null +++ b/synfig-studio/trunk/images/about_icon.sif @@ -0,0 +1,65 @@ + + + Untitled0 + + + + + + + + + + + + + 0.0000000000 + 0.0500000007 + + + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.1000000015 + -0.1000000015 + + + + + 0.2000000030 + 0.2000000030 + + + + + + + + + + diff --git a/synfig-studio/trunk/images/angle_icon.sif b/synfig-studio/trunk/images/angle_icon.sif new file mode 100644 index 0000000..d53afe1 --- /dev/null +++ b/synfig-studio/trunk/images/angle_icon.sif @@ -0,0 +1,65 @@ + + + Untitled0 + + + + + + + + + + + + DEG + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + Arial + + + + + + + + + + + + + + + + 1.0000000000 + 1.2031250000 + + + + + 0.5000000000 + 0.5000000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + diff --git a/synfig-studio/trunk/images/bline_icon.sif b/synfig-studio/trunk/images/bline_icon.sif new file mode 100644 index 0000000..824157f --- /dev/null +++ b/synfig-studio/trunk/images/bline_icon.sif @@ -0,0 +1,540 @@ + + + Untitled2 + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.1000000015 + -0.1000000015 + + + + + + + + + + + + + + + + + + + + + 0.8000000119 + 0.8000000119 + + + + + + + + + + + + + + 0.9769230485 + 1.8730769157 + + + + + -2.2346153259 + -0.9346153736 + + + + + + + + + -0.8000000119 + 0.8000000119 + + + + + + + + + + + + + + -0.8999999762 + -0.8999999762 + + + + + -0.8999999762 + -0.8999999762 + + + + + + + + + -0.6000000238 + -0.8000000119 + + + + + + + + + + + + + + -1.3999999762 + -3.0000000000 + + + + + 4.0615386963 + -0.0384615399 + + + + + + + + + + + + + + + + + + + + 0.000000 + 0.500000 + 1.000000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + 0.8000000119 + 0.8000000119 + + + + + + + + + + + + + + 0.9769230485 + 1.8730769157 + + + + + -2.2346153259 + -0.9346153736 + + + + + + + + + -0.8000000119 + 0.8000000119 + + + + + + + + + + + + + + -0.8999999762 + -0.8999999762 + + + + + -0.8999999762 + -0.8999999762 + + + + + + + + + -0.6000000238 + -0.8000000119 + + + + + + + + + + + + + + -1.3999999762 + -3.0000000000 + + + + + 4.0615386963 + -0.0384615399 + + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + + + + + + + -0.6999999881 + 0.8000000119 + + + + + + + + + + + + + + + + + + + + + + + + + 1.000000 + 1.000000 + 1.000000 + 1.000000 + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + 0.8000000119 + 0.8000000119 + + + + + + + + + + + + + + 0.9769230485 + 1.8730769157 + + + + + -2.2346153259 + -0.9346153736 + + + + + + + + + -0.8000000119 + 0.8000000119 + + + + + + + + + + + + + + -0.8999999762 + -0.8999999762 + + + + + -0.8999999762 + -0.8999999762 + + + + + + + + + -0.6000000238 + -0.8000000119 + + + + + + + + + + + + + + -1.3999999762 + -3.0000000000 + + + + + 4.0615386963 + -0.0384615399 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.1000000015 + -0.1000000015 + + + + + 0.1000000015 + 0.1000000015 + + + + + + + + + + diff --git a/synfig-studio/trunk/images/blinepoint_icon.sif b/synfig-studio/trunk/images/blinepoint_icon.sif new file mode 100644 index 0000000..badbf3a --- /dev/null +++ b/synfig-studio/trunk/images/blinepoint_icon.sif @@ -0,0 +1,66 @@ + + + Untitled0 + + + + + + + + + + + + BLINE +POINT + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + Arial + + + + + + + + + + + + + + + + 0.6250000000 + 1.2500000000 + + + + + 0.5000000000 + 0.5000000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + diff --git a/synfig-studio/trunk/images/bool_icon.sif b/synfig-studio/trunk/images/bool_icon.sif new file mode 100644 index 0000000..2f1a95e --- /dev/null +++ b/synfig-studio/trunk/images/bool_icon.sif @@ -0,0 +1,266 @@ + + + Untitled0 + + + + + + + + + + + + ON +OFF + + + + 0.531049 + 0.000000 + 0.000000 + 1.000000 + + + + Sans Serif + + + + + + + + + + + + + + + + 0.6250000000 + 0.7500000000 + + + + + 0.5000000000 + 0.5000000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + + -0.000000 + 0.217638 + -0.000000 + 1.000000 + + + + + -1.2500000000 + 0.1250000000 + + + + + 1.3750000000 + 1.3750000000 + + + + + + + + + + + + + + + + + + + + + + + + + 1.000000 + 1.000000 + 1.000000 + 1.000000 + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -0.000000 + -0.000000 + -0.000000 + 1.000000 + + + + + -1.5000000000 + -0.1250000000 + + + + + 1.5000000000 + 0.1250000000 + + + + + + + + + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.1000000015 + -0.1000000015 + + + + + 0.1000000015 + 0.1000000015 + + + + + + + + + + + + + 0.0000000000 + 0.1250000000 + + + + + + + + + + + + + + + + + + diff --git a/synfig-studio/trunk/images/canvas_icon.sif b/synfig-studio/trunk/images/canvas_icon.sif new file mode 100644 index 0000000..34dcbfa --- /dev/null +++ b/synfig-studio/trunk/images/canvas_icon.sif @@ -0,0 +1,332 @@ + + + Sinfg Studio Canvas Icon + + + Sphere + + + + + + + + + + + + + 0.000000 + 0.744518 + 0.825040 + 1.000000 + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + + + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + + 0.587045 + 0.941024 + 1.000000 + 1.000000 + + + + + + + + + + + 0.0000000000 + 0.7500000000 + + + + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + + + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + + 1.000000 + 1.000000 + 1.000000 + 1.000000 + + + + + + + + + + + -0.1500000060 + -0.3499999940 + + + + + + + + + + + + + + + + + + + + + + 0.2000000030 + 0.2000000030 + + + + + + + + + + + + + + + + + + + 0.000000 + 0.762890 + 1.000000 + 1.000000 + + + + + + + + + + + + + + + + 1.000000 + 1.000000 + 1.000000 + 0.000000 + + + + + + + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + + + + 1.000000 + 1.000000 + 1.000000 + 1.000000 + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + + + + + + + 0.1000000015 + 0.1000000015 + + + + + + + + + + + + + + + + + + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + diff --git a/synfig-studio/trunk/images/canvas_pointer_icon.sif b/synfig-studio/trunk/images/canvas_pointer_icon.sif new file mode 100644 index 0000000..99a4c06 --- /dev/null +++ b/synfig-studio/trunk/images/canvas_pointer_icon.sif @@ -0,0 +1,193 @@ + + + Untitled0 + + + + + + + + + + + + + 0.985195 + 0.174900 + -0.000000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + -0.6000000238 + 0.2000000030 + + + + + 0.8000000119 + 0.2000000030 + + + + + 0.8000000119 + -0.2000000030 + + + + + 1.6000000238 + 0.6000000238 + + + + + 0.8000000119 + 1.3999999762 + + + + + 0.8000000119 + 1.0000000000 + + + + + -0.6000000238 + 1.0000000000 + + + + + + + + + + + + + + + + + + + + + 1.000000 + 1.000000 + 1.000000 + 1.000000 + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.0000000000 + -0.0000000000 + + + + + 0.3499999940 + 0.3499999940 + + + + + + + + + + + + + + + + + + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + diff --git a/synfig-studio/trunk/images/children_icon.sif b/synfig-studio/trunk/images/children_icon.sif new file mode 100644 index 0000000..c3bb476 --- /dev/null +++ b/synfig-studio/trunk/images/children_icon.sif @@ -0,0 +1,80 @@ + + + Untitled0 + + + + + + + + + + + + + + + + CHILD + + + + 0.000000 + 0.189396 + 0.155043 + 1.000000 + + + + Arial Black + + + + + + + + + + + + + + + + 0.7919595838 + 0.7919595838 + + + + + 0.5000000000 + 0.5000000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + 0.0000000000 + 0.0000000000 + + + + + + + diff --git a/synfig-studio/trunk/images/circle_icon.sif b/synfig-studio/trunk/images/circle_icon.sif new file mode 100644 index 0000000..61026d6 --- /dev/null +++ b/synfig-studio/trunk/images/circle_icon.sif @@ -0,0 +1,445 @@ + + + Untitled0 + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000042 + 1.000000 + + + + + + + + + + + 0.1000000015 + -0.1000000015 + + + + + + + + + + + + + + + + + + + + + + -0.000000 + -0.000000 + 0.000000 + 1.000000 + + + + + + + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + + 1.000000 + 1.000000 + 1.000000 + 1.000000 + + + + + + + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + 0.0000100000 + 0.0000000000 + + + + + 0.0000100000 + 0.0000000000 + + + + + + + + + 0.7500000000 + 0.0000000000 + + + + + + + + + + + + + + -0.0000100000 + 0.0000000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + + + + + + + -0.4230769277 + 0.4487179518 + + + + + + + + + + + + + + + + + + + + + + 0.214520 + 0.214520 + 0.214520 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + 0.0000000000 + 0.2500000000 + + + + + 0.2500000000 + 0.0000000000 + + + + + 0.0000000000 + -0.2500000000 + + + + + -0.2500000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + 0.214520 + 0.214520 + 0.214520 + 1.000000 + + + + + 0.7500000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + 0.0000000000 + 0.2500000000 + + + + + 0.2500000000 + 0.0000000000 + + + + + 0.0000000000 + -0.2500000000 + + + + + -0.2500000000 + 0.0000000000 + + + + + + + + + -0.1093750000 + 0.0312500000 + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.1000000015 + -0.1000000015 + + + + + 0.1000000015 + 0.1000000015 + + + + + + + + + + diff --git a/synfig-studio/trunk/images/clear_redo_icon.sif b/synfig-studio/trunk/images/clear_redo_icon.sif new file mode 100644 index 0000000..9f89262 --- /dev/null +++ b/synfig-studio/trunk/images/clear_redo_icon.sif @@ -0,0 +1,1834 @@ + + + Untitled0 + + + + + + + + + + + + + + + + + 0.213899 + 0.706536 + 0.150728 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + 1.2500000000 + 0.7500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.2499999702 + 1.7500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.2499999702 + 1.2500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -1.0000001192 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.2499999702 + -1.5000000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -0.2500000298 + -0.5000000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.2499999702 + 0.2500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.2499999702 + -0.2500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + 1.2500000000 + 0.7500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.2499999702 + 1.7500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.2499999702 + 1.2500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -1.0000001192 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.2499999702 + -1.5000000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -0.2500000298 + -0.5000000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.2499999702 + 0.2500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.2499999702 + -0.2500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + 1.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + -1.7500000000 + 1.2500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -1.2500000000 + 1.7500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.0000000000 + 0.5000000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 1.2500000000 + 1.7500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 1.7500000000 + 1.2500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.5000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 1.7500000000 + -1.2500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 1.2500000000 + -1.7500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.0000000000 + -0.5000000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -1.2500000000 + -1.7500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -1.7500000000 + -1.2500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -0.5000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 1.000000 + 1.000000 + 1.000000 + 1.000000 + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + -1.7500000000 + 1.2500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -1.2500000000 + 1.7500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.0000000000 + 0.5000000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 1.2500000000 + 1.7500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 1.7500000000 + 1.2500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.5000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 1.7500000000 + -1.2500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 1.2500000000 + -1.7500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.0000000000 + -0.5000000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -1.2500000000 + -1.7500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -1.7500000000 + -1.2500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -0.5000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/synfig-studio/trunk/images/clear_undo_icon.sif b/synfig-studio/trunk/images/clear_undo_icon.sif new file mode 100644 index 0000000..f5eaa34 --- /dev/null +++ b/synfig-studio/trunk/images/clear_undo_icon.sif @@ -0,0 +1,1834 @@ + + + Untitled0 + + + + + + + + + + + + + + + + + 1.000000 + 0.250000 + 0.000000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + -1.2500000000 + 0.7500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -0.2500000000 + 1.7500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -0.2500000000 + 1.2500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 1.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -0.2500000000 + -1.5000000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.2500000000 + -0.5000000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -0.2500000000 + 0.2500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -0.2500000000 + -0.2500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + -1.2500000000 + 0.7500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -0.2500000000 + 1.7500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -0.2500000000 + 1.2500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 1.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -0.2500000000 + -1.5000000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.2500000000 + -0.5000000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -0.2500000000 + 0.2500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -0.2500000000 + -0.2500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + 1.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + -1.7500000000 + 1.2500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -1.2500000000 + 1.7500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.0000000000 + 0.5000000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 1.2500000000 + 1.7500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 1.7500000000 + 1.2500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.5000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 1.7500000000 + -1.2500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 1.2500000000 + -1.7500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.0000000000 + -0.5000000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -1.2500000000 + -1.7500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -1.7500000000 + -1.2500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -0.5000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 1.000000 + 1.000000 + 1.000000 + 1.000000 + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + -1.7500000000 + 1.2500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -1.2500000000 + 1.7500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.0000000000 + 0.5000000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 1.2500000000 + 1.7500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 1.7500000000 + 1.2500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.5000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 1.7500000000 + -1.2500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 1.2500000000 + -1.7500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.0000000000 + -0.5000000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -1.2500000000 + -1.7500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -1.7500000000 + -1.2500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -0.5000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/synfig-studio/trunk/images/color_icon.sif b/synfig-studio/trunk/images/color_icon.sif new file mode 100644 index 0000000..d2093e4 --- /dev/null +++ b/synfig-studio/trunk/images/color_icon.sif @@ -0,0 +1,391 @@ + + + Sinfg Studio Color Icon + + + ColorDisc + + + + 1.000000 + 0.000000 + 0.000000 + 1.000000 + + + 1.000000 + 1.000000 + 0.000000 + 1.000000 + + + 0.000000 + 1.000000 + 0.000000 + 1.000000 + + + 0.000000 + 1.000000 + 1.000000 + 1.000000 + + + 0.000000 + 0.000000 + 1.000000 + 1.000000 + + + 1.000000 + 0.000000 + 1.000000 + 1.000000 + + + 1.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + + + + + + + + + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + + 0.2000000030 + 0.2000000030 + + + + + + + + + + + + + + + + + + + 1.000000 + 1.000000 + 1.000000 + 1.000000 + + + + + + + + + + + 0.0625000000 + 0.1093750000 + + + + + + + + + + + + + + + + + + + + + + 0.333252 + 0.000000 + 1.000000 + 1.000000 + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + + + + + + + -0.1093750000 + -0.1406250000 + + + + + + + + + + + + + + + + + + + + + + 1.000000 + 1.000000 + 1.000000 + 0.000000 + + + + + + + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + + + + 1.000000 + 1.000000 + 1.000000 + 1.000000 + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + + + + + + + 0.1151999980 + 0.1151999980 + + + + + + + + + + + + + + + + + + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + + + + 1.000000 + 1.000000 + 1.000000 + 1.000000 + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.1000000015 + -0.1000000015 + + + + + 0.1000000015 + 0.1000000015 + + + + + + + + + + diff --git a/synfig-studio/trunk/images/draw_icon.sif b/synfig-studio/trunk/images/draw_icon.sif new file mode 100644 index 0000000..4fe8054 --- /dev/null +++ b/synfig-studio/trunk/images/draw_icon.sif @@ -0,0 +1,199 @@ + + + Untitled0 + + + + + + + + + + + + + 0.630956 + 0.260201 + 0.059618 + 1.000000 + + + + + + + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + + + + + 1.000000 + 1.000000 + 1.000000 + 1.000000 + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + DRAW + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + Sans Serif + + + + + + + + + + + + + + + + 0.7954951525 + 0.7954950929 + + + + + 0.5000000000 + 0.5000000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/synfig-studio/trunk/images/duplicate_icon.sif b/synfig-studio/trunk/images/duplicate_icon.sif new file mode 100644 index 0000000..06507b5 --- /dev/null +++ b/synfig-studio/trunk/images/duplicate_icon.sif @@ -0,0 +1,366 @@ + + + Untitled1 + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.1000000015 + -0.1000000015 + + + + + + + + + + + + + + + + + + + -0.4000000060 + 0.4000000060 + + + + + -0.4000000060 + -0.4000000060 + + + + + 0.4000000060 + -0.4000000060 + + + + + 0.4000000060 + 0.4000000060 + + + + + + + + + + + + + + + + + + 0.1000000015 + 0.1000000015 + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + -0.4000000060 + 0.4000000060 + + + + + -0.4000000060 + -0.4000000060 + + + + + 0.4000000060 + -0.4000000060 + + + + + 0.4000000060 + 0.4000000060 + + + + + + + + + + + + + + + + + + 1.000000 + 0.900000 + 0.600000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + -0.3000000119 + 0.3000000119 + + + + + -0.3000000119 + -0.3000000119 + + + + + 0.3000000119 + -0.3000000119 + + + + + 0.3000000119 + 0.3000000119 + + + + + + + + + + + + + + + + + + + + 0.4000000060 + -0.4000000060 + + + + + + + + + + + + + + + + + + + + + -0.5000000000 + 0.5000000000 + + + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + -0.8000000119 + -0.1000000015 + + + + + -0.6000000238 + -0.1000000015 + + + + + -0.6000000238 + -0.4000000060 + + + + + -0.4000000060 + -0.4000000060 + + + + + -0.4000000060 + -0.2000000030 + + + + + -0.1000000015 + -0.5000000000 + + + + + -0.4000000060 + -0.8000000119 + + + + + -0.4000000060 + -0.6000000238 + + + + + -0.8000000119 + -0.6000000238 + + + + + + diff --git a/synfig-studio/trunk/images/eyedrop_icon.sif b/synfig-studio/trunk/images/eyedrop_icon.sif new file mode 100644 index 0000000..d0fff4c --- /dev/null +++ b/synfig-studio/trunk/images/eyedrop_icon.sif @@ -0,0 +1,1386 @@ + + + Untitled1 + + + + + + + + + + + + + -0.000000 + 0.152747 + 0.941503 + 1.000000 + + + + + -1.6000000238 + -1.6000000238 + + + + + 1.6000000238 + 1.6000000238 + + + + + + + + + + + + + + + + + + + + + + -0.1000000015 + 0.0000000000 + + + + + + + + + + + + + + + + + 0.241820 + 0.376990 + 0.966331 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + -1.2500000000 + -0.7500000000 + + + + + + + + + + + + + + -0.5000000000 + -0.5000000000 + + + + + -0.5000000000 + -0.5000000000 + + + + + + + + + -1.7500000000 + -1.5000000000 + + + + + + + + + + + + + + -0.7500000000 + -0.7500000000 + + + + + 0.2500000000 + -0.2500000000 + + + + + + + + + -1.5000000000 + -1.7500000000 + + + + + + + + + + + + + + 0.2500000000 + -0.2500000000 + + + + + 0.7500000000 + 0.7500000000 + + + + + + + + + -0.7500000000 + -1.2500000000 + + + + + + + + + + + + + + 0.5000000000 + 0.5000000000 + + + + + 0.5000000000 + 0.5000000000 + + + + + + + + + 1.0000000000 + 0.5000000000 + + + + + + + + + + + + + + 0.7500000000 + 0.7500000000 + + + + + -0.5000000000 + 0.5000000000 + + + + + + + + + 0.5000000000 + 1.0000000000 + + + + + + + + + + + + + + -0.5000000000 + 0.5000000000 + + + + + -0.7500000000 + -0.7500000000 + + + + + + + + + + + + + + + + + + + + 0.5000000000 + 0.5000000000 + + + + + -1.5000000000 + -1.5000000000 + + + + + + 1.000000 + -0.000000 + -0.000000 + 1.000000 + + + 1.000000 + 1.000000 + -0.000000 + 1.000000 + + + -0.000000 + 1.000000 + -0.000000 + 1.000000 + + + -0.000000 + 1.000000 + 1.000000 + 1.000000 + + + -0.000000 + -0.000000 + 1.000000 + 1.000000 + + + 1.000000 + -0.000000 + 1.000000 + 1.000000 + + + 1.000000 + -0.000000 + -0.000000 + 1.000000 + + + + + + + + + + + + + + + + + + + + + + + -0.8615384698 + 0.1025641039 + + + + + -0.1128205135 + -0.6666666865 + + + + + + -0.000000 + -0.000000 + -0.000000 + 1.000000 + + + 0.117420 + 0.117420 + 0.117420 + 1.000000 + + + 0.252708 + 0.252708 + 0.252708 + 1.000000 + + + 0.433233 + 0.433233 + 0.433233 + 1.000000 + + + 0.628843 + 0.628843 + 0.628843 + 1.000000 + + + 1.000000 + 1.000000 + 1.000000 + 1.000000 + + + + + + + + + + + + + + + + + + + + + + + -0.8615384698 + 0.1025641039 + + + + + -0.1128205135 + -0.6666666865 + + + + + + -0.000000 + -0.000000 + 0.000000 + 1.000000 + + + 0.388889 + 0.388889 + 0.388889 + 1.000000 + + + 1.000000 + 1.000000 + 1.000000 + 1.000000 + + + + + + + + + + + + + + + + + + + + + + + -0.000000 + -0.000000 + -0.000000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + -1.2500000000 + -0.7500000000 + + + + + + + + + + + + + + -0.5000000000 + -0.5000000000 + + + + + -0.5000000000 + -0.5000000000 + + + + + + + + + -1.7500000000 + -1.5000000000 + + + + + + + + + + + + + + -0.7500000000 + -0.7500000000 + + + + + 0.2500000000 + -0.2500000000 + + + + + + + + + -1.5000000000 + -1.7500000000 + + + + + + + + + + + + + + 0.2500000000 + -0.2500000000 + + + + + 0.7500000000 + 0.7500000000 + + + + + + + + + -0.7500000000 + -1.2500000000 + + + + + + + + + + + + + + 0.5000000000 + 0.5000000000 + + + + + 0.5000000000 + 0.5000000000 + + + + + + + + + 1.0000000000 + 0.5000000000 + + + + + + + + + + + + + + 0.7500000000 + 0.7500000000 + + + + + -0.5000000000 + 0.5000000000 + + + + + + + + + 0.5000000000 + 1.0000000000 + + + + + + + + + + + + + + -0.5000000000 + 0.5000000000 + + + + + -0.7500000000 + -0.7500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + 0.015396 + 0.015396 + 0.015396 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + 1.7500000000 + 1.7500000000 + + + + + + + + + + + + + + 1.5000000000 + -1.5000000000 + + + + + 1.0000000000 + -1.0000000000 + + + + + + + + + 1.2500000000 + 0.7500000000 + + + + + + + + + + + + + + 0.0000000000 + -0.5000000000 + + + + + 0.0000000000 + -0.5000000000 + + + + + + + + + 1.2500000000 + 0.2500000000 + + + + + + + + + + + + + + -0.5000000000 + -0.5000000000 + + + + + -0.2500000000 + -0.2500000000 + + + + + + + + + 1.0000000000 + 0.0000000000 + + + + + + + + + + + + + + -0.2500000000 + -0.2500000000 + + + + + -0.7500000000 + 0.7500000000 + + + + + + + + + 0.0000000000 + 1.0000000000 + + + + + + + + + + + + + + -0.7500000000 + 0.7500000000 + + + + + 0.2500000000 + 0.2500000000 + + + + + + + + + 0.2500000000 + 1.2500000000 + + + + + + + + + + + + + + 0.2500000000 + 0.2500000000 + + + + + 0.5000000000 + 0.5000000000 + + + + + + + + + 0.7500000000 + 1.2500000000 + + + + + + + + + + + + + + 0.5000000000 + 0.0000000000 + + + + + 0.5000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + + + 1.000000 + 1.000000 + 1.000000 + 0.622449 + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + 1.7500000000 + 1.7500000000 + + + + + + + + + + + + + + 1.5000000000 + -1.5000000000 + + + + + 1.0000000000 + -1.0000000000 + + + + + + + + + 1.2500000000 + 0.7500000000 + + + + + + + + + + + + + + 0.0000000000 + -0.5000000000 + + + + + 0.0000000000 + -0.5000000000 + + + + + + + + + 1.2500000000 + 0.2500000000 + + + + + + + + + + + + + + -0.5000000000 + -0.5000000000 + + + + + -0.2500000000 + -0.2500000000 + + + + + + + + + 1.0000000000 + 0.0000000000 + + + + + + + + + + + + + + -0.2500000000 + -0.2500000000 + + + + + -0.7500000000 + 0.7500000000 + + + + + + + + + 0.0000000000 + 1.0000000000 + + + + + + + + + + + + + + -0.7500000000 + 0.7500000000 + + + + + 0.2500000000 + 0.2500000000 + + + + + + + + + 0.2500000000 + 1.2500000000 + + + + + + + + + + + + + + 0.2500000000 + 0.2500000000 + + + + + 0.5000000000 + 0.5000000000 + + + + + + + + + 0.7500000000 + 1.2500000000 + + + + + + + + + + + + + + 0.5000000000 + 0.0000000000 + + + + + 0.5000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.1000000015 + -0.1000000015 + + + + + 0.1500000060 + 0.1500000060 + + + + + + + + + + diff --git a/synfig-studio/trunk/images/fill_icon.sif b/synfig-studio/trunk/images/fill_icon.sif new file mode 100644 index 0000000..fe415c3 --- /dev/null +++ b/synfig-studio/trunk/images/fill_icon.sif @@ -0,0 +1,3130 @@ + + + Untitled0 + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + -0.7500000000 + -1.0000000000 + + + + + + + + + + + + + + -0.7500000000 + -0.0000000000 + + + + + 0.7538461685 + 1.1230769157 + + + + + + + + + -0.2500000000 + -0.2500000000 + + + + + + + + + + + + + + 0.7384615541 + 1.1230769157 + + + + + 0.7500000000 + 0.7500000000 + + + + + + + + + 1.2500000000 + -0.2500000000 + + + + + + + + + + + + + + -0.7500000000 + -0.7500000000 + + + + + -0.7384615541 + -1.1230769157 + + + + + + + + + 0.7500000000 + -1.0000000000 + + + + + + + + + + + + + + -0.7538461685 + -1.1076923609 + + + + + -0.7500000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + 0.1500000060 + 0.1500000060 + + + + + + + + + + + + + + + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + 1.000000 + 1.000000 + 1.000000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + -0.7500000000 + 0.5000000000 + + + + + + + + + + + + + + -0.0000000000 + 0.7500000000 + + + + + -0.0000000000 + 0.7500000000 + + + + + + + + + 0.7500000000 + 0.4939709008 + + + + + + + + + + + + + + -0.0000000000 + -0.7680873275 + + + + + -0.0000000000 + -0.7680873275 + + + + + + + + + 0.5000000000 + -0.5000000000 + + + + + + + + + + + + + + -0.0192307699 + -0.7488565445 + + + + + -0.0192307699 + -0.7488565445 + + + + + + + + + -0.5000000000 + -0.5000000000 + + + + + + + + + + + + + + -0.0192307699 + 0.7511434555 + + + + + -0.0192307699 + 0.7511434555 + + + + + + + + + + + + + + + + + + + + -0.7500000000 + 0.5000000000 + + + + + 0.7500000000 + 0.5000000000 + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + 0.921951 + 0.921951 + 0.921951 + 1.000000 + + + 1.000000 + 1.000000 + 1.000000 + 1.000000 + + + 0.864472 + 0.864472 + 0.864472 + 1.000000 + + + 0.165981 + 0.165981 + 0.165981 + 1.000000 + + + + + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + -0.7500000000 + 0.5000000000 + + + + + + + + + + + + + + -0.0000000000 + 0.7500000000 + + + + + -0.0000000000 + 0.7500000000 + + + + + + + + + 0.7500000000 + 0.4939709008 + + + + + + + + + + + + + + -0.0000000000 + -0.7680873275 + + + + + -0.0000000000 + -0.7680873275 + + + + + + + + + 0.5000000000 + -0.5000000000 + + + + + + + + + + + + + + -0.0192307699 + -0.7488565445 + + + + + -0.0192307699 + -0.7488565445 + + + + + + + + + -0.5000000000 + -0.5000000000 + + + + + + + + + + + + + + -0.0192307699 + 0.7511434555 + + + + + -0.0192307699 + 0.7511434555 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.0000000000 + 0.0442307703 + + + + + + + + + + + + + + + + + -0.000000 + 0.295220 + 1.000000 + 1.000000 + + + + + 0.0000000000 + -0.1250000000 + + + + + + + + + + + + + + + + + + + + + -0.7500000000 + 0.5000000000 + + + + + + + + + + + + + + -0.0000000000 + 0.7500000000 + + + + + -0.0000000000 + 0.7500000000 + + + + + + + + + 0.7500000000 + 0.4939709008 + + + + + + + + + + + + + + -0.0000000000 + -0.7680873275 + + + + + -0.0000000000 + -0.7680873275 + + + + + + + + + 0.5000000000 + -0.5000000000 + + + + + + + + + + + + + + -0.0192307699 + -0.7488565445 + + + + + -0.0192307699 + -0.7488565445 + + + + + + + + + -0.5000000000 + -0.5000000000 + + + + + + + + + + + + + + -0.0192307699 + 0.7511434555 + + + + + -0.0192307699 + 0.7511434555 + + + + + + + + + + + + + + + + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + 1.000000 + -0.000000 + -0.000000 + 1.000000 + + + 1.000000 + 1.000000 + -0.000000 + 1.000000 + + + -0.000000 + 1.000000 + -0.000000 + 1.000000 + + + -0.000000 + 1.000000 + 1.000000 + 1.000000 + + + -0.000000 + -0.000000 + 1.000000 + 1.000000 + + + 1.000000 + -0.000000 + 1.000000 + 1.000000 + + + 1.000000 + -0.000000 + -0.000000 + 1.000000 + + + + + + 0.0000000000 + 0.3750000000 + + + + + + + + + + + + + + + + 1.0000000000 + 0.4499999881 + + + + + 0.0000000000 + 0.3750000000 + + + + + + + + + + + + + + + + 0.1000000015 + 0.1000000015 + + + + + + + + + + + + + + + + + + + + + + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + 1.000000 + 1.000000 + 1.000000 + 1.000000 + + + + + -0.0000000000 + -0.1442307681 + + + + + + + + + + + + + + + + + + + + + -0.7500000000 + 0.5000000000 + + + + + + + + + + + + + + -0.0000000000 + 0.7500000000 + + + + + -0.0000000000 + 0.7500000000 + + + + + + + + + 0.7500000000 + 0.4939709008 + + + + + + + + + + + + + + -0.0000000000 + -0.7680873275 + + + + + -0.0000000000 + -0.7680873275 + + + + + + + + + 0.5000000000 + -0.5000000000 + + + + + + + + + + + + + + -0.0192307699 + -0.7488565445 + + + + + -0.0192307699 + -0.7488565445 + + + + + + + + + -0.5000000000 + -0.5000000000 + + + + + + + + + + + + + + -0.0192307699 + 0.7511434555 + + + + + -0.0192307699 + 0.7511434555 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.0320512839 + -0.1955128163 + + + + + + + + + + + + + + + + + + + + + -0.7500000000 + 0.5000000000 + + + + + + + + + + + + + + -0.0000000000 + 0.7500000000 + + + + + -0.0000000000 + 0.7500000000 + + + + + + + + + 0.7500000000 + 0.4939709008 + + + + + + + + + + + + + + -0.0000000000 + -0.7680873275 + + + + + -0.0000000000 + -0.7680873275 + + + + + + + + + 0.5000000000 + -0.5000000000 + + + + + + + + + + + + + + -0.0192307699 + -0.7488565445 + + + + + -0.0192307699 + -0.7488565445 + + + + + + + + + -0.5000000000 + -0.5000000000 + + + + + + + + + + + + + + -0.0192307699 + 0.7511434555 + + + + + -0.0192307699 + 0.7511434555 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.0399999991 + 0.0399999991 + + + + + + + + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.0000000000 + -0.1250000000 + + + + + + + + + + + + + + + + + + + + + -0.7500000000 + 0.5000000000 + + + + + + + + + + + + + + -0.0000000000 + 0.7500000000 + + + + + -0.0000000000 + 0.7500000000 + + + + + + + + + 0.7500000000 + 0.4939709008 + + + + + + + + + + + + + + -0.0000000000 + -0.7680873275 + + + + + -0.0000000000 + -0.7680873275 + + + + + + + + + 0.5000000000 + -0.5000000000 + + + + + + + + + + + + + + -0.0192307699 + -0.7488565445 + + + + + -0.0192307699 + -0.7488565445 + + + + + + + + + -0.5000000000 + -0.5000000000 + + + + + + + + + + + + + + -0.0192307699 + 0.7511434555 + + + + + -0.0192307699 + 0.7511434555 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + 1.000000 + 1.000000 + 1.000000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + -0.7500000000 + 0.5000000000 + + + + + + + + + + + + + + -0.0000000000 + 0.7500000000 + + + + + 0.0000000000 + -0.7500000000 + + + + + + + + + 0.7500000000 + 0.5000000000 + + + + + + + + + + + + + + -0.0000000000 + 0.7500000000 + + + + + 0.0000000000 + -0.7500000000 + + + + + + + + + 0.7500000000 + -1.0000000000 + + + + + + + + + + + + + + -0.0000000000 + -0.7500000000 + + + + + 0.0000000000 + -0.7500000000 + + + + + + + + + -0.7500000000 + -1.0000000000 + + + + + + + + + + + + + + -0.0000000000 + 0.7500000000 + + + + + 0.0000000000 + 0.7500000000 + + + + + + + + + + + + + + + + + + + + 0.7500000000 + -0.2500000000 + + + + + -0.7500000000 + -0.2500000000 + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + 0.921951 + 0.921951 + 0.921951 + 1.000000 + + + 1.000000 + 1.000000 + 1.000000 + 1.000000 + + + 0.864472 + 0.864472 + 0.864472 + 1.000000 + + + 0.165981 + 0.165981 + 0.165981 + 1.000000 + + + + + + + + + + + + + + + + + + + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + 1.0000000000 + 1.0000000000 + + + + + -1.0000000000 + -1.0000000000 + + + + + + + 0.000000 + 0.000000 + 0.000000 + 0.000000 + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + + + + + + + + + + + + + + -0.0019615984 + -0.4694150686 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + -0.7500000000 + 0.5000000000 + + + + + + + + + + + + + + -0.0000000000 + 0.7500000000 + + + + + 0.0000000000 + -0.7500000000 + + + + + + + + + 0.7500000000 + 0.5000000000 + + + + + + + + + + + + + + -0.0000000000 + 0.7500000000 + + + + + 0.0000000000 + -0.7500000000 + + + + + + + + + 0.7500000000 + -1.0000000000 + + + + + + + + + + + + + + -0.0000000000 + -0.7500000000 + + + + + 0.0000000000 + -0.7500000000 + + + + + + + + + -0.7500000000 + -1.0000000000 + + + + + + + + + + + + + + -0.0000000000 + 0.7500000000 + + + + + 0.0000000000 + 0.7500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + 1.000000 + 1.000000 + 1.000000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + -0.8000000119 + 0.5000000000 + + + + + + + + + + + + + + 0.0000000000 + 0.1000000015 + + + + + + + 0.0000000000 + 0.9499999881 + + + + + + + + + + + + + + 0.8000000119 + 0.5000000000 + + + + + + + + + + + + + + 0.0000000000 + 0.9499999881 + + + + + 0.0000000000 + -0.1000000015 + + + + + + + + + 0.8000000119 + 0.3750000000 + + + + + + + + + + + + + + 0.0000000000 + -0.1000000015 + + + + + + + 0.0000000000 + 0.9499999881 + + + + + + + + + + + + + + -0.8000000119 + 0.3750000000 + + + + + + + + + + + + + + 0.0000000000 + 0.9499999881 + + + + + 0.0000000000 + 0.1000000015 + + + + + + + + + + + + + + + + + + + + 0.8000000119 + 0.5000000000 + + + + + -0.8000000119 + 0.5000000000 + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + 0.921951 + 0.921951 + 0.921951 + 1.000000 + + + 1.000000 + 1.000000 + 1.000000 + 1.000000 + + + 0.864472 + 0.864472 + 0.864472 + 1.000000 + + + 0.165981 + 0.165981 + 0.165981 + 1.000000 + + + + + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + -0.8000000119 + 0.5000000000 + + + + + + + + + + + + + + 0.0000000000 + 0.1000000015 + + + + + + + 0.0000000000 + 0.9499999881 + + + + + + + + + + + + + + 0.8000000119 + 0.5000000000 + + + + + + + + + + + + + + 0.0000000000 + 0.9499999881 + + + + + 0.0000000000 + -0.1000000015 + + + + + + + + + 0.8000000119 + 0.3750000000 + + + + + + + + + + + + + + 0.0000000000 + -0.1000000015 + + + + + + + 0.0000000000 + 0.9499999881 + + + + + + + + + + + + + + -0.8000000119 + 0.3750000000 + + + + + + + + + + + + + + 0.0000000000 + 0.9499999881 + + + + + 0.0000000000 + 0.1000000015 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + 1.000000 + 1.000000 + 1.000000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + -0.8000000119 + 0.5000000000 + + + + + + + + + + + + + + 0.0000000000 + 0.9499999881 + + + + + 0.0615384616 + 0.9076923132 + + + + + + + + + 0.8000000119 + 0.5000000000 + + + + + + + + + + + + + + + + 0.0000000000 + 0.9499999881 + + + + + + + + + + -0.0205128212 + -0.8717948794 + + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + + + + + + + -0.5000000000 + 0.7500000000 + + + + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + -0.8000000119 + 0.5000000000 + + + + + + + + + + + + + + 0.0000000000 + 0.9499999881 + + + + + 0.0615384616 + 0.9076923132 + + + + + + + + + 0.8000000119 + 0.5000000000 + + + + + + + + + + + + + + + + 0.0000000000 + 0.9499999881 + + + + + + + + + + -0.0205128212 + -0.8717948794 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 1.000000 + 1.000000 + 1.000000 + 0.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + -0.7500000000 + 0.5000000000 + + + + + + + + + + + + + + 0.0000000000 + 0.7500000000 + + + + + 0.0000000000 + 0.7500000000 + + + + + + + + + 0.7500000000 + 0.5000000000 + + + + + + + + + + + + + + -0.0000000000 + -0.7500000000 + + + + + -0.0000000000 + -0.7500000000 + + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + -0.7500000000 + 0.5000000000 + + + + + + + + + + + + + + 0.0000000000 + 0.7500000000 + + + + + 0.0000000000 + 0.7500000000 + + + + + + + + + 0.7500000000 + 0.5000000000 + + + + + + + + + + + + + + -0.0000000000 + -0.7500000000 + + + + + -0.0000000000 + -0.7500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + FILL + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + Sans Serif + + + + + + + + + + + + + + + + 0.3546048403 + 0.3546048403 + + + + + 0.5000000000 + 0.5000000000 + + + + + 0.0000000000 + -0.2500000000 + + + + + + + + + + + + + -0.2412532866 + 0.2151449770 + + + + + + + + + + 0.0000000000 + 0.0000000000 + + + + diff --git a/synfig-studio/trunk/images/gradient_icon.sif b/synfig-studio/trunk/images/gradient_icon.sif new file mode 100644 index 0000000..165409c --- /dev/null +++ b/synfig-studio/trunk/images/gradient_icon.sif @@ -0,0 +1,182 @@ + + + Untitled0 + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + -0.6999999881 + 0.6999999881 + + + + + -0.6999999881 + -0.6999999881 + + + + + 0.6999999881 + -0.6999999881 + + + + + 0.6999999881 + 0.6999999881 + + + + + + + + + + + + + + + + + + 0.6999999881 + 0.6999999881 + + + + + -0.6999999881 + -0.6999999881 + + + + + + 1.000000 + -0.000000 + -0.000000 + 1.000000 + + + -0.000000 + -0.000000 + 1.000000 + 1.000000 + + + + + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + -0.8000000119 + 0.8000000119 + + + -0.8000000119 + -0.8000000119 + + + 0.8000000119 + -0.8000000119 + + + 0.8000000119 + 0.8000000119 + + + + + + + + + + + 0.0000000000 + 0.0000000000 + + + + diff --git a/synfig-studio/trunk/images/group_icon.sif b/synfig-studio/trunk/images/group_icon.sif new file mode 100644 index 0000000..f84e075 --- /dev/null +++ b/synfig-studio/trunk/images/group_icon.sif @@ -0,0 +1,2065 @@ + + + Untitled0 + + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.1000000015 + -0.1000000015 + + + + + + + + + + + + + + + + + + + -0.8000000119 + 0.8000000119 + + + + + -0.8000000119 + -0.2000000030 + + + + + 0.2000000030 + -0.2000000030 + + + + + 0.2000000030 + 0.8000000119 + + + + + + + + + + + + + + + + + + 0.2000000030 + 0.2000000030 + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + -0.8000000119 + 0.8000000119 + + + + + -0.8000000119 + -0.2000000030 + + + + + 0.2000000030 + -0.2000000030 + + + + + 0.2000000030 + 0.8000000119 + + + + + + + + + + + + + + + + + + 1.000000 + 0.900000 + 0.600000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + -0.6999999881 + 0.6999999881 + + + + + -0.6999999881 + -0.1000000015 + + + + + 0.1000000015 + -0.1000000015 + + + + + 0.1000000015 + 0.6999999881 + + + + + + + + + + + + + + + + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + 0.000000 + 1.000000 + 0.250000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + -0.2500000000 + 0.6217948794 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.7500000000 + 0.6217948794 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.7500000000 + -0.3782051206 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -0.2500000000 + -0.3782051206 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + -0.2500000000 + 0.6217948794 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.7500000000 + 0.6217948794 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.7500000000 + -0.3782051206 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -0.2500000000 + -0.3782051206 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + 0.000000 + 1.000000 + 0.250000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + -0.2500000000 + 0.6217948794 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -0.7500000000 + 0.2500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -0.7500000000 + -0.7500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -0.2500000000 + -0.3782051206 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + -0.2500000000 + 0.6217948794 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -0.7500000000 + 0.2500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -0.7500000000 + -0.7500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -0.2500000000 + -0.3782051206 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + + + + + + + 0.3589743674 + -0.1217948720 + + + + + + + + + + + + + + + + + + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + 0.000000 + 1.000000 + 0.250000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + 0.7500000000 + 0.6217948794 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.2500000000 + 0.2500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.2500000000 + -0.7500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.7500000000 + -0.3782051206 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + 0.7500000000 + 0.6217948794 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.2500000000 + 0.2500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.2500000000 + -0.7500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.7500000000 + -0.3782051206 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + + + + + + + + + + + + + + + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + 0.000000 + 1.000000 + 0.250000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + -0.7500000000 + 0.2500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.2500000000 + 0.2500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.2500000000 + -0.7500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -0.7500000000 + -0.7500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + -0.7500000000 + 0.2500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.2500000000 + 0.2500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.2500000000 + -0.7500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -0.7500000000 + -0.7500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + + + + + + + -0.7500000000 + 0.2500000000 + + + + + + + + + + + + + + + + + diff --git a/synfig-studio/trunk/images/info_icon.sif b/synfig-studio/trunk/images/info_icon.sif new file mode 100644 index 0000000..c736939 --- /dev/null +++ b/synfig-studio/trunk/images/info_icon.sif @@ -0,0 +1,106 @@ + + + Untitled0 + + + + + + + + + + + + + + + + + 0.000000 + 0.265778 + 0.265778 + 1.000000 + + + + + + + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + i + + + + 1.000000 + 1.000000 + 1.000000 + 1.000000 + + + + Times + + + + + + + + + + + + + + + + 2.2500000000 + 2.2500000000 + + + + + 0.5000000000 + 0.5000000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + diff --git a/synfig-studio/trunk/images/integer_icon.sif b/synfig-studio/trunk/images/integer_icon.sif new file mode 100644 index 0000000..48fe158 --- /dev/null +++ b/synfig-studio/trunk/images/integer_icon.sif @@ -0,0 +1,66 @@ + + + Untitled0 + + + + + + + + + + + + 123 +456 + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + Sans Serif + + + + + + + + + + + + + + + + 1.2656250000 + 1.2968750000 + + + + + 0.5000000000 + 0.5000000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + diff --git a/synfig-studio/trunk/images/keyframe_icon.sif b/synfig-studio/trunk/images/keyframe_icon.sif new file mode 100644 index 0000000..5d657ca --- /dev/null +++ b/synfig-studio/trunk/images/keyframe_icon.sif @@ -0,0 +1,331 @@ + + + Untitled0 + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + -1.0000000000 + 0.2500000000 + + + + + 1.7500000000 + 0.2500000000 + + + + + 1.7500000000 + -0.7500000000 + + + + + 1.5000000000 + -0.7500000000 + + + + + 1.5000000000 + 0.0000000000 + + + + + 1.2500000000 + 0.0000000000 + + + + + 1.2500000000 + -0.2500000000 + + + + + 1.0000000000 + -0.2500000000 + + + + + 1.0000000000 + 0.0000000000 + + + + + 0.7500000000 + 0.0000000000 + + + + + 0.7500000000 + -0.5000000000 + + + + + 0.5000000000 + -0.5000000000 + + + + + 0.5000000000 + 0.0000000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + -0.2500000000 + -0.5000000000 + + + + + -1.0000000000 + -0.5000000000 + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + + + + + + + -1.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 0.000000 + + + + + + + + + + + -1.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + + 0.377273 + 0.210909 + 0.054545 + 1.000000 + + + + + + + + + + + + + + + + + + + 1.000000 + 1.000000 + 1.000000 + 1.000000 + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.0937500000 + -0.0937500000 + + + + + 0.1250000000 + 0.1250000000 + + + + + + + + + + + + + 0.0000000000 + 0.0000000000 + + + + + + + diff --git a/synfig-studio/trunk/images/keyframe_lock_icon.sif b/synfig-studio/trunk/images/keyframe_lock_icon.sif new file mode 100644 index 0000000..bd8f202 --- /dev/null +++ b/synfig-studio/trunk/images/keyframe_lock_icon.sif @@ -0,0 +1,2407 @@ + + + Keyframe Lock Button + + + + + + + + + + + + + + + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + + + + + + + + + + 0.7500000000 + 0.7500000000 + + + + + 0.7500000000 + -1.5000000000 + + + + + 2.0000000000 + -1.5000000000 + + + + + 2.0000000000 + 0.7500000000 + + + + + + + + + + + + + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + -2.0000000000 + 2.0000000000 + + + + + 0.0000000000 + -2.0000000000 + + + + + + + + + + + + + + + + + + + + -2.0000000000 + 0.7500000000 + + + + + -2.0000000000 + -1.2500000000 + + + + + -0.7500000000 + -1.2500000000 + + + + + -0.7500000000 + 0.7500000000 + + + + + + + + + + + + + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.0000000000 + 2.0000000000 + + + + + 2.0000000000 + -2.0000000000 + + + + + + + + + + + + + + + + + + + + + + + + 0.0000000000 + -0.5000000000 + + + + + + + + + + + + + + + + + 0.493452 + 0.491552 + 0.491552 + 1.000000 + + + + + -0.7500000000 + 0.7500000000 + + + + + 0.7500000000 + -0.7500000000 + + + + + + + + + + + + + + + + + + + + + + -0.7500000000 + 0.0000000000 + + + + + 0.7500000000 + 0.0000000000 + + + + + + 1.000000 + 1.000000 + 1.000000 + 1.000000 + + + 0.505263 + 0.505263 + 0.505263 + 1.000000 + + + 0.485435 + 0.484084 + 0.485435 + 1.000000 + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + -0.7500000000 + 0.7500000000 + + + + + 0.7500000000 + -0.7500000000 + + + + + + + + + + + + + + + + + + + + + + 0.0000000000 + 0.0900000036 + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + 0.0000000000 + 0.2500000000 + + + + + -0.2151769996 + -0.6455309987 + + + + + 0.2151769996 + -0.6455309987 + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + + + + + + + 0.0000000000 + 0.2500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + 0.280608 + 0.280608 + 0.280608 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + -0.0000000000 + 1.6250000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.6250000000 + 0.7500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.3750000000 + 0.7500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -0.0000000000 + 1.3750000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -0.3750000000 + 0.7500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -0.6250000000 + 0.7500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 1.000000 + 1.000000 + 1.000000 + 1.000000 + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + -0.0000000000 + 1.6250000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.6250000000 + 0.7500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.3750000000 + 0.7500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -0.0000000000 + 1.3750000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -0.3750000000 + 0.7500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -0.6250000000 + 0.7500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.1000000015 + -0.1000000015 + + + + + 0.2000000030 + 0.2000000030 + + + + + + + + + + + + + + + + + + + + + + 0.0000000000 + -0.5000000000 + + + + + + + + + + + + + + + + + 0.2500000000 + 0.0000000000 + + + + + + + + + + + + + + + + + 1.000000 + 1.000000 + 0.000000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + -1.7500000000 + 0.0000000000 + + + + + + + + + + + + + + -0.7500000000 + 0.7500000000 + + + + + 0.7500000000 + 0.7500000000 + + + + + + + + + -1.0000000000 + 0.7500000000 + + + + + + + + + + + + + + 0.7500000000 + 0.7500000000 + + + + + 0.0000000000 + -0.7500000000 + + + + + + + + + -1.0000000000 + 0.2500000000 + + + + + + + + + + + + + + 0.0192307699 + -0.6346153617 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + -0.5000000000 + 0.2500000000 + + + + + + + + + + + + + + -0.0000000000 + -0.0000000000 + + + + + 0.0000000000 + -0.7500000000 + + + + + + + + + -0.5000000000 + -0.2500000000 + + + + + + + + + + + + + + -0.0000000000 + -0.7500000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + -1.0000000000 + -0.2500000000 + + + + + + + + + + + + + + -0.0000000000 + -0.0000000000 + + + + + 0.0000000000 + -0.7500000000 + + + + + + + + + -1.0000000000 + -0.7500000000 + + + + + + + + + + + + + + -0.0000000000 + -0.7500000000 + + + + + -0.7500000000 + 0.7500000000 + + + + + + + + + + + + + + + + + + + + 0.352394 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + -1.7500000000 + 0.0000000000 + + + + + + + + + + + + + + -0.7500000000 + 0.7500000000 + + + + + 0.7500000000 + 0.7500000000 + + + + + + + + + -1.0000000000 + 0.7500000000 + + + + + + + + + + + + + + 0.7500000000 + 0.7500000000 + + + + + 0.0000000000 + -0.7500000000 + + + + + + + + + -1.0000000000 + 0.2500000000 + + + + + + + + + + + + + + 0.0192307699 + -0.6346153617 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + -0.5000000000 + 0.2500000000 + + + + + + + + + + + + + + -0.0000000000 + -0.0000000000 + + + + + 0.0000000000 + -0.7500000000 + + + + + + + + + -0.5000000000 + -0.2500000000 + + + + + + + + + + + + + + -0.0000000000 + -0.7500000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + -1.0000000000 + -0.2500000000 + + + + + + + + + + + + + + -0.0000000000 + -0.0000000000 + + + + + 0.0000000000 + -0.7500000000 + + + + + + + + + -1.0000000000 + -0.7500000000 + + + + + + + + + + + + + + -0.0000000000 + -0.7500000000 + + + + + -0.7500000000 + 0.7500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -0.2500000000 + 0.0000000000 + + + + + + + + + + + + + + + + + 1.000000 + 1.000000 + 0.000000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + 1.7500000000 + 0.0000000000 + + + + + + + + + + + + + + 0.7500000000 + -0.7500000000 + + + + + -0.7500000000 + -0.7500000000 + + + + + + + + + 1.0000000000 + -0.7500000000 + + + + + + + + + + + + + + -0.7500000000 + -0.7500000000 + + + + + 0.0000000000 + 0.7500000000 + + + + + + + + + 1.0000000000 + -0.2500000000 + + + + + + + + + + + + + + -0.0000000000 + 0.7500000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + 0.5000000000 + -0.2500000000 + + + + + + + + + + + + + + -0.0000000000 + -0.0000000000 + + + + + 0.0000000000 + 0.7500000000 + + + + + + + + + 0.5000000000 + 0.2500000000 + + + + + + + + + + + + + + -0.0000000000 + 0.7500000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + 1.0000000000 + 0.2500000000 + + + + + + + + + + + + + + -0.0000000000 + -0.0000000000 + + + + + 0.0000000000 + 0.7500000000 + + + + + + + + + 1.0000000000 + 0.7500000000 + + + + + + + + + + + + + + -0.0000000000 + 0.7500000000 + + + + + 0.7500000000 + -0.7500000000 + + + + + + + + + + + + + + + + + + + + 0.352394 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + 1.7500000000 + 0.0000000000 + + + + + + + + + + + + + + 0.7500000000 + -0.7500000000 + + + + + -0.7500000000 + -0.7500000000 + + + + + + + + + 1.0000000000 + -0.7500000000 + + + + + + + + + + + + + + -0.7500000000 + -0.7500000000 + + + + + 0.0000000000 + 0.7500000000 + + + + + + + + + 1.0000000000 + -0.2500000000 + + + + + + + + + + + + + + -0.0000000000 + 0.7500000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + 0.5000000000 + -0.2500000000 + + + + + + + + + + + + + + -0.0000000000 + -0.0000000000 + + + + + 0.0000000000 + 0.7500000000 + + + + + + + + + 0.5000000000 + 0.2500000000 + + + + + + + + + + + + + + -0.0000000000 + 0.7500000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + 1.0000000000 + 0.2500000000 + + + + + + + + + + + + + + -0.0000000000 + -0.0000000000 + + + + + 0.0000000000 + 0.7500000000 + + + + + + + + + 1.0000000000 + 0.7500000000 + + + + + + + + + + + + + + -0.0000000000 + 0.7500000000 + + + + + 0.7500000000 + -0.7500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.1000000015 + -0.1000000015 + + + + + 0.2000000030 + 0.2000000030 + + + + + + + + + + + + + + + + + + + + 0.0000000000 + -0.2500000000 + + + + diff --git a/synfig-studio/trunk/images/layer_icon.sif b/synfig-studio/trunk/images/layer_icon.sif new file mode 100644 index 0000000..395e88c --- /dev/null +++ b/synfig-studio/trunk/images/layer_icon.sif @@ -0,0 +1,332 @@ + + + Untitled0 + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.1000000015 + -0.1000000015 + + + + + + + + + + + + + + + + + + + -0.8000000119 + 0.8000000119 + + + + + -0.8000000119 + -0.2000000030 + + + + + 0.2000000030 + -0.2000000030 + + + + + 0.2000000030 + 0.8000000119 + + + + + + + + + + + + + + + + + + 0.2000000030 + 0.2000000030 + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + -0.8000000119 + 0.8000000119 + + + + + -0.8000000119 + -0.2000000030 + + + + + 0.2000000030 + -0.2000000030 + + + + + 0.2000000030 + 0.8000000119 + + + + + + + + + + + + + + + + + + 1.000000 + 0.900000 + 0.600000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + -0.6999999881 + 0.6999999881 + + + + + -0.6999999881 + -0.1000000015 + + + + + 0.1000000015 + -0.1000000015 + + + + + 0.1000000015 + 0.6999999881 + + + + + + + + + + + + + + + + + + + + 0.5000000000 + -0.5000000000 + + + + + + + + + + + + + + + + + + + + + 0.2000000030 + -0.2000000030 + + + + + + + + + + + + + + + + + + + + + -0.1000000015 + 0.1000000015 + + + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + + + + + + + -0.6999999881 + 0.6999999881 + + + + + + + + + + diff --git a/synfig-studio/trunk/images/list_icon.sif b/synfig-studio/trunk/images/list_icon.sif new file mode 100644 index 0000000..07c99dc --- /dev/null +++ b/synfig-studio/trunk/images/list_icon.sif @@ -0,0 +1,65 @@ + + + Untitled0 + + + + + + + + + + + + LIST + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + Sans Serif + + + + + + + + + + + + + + + + 0.9375000000 + 1.0781250000 + + + + + 0.5000000000 + 0.5000000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + diff --git a/synfig-studio/trunk/images/logo.sif b/synfig-studio/trunk/images/logo.sif new file mode 100644 index 0000000..a83e78b --- /dev/null +++ b/synfig-studio/trunk/images/logo.sif @@ -0,0 +1,3062 @@ + + + Voria Logo + + + WhiteBG + + + + + + + + + + + + + 0.0000000000 + 0.0273553673 + + + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.0495141000 + -0.0378637239 + + + + + 0.1417397559 + 0.1417397559 + + + + + + + + + + + + + + + + + + + + + + 1.000000 + 1.000000 + 1.000000 + 1.000000 + + + + + + + + + + + + + + + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + 0.000000 + 0.333333 + 1.000000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + 0.0000000000 + 1.2500000000 + + + + + + + + + + + + + + -2.2500000000 + 2.2500000000 + + + + + -2.2500000000 + -2.2500000000 + + + + + + + + + -1.0000000000 + -1.0000000000 + + + + + + + + + + + + + + -0.2500000000 + -2.2500000000 + + + + + 1.5000000000 + 0.0000000000 + + + + + + + + + 0.0000000000 + -1.5000000000 + + + + + + + + + + + + + + 0.7500000000 + -0.7500000000 + + + + + 0.7500000000 + 0.7500000000 + + + + + + + + + 1.0000000000 + -1.0000000000 + + + + + + + + + + + + + + 1.5000000000 + 0.0000000000 + + + + + -0.2500000000 + 2.2500000000 + + + + + + + + + + + + + + + + + + + + 1.000000 + 1.000000 + 1.000000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + 0.0000000000 + 1.2500000000 + + + + + + + + + + + + + + -2.2500000000 + 2.2500000000 + + + + + -2.2500000000 + -2.2500000000 + + + + + + + + + -1.0000000000 + -1.0000000000 + + + + + + + + + + + + + + -0.2500000000 + -2.2500000000 + + + + + 1.5000000000 + 0.0000000000 + + + + + + + + + 0.0000000000 + -1.5000000000 + + + + + + + + + + + + + + 0.7500000000 + -0.7500000000 + + + + + 0.7500000000 + 0.7500000000 + + + + + + + + + 1.0000000000 + -1.0000000000 + + + + + + + + + + + + + + 1.5000000000 + 0.0000000000 + + + + + -0.2500000000 + 2.2500000000 + + + + + + + + + + + + + + + + + + + + 1.000000 + 1.000000 + 1.000000 + 1.000000 + + + + + 0.0000000000 + -1.3750000000 + + + + + 0.7500000000 + 0.7500000000 + + + + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + 1.3999999762 + 1.3999999762 + + + + + + + + + + + + + + + + + + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + + + + + + + 0.0000000000 + -0.5000000000 + + + + + + + + + + + + + + + + + + + + + + + + -0.000000 + -0.000000 + -0.000000 + -0.000000 + + + + + -0.000000 + -0.000000 + -0.000000 + 1.000000 + + + + + + + + + + 0.0000000000 + -0.5000000000 + + + + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.0000000000 + -0.5000000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + 0.0000000000 + 1.2500000000 + + + + + + + + + + + + + + -2.2500000000 + 2.2500000000 + + + + + -2.2500000000 + -2.2500000000 + + + + + + + + + -1.0000000000 + -1.0000000000 + + + + + + + + + + + + + + -0.2500000000 + -2.2500000000 + + + + + 1.5000000000 + 0.0000000000 + + + + + + + + + 0.0000000000 + -1.5000000000 + + + + + + + + + + + + + + 0.7500000000 + -0.7500000000 + + + + + 0.7500000000 + 0.7500000000 + + + + + + + + + 1.0000000000 + -1.0000000000 + + + + + + + + + + + + + + 1.5000000000 + 0.0000000000 + + + + + -0.2500000000 + 2.2500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + -0.7500000000 + 0.0000000000 + + + + + + + + + + + + + + 0.7500000000 + -0.2500000000 + + + + + 1.0000000000 + 1.0000000000 + + + + + + + + + 0.0000000000 + -0.5000000000 + + + + + + + + + + + + + + 0.5000000000 + -0.5000000000 + + + + + 0.7300000191 + -0.2599999905 + + + + + + + + + 0.5000000000 + -1.1250000000 + + + + + + + + + + + + + + 0.3750000000 + -0.6250000000 + + + + + 0.4900000095 + -0.6999999881 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + 0.7500000000 + 0.0000000000 + + + + + + + + + + + + + + -0.7500000000 + -0.2500000000 + + + + + 1.0000000000 + 1.0000000000 + + + + + + + + + 0.0000000000 + -0.5000000000 + + + + + + + + + + + + + + -0.5000000000 + -0.5000000000 + + + + + -0.8012820482 + -0.5311999917 + + + + + + + + + -0.5000000000 + -1.1250000000 + + + + + + + + + + + + + + -0.3750000000 + -0.6250000000 + + + + + -0.5833333135 + -0.3968000114 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + -0.8846153617 + -0.4679712355 + + + + + + + + + + + + + + 0.3538461626 + -0.0614596680 + + + + + 1.0000000000 + 1.0000000000 + + + + + + + + + -0.5615384579 + -0.5704039931 + + + + + + + + + + + + + + 0.2500000000 + -0.1250000000 + + + + + 0.3076923192 + -0.1280000061 + + + + + + + + + -0.2794871926 + -0.7752695680 + + + + + + + + + + + + + + 0.2615384758 + -0.2612035871 + + + + + 0.1923076957 + -0.1536000073 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + -0.3871794939 + -0.2170109153 + + + + + + + + + + + + + + -0.1846153885 + -0.2612035871 + + + + + 1.0000000000 + 1.0000000000 + + + + + + + + + -0.5615384579 + -0.5704039931 + + + + + + + + + + + + + + -0.1538461596 + -0.3533930779 + + + + + 0.3076923192 + -0.1280000061 + + + + + + + + + -0.6999999881 + -0.9955000281 + + + + + + + + + + + + + + -0.0769230798 + -0.3687579930 + + + + + 0.1923076957 + -0.1536000073 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + 0.8846153617 + -0.4679712355 + + + + + + + + + + + + + + -0.3538461626 + -0.0614596680 + + + + + 1.0000000000 + 1.0000000000 + + + + + + + + + 0.5615384579 + -0.5704039931 + + + + + + + + + + + + + + -0.2500000000 + -0.1250000000 + + + + + 0.3076923192 + -0.1280000061 + + + + + + + + + 0.2794871926 + -0.7752695680 + + + + + + + + + + + + + + -0.2615384758 + -0.2612035871 + + + + + 0.1923076957 + -0.1536000073 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + 0.3871794939 + -0.2170109153 + + + + + + + + + + + + + + 0.1846153885 + -0.2612035871 + + + + + 1.0000000000 + 1.0000000000 + + + + + + + + + 0.5615384579 + -0.5704039931 + + + + + + + + + + + + + + 0.1538461596 + -0.3533930779 + + + + + 0.3076923192 + -0.1280000061 + + + + + + + + + 0.6999999881 + -0.9955000281 + + + + + + + + + + + + + + 0.0769230798 + -0.3687579930 + + + + + 0.1923076957 + -0.1536000073 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + 0.4713114798 + 0.6239523292 + + + + + + + + + + + + + + -0.5000000000 + -0.1875000000 + + + + + 1.0000000000 + 1.0000000000 + + + + + + + + + 0.0000000000 + 0.3125000000 + + + + + + + + + + + + + + -0.3750000000 + -0.3750000000 + + + + + 0.3076923192 + -0.1280000061 + + + + + + + + + -0.3639999926 + -0.1780321598 + + + + + + + + + + + + + + -0.1875000000 + -0.5000000000 + + + + + 0.1923076957 + -0.1536000073 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + -0.4713114798 + 0.6239523292 + + + + + + + + + + + + + + 0.5000000000 + -0.1875000000 + + + + + 1.0000000000 + 1.0000000000 + + + + + + + + + 0.0000000000 + 0.3125000000 + + + + + + + + + + + + + + 0.3750000000 + -0.3750000000 + + + + + 0.3076923192 + -0.1280000061 + + + + + + + + + 0.3639999926 + -0.1780321598 + + + + + + + + + + + + + + 0.1875000000 + -0.5000000000 + + + + + 0.1923076957 + -0.1536000073 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + -0.2500000000 + -0.8125000000 + + + + + + + + + + + + + + 0.2500000000 + -0.1250000000 + + + + + 1.0000000000 + 1.0000000000 + + + + + + + + + 0.0000000000 + -1.0000000000 + + + + + + + + + + + + + + 0.1875000000 + -0.1875000000 + + + + + 0.3076923192 + -0.1280000061 + + + + + + + + + 0.2019230723 + -1.2694432735 + + + + + + + + + + + + + + 0.1888111830 + -0.3540983498 + + + + + 0.1923076957 + -0.1536000073 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + 0.2500000000 + -0.8125000000 + + + + + + + + + + + + + + -0.2500000000 + -0.1250000000 + + + + + 1.0000000000 + 1.0000000000 + + + + + + + + + 0.0000000000 + -1.0000000000 + + + + + + + + + + + + + + -0.1875000000 + -0.1875000000 + + + + + 0.3076923192 + -0.1280000061 + + + + + + + + + -0.2045454532 + -1.2720662355 + + + + + + + + + + + + + + -0.1730769277 + -0.3304918110 + + + + + 0.1923076957 + -0.1536000073 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + 1.000000 + 1.000000 + 1.000000 + 1.000000 + + + + + + 0.0000000000 + 0.3750000000 + + + + + + + + + + + + + + + + + + + + + + + + + 0.0000000000 + 0.3750000000 + + + + + 0.0000000000 + 1.0000000000 + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + 1.000000 + 1.000000 + 1.000000 + 1.000000 + + + + + + + + + + + + + + + + + + + + + + + 1.000000 + 1.000000 + 1.000000 + 0.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + -0.0000000150 + 1.0000000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -0.5000000000 + 0.5000000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.0000000000 + 0.2500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.5000000000 + 0.5000000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.0000000000 + 0.1250000000 + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.0500000007 + -0.0500000007 + + + + + 0.1000000015 + 0.1000000015 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 1.000000 + 1.000000 + 1.000000 + 1.000000 + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + diff --git a/synfig-studio/trunk/images/meta_data_icon.sif b/synfig-studio/trunk/images/meta_data_icon.sif new file mode 100644 index 0000000..dc77e29 --- /dev/null +++ b/synfig-studio/trunk/images/meta_data_icon.sif @@ -0,0 +1,80 @@ + + + Untitled0 + + + + + + + + + + + + + + + + META + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + Arial Black + + + + + + + + + + + + + + + + 0.7919595838 + 0.7919595838 + + + + + 0.5000000000 + 0.5000000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + 0.0000000000 + 0.0000000000 + + + + + + + diff --git a/synfig-studio/trunk/images/mirror_icon.sif b/synfig-studio/trunk/images/mirror_icon.sif new file mode 100644 index 0000000..66dc615 --- /dev/null +++ b/synfig-studio/trunk/images/mirror_icon.sif @@ -0,0 +1,202 @@ + + + Untitled0 + + + + + + + + + + + + + 0.156182 + 0.216089 + 0.621507 + 1.000000 + + + + + + + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + + + + + 1.000000 + 1.000000 + 1.000000 + 1.000000 + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + MIRROR + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + Sans Serif + + + + + + + + + + + + + + + + 0.6536458135 + 0.7733984590 + + + + + 0.5000000000 + 0.5000000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/synfig-studio/trunk/images/navigator_icon.sif b/synfig-studio/trunk/images/navigator_icon.sif new file mode 100644 index 0000000..f09c758 --- /dev/null +++ b/synfig-studio/trunk/images/navigator_icon.sif @@ -0,0 +1,451 @@ + + + Untitled0 + + + + + + + + + + + + + + + + + 0.000000 + 0.411657 + 1.000000 + 1.000000 + + + + + + + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + 0.068166 + 0.086724 + 0.444444 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + 0.0000000000 + 1.7500000000 + + + + + -0.5000000000 + 1.0000000000 + + + + + 0.5000000000 + 1.0000000000 + + + + + + + + + + + + + + + + + + 0.068166 + 0.086724 + 0.444444 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + 1.7500000000 + 0.0000000000 + + + + + 1.0000000000 + 0.5000000000 + + + + + 1.0000000000 + -0.5000000000 + + + + + + + + + + + + + + + + + + 0.068166 + 0.086724 + 0.444444 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + 0.0000000000 + -1.7500000000 + + + + + 0.5000000000 + -1.0000000000 + + + + + -0.5000000000 + -1.0000000000 + + + + + + + + + + + + + + + + + + 0.068166 + 0.086724 + 0.444444 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + -1.7500000000 + 0.0000000000 + + + + + -1.0000000000 + -0.5000000000 + + + + + -1.0000000000 + 0.5000000000 + + + + + + + + + + + + + + + + + + + + + 1.000000 + 1.000000 + 1.000000 + 1.000000 + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + NAV + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + Sans Serif + + + + + + + + + + + + + + + + 0.5000000000 + 0.7500000000 + + + + + 0.5000000000 + 0.5000000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + 0.1562500000 + 0.1562500000 + + + + + + + + + + diff --git a/synfig-studio/trunk/images/normal_icon.sif b/synfig-studio/trunk/images/normal_icon.sif new file mode 100644 index 0000000..8934fb8 --- /dev/null +++ b/synfig-studio/trunk/images/normal_icon.sif @@ -0,0 +1,310 @@ + + + Untitled0 + + + + + + + + + + + + + -0.000000 + 0.147464 + 0.764577 + 1.000000 + + + + + + + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + + + + + 1.000000 + 1.000000 + 1.000000 + 1.000000 + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + 4.594794 + 4.594794 + 4.594794 + 1.000000 + + + + + 0.1005025133 + -0.0201005023 + + + + + + + + + + + + + + + + + + + 0.4000000060 + 0.4000000060 + + + + + -0.8000000119 + 1.6000000238 + + + + + -0.8000000119 + -0.2000000030 + + + + + -0.4000000060 + 0.0000000000 + + + + + 0.4000000060 + -1.6000000238 + + + + + 0.8000000119 + -1.3999999762 + + + + + -0.0000000000 + 0.2000000030 + + + + + + + + + + + + + + + + + + 0.2500000000 + 0.2500000000 + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.1005025133 + -0.0201005023 + + + + + + + + + + + + + + + + + + + 0.4000000060 + 0.4000000060 + + + + + -0.8000000119 + 1.6000000238 + + + + + -0.8000000119 + -0.2000000030 + + + + + -0.4000000060 + 0.0000000000 + + + + + 0.4000000060 + -1.6000000238 + + + + + 0.8000000119 + -1.3999999762 + + + + + -0.0000000000 + 0.2000000030 + + + + + + + + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + diff --git a/synfig-studio/trunk/images/pastecanvas_icon.sif b/synfig-studio/trunk/images/pastecanvas_icon.sif new file mode 100644 index 0000000..58e809e --- /dev/null +++ b/synfig-studio/trunk/images/pastecanvas_icon.sif @@ -0,0 +1,2065 @@ + + + Untitled0 + + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.1000000015 + -0.1000000015 + + + + + + + + + + + + + + + + + + + -0.8000000119 + 0.8000000119 + + + + + -0.8000000119 + -0.2000000030 + + + + + 0.2000000030 + -0.2000000030 + + + + + 0.2000000030 + 0.8000000119 + + + + + + + + + + + + + + + + + + 0.2000000030 + 0.2000000030 + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + -0.8000000119 + 0.8000000119 + + + + + -0.8000000119 + -0.2000000030 + + + + + 0.2000000030 + -0.2000000030 + + + + + 0.2000000030 + 0.8000000119 + + + + + + + + + + + + + + + + + + 1.000000 + 0.900000 + 0.600000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + -0.6999999881 + 0.6999999881 + + + + + -0.6999999881 + -0.1000000015 + + + + + 0.1000000015 + -0.1000000015 + + + + + 0.1000000015 + 0.6999999881 + + + + + + + + + + + + + + + + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + 0.850000 + 0.640000 + 0.200000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + -0.2500000000 + 0.6217948794 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.7500000000 + 0.6217948794 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.7500000000 + -0.3782051206 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -0.2500000000 + -0.3782051206 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + -0.2500000000 + 0.6217948794 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.7500000000 + 0.6217948794 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.7500000000 + -0.3782051206 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -0.2500000000 + -0.3782051206 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + 0.850000 + 0.640000 + 0.200000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + -0.2500000000 + 0.6217948794 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -0.7500000000 + 0.2500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -0.7500000000 + -0.7500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -0.2500000000 + -0.3782051206 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + -0.2500000000 + 0.6217948794 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -0.7500000000 + 0.2500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -0.7500000000 + -0.7500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -0.2500000000 + -0.3782051206 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + + + + + + + 0.3589743674 + -0.1217948720 + + + + + + + + + + + + + + + + + + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + 0.850000 + 0.640000 + 0.200000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + 0.7500000000 + 0.6217948794 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.2500000000 + 0.2500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.2500000000 + -0.7500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.7500000000 + -0.3782051206 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + 0.7500000000 + 0.6217948794 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.2500000000 + 0.2500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.2500000000 + -0.7500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.7500000000 + -0.3782051206 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + + + + + + + + + + + + + + + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + 0.850000 + 0.640000 + 0.200000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + -0.7500000000 + 0.2500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.2500000000 + 0.2500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.2500000000 + -0.7500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -0.7500000000 + -0.7500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + -0.7500000000 + 0.2500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.2500000000 + 0.2500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.2500000000 + -0.7500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -0.7500000000 + -0.7500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + + + + + + + -0.7500000000 + 0.2500000000 + + + + + + + + + + + + + + + + + diff --git a/synfig-studio/trunk/images/polygon_icon.sif b/synfig-studio/trunk/images/polygon_icon.sif new file mode 100644 index 0000000..2f6fa6b --- /dev/null +++ b/synfig-studio/trunk/images/polygon_icon.sif @@ -0,0 +1,288 @@ + + + Untitled1 + + + + + + + + + + + + + 0.000000 + 0.500000 + 1.000000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + -0.7232009768 + 0.1709987968 + + + + + -0.7232009768 + -0.7174007297 + + + + + 0.6174007058 + -0.7174007297 + + + + + 0.1883995235 + -0.3000000119 + + + + + 0.6825993061 + 0.1941997558 + + + + + 0.0000000000 + 0.6999999881 + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + + + + + + + -0.6000000238 + 0.5000000000 + + + + + + + + + + + + + + + + + + + + + + + + + 1.000000 + 1.000000 + 1.000000 + 1.000000 + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + -0.8000000119 + 0.2000000030 + + + + + -0.8000000119 + -0.8000000119 + + + + + 0.8000000119 + -0.8000000119 + + + + + 0.3000000119 + -0.3000000119 + + + + + 0.8000000119 + 0.2000000030 + + + + + 0.0000000000 + 0.8000000119 + + + + + + + + + + + + 0.6000000238 + -0.8999999762 + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.1000000015 + -0.1000000015 + + + + + 0.1000000015 + 0.1000000015 + + + + + + + + + + diff --git a/synfig-studio/trunk/images/real_icon.sif b/synfig-studio/trunk/images/real_icon.sif new file mode 100644 index 0000000..2a8e77d --- /dev/null +++ b/synfig-studio/trunk/images/real_icon.sif @@ -0,0 +1,281 @@ + + + Sinfg Studio Canvas Icon + + + Untitled + + + + + + + + + + + + + 1.000000 + 0.300000 + 0.100000 + 1.000000 + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + + + + + + + -0.2187500000 + -0.2812500000 + + + + + + + + + + + + + + + + + + + + + + 1.000000 + 1.000000 + 1.000000 + 1.000000 + + + + + + + + + + + -0.2031250000 + -0.2656250000 + + + + + + + + + + + + + + + + + + + + + + 0.2000000030 + 0.2000000030 + + + + + + + + + + + + + + + + + + + 1.000000 + 1.000000 + 1.000000 + 0.000000 + + + + + + + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + + + 0.4215 + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + Sans Serif + + + + + + + + + + + + + + + + 0.3281250000 + 0.3828125000 + + + + + 0.5000000000 + 0.5000000000 + + + + + 0.2624999881 + -0.8750000000 + + + + + + + + + + + + + + + + + + + + + 3.1415 + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + Sans Serif + + + + + + + + + + + + + + + + 0.4046874940 + 0.6234375238 + + + + + 0.5000000000 + 0.5000000000 + + + + + -0.1312499940 + 0.2843750119 + + + + + + + + + + diff --git a/synfig-studio/trunk/images/rectangle_icon.sif b/synfig-studio/trunk/images/rectangle_icon.sif new file mode 100644 index 0000000..f8f5076 --- /dev/null +++ b/synfig-studio/trunk/images/rectangle_icon.sif @@ -0,0 +1,310 @@ + + + Untitled0 + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.6250000000 + -0.6250000000 + + + + + -0.6250000000 + 0.6250000000 + + + + + + + + + + + + + + + + + + + + + + 0.2000000030 + 0.2000000030 + + + + + + + + + + 0.1250000000 + -0.1250000000 + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.6250000000 + -0.6250000000 + + + + + -0.6250000000 + 0.6250000000 + + + + + + + + + + + + + + + + + + + + + + 1.000000 + 1.000000 + 1.000000 + 1.000000 + + + + + 0.6250000000 + -0.6250000000 + + + + + -0.6250000000 + 0.6250000000 + + + + + + + + + + + + + + + + + + + + + + 0.217638 + 0.217638 + 0.217638 + 1.000000 + + + + + -0.6250000000 + 0.6250000000 + + + + + + + + + + + + + + + + + + + 0.0000000000 + 0.2500000000 + + + + + -0.2500000000 + 0.0000000000 + + + + + 0.0000000000 + -0.2500000000 + + + + + 0.2500000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + 0.217638 + 0.217638 + 0.217638 + 1.000000 + + + + + 0.6250000000 + -0.6250000000 + + + + + + + + + + + + + + + + + + + 0.0000000000 + 0.2500000000 + + + + + -0.2500000000 + 0.0000000000 + + + + + 0.0000000000 + -0.2500000000 + + + + + 0.2500000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + + + + + + + -0.6250000000 + 0.6250000000 + + + + + + + + + + diff --git a/synfig-studio/trunk/images/rotate_icon.sif b/synfig-studio/trunk/images/rotate_icon.sif new file mode 100644 index 0000000..8947644 --- /dev/null +++ b/synfig-studio/trunk/images/rotate_icon.sif @@ -0,0 +1,398 @@ + + + Untitled0 + + + + + + + + + + + + + + + 1.000000 + 0.000000 + 0.103813 + 1.000000 + + + + + + + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + + 0.060778 + 0.058655 + 0.058655 + 0.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + 1.0000000000 + -1.0000000000 + + + + + + + + + + + + + + + + + + + + + + 0.060778 + 0.058655 + 0.058655 + 0.000000 + + + + + + + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + + 1.000000 + 0.000000 + 0.103813 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + 0.1250000000 + 0.0000000000 + + + + + 0.2500000000 + 0.0000000000 + + + + + 0.3750000000 + 0.1250000000 + + + + + 0.5000000000 + 0.0000000000 + + + + + 0.6250000000 + 0.0000000000 + + + + + 0.3750000000 + -0.3750000000 + + + + + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + 0.1500000060 + 0.1500000060 + + + + + + + + + + + + + + + + + + + + + + + + + 1.000000 + 1.000000 + 1.000000 + 1.000000 + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + + + + + + + -0.2500000000 + 0.2500000000 + + + + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.0500000007 + -0.0500000007 + + + + + 0.1000000015 + 0.1000000015 + + + + + + + + + + + + + + + + 0.1250000000 + -0.1250000000 + + + + diff --git a/synfig-studio/trunk/images/saveall_icon.sif b/synfig-studio/trunk/images/saveall_icon.sif new file mode 100644 index 0000000..98d9282 --- /dev/null +++ b/synfig-studio/trunk/images/saveall_icon.sif @@ -0,0 +1,66 @@ + + + Untitled0 + + + + + + + + + + + + SAVE +ALL + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + Arial + + + + + + + + + + + + + + + + 0.7500000000 + 1.0000000000 + + + + + 0.5000000000 + 0.5000000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + diff --git a/synfig-studio/trunk/images/scale_icon.sif b/synfig-studio/trunk/images/scale_icon.sif new file mode 100644 index 0000000..0ac41a9 --- /dev/null +++ b/synfig-studio/trunk/images/scale_icon.sif @@ -0,0 +1,199 @@ + + + Untitled0 + + + + + + + + + + + + + 0.000080 + 0.416027 + 0.000000 + 1.000000 + + + + + + + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + + + + + 1.000000 + 1.000000 + 1.000000 + 1.000000 + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + SCALE + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + Sans Serif + + + + + + + + + + + + + + + + 0.7513009906 + 0.7733980417 + + + + + 0.5000000000 + 0.5000000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/synfig-studio/trunk/images/segment_icon.sif b/synfig-studio/trunk/images/segment_icon.sif new file mode 100644 index 0000000..9ec6a04 --- /dev/null +++ b/synfig-studio/trunk/images/segment_icon.sif @@ -0,0 +1,65 @@ + + + Untitled0 + + + + + + + + + + + + SEG + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + Sans Serif + + + + + + + + + + + + + + + + 1.0000000000 + 1.2500000000 + + + + + 0.5000000000 + 0.5000000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + diff --git a/synfig-studio/trunk/images/sif_icon.sif b/synfig-studio/trunk/images/sif_icon.sif new file mode 100644 index 0000000..e761f30 --- /dev/null +++ b/synfig-studio/trunk/images/sif_icon.sif @@ -0,0 +1,1236 @@ + + + Untitled0 + + + + + + + + + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + 1.000000 + 1.000000 + 1.000000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + 0.5091290474 + 1.5202518702 + + + + + + + + + + + + + + -0.0000000000 + 1.2000000477 + + + + + 1.2000000477 + -1.2000000477 + + + + + + + + + 1.5202518702 + 0.5133263469 + + + + + + + + + + + + + + 1.2000000477 + -1.2000000477 + + + + + -1.2000000477 + 0.0000000000 + + + + + + + + + 0.4000000060 + 0.4000000060 + + + + + + + + + + + + + + -1.2000000477 + -0.0000000000 + + + + + 0.0000000000 + 1.2000000477 + + + + + + + + + + + + + + + + + + + + 1.0499999523 + 1.0499999523 + + + + + 0.6999999881 + 0.6999999881 + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + 1.000000 + 1.000000 + 1.000000 + 1.000000 + + + + + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + 0.5091290474 + 1.5202518702 + + + + + + + + + + + + + + -0.0000000000 + 1.2000000477 + + + + + 1.2000000477 + -1.2000000477 + + + + + + + + + 1.5202518702 + 0.5133263469 + + + + + + + + + + + + + + 1.2000000477 + -1.2000000477 + + + + + -1.2000000477 + 0.0000000000 + + + + + + + + + 0.4000000060 + 0.4000000060 + + + + + + + + + + + + + + -1.2000000477 + -0.0000000000 + + + + + 0.0000000000 + 1.2000000477 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + 1.000000 + 1.000000 + 1.000000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + -0.8000000119 + 1.6000000238 + + + + + + + + + + + + + + -1.2000000477 + -0.0000000000 + + + + + 0.0000000000 + -1.7999999523 + + + + + + + + + -0.8000000119 + -1.6000000238 + + + + + + + + + + + + + + -0.0000000000 + -2.4000000954 + + + + + 1.7999999523 + 0.0000000000 + + + + + + + + + 1.6000000238 + -1.6000000238 + + + + + + + + + + + + + + 1.7999999523 + -0.0000000000 + + + + + -0.0000000000 + 1.7999999523 + + + + + + + + + 1.6000000238 + 0.2000000030 + + + + + + + + + + + + + + -0.0000000000 + 1.7999999523 + + + + + 0.0000000000 + 0.6000000238 + + + + + + + + + 1.2000000477 + 0.6000000238 + + + + + + + + + + + + + + -1.2000000477 + -0.0000000000 + + + + + -0.6000000238 + 0.0000000000 + + + + + + + + + 0.6000000238 + 0.6000000238 + + + + + + + + + + + + + + -0.6000000238 + -0.0000000000 + + + + + 0.0000000000 + 0.6000000238 + + + + + + + + + 0.6000000238 + 1.2000000477 + + + + + + + + + + + + + + 0.0000000000 + 1.2000000477 + + + + + -0.0000000000 + 0.6000000238 + + + + + + + + + 0.2000000030 + 1.6000000238 + + + + + + + + + + + + + + -0.6000000238 + -0.0000000000 + + + + + -0.6000000238 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + 1.0499999523 + 1.0499999523 + + + + + 0.8500000238 + 0.8500000238 + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + 1.000000 + 1.000000 + 1.000000 + 1.000000 + + + + + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + -0.8000000119 + 1.6000000238 + + + + + + + + + + + + + + -1.2000000477 + -0.0000000000 + + + + + 0.0000000000 + -1.7999999523 + + + + + + + + + -0.8000000119 + -1.6000000238 + + + + + + + + + + + + + + -0.0000000000 + -2.4000000954 + + + + + 1.7999999523 + 0.0000000000 + + + + + + + + + 1.6000000238 + -1.6000000238 + + + + + + + + + + + + + + 1.7999999523 + -0.0000000000 + + + + + -0.0000000000 + 1.7999999523 + + + + + + + + + 1.6000000238 + 0.2000000030 + + + + + + + + + + + + + + -0.0000000000 + 1.7999999523 + + + + + 0.0000000000 + 0.6000000238 + + + + + + + + + 1.2000000477 + 0.6000000238 + + + + + + + + + + + + + + -1.2000000477 + -0.0000000000 + + + + + -0.6000000238 + 0.0000000000 + + + + + + + + + 0.6000000238 + 0.6000000238 + + + + + + + + + + + + + + -0.6000000238 + -0.0000000000 + + + + + 0.0000000000 + 0.6000000238 + + + + + + + + + 0.6000000238 + 1.2000000477 + + + + + + + + + + + + + + 0.0000000000 + 1.2000000477 + + + + + -0.0000000000 + 0.6000000238 + + + + + + + + + 0.2000000030 + 1.6000000238 + + + + + + + + + + + + + + -0.6000000238 + -0.0000000000 + + + + + -0.6000000238 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + + + + + + + -0.2307692319 + 0.7179487348 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.1000000015 + -0.1000000015 + + + + + 0.1000000015 + 0.1000000015 + + + + + + + + + + + + + + + + + + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + -0.4000000060 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.0750000030 + -0.0750000030 + + + + + 0.1500000060 + 0.1500000060 + + + + + + + + + + + + + + + + + + + + -0.2000000030 + 0.0000000000 + + + + diff --git a/synfig-studio/trunk/images/sinfg_icon.sif b/synfig-studio/trunk/images/sinfg_icon.sif new file mode 100644 index 0000000..aff3ee3 --- /dev/null +++ b/synfig-studio/trunk/images/sinfg_icon.sif @@ -0,0 +1,65 @@ + + + Untitled0 + + + + + + + + + + + + + 0.0000000000 + 0.0500000007 + + + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.1000000015 + -0.1000000015 + + + + + 0.2000000030 + 0.2000000030 + + + + + + + + + + diff --git a/synfig-studio/trunk/images/sketch_icon.sif b/synfig-studio/trunk/images/sketch_icon.sif new file mode 100644 index 0000000..e4d585d --- /dev/null +++ b/synfig-studio/trunk/images/sketch_icon.sif @@ -0,0 +1,199 @@ + + + Untitled0 + + + + + + + + + + + + + -0.000000 + 0.499984 + 0.479841 + 1.000000 + + + + + + + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + + + + + 1.000000 + 1.000000 + 1.000000 + 1.000000 + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + SKETCH + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + Sans Serif + + + + + + + + + + + + + + + + 0.6187184453 + 0.6187184453 + + + + + 0.5000000000 + 0.5000000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/synfig-studio/trunk/images/smooth_move_icon.sif b/synfig-studio/trunk/images/smooth_move_icon.sif new file mode 100644 index 0000000..0d4c879 --- /dev/null +++ b/synfig-studio/trunk/images/smooth_move_icon.sif @@ -0,0 +1,199 @@ + + + Untitled0 + + + + + + + + + + + + + 0.647450 + 0.215732 + 0.361425 + 1.000000 + + + + + + + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + + + + + 1.000000 + 1.000000 + 1.000000 + 1.000000 + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + SMOOTH + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + Sans Serif + + + + + + + + + + + + + + + + 0.5855728388 + 0.6076698899 + + + + + 0.5000000000 + 0.5000000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/synfig-studio/trunk/images/string_icon.sif b/synfig-studio/trunk/images/string_icon.sif new file mode 100644 index 0000000..04f81d5 --- /dev/null +++ b/synfig-studio/trunk/images/string_icon.sif @@ -0,0 +1,65 @@ + + + Untitled0 + + + + + + + + + + + + STR + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + Sans Serif + + + + + + + + + + + + + + + + 1.0000000000 + 1.1250000000 + + + + + 0.5000000000 + 0.5000000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + diff --git a/synfig-studio/trunk/images/swap_colors_icon.sif b/synfig-studio/trunk/images/swap_colors_icon.sif new file mode 100644 index 0000000..2b75b0b --- /dev/null +++ b/synfig-studio/trunk/images/swap_colors_icon.sif @@ -0,0 +1,308 @@ + + + Untitled1 + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + -0.2500000000 + 0.3750000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.3750000000 + -0.2500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + -0.1250000000 + -0.2500000000 + + + + + 0.3750000000 + -0.8750000000 + + + + + 0.8750000000 + -0.2500000000 + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + -0.2500000000 + 0.8750000000 + + + + + -0.8750000000 + 0.3750000000 + + + + + -0.2500000000 + -0.1250000000 + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.0625000000 + -0.0625000000 + + + + + 0.0625000000 + 0.0625000000 + + + + + + + + + + + + + + + + 0.0000000000 + 0.0000000000 + + + + diff --git a/synfig-studio/trunk/images/time_track_icon.sif b/synfig-studio/trunk/images/time_track_icon.sif new file mode 100644 index 0000000..bea21fe --- /dev/null +++ b/synfig-studio/trunk/images/time_track_icon.sif @@ -0,0 +1,242 @@ + + + Untitled0 + + + + + + + + + + + + + + + + + + + 0.000000 + 0.265778 + 0.265778 + 1.000000 + + + + + + + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + i + + + + 1.000000 + 1.000000 + 1.000000 + 1.000000 + + + + Times + + + + + + + + + + + + + + + + 2.2500000000 + 2.2500000000 + + + + + 0.5000000000 + 0.5000000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + + 0.444444 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + -1.7500000000 + 1.7500000000 + + + + + 1.7500000000 + 1.7500000000 + + + + + 1.7500000000 + 0.7500000000 + + + + + 0.5000000000 + 0.7500000000 + + + + + 0.5000000000 + -1.7500000000 + + + + + -0.5000000000 + -1.7500000000 + + + + + -0.5000000000 + 0.7500000000 + + + + + -1.7500000000 + 0.7500000000 + + + + + + + + + + + + + + + + + + + + + 1.000000 + 1.000000 + 1.000000 + 1.000000 + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + + + + + + + + + + + + + + + diff --git a/synfig-studio/trunk/images/valuenode_icon.sif b/synfig-studio/trunk/images/valuenode_icon.sif new file mode 100644 index 0000000..1a7907d --- /dev/null +++ b/synfig-studio/trunk/images/valuenode_icon.sif @@ -0,0 +1,240 @@ + + + DataNode Icon + + + Untitled + + + + + + + + + + + + + 1.000000 + 0.300000 + 0.100000 + 1.000000 + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + + + + + + + -0.2187500000 + -0.2812500000 + + + + + + + + + + + + + + + + + + + + + + 1.000000 + 1.000000 + 1.000000 + 1.000000 + + + + + + + + + + + -0.2031250000 + -0.2656250000 + + + + + + + + + + + + + + + + + + + + + + 0.2000000030 + 0.2000000030 + + + + + + + + + + + + + + + + + + + 1.000000 + 1.000000 + 1.000000 + 0.000000 + + + + + + + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + + + DYN + + + + 0.500000 + 0.750000 + 1.000000 + 1.000000 + + + + Sans Serif + + + + + + + + + + + + + + + + 0.6250000000 + 1.0000000000 + + + + + 0.5000000000 + 0.5000000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + + 0.1000000015 + 0.1000000015 + + + + + + + diff --git a/synfig-studio/trunk/images/vector_icon.sif b/synfig-studio/trunk/images/vector_icon.sif new file mode 100644 index 0000000..2d2bde7 --- /dev/null +++ b/synfig-studio/trunk/images/vector_icon.sif @@ -0,0 +1,250 @@ + + + Sinfg Studio Vector Icon + + + Sphere + + + + + + + + + + + + + 0.898889 + 0.100146 + 0.001630 + 0.986486 + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + + + + + + + -0.2187500000 + -0.2812500000 + + + + + + + + + + + + + + + + + + + + + + 1.000000 + 1.000000 + 1.000000 + 1.000000 + + + + + + + + + + + -0.2031250000 + -0.2656250000 + + + + + + + + + + + + + + + + + + + + + + 0.4375000000 + 0.4218750000 + + + + + + + + + + + + + + + + + + + 1.000000 + 1.000000 + 1.000000 + 0.000000 + + + + + + + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + + + + 1.000000 + 1.000000 + 1.000000 + 1.000000 + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + + + + + + + 0.1000000015 + 0.1000000015 + + + + + + + + + + + + + + + + + + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + 0.5749999881 + 0.5500000119 + + + + diff --git a/synfig-studio/trunk/images/wallpaper.sif b/synfig-studio/trunk/images/wallpaper.sif new file mode 100644 index 0000000..66db075 --- /dev/null +++ b/synfig-studio/trunk/images/wallpaper.sif @@ -0,0 +1,687 @@ + + + Untitled0 + + + + + + + + + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + 1.000000 + 1.000000 + 1.000000 + 1.000000 + + + + + + + + + 0.0149999997 + 0.1562500000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.0000000000 + 0.1000000015 + + + + + + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + 0.470726 + 0.477000 + 0.477000 + 1.000000 + + + + + + + + + + + + + + + + 0.638086 + 0.509474 + 0.361408 + 1.000000 + + + + + + + + + + + + + + + + + + + + + + + + 0.531049 + 0.531049 + 0.531049 + 0.000000 + + + 0.006310 + 0.000000 + 0.000000 + 0.485794 + + + 0.006310 + 0.000000 + 0.000000 + 0.750000 + + + 0.076829 + 0.010931 + 0.001345 + 0.652360 + + + + + + + + + 1.0000000000 + 1.0000000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.0000000000 + -1.5000000000 + + + + + 0.0000000000 + 1.5000000000 + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + 1.000000 + 1.000000 + 1.000000 + 1.000000 + + + + + + + + + + + + + + + + + + + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + 0.457498 + 0.383419 + 0.344119 + 0.000000 + + + 0.500000 + 0.500000 + 0.500000 + 1.000000 + + + + + + + + + 1.0000000000 + 1.0000000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.295985 + 0.026400 + 0.000000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + 0.0750000030 + 0.0750000030 + + + + + + + + + + + + + + + + + + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + 1.000000 + 1.000000 + 1.000000 + 1.000000 + + + + + + + + + 0.0111111114 + 0.0111111114 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.881822 + 0.788820 + 0.722108 + 0.602041 + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.956527 + 0.878455 + 0.809212 + 0.500000 + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + + + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + + + + 1.000000 + 1.000000 + 1.000000 + 0.561224 + + + + + 0.000000 + 0.000000 + 0.000000 + 1.100000 + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/synfig-studio/trunk/images/width_icon.sif b/synfig-studio/trunk/images/width_icon.sif new file mode 100644 index 0000000..886143a --- /dev/null +++ b/synfig-studio/trunk/images/width_icon.sif @@ -0,0 +1,153 @@ + + + Untitled0 + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + -0.8906250000 + 0.7656250000 + + + + + + + + + + + + + + 1.0937500000 + 1.0000000000 + + + + + 1.0937500000 + 1.0000000000 + + + + + + + + + -0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + 0.2197851539 + -0.9105731249 + + + + + 0.2197851539 + -0.9105731249 + + + + + + + + + 0.8906250000 + -0.8125000000 + + + + + + + + + + + + + + 1.6562500000 + 0.7656250000 + + + + + 1.6562500000 + 0.7656250000 + + + + + + + + + + + + + + + + + + + + + + + diff --git a/synfig-studio/trunk/images/zoom_icon.sif b/synfig-studio/trunk/images/zoom_icon.sif new file mode 100644 index 0000000..839c2f7 --- /dev/null +++ b/synfig-studio/trunk/images/zoom_icon.sif @@ -0,0 +1,1976 @@ + + + Untitled0 + + + + + + + + + + + + + + + + + 0.436364 + 0.264545 + 0.072727 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + 0.5000000000 + -0.2500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.7500000000 + -0.2500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.7500000000 + -0.5000000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 1.0000000000 + -0.5000000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 1.0000000000 + -0.7500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 1.2500000000 + -0.7500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 1.2500000000 + -1.0000000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 1.5000000000 + -1.0000000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 1.5000000000 + -1.2500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 1.7500000000 + -1.2500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 1.2500000000 + -1.7500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 1.2500000000 + -1.5000000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 1.0000000000 + -1.5000000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 1.0000000000 + -1.2500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.7500000000 + -1.2500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.7500000000 + -1.0000000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.5000000000 + -1.0000000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.5000000000 + -0.7500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.2500000000 + -0.7500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.2500000000 + -0.5000000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 1.000000 + 1.000000 + 1.000000 + 1.000000 + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.073955 + 0.016095 + 0.000000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + 0.5000000000 + -0.2500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.7500000000 + -0.2500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.7500000000 + -0.5000000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 1.0000000000 + -0.5000000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 1.0000000000 + -0.7500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 1.2500000000 + -0.7500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 1.2500000000 + -1.0000000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 1.5000000000 + -1.0000000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 1.5000000000 + -1.2500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 1.7500000000 + -1.2500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 1.2500000000 + -1.7500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 1.2500000000 + -1.5000000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 1.0000000000 + -1.5000000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 1.0000000000 + -1.2500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.7500000000 + -1.2500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.7500000000 + -1.0000000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.5000000000 + -1.0000000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.5000000000 + -0.7500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.2500000000 + -0.7500000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.2500000000 + -0.5000000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + 0.000000 + 0.278221 + 0.790321 + 1.000000 + + + + + + + + + + + -0.5000000000 + 0.5000000000 + + + + + + + + + + + + + + + + + + + + + + + + + 1.000000 + 1.000000 + 1.000000 + 1.000000 + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 0.000000 + + + + + + + + + + + + + + + + + + + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + + + + + + + -0.5000000000 + 0.5000000000 + + + + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 0.000000 + + + + + + + + + + + -0.5000000000 + 0.5000000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.1250000000 + -0.1250000000 + + + + + 0.1562500000 + 0.1562500000 + + + + + + + + + + diff --git a/synfig-studio/trunk/sinfgstudio.desktop.in b/synfig-studio/trunk/sinfgstudio.desktop.in new file mode 100644 index 0000000..5fdeb2e --- /dev/null +++ b/synfig-studio/trunk/sinfgstudio.desktop.in @@ -0,0 +1,11 @@ +[Desktop Entry] +Name=@PACKAGE_NAME@ +Comment=A Powerful 2D Animation and Composition Package +Exec=@prefix@/bin/sinfgstudio +Terminal=1 +Type=Application +Icon=@prefix@/share/pixmaps/sinfg_icon.@imageext@ +Categories=Application;Graphics; +StartupNotify=true +Encoding=UTF-8 +MimeType=image/sif diff --git a/synfig-studio/trunk/sinfgstudio.keys.in b/synfig-studio/trunk/sinfgstudio.keys.in new file mode 100644 index 0000000..4d4c1c8 --- /dev/null +++ b/synfig-studio/trunk/sinfgstudio.keys.in @@ -0,0 +1,23 @@ + +image/sif: + open=@prefix@/bin/sinfgstudio %f + view=@prefix@/bin/sinfgstudio %f + icon-filename=@prefix@/share/pixmaps/sif_icon.@imageext@ + description=SINFG Composition + default_action_type=application + short_list_application_ids_for_novice_user_level=sinfgstudio + short_list_application_ids_for_intermediate_user_level=sinfgstudio + short_list_application_ids_for_advanced_user_level=sinfgstudio +# category=Images + + +image/sifz: + open=@prefix@/bin/sinfgstudio %f + view=@prefix@/bin/sinfgstudio %f + icon-filename=@prefix@/share/pixmaps/sif_icon.@imageext@ + description=Compressed SINFG Composition + default_action_type=application + short_list_application_ids_for_novice_user_level=sinfgstudio + short_list_application_ids_for_intermediate_user_level=sinfgstudio + short_list_application_ids_for_advanced_user_level=sinfgstudio +# category=Images diff --git a/synfig-studio/trunk/sinfgstudio.mime.in b/synfig-studio/trunk/sinfgstudio.mime.in new file mode 100644 index 0000000..1b95060 --- /dev/null +++ b/synfig-studio/trunk/sinfgstudio.mime.in @@ -0,0 +1,7 @@ +# mime types for sinfg studio + +image/sif + ext: sif SIF + +image/sifz + ext: sifZ SIFZ sif.gz SIF.GZ SIF.gz diff --git a/synfig-studio/trunk/src/Makefile.am b/synfig-studio/trunk/src/Makefile.am new file mode 100644 index 0000000..bd320f4 --- /dev/null +++ b/synfig-studio/trunk/src/Makefile.am @@ -0,0 +1,20 @@ +# $Header: /opt/voria/cvs/studio/src/Makefile.am,v 1.1.1.1 2005/01/07 03:34:35 darco Exp $ + +MAINTAINERCLEANFILES=Makefile.in +EXTRA_DIST=template.cpp template.h + +SUBDIRS=sinfgapp gtkmm + +#if WINDOWSYS_GTKMM +#WINDOWSYS_LIBS=$(top_builddir)/src/gtkmm/libwindowsys.a @GTKMM_LIBS@ +#SUBDIRS=sinfgapp gtkmm +#else +#WINDOWSYS_LIBS=$(top_builddir)/src/win32/libwindowsys.a @WIN32_LIBS@ +#SUBDIRS=win32 +#endif + +#bin_PROGRAMS = sinfgstudio +#sinfgstudio_SOURCES = main.cpp app.cpp app.h instance.cpp instance.h actions.cpp actions.h toolbox.cpp toolbox.h compview.cpp compview.h canvasview.cpp canvasview.h workarea.cpp workarea.h canvasproperties.cpp canvasproperties.h +# view.h view.cpp workarea.cpp workarea.h toolbox.cpp toolbox.h trackview.cpp trackview.h actions.cpp actions.h compview.cpp compview.h +#sinfgstudio_LDADD = @SINFG_LIBS@ $(WINDOWSYS_LIBS) +#sinfgstudio_LDFLAGS=-dlopen self diff --git a/synfig-studio/trunk/src/gtkmm/Makefile.am b/synfig-studio/trunk/src/gtkmm/Makefile.am new file mode 100644 index 0000000..c88314f --- /dev/null +++ b/synfig-studio/trunk/src/gtkmm/Makefile.am @@ -0,0 +1,53 @@ +# $Id: Makefile.am,v 1.1.1.1 2005/01/07 03:34:36 darco Exp $ + +MAINTAINERCLEANFILES=Makefile.in $(GLADE_FILES) + +CELLRENDERER_HH=cellrenderer_gradient.h cellrenderer_timetrack.h cellrenderer_time.h cellrenderer_value.h +CELLRENDERER_CC=cellrenderer_gradient.cpp cellrenderer_timetrack.cpp cellrenderer_time.cpp cellrenderer_value.cpp + +WORKAREARENDERER_HH=renderer_bbox.h renderer_dragbox.h renderer_ducks.h renderer_grid.h renderer_guides.h renderer_timecode.h renderer_canvas.h workarearenderer.h +WORKAREARENDERER_CC=renderer_bbox.cpp renderer_dragbox.cpp renderer_ducks.cpp renderer_grid.cpp renderer_guides.cpp renderer_timecode.cpp renderer_canvas.cpp workarearenderer.cpp + +PALETTE_HH=mod_palette/mod_palette.h mod_palette/dock_paledit.h mod_palette/dock_palbrowse.h +PALETTE_CC=mod_palette/mod_palette.cpp mod_palette/dock_paledit.cpp mod_palette/dock_palbrowse.cpp + +MOD_MIRROR_HH=mod_mirror/mod_mirror.h mod_mirror/state_mirror.h +MOD_MIRROR_CC=mod_mirror/mod_mirror.cpp mod_mirror/state_mirror.cpp + +DIALOG_HH=dialog_setup.h dialog_waypoint.h dialog_gradient.h dialog_color.h dialog_keyframe.h dialog_preview.h dialog_soundselect.h +DIALOG_CC=dialog_setup.cpp dialog_waypoint.cpp dialog_gradient.cpp dialog_color.cpp dialog_keyframe.cpp dialog_preview.cpp dialog_soundselect.cpp + +DOCK_HH=dock_layergroups.h dock_children.h dock_canvasspecific.h dock_metadata.h dock_layers.h dock_params.h dock_keyframes.h dialog_tooloptions.h dock_canvases.h dock_history.h dockmanager.h dockbook.h dockdialog.h dockable.h dock_info.h dock_navigator.h dock_curves.h dock_timetrack.h +DOCK_CC=dock_layergroups.cpp dock_children.cpp dock_canvasspecific.cpp dock_metadata.cpp dock_layers.cpp dock_params.cpp dock_keyframes.cpp dialog_tooloptions.cpp dock_canvases.cpp dock_history.cpp dockmanager.cpp dockbook.cpp dockdialog.cpp dockable.cpp dock_info.cpp dock_navigator.cpp dock_curves.cpp dock_timetrack.cpp + +WIDGET_HH=widget_compselect.h widget_gradient.h widget_color.h widget_enum.h widget_canvaschooser.h widget_time.h widget_filename.h widget_vector.h widget_value.h widget_defaults.h widget_coloredit.h widget_waypoint.h widget_waypointmodel.h widget_distance.h widget_sound.h widget_timeslider.h widget_curves.h +WIDGET_CC=widget_compselect.cpp widget_gradient.cpp widget_color.cpp widget_enum.cpp widget_canvaschooser.cpp widget_time.cpp widget_filename.cpp widget_vector.cpp widget_value.cpp widget_defaults.cpp widget_coloredit.cpp widget_waypoint.cpp widget_waypointmodel.cpp widget_distance.cpp widget_sound.cpp widget_timeslider.cpp widget_curves.cpp + +STATE_HH=state_normal.h state_eyedrop.h state_draw.h state_stroke.h state_fill.h state_bline.h state_polygon.h state_sketch.h state_gradient.h state_circle.h state_rectangle.h state_width.h state_smoothmove.h state_scale.h state_rotate.h state_zoom.h +STATE_CC=state_normal.cpp state_eyedrop.cpp state_draw.cpp state_stroke.cpp state_fill.cpp state_bline.cpp state_polygon.cpp state_sketch.cpp state_gradient.cpp state_circle.cpp state_rectangle.cpp state_width.cpp state_smoothmove.cpp state_scale.cpp state_rotate.cpp state_zoom.cpp + +TREEVIEW_HH=childrentree.h layertree.h keyframetree.h layergrouptree.h +TREEVIEW_CC=childrentree.cpp layertree.cpp keyframetree.cpp layergrouptree.cpp + +TREESTORE_HH=layergrouptreestore.h metadatatreestore.h historytreestore.h keyframetreestore.h childrentreestore.h canvastreestore.h layertreestore.h layerparamtreestore.h +TREESTORE_CC=layergrouptreestore.cpp metadatatreestore.cpp historytreestore.cpp keyframetreestore.cpp childrentreestore.cpp canvastreestore.cpp layertreestore.cpp layerparamtreestore.cpp + +DUCKTRASNFORM_HH=duck.h ducktransform_translate.h ducktransform_scale.h ducktransform_rotate.h +DUCKTRANSFORM_CC=duck.cpp + +EVENTS_HH=event_layerclick.h event_mouse.h +EVENTS_CC= + +ACTION_MANAGERS_HH=layeractionmanager.h keyframeactionmanager.h groupactionmanager.h +ACTION_MANAGERS_CC=layeractionmanager.cpp keyframeactionmanager.cpp groupactionmanager.cpp + +OTHER_HH=statemanager.h module.h ipc.h asyncrenderer.h smach.h duckmatic.h canvasoptions.h render.h app.h instance.h canvasview.h about.h iconcontroler.h toolbox.h workarea.h canvasproperties.h renddesc.h zoomdial.h eventkey.h onemoment.h devicetracker.h dialogsettings.h autorecover.h keymapsettings.h preview.h audiocontainer.h adjust_window.h valuelink.h +OTHER_CC=statemanager.cpp module.cpp ipc.cpp asyncrenderer.cpp duckmatic.cpp main.cpp canvasoptions.cpp render.cpp app.cpp instance.cpp canvasview.cpp about.cpp iconcontroler.cpp toolbox.cpp workarea.cpp canvasproperties.cpp renddesc.cpp zoomdial.cpp onemoment.cpp devicetracker.cpp dialogsettings.cpp autorecover.cpp keymapsettings.cpp preview.cpp audiocontainer.cpp adjust_window.cpp valuelink.cpp + +INCLUDES=-I$(top_srcdir)/src + +bin_PROGRAMS = sinfgstudio +sinfgstudio_SOURCES = $(MOD_MIRROR_CC) $(MOD_MIRROR_HH) $(PALETTE_CC) $(PALETTE_HH) $(WORKAREARENDERER_CC) $(WORKAREARENDERER_HH) $(ACTION_MANAGERS_HH) $(ACTION_MANAGERS_CC) $(DOCK_HH) $(DOCK_CC) $(OTHER_HH) $(OTHER_CC) $(EVENTS_HH) $(EVENTS_CC) $(DUCKTRANSFORM_HH) $(DUCKTRANSFORM_CC) $(TREEVIEW_HH) $(TREEVIEW_CC) $(TREESTORE_HH) $(TREESTORE_CC) $(STATE_CC) $(STATE_HH) $(WIDGET_CC) $(WIDGET_HH) $(DIALOG_HH) $(DIALOG_CC) $(CELLRENDERER_HH) $(CELLRENDERER_CC) +sinfgstudio_LDADD = -L../sinfgapp -lsinfgapp @SINFG_LIBS@ @GTKMM_LIBS@ @FMOD_LIBS@ +sinfgstudio_LDFLAGS=-dlopen self +sinfgstudio_CXXFLAGS=@SINFG_CFLAGS@ @GTKMM_CFLAGS@ diff --git a/synfig-studio/trunk/src/gtkmm/about.cpp b/synfig-studio/trunk/src/gtkmm/about.cpp new file mode 100644 index 0000000..819ed63 --- /dev/null +++ b/synfig-studio/trunk/src/gtkmm/about.cpp @@ -0,0 +1,289 @@ +/*! ======================================================================== +** Sinfg +** Template File +** $Id: about.cpp,v 1.2 2005/01/13 21:11:16 darco Exp $ +** +** Copyright (c) 2002 Robert B. Quattlebaum Jr. +** +** This software and associated documentation +** are CONFIDENTIAL and PROPRIETARY property of +** the above-mentioned copyright holder. +** +** You may not copy, print, publish, or in any +** other way distribute this software without +** a prior written agreement with +** the copyright holder. +** +** === N O T E S =========================================================== +** +** ========================================================================= */ + +/* === H E A D E R S ======================================================= */ + +#ifdef USING_PCH +# include "pch.h" +#else +#ifdef HAVE_CONFIG_H +# include +#endif + +#include +#include + +#include + +#include +#include +#include +#include +#include + +#include + +#include "about.h" +#include "app.h" + +#endif + +using namespace std; +using namespace etl; +using namespace studio; + +/* === M A C R O S ========================================================= */ + +#ifndef VERSION +#define VERSION "unknown" +#define PACKAGE "sinfgstudio" +#endif + +#ifdef WIN32 +# ifdef IMAGE_DIR +# undef IMAGE_DIR +# define IMAGE_DIR "share\\pixmaps" +# endif +#endif + +#ifndef IMAGE_DIR +# define IMAGE_DIR "/usr/local/share/pixmaps" +#endif + +#ifndef IMAGE_EXT +# define IMAGE_EXT "png" +#endif + +/* === G L O B A L S ======================================================= */ +extern const guint gtk_major_version; +extern const guint gtk_minor_version; +extern const guint gtk_micro_version; +extern const guint gtk_binary_age; +extern const guint gtk_interface_age; + +/* === P R O C E D U R E S ================================================= */ + +class studio::AboutProgress : public sinfg::ProgressCallback +{ + About &about; + +public: + + AboutProgress(About &about):about(about) { } + + virtual bool task(const std::string &task) + { + if(about.tasklabel) + { + about.tasklabel->set_label(task); + about.tasklabel->show(); + } + else + { + cerr<set_label(_("ERROR:")+task); + about.tasklabel->show(); + } + else + { + cerr<set_label(_("WARNING:")+task); + about.tasklabel->show(); + } + else + { + cerr<set_fraction((float)current/(float)total); + about.progressbar->show(); + } + else + cerr<set(imagepath+"about_dialog."IMAGE_EXT); + Logo->set_size_request(image_w,image_h); + Logo->set_alignment(0.5,0.5); + Logo->set_padding(0,0); + + // Create the Copyright Label + Gtk::Label *CopyrightLabel = manage(new class Gtk::Label(SINFG_COPYRIGHT)); + CopyrightLabel->set_size_request(image_w,24); + CopyrightLabel->set_alignment(0.5,0.5); + CopyrightLabel->set_padding(0,0); + CopyrightLabel->set_justify(Gtk::JUSTIFY_CENTER); + CopyrightLabel->set_line_wrap(false); + + // Create the Version information label + Gtk::Label *VersionLabel = manage(new class Gtk::Label("Version")); + VersionLabel->set_size_request(image_w,80); + VersionLabel->set_flags(Gtk::CAN_FOCUS); + VersionLabel->set_alignment(0.5,0.5); + VersionLabel->set_padding(0,0); + VersionLabel->set_justify(Gtk::JUSTIFY_CENTER); + VersionLabel->set_line_wrap(false); + + // Set the version label to contain the correct information + string ver; + ver+="Version "VERSION" ("__DATE__" "__TIME__")\n"; + ver+="Using SINFG "; + ver+=sinfg::get_version(); + #ifdef __GNUC__ + ver+=strprintf(" and GNU G++ %d.%d.%d",__GNUC__,__GNUC_MINOR__,__GNUC_PATCHLEVEL__); + #endif + + ver+=strprintf("\nGtk+ %d.%d.%d",gtk_major_version,gtk_minor_version,gtk_micro_version); + + #ifdef _DEBUG + ver+="\nDEBUG BUILD"; + #endif + VersionLabel->set_text(ver); + + // Create the image that will be used on the close button + Gtk::Image *image2 = manage(new class Gtk::Image(Gtk::StockID("gtk-close"), Gtk::IconSize(4))); + image2->set_alignment(0.5,0.5); + image2->set_padding(0,0); + + // Create the close button, and attach the image to it + CloseButton = manage(new class Gtk::Button()); + CloseButton->set_size_request(24,24); + CloseButton->set_flags(Gtk::CAN_FOCUS); + _tooltips.set_tip(*CloseButton, "Close", ""); + CloseButton->set_relief(Gtk::RELIEF_NONE); + CloseButton->add(*image2); + + // Create the progress bar + progressbar = manage(new class Gtk::ProgressBar()); + progressbar->set_size_request(image_w,24); + + // Create the current task label + tasklabel = manage(new class Gtk::Label()); + tasklabel->set_size_request(image_w,24); + tasklabel->set_use_underline(false); + + // Create the Gtk::Fixed container and put all of the widgets into it + Gtk::Fixed *fixed1 = manage(new class Gtk::Fixed()); + fixed1->put(*Logo, 0, 0); + fixed1->put(*CopyrightLabel, 0, image_h-25); + fixed1->put(*CloseButton, image_w-24, 0); + fixed1->put(*VersionLabel, 0, image_h-90); + fixed1->put(*progressbar, 0, image_h+24); + fixed1->put(*tasklabel, 0, image_h); + + // Set up the parameters for this pop-up window + set_title("Sinfg Studio "VERSION); + set_modal(false); + property_window_position().set_value(Gtk::WIN_POS_CENTER); + set_resizable(false); + add(*fixed1); + + // show everything off + Logo->show(); + CopyrightLabel->show(); + image2->show(); + CloseButton->show(); + VersionLabel->show(); + fixed1->show(); + + // Connect relevant signals + CloseButton->signal_clicked().connect(sigc::mem_fun(*this, &About::close)); + + cb=new AboutProgress(*this); +} + +About::~About() +{ + delete cb; +} + +void About::close() +{ + hide(); + if(can_self_destruct) + delete this; +} + +void +About::set_can_self_destruct(bool x) +{ + can_self_destruct=x; + if(x==true) + CloseButton->show(); + else + CloseButton->hide(); +} + +sinfg::ProgressCallback * +About::get_callback() +{ + return cb; +} diff --git a/synfig-studio/trunk/src/gtkmm/about.h b/synfig-studio/trunk/src/gtkmm/about.h new file mode 100644 index 0000000..1766bfd --- /dev/null +++ b/synfig-studio/trunk/src/gtkmm/about.h @@ -0,0 +1,77 @@ +/*! ======================================================================== +** Sinfg +** Template Header File +** $Id: about.h,v 1.1.1.1 2005/01/07 03:34:35 darco Exp $ +** +** Copyright (c) 2002 Robert B. Quattlebaum Jr. +** +** This software and associated documentation +** are CONFIDENTIAL and PROPRIETARY property of +** the above-mentioned copyright holder. +** +** You may not copy, print, publish, or in any +** other way distribute this software without +** a prior written agreement with +** the copyright holder. +** +** === N O T E S =========================================================== +** +** ========================================================================= */ + +/* === S T A R T =========================================================== */ + +#ifndef __SINFG_GTKMM_ABOUT_H +#define __SINFG_GTKMM_ABOUT_H + +/* === H E A D E R S ======================================================= */ + +//#include +#include +#include +#include +#include +#include + +/* === M A C R O S ========================================================= */ + +/* === T Y P E D E F S ===================================================== */ + +/* === C L A S S E S & S T R U C T S ======================================= */ + +namespace sinfg { class ProgressCallback; }; + +namespace studio { + +class AboutProgress; + +class About : public Gtk::Window +{ + friend class AboutProgress; + + AboutProgress *cb; + + Gtk::Tooltips _tooltips; + + Gtk::Label *tasklabel; + Gtk::ProgressBar *progressbar; + Gtk::Button *CloseButton; + + void close(); + + bool can_self_destruct; + +public: + + sinfg::ProgressCallback *get_callback(); + + void set_can_self_destruct(bool x); + + About(); + ~About(); +}; + +} + +/* === E N D =============================================================== */ + +#endif diff --git a/synfig-studio/trunk/src/gtkmm/adjust_window.cpp b/synfig-studio/trunk/src/gtkmm/adjust_window.cpp new file mode 100644 index 0000000..90ca220 --- /dev/null +++ b/synfig-studio/trunk/src/gtkmm/adjust_window.cpp @@ -0,0 +1,166 @@ +/* === S I N F G =========================================================== */ +/*! \file adjust_window.cpp +** \brief Adjustment Window Implementation File +** +** $Id: adjust_window.cpp,v 1.1.1.1 2005/01/07 03:34:35 darco Exp $ +** +** \legal +** Copyright (c) 2004 Adrian Bentley +** +** This software and associated documentation +** are CONFIDENTIAL and PROPRIETARY property of +** the above-mentioned copyright holder. +** +** You may not copy, print, publish, or in any +** other way distribute this software without +** a prior written agreement with +** the copyright holder. +** \endlegal +*/ +/* ========================================================================= */ + +/* === H E A D E R S ======================================================= */ + +#ifdef USING_PCH +# include "pch.h" +#else +#ifdef HAVE_CONFIG_H +# include +#endif + +#include "adjust_window.h" +#include "app.h" + +#endif + +/* === U S I N G =========================================================== */ + +using namespace std; +//using namespace etl; +//using namespace sinfg; + +using studio::Adjust_Window; + +/* === M A C R O S ========================================================= */ +const double EPSILON = 1.0e-6; + +/* === G L O B A L S ======================================================= */ + +/* === P R O C E D U R E S ================================================= */ + +/* === M E T H O D S ======================================================= */ + +/* === E N T R Y P O I N T ================================================= */ + +Adjust_Window::Adjust_Window(double value, double lower, double upper, + double stepinc, double pageinc, double pagesize, + Gtk::Adjustment *adj) +: Adjustment(value,lower,upper,stepinc,pageinc,pagesize), + adj_child(0) +{ + if(adj) set_child_adjustment(adj); +} + +Adjust_Window::~Adjust_Window() +{ + //connections should automatically be killed etc. +} + +//child interface functions +Gtk::Adjustment *Adjust_Window::get_child_adjustment() +{ + return adj_child; +} + +const Gtk::Adjustment *Adjust_Window::get_child_adjustment() const +{ + return adj_child; +} + +void Adjust_Window::set_child_adjustment(Gtk::Adjustment *child) +{ + childchanged.disconnect(); + + adj_child = child; + + sinfg::info("Adjust: connecting to child signals"); + if(child) + { + childchanged = child->signal_changed().connect(sigc::mem_fun(*this,&Adjust_Window::update_fromchild)); + + update_child(); + } +} + +void Adjust_Window::on_changed() +{ + update_child(); +} + +void Adjust_Window::on_value_changed() +{ + update_child(); +} + +//SUB TIME FUNCTIONS +double Adjust_Window::get_sub_lower() const +{ + return get_value(); +} + +double Adjust_Window::get_sub_upper() const +{ + return get_value() + get_page_size(); +} + +//---- REFRESH FUNCTIONS ----- +void Adjust_Window::update_child() +{ + if(adj_child) + { + bool childchanged = false; + + double v = get_value(); + double ve = v + get_page_size(); + + //reset child's values if they need to be... + if(abs(v - adj_child->get_lower()) > EPSILON) + { + adj_child->set_lower(v); + childchanged = true; + } + + if(abs(ve - adj_child->get_upper()) > EPSILON) + { + adj_child->set_upper(ve); + childchanged = true; + } + + if(childchanged) + { + adj_child->changed(); + } + } +} + +void Adjust_Window::update_fromchild() +{ + if(adj_child) + { + double b = adj_child->get_lower(); + double dist = adj_child->get_upper() - b; + + //reset our values if they need to be... + if(abs(get_value() - b) > EPSILON) + { + set_value(b); + value_changed(); + } + + if(abs(get_page_size() - dist) > EPSILON) + { + set_page_size(dist); + changed(); + } + } +} diff --git a/synfig-studio/trunk/src/gtkmm/adjust_window.h b/synfig-studio/trunk/src/gtkmm/adjust_window.h new file mode 100644 index 0000000..5cbf4a4 --- /dev/null +++ b/synfig-studio/trunk/src/gtkmm/adjust_window.h @@ -0,0 +1,93 @@ +/* === S I N F G =========================================================== */ +/*! \file adjust_window.h +** \brief Adjustment Window Header +** +** $Id: adjust_window.h,v 1.1.1.1 2005/01/07 03:34:35 darco Exp $ +** +** \legal +** Copyright (c) 2004 Adrian Bentley +** +** This software and associated documentation +** are CONFIDENTIAL and PROPRIETARY property of +** the above-mentioned copyright holder. +** +** You may not copy, print, publish, or in any +** other way distribute this software without +** a prior written agreement with +** the copyright holder. +** \endlegal +*/ +/* ========================================================================= */ + +/* === S T A R T =========================================================== */ + +#ifndef __SINFG_TEMPLATE_H +#define __SINFG_TEMPLATE_H + +/* === H E A D E R S ======================================================= */ +#include + +/* === M A C R O S ========================================================= */ + +/* === T Y P E D E F S ===================================================== */ + +/* === C L A S S E S & S T R U C T S ======================================= */ + +namespace studio { + +/* Sets up an adjustment that controls/communicates with another adjustment + (could be expanded to multiple children) + + The current value and pagesize define the lower and upper bounds of the + child adjustment. + + NEED TO REPLACE FUNCTIONALITY IN: + refresh_rend_desc + refresh_time_window + on_time_changed - possibly.... + + time_zoom_in - possibly... + time_zoom_out - possibly... + + play - possibly... + + THINGS TO CHECK: + disp_audio's use of time_adjustment + children_tree's use of time_adjustment + layer_tree's use of time_adjustment +*/ +class Adjust_Window : public Gtk::Adjustment +{ + Gtk::Adjustment *adj_child; + + sigc::connection childchanged; //we only care about the non-value parts of the child + + virtual void on_changed(); //value+pagesize corresponds to child upper + virtual void on_value_changed(); //value corresponds to child lower + +protected: //update interface + virtual void update_child(); + virtual void update_fromchild(); + +public: //structors + Adjust_Window(double value, double lower, double upper, + double step_increment=1, double page_increment=10, double page_size=0, + Gtk::Adjustment *adj = 0); + + virtual ~Adjust_Window(); + +public: //child interface + Gtk::Adjustment *get_child_adjustment(); + const Gtk::Adjustment *get_child_adjustment() const; + void set_child_adjustment(Gtk::Adjustment *child); + +public: //Sub value interface + double get_sub_lower() const; + double get_sub_upper() const; +}; + +}; // END of namespace studio + +/* === E N D =============================================================== */ + +#endif diff --git a/synfig-studio/trunk/src/gtkmm/app.cpp b/synfig-studio/trunk/src/gtkmm/app.cpp new file mode 100644 index 0000000..b63b37d --- /dev/null +++ b/synfig-studio/trunk/src/gtkmm/app.cpp @@ -0,0 +1,2084 @@ +/* === S I N F G =========================================================== */ +/*! \file app.cpp +** \brief writeme +** +** $Id: app.cpp,v 1.10 2005/01/17 06:31:12 darco Exp $ +** +** \legal +** Copyright (c) 2002 Robert B. Quattlebaum Jr. +** +** This software and associated documentation +** are CONFIDENTIAL and PROPRIETARY property of +** the above-mentioned copyright holder. +** +** You may not copy, print, publish, or in any +** other way distribute this software without +** a prior written agreement with +** the copyright holder. +** \endlegal +*/ +/* ========================================================================= */ + +/* === H E A D E R S ======================================================= */ + +#ifdef USING_PCH +# include "pch.h" +#else +#ifdef HAVE_CONFIG_H +# include +#endif + +#include +#include + +#include +#include +#include +#include +#include +#include +#include +#include +#include + +#include + +#include + +#include "app.h" +#include "about.h" +#include "instance.h" +#include "canvasview.h" +#include "dialog_setup.h" +#include "dialog_gradient.h" +#include "dialog_color.h" +#include "toolbox.h" +#include "compview.h" +#include "onemoment.h" + +#include "dockmanager.h" + +#include "state_eyedrop.h" +#include "state_normal.h" +#include "state_draw.h" +#include "state_fill.h" +#include "state_bline.h" +#include "state_polygon.h" +#include "state_sketch.h" +#include "state_gradient.h" +#include "state_circle.h" +#include "state_rectangle.h" +#include "state_smoothmove.h" +#include "state_scale.h" +#include "state_width.h" +#include "state_rotate.h" +#include "state_zoom.h" + +#include "devicetracker.h" +#include "dialog_tooloptions.h" + +#include "autorecover.h" + +#include +#include "dock_history.h" +#include "dock_canvases.h" +#include "dock_keyframes.h" +#include "dock_layers.h" +#include "dock_params.h" +#include "dock_metadata.h" +#include "dock_children.h" +#include "dock_info.h" +#include "dock_navigator.h" +#include "dock_layergroups.h" +#include "dock_timetrack.h" +#include "dock_curves.h" + +#include "mod_palette/mod_palette.h" +#include "mod_mirror/mod_mirror.h" + +#include + +#include "ipc.h" + +#include "module.h" + +#include "statemanager.h" + +#ifdef WITH_FMOD +#include +#endif + +#ifdef WIN32 +#include +#endif +#include + +#endif + +/* === U S I N G =========================================================== */ + +using namespace std; +using namespace etl; +using namespace sinfg; +using namespace studio; + +/* === M A C R O S ========================================================= */ + +#ifndef DPM2DPI +#define DPM2DPI(x) (float(x)/39.3700787402f) +#define DPI2DPM(x) (float(x)*39.3700787402f) +#endif + +#ifdef WIN32 +# ifdef IMAGE_DIR +# undef IMAGE_DIR +# define IMAGE_DIR "share\\pixmaps" +# endif +#endif + +#ifndef IMAGE_DIR +# define IMAGE_DIR "/usr/local/share/pixmaps" +#endif + +#ifndef IMAGE_EXT +# define IMAGE_EXT "tif" +#endif + +#include + +/* === S I G N A L S ======================================================= */ + +static sigc::signal signal_present_all_; +sigc::signal& +App::signal_present_all() { return signal_present_all_; } + +static sigc::signal signal_recent_files_changed_; +sigc::signal& +App::signal_recent_files_changed() { return signal_recent_files_changed_; } + +static sigc::signal > signal_canvas_view_focus_; +sigc::signal >& +App::signal_canvas_view_focus() { return signal_canvas_view_focus_; } + +static sigc::signal > signal_instance_selected_; +sigc::signal >& +App::signal_instance_selected() { return signal_instance_selected_; } + +static sigc::signal > signal_instance_created_; +sigc::signal >& +App::signal_instance_created() { return signal_instance_created_; } + +static sigc::signal > signal_instance_deleted_; +sigc::signal >& +App::signal_instance_deleted() { return signal_instance_deleted_; } + +/* === G L O B A L S ======================================================= */ + +static std::list recent_files; +const std::list& App::get_recent_files() { return recent_files; } + +int App::Busy::count; +bool App::shutdown_in_progress; + +sinfg::Gamma App::gamma; + +Glib::RefPtr App::ui_manager_; + +sinfg::Distance::System App::distance_system; + +studio::Dialog_Setup* App::dialog_setup; + +etl::handle< studio::ModPalette > mod_palette_; +//studio::Dialog_Palette* App::dialog_palette; + +std::list > App::instance_list; + +static etl::handle ui_interface_; +const etl::handle& App::get_ui_interface() { return ui_interface_; } + +etl::handle App::selected_instance; +etl::handle App::selected_canvas_view; + +studio::Toolbox *studio::App::toolbox=NULL; + +studio::AutoRecover *studio::App::auto_recover=NULL; + +studio::IPC *ipc=NULL; + +studio::DockManager* studio::App::dock_manager=0; + +studio::DeviceTracker* studio::App::device_tracker=0; + +studio::Dialog_Gradient* studio::App::dialog_gradient; + +studio::Dialog_Color* studio::App::dialog_color; + +Gtk::InputDialog* studio::App::dialog_input; + +studio::Dialog_ToolOptions* studio::App::dialog_tool_options; + +studio::Dock_History* dock_history; +studio::Dock_Canvases* dock_canvases; +studio::Dock_Keyframes* dock_keyframes; +studio::Dock_Layers* dock_layers; +studio::Dock_Params* dock_params; +studio::Dock_MetaData* dock_meta_data; +studio::Dock_Children* dock_children; +studio::Dock_Info* dock_info; +studio::Dock_LayerGroups* dock_layer_groups; +studio::Dock_Navigator* dock_navigator; +studio::Dock_Timetrack* dock_timetrack; +studio::Dock_Curves* dock_curves; + +std::list< etl::handle< studio::Module > > module_list_; + +bool studio::App::use_colorspace_gamma=true; + +static int max_recent_files_=25; +int studio::App::get_max_recent_files() { return max_recent_files_; } +void studio::App::set_max_recent_files(int x) { max_recent_files_=x; } + +static sinfg::String app_base_path_; + +namespace studio { +}; // END of namespace studio +studio::StateManager* state_manager; + + + + +class GlobalUIInterface : public sinfgapp::UIInterface +{ +public: + + virtual Response yes_no(const std::string &title, const std::string &message,Response dflt=RESPONSE_YES) + { + Gtk::Dialog dialog( + title, // Title + true, // Modal + true // use_separator + ); + Gtk::Label label(message); + label.show(); + + dialog.get_vbox()->pack_start(label); + dialog.add_button(Gtk::StockID("gtk-yes"),RESPONSE_YES); + dialog.add_button(Gtk::StockID("gtk-no"),RESPONSE_NO); + + dialog.set_default_response(dflt); + dialog.show(); + return (Response)dialog.run(); + } + virtual Response yes_no_cancel(const std::string &title, const std::string &message,Response dflt=RESPONSE_YES) + { + Gtk::Dialog dialog( + title, // Title + true, // Modal + true // use_separator + ); + Gtk::Label label(message); + label.show(); + + dialog.get_vbox()->pack_start(label); + dialog.add_button(Gtk::StockID("gtk-yes"),RESPONSE_YES); + dialog.add_button(Gtk::StockID("gtk-no"),RESPONSE_NO); + dialog.add_button(Gtk::StockID("gtk-cancel"),RESPONSE_CANCEL); + + dialog.set_default_response(dflt); + dialog.show(); + return (Response)dialog.run(); + } + virtual Response ok_cancel(const std::string &title, const std::string &message,Response dflt=RESPONSE_OK) + { + Gtk::Dialog dialog( + title, // Title + true, // Modal + true // use_separator + ); + Gtk::Label label(message); + label.show(); + + dialog.get_vbox()->pack_start(label); + dialog.add_button(Gtk::StockID("gtk-ok"),RESPONSE_OK); + dialog.add_button(Gtk::StockID("gtk-cancel"),RESPONSE_CANCEL); + + dialog.set_default_response(dflt); + dialog.show(); + return (Response)dialog.run(); + } + + virtual bool + task(const std::string &task) + { + std::cerr<pack_start(label); + dialog.add_button(Gtk::StockID("gtk-ok"),RESPONSE_OK); + dialog.show(); + dialog.run(); + return true; + } + + virtual bool + warning(const std::string &err) + { + std::cerr<<"warning: "<element.serial=0; + unwound->element.checksum=0; + + for(i=0;i<16;i++) + { + U8 data; + + switch(key[i]) + { + case '0': data=0; break; + case '1': data=1; break; + case '2': data=2; break; + case '3': data=3; break; + case '4': data=4; break; + case '5': data=5; break; + case '6': data=6; break; + case '7': data=7; break; + case '8': data=8; break; + case '9': data=9; break; + case 'a': case 'A': data=10; break; + case 'b': case 'B': data=11; break; + case 'c': case 'C': data=12; break; + case 'd': case 'D': data=13; break; + case 'e': case 'E': data=14; break; + case 'f': case 'F': data=15; break; + default: return 0; break; + } + int bit=i*2; + unwound->element.checksum|=(((U32)data&3)<element.serial|=(((U32)(data>>2)&3)<>24); + } + } + + unwound_key.element.serial^=appid_mask_a; + unwound_key.element.checksum^=appid_mask_b; + + *serial=unwound_key.element.serial; + + return unwound_key.element.checksum==hash_U32(unwound_key.element.serial); +} + + +int check_license(String basedir) +{ + String key; + String license_file; + +#ifndef _WIN32 + license_file="/usr/local/etc/.synfiglicense"; +#else + license_file=basedir+"\\etc\\.synfiglicense"; +#endif + + try { + key=Glib::file_get_contents(license_file); + } catch (Glib::FileError) { } + U32 serial(0); + if(!v_key_check(key.c_str(),&serial,0xdeadbeef)) + { + while(!v_key_check(key.c_str(),&serial,0xdeadbeef)) + { + key.clear(); + + if(!App::dialog_entry( + _("Synfig Studio Authentication"), + _("Please enter your license key below. You will not\nbe able to use this software without a valid license key."), + key + )) + throw String("No License"); + } + + FILE* file=fopen(license_file.c_str(),"w"); + if(file) + { + fprintf(file,"%s",key.c_str()); + fclose(file); + } + else + sinfg::error("Unable to save license key!"); + } + sinfg::info("License Authenticated -- Serial #%05d",serial); + return serial; +} + +/* +void +studio::UIManager::insert_action_group (const Glib::RefPtr& action_group, int pos) +{ + action_group_list.push_back(action_group); + Gtk::UIManager::insert_action_group(action_group, pos); +} + +void +studio::UIManager::remove_action_group (const Glib::RefPtr& action_group) +{ + std::list >::iterator iter; + for(iter=action_group_list.begin();iter!=action_group_list.end();++iter) + if(*iter==action_group) + { + action_group_list.erase(iter); + Gtk::UIManager::remove_action_group(action_group); + return; + } + sinfg::error("Unable to find action group"); +} + +void +studio::add_action_group_to_top(Glib::RefPtr ui_manager, Glib::RefPtr group) +{ + ui_manager->insert_action_group(group,0); + return; + DEBUGPOINT(); + std::list > prev_groups(ui_manager->get_action_groups()); + std::list >::reverse_iterator iter; + + DEBUGPOINT(); + for(iter=prev_groups.rbegin();iter!=prev_groups.rend();++iter) + { + DEBUGPOINT(); + if(*iter && (*iter)->get_name()!="menus") + { + sinfg::info("Removing action group "+(*iter)->get_name()); + ui_manager->remove_action_group(*iter); + } + } + DEBUGPOINT(); + ui_manager->insert_action_group(group,0); + + DEBUGPOINT(); + for(;!prev_groups.empty();prev_groups.pop_front()) + { + if(prev_groups.front() && prev_groups.front()!=group && prev_groups.front()->get_name()!="menus") + ui_manager->insert_action_group(prev_groups.front(),1); + } + DEBUGPOINT(); +} +*/ +class Preferences : public sinfgapp::Settings +{ +public: + virtual bool get_value(const sinfg::String& key, sinfg::String& value)const + { + if(key=="gamma") + { + value=strprintf("%f %f %f %f", + App::gamma.get_gamma_r(), + App::gamma.get_gamma_g(), + App::gamma.get_gamma_b(), + App::gamma.get_black_level() + ); + return true; + } + if(key=="time_format") + { + value=strprintf("%i",App::get_time_format()); + return true; + } + if(key=="file_history.size") + { + value=strprintf("%i",App::get_max_recent_files()); + return true; + } + if(key=="use_colorspace_gamma") + { + value=strprintf("%i",(int)App::use_colorspace_gamma); + return true; + } + if(key=="distance_system") + { + value=strprintf("%s",Distance::system_name(App::distance_system).c_str()); + return true; + } + if(key=="auto_recover_backup_interval") + { + value=strprintf("%i",App::auto_recover->get_timeout()); + return true; + } + + return sinfgapp::Settings::get_value(key,value); + } + + virtual bool set_value(const sinfg::String& key,const sinfg::String& value) + { + if(key=="gamma") + { + float r,g,b,blk; + + strscanf(value,"%f %f %f %f", + &r, + &g, + &b, + &blk + ); + + App::gamma.set_all(r,g,b,blk); + + return true; + } + if(key=="time_format") + { + int i(atoi(value.c_str())); + App::set_time_format(static_cast(i)); + return true; + } + if(key=="auto_recover_backup_interval") + { + int i(atoi(value.c_str())); + App::auto_recover->set_timeout(i); + return true; + } + if(key=="file_history.size") + { + int i(atoi(value.c_str())); + App::set_max_recent_files(i); + return true; + } + if(key=="use_colorspace_gamma") + { + int i(atoi(value.c_str())); + App::use_colorspace_gamma=i; + return true; + } + if(key=="distance_system") + { + App::distance_system=Distance::ident_system(value);; + return true; + } + + return sinfgapp::Settings::set_value(key,value); + } + + virtual KeyList get_key_list()const + { + KeyList ret(sinfgapp::Settings::get_key_list()); + ret.push_back("gamma"); + ret.push_back("time_format"); + ret.push_back("distance_system"); + ret.push_back("file_history.size"); + ret.push_back("use_colorspace_gamma"); + ret.push_back("auto_recover_backup_interval"); + return ret; + } +}; + +static Preferences _preferences; + +void +init_ui_manager() +{ + Glib::RefPtr menus_action_group = Gtk::ActionGroup::create("menus"); + + Glib::RefPtr toolbox_action_group = Gtk::ActionGroup::create("toolbox"); + + Glib::RefPtr actions_action_group = Gtk::ActionGroup::create(); + + menus_action_group->add( Gtk::Action::create("menu-file", "_File") ); + menus_action_group->add( Gtk::Action::create("menu-edit", "_Edit") ); + menus_action_group->add( Gtk::Action::create("menu-view", "_View") ); + menus_action_group->add( Gtk::Action::create("menu-canvas", "_Canvas") ); + menus_action_group->add( Gtk::Action::create("menu-layer", "_Layer") ); + menus_action_group->add( Gtk::Action::create("menu-duck-mask", "Mask Ducks") ); + menus_action_group->add( Gtk::Action::create("menu-preview-quality", "Preview Quality") ); + menus_action_group->add( Gtk::Action::create("menu-layer-new", "New Layer") ); + menus_action_group->add( Gtk::Action::create("menu-keyframe", "Keyframe") ); + menus_action_group->add( Gtk::Action::create("menu-group", "Group") ); + menus_action_group->add( Gtk::Action::create("menu-state", "State") ); + menus_action_group->add( Gtk::Action::create("menu-toolbox", "Toolbox") ); + + // Add the sinfgapp actions... + sinfgapp::Action::Book::iterator iter; + for(iter=sinfgapp::Action::book().begin();iter!=sinfgapp::Action::book().end();++iter) + { + actions_action_group->add(Gtk::Action::create( + "action-"+iter->second.name, + get_action_stock_id(iter->second), + iter->second.local_name,iter->second.local_name + )); + } + +#define DEFINE_ACTION(x,stock) { Glib::RefPtr action( Gtk::Action::create(x, stock) ); /*action->set_sensitive(false);*/ actions_action_group->add(action); } +#define DEFINE_ACTION2(x,stock,label) { Glib::RefPtr action( Gtk::Action::create(x, stock,label,label) ); /*action->set_sensitive(false);*/ actions_action_group->add(action); } +#define DEFINE_ACTION_SIG(group,x,stock,sig) { Glib::RefPtr action( Gtk::Action::create(x, stock) ); /*action->set_sensitive(false);*/ group->add(action,sig); } + + DEFINE_ACTION2("keyframe-properties", Gtk::StockID("gtk-properties"), _("Keyframe Properties")); + DEFINE_ACTION("about", Gtk::StockID("sinfg-about")); + DEFINE_ACTION("open", Gtk::Stock::OPEN); + DEFINE_ACTION("save", Gtk::Stock::SAVE); + DEFINE_ACTION("save-as", Gtk::Stock::SAVE_AS); + DEFINE_ACTION("revert", Gtk::Stock::REVERT_TO_SAVED); + DEFINE_ACTION("cvs-add", Gtk::StockID("sinfg-cvs_add")); + DEFINE_ACTION("cvs-update", Gtk::StockID("sinfg-cvs_update")); + DEFINE_ACTION("cvs-commit", Gtk::StockID("sinfg-cvs_commit")); + DEFINE_ACTION("cvs-revert", Gtk::StockID("sinfg-cvs_revert")); + DEFINE_ACTION("import", _("Import")); + DEFINE_ACTION("render", _("Render")); + DEFINE_ACTION("preview", _("Preview")); + DEFINE_ACTION("dialog-flipbook", _("Preview Dialog")); + DEFINE_ACTION("sound", _("Sound File")); + DEFINE_ACTION("options", _("Options")); + DEFINE_ACTION("close", _("Close")); + + + DEFINE_ACTION("undo", Gtk::StockID("gtk-undo")); + DEFINE_ACTION("redo", Gtk::StockID("gtk-redo")); + DEFINE_ACTION("cut", Gtk::StockID("gtk-cut")); + DEFINE_ACTION("copy", Gtk::StockID("gtk-copy")); + DEFINE_ACTION("paste", Gtk::StockID("gtk-paste")); + DEFINE_ACTION("select-all-ducks", _("Select All Ducks")); + DEFINE_ACTION("unselect-all-layers", _("Unselect All Layers")); + DEFINE_ACTION("properties", _("Properties")); + + DEFINE_ACTION("mask-position-ducks", _("Mask Position Ducks")); + DEFINE_ACTION("mask-vertex-ducks", _("Mask Vertex Ducks")); + DEFINE_ACTION("mask-tangent-ducks", _("Mask Tangent Ducks")); + DEFINE_ACTION("mask-radius-ducks", _("Mask Radius Ducks")); + DEFINE_ACTION("mask-width-ducks", _("Mask Width Ducks")); + DEFINE_ACTION("mask-angle-ducks", _("Mask Angle Ducks")); + DEFINE_ACTION("quality-00", _("Use Parametric Renderer")); + DEFINE_ACTION("quality-01", _("Use Quality Level 1")); + DEFINE_ACTION("quality-02", _("Use Quality Level 2")); + DEFINE_ACTION("quality-03", _("Use Quality Level 3")); + DEFINE_ACTION("quality-04", _("Use Quality Level 4")); + DEFINE_ACTION("quality-05", _("Use Quality Level 5")); + DEFINE_ACTION("quality-06", _("Use Quality Level 6")); + DEFINE_ACTION("quality-07", _("Use Quality Level 7")); + DEFINE_ACTION("quality-08", _("Use Quality Level 8")); + DEFINE_ACTION("quality-09", _("Use Quality Level 9")); + DEFINE_ACTION("quality-10", _("Use Quality Level 10")); + DEFINE_ACTION("play", _("Play")); + DEFINE_ACTION("pause", _("Pause")); + DEFINE_ACTION("stop", _("Stop")); + DEFINE_ACTION("toggle-grid-show", _("Toggle Grid Show")); + DEFINE_ACTION("toggle-grid-snap", _("Toggle Grid Snap")); + DEFINE_ACTION("toggle-guide-show", _("Toggle Guide Show")); + DEFINE_ACTION("toggle-low-res", _("Toggle Low-Res")); + DEFINE_ACTION("toggle-onion-skin", _("Toggle Onion Skin")); + DEFINE_ACTION("canvas-zoom-in", Gtk::StockID("gtk-zoom-in")); + DEFINE_ACTION("canvas-zoom-out", Gtk::StockID("gtk-zoom-out")); + DEFINE_ACTION("canvas-zoom-fit", Gtk::StockID("gtk-zoom-fit")); + DEFINE_ACTION("canvas-zoom-100", Gtk::StockID("gtk-zoom-100")); + DEFINE_ACTION("time-zoom-in", Gtk::StockID("gtk-zoom-in")); + DEFINE_ACTION("time-zoom-out", Gtk::StockID("gtk-zoom-out")); + DEFINE_ACTION("jump-next-keyframe", _("Jump to Next Keyframe")); + DEFINE_ACTION("jump-prev-keyframe", _("Jump to Prev Keyframe")); + DEFINE_ACTION("seek-next-frame", _("Next Frame")); + DEFINE_ACTION("seek-prev-frame", _("Prev Frame")); + DEFINE_ACTION("seek-next-second", _("Seek Forward")); + DEFINE_ACTION("seek-prev-second", _("Seek Backward")); + DEFINE_ACTION("seek-begin", _("Seek to Begin")); + DEFINE_ACTION("seek-end", _("Seek to End")); + + DEFINE_ACTION("action-group_add", _("Add group")); + + DEFINE_ACTION("canvas-new", _("New Canvas")); + + DEFINE_ACTION("amount-inc", _("Increase Amount")); + DEFINE_ACTION("amount-dec", _("Decrease Amount")); + +#undef DEFINE_ACTION + + +// Set up sinfgapp actions + /*{ + sinfgapp::Action::Book::iterator iter; + + for(iter=sinfgapp::Action::book().begin();iter!=sinfgapp::Action::book().end();++iter) + { + Gtk::StockID stock_id; + + if(!(iter->second.category&sinfgapp::Action::CATEGORY_HIDDEN)) + { + //Gtk::Image* image(manage(new Gtk::Image())); + if(iter->second.task=="raise") stock_id=Gtk::Stock::GO_UP; + else if(iter->second.task=="lower") stock_id=Gtk::Stock::GO_DOWN; + else if(iter->second.task=="move_top") stock_id=Gtk::Stock::GOTO_TOP; + else if(iter->second.task=="move_bottom") stock_id=Gtk::Stock::GOTO_BOTTOM; + else if(iter->second.task=="remove") stock_id=Gtk::Stock::DELETE; + else if(iter->second.task=="set_on") stock_id=Gtk::Stock::YES; + else if(iter->second.task=="set_off") stock_id=Gtk::Stock::NO; + //else if(iter->second.task=="duplicate") stock_id=Gtk::Stock::COPY; + else if(iter->second.task=="remove") stock_id=Gtk::Stock::DELETE; + else stock_id=Gtk::StockID("sinfg-"+iter->second.task); + + actions_action_group->add(Gtk::Action::create( + "action-"+iter->second.name, + stock_id, + iter->second.local_name,iter->second.local_name + )); + } + } + } +*/ + + + Glib::ustring ui_info = +"" +" " +" " +" " +" " +" " +" " +" " +" " +" " +" " +" " +" " +" " +" " +" " +" " +" " +" " +" " +" " +" " +" " +" " +" " +" " +" " +" " +" " +" " +" " +" " +" " +" " +" " +" " +" " +" " +" " +" " +" " +" " +" " +" " +" " +" " +" " +" " +" " +" " +" " +" " +" " +" " +" " +" " +" " +" " +" " +" " +" " +" " +" " +" " +" " +" " +" " +" " +" " +" " +" " +" " +" " +" " +" " +" " +" " +" " +" " +" " +" " +" " +" " +" " +" " +" " +" " +" " +" " +" " +" " + " " + " " +" " +" " +" " +" " +" " +" " +" " +//" " +//" " +//" " +//" " +" " +" " +" " +" " +" " +" " + +"" +; +/* "" + " " + " " + " " + " " + " " + " " + " " + " " + " " + " " + " " + " " + " " + " " + " " + " " + " " + ""; +*/ + try + { + actions_action_group->set_sensitive(false); + App::ui_manager()->set_add_tearoffs(true); + App::ui_manager()->insert_action_group(menus_action_group,1); + App::ui_manager()->insert_action_group(actions_action_group,1); + App::ui_manager()->add_ui_from_string(ui_info); + + //App::ui_manager()->get_accel_group()->unlock(); + } + catch(const Glib::Error& ex) + { + sinfg::error("building menus and toolbars failed: " + ex.what()); + } + + // Add default keyboard accelerators +#define ACCEL(path,accel) { Gtk::AccelKey accel_key(accel,path); Gtk::AccelMap::add_entry(accel_key.get_path(), accel_key.get_key(),accel_key.get_mod()); } +#define ACCEL2(accel) { Gtk::AccelKey accel_key(accel); Gtk::AccelMap::add_entry(accel_key.get_path(), accel_key.get_key(),accel_key.get_mod()); } + ACCEL("//select-all-ducks","a"); + ACCEL("//unselect-all-layers","d"); + ACCEL("//render","F9"); + ACCEL("//preview","F11"); + ACCEL("//properties","F8"); + ACCEL("//options","F12"); + ACCEL("//import","i"); + ACCEL2(Gtk::AccelKey(GDK_Escape,static_cast(0),"//stop")); + ACCEL("//toggle-grid-show","g"); + ACCEL("//toggle-grid-snap","l"); + ACCEL2(Gtk::AccelKey('`',Gdk::CONTROL_MASK,"//toggle-low-res")); + ACCEL("//mask-position-ducks", "1"); + ACCEL("//mask-vertex-ducks", "2"); + ACCEL("//mask-tangent-ducks", "3"); + ACCEL("//mask-radius-ducks", "4"); + ACCEL("//mask-width-ducks", "5"); + ACCEL("//mask-angle-ducks", "6"); + + + ACCEL2(Gtk::AccelKey(GDK_Page_Up,Gdk::SHIFT_MASK,"//action-layer_raise")); + ACCEL2(Gtk::AccelKey(GDK_Page_Down,Gdk::SHIFT_MASK,"//action-layer_lower")); + + ACCEL("//quality-01","1"); + ACCEL("//quality-02","2"); + ACCEL("//quality-03","3"); + ACCEL("//quality-04","4"); + ACCEL("//quality-05","5"); + ACCEL("//quality-06","6"); + ACCEL("//quality-07","7"); + ACCEL("//quality-08","8"); + ACCEL("//quality-09","9"); + ACCEL("//quality-10","0"); + ACCEL("//undo","z"); + ACCEL("//redo","r"); + ACCEL("//action-layer_remove","Delete"); + +/* ACCEL2(Gtk::AccelKey(']',static_cast(0),"//jump-next-keyframe")); + ACCEL2(Gtk::AccelKey('[',static_cast(0),"//jump-prev-keyframe")); + ACCEL2(Gtk::AccelKey('=',static_cast(0),"//canvas-zoom-in")); + ACCEL2(Gtk::AccelKey('-',static_cast(0),"//canvas-zoom-out")); + ACCEL("//time-zoom-in","+"); + ACCEL("//time-zoom-out","_"); +*/ + ACCEL2(Gtk::AccelKey('(',Gdk::MOD1_MASK|Gdk::CONTROL_MASK,"//amount-dec")); + ACCEL2(Gtk::AccelKey(')',Gdk::MOD1_MASK|Gdk::CONTROL_MASK,"//amount-inc")); + + ACCEL2(Gtk::AccelKey(']',Gdk::CONTROL_MASK,"//jump-next-keyframe")); + ACCEL2(Gtk::AccelKey('[',Gdk::CONTROL_MASK,"//jump-prev-keyframe")); + ACCEL2(Gtk::AccelKey('=',Gdk::CONTROL_MASK,"//canvas-zoom-in")); + ACCEL2(Gtk::AccelKey('-',Gdk::CONTROL_MASK,"//canvas-zoom-out")); + ACCEL2(Gtk::AccelKey('+',Gdk::CONTROL_MASK,"//time-zoom-in")); + ACCEL2(Gtk::AccelKey('_',Gdk::CONTROL_MASK,"//time-zoom-out")); + ACCEL2(Gtk::AccelKey('.',Gdk::CONTROL_MASK,"//seek-next-frame")); + ACCEL2(Gtk::AccelKey(',',Gdk::CONTROL_MASK,"//seek-prev-frame")); + ACCEL2(Gtk::AccelKey('>',Gdk::CONTROL_MASK,"//seek-next-second")); + ACCEL2(Gtk::AccelKey('<',Gdk::CONTROL_MASK,"//seek-prev-second")); + ACCEL2(Gtk::AccelKey('o',Gdk::CONTROL_MASK,"//toggle-onion-skin")); + ACCEL("//seek-begin","Home"); + ACCEL("//seek-end","End"); + ACCEL("//state-normal","a"); + ACCEL("//state-rotate","s"); + ACCEL("//state-scale","d"); + ACCEL("//state-bline","b"); + ACCEL("//state-fill","f"); + ACCEL("//state-eyedrop","e"); + ACCEL("//state-gradient","g"); + ACCEL("//state-zoom","z"); + ACCEL("//canvas-zoom-fit","z"); + +#undef ACCEL +} + +#ifdef _WIN32 +#define mkdir(x,y) mkdir(x) +#endif + +/* === M E T H O D S ======================================================= */ + +App::App(int *argc, char ***argv): + Gtk::Main(argc,argv), + IconControler(etl::dirname((*argv)[0])) +{ + app_base_path_=etl::dirname(etl::dirname((*argv)[0])); + + int serial_; + serial_=check_license(app_base_path_); + + + ui_interface_=new GlobalUIInterface(); + + gdk_rgb_init(); + + Glib::thread_init(); + + distance_system=Distance::SYSTEM_UNITS; + + if(mkdir(get_user_app_directory().c_str(),ACCESSPERMS)<0) + { + if(errno!=EEXIST) + sinfg::error("UNABLE TO CREATE \"%s\"",get_user_app_directory().c_str()); + } + else + { + sinfg::info("Created directory \"%s\"",get_user_app_directory().c_str()); + } + + + ipc=new IPC(); + + try + { + if(!SINFG_CHECK_VERSION()) + { + cerr<<"FATAL: Sinfg Version Mismatch"<(new sinfgapp::Main(etl::dirname((*argv)[0]),&sinfg_init_cb)); } + catch(...) + { + get_ui_interface()->error("Failed to initialize sinfg!"); + throw; + } + + // add the preferences to the settings + sinfgapp::Main::settings().add_domain(&_preferences,"pref"); + + try + { + studio_init_cb.task("Init UI Manager..."); + App::ui_manager_=studio::UIManager::create(); + init_ui_manager(); + + studio_init_cb.task("Init Dock Manager..."); + dock_manager=new studio::DockManager(); + + studio_init_cb.task("Init State Manager..."); + state_manager=new StateManager(); + + studio_init_cb.task("Init Toolbox..."); + toolbox=new studio::Toolbox(); + + studio_init_cb.task("Init Tool Options..."); + dialog_tool_options=new studio::Dialog_ToolOptions(); + dock_manager->register_dockable(*dialog_tool_options); + + studio_init_cb.task("Init History..."); + dock_history=new studio::Dock_History(); + dock_manager->register_dockable(*dock_history); + + studio_init_cb.task("Init Canvases..."); + dock_canvases=new studio::Dock_Canvases(); + dock_manager->register_dockable(*dock_canvases); + + studio_init_cb.task("Init Keyframes..."); + dock_keyframes=new studio::Dock_Keyframes(); + dock_manager->register_dockable(*dock_keyframes); + + studio_init_cb.task("Init Layers..."); + dock_layers=new studio::Dock_Layers(); + dock_manager->register_dockable(*dock_layers); + + studio_init_cb.task("Init Params..."); + dock_params=new studio::Dock_Params(); + dock_manager->register_dockable(*dock_params); + + studio_init_cb.task("Init MetaData..."); + dock_meta_data=new studio::Dock_MetaData(); + dock_manager->register_dockable(*dock_meta_data); + + studio_init_cb.task("Init Children..."); + dock_children=new studio::Dock_Children(); + dock_manager->register_dockable(*dock_children); + + studio_init_cb.task("Init Info..."); + dock_info = new studio::Dock_Info(); + dock_manager->register_dockable(*dock_info); + + studio_init_cb.task("Init Navigator..."); + dock_navigator = new studio::Dock_Navigator(); + dock_manager->register_dockable(*dock_navigator); + + studio_init_cb.task("Init Timetrack..."); + dock_timetrack = new studio::Dock_Timetrack(); + dock_manager->register_dockable(*dock_timetrack); + + studio_init_cb.task("Init Curve Editor..."); + dock_curves = new studio::Dock_Curves(); + dock_manager->register_dockable(*dock_curves); + + studio_init_cb.task("Init Layer Groups..."); + dock_layer_groups = new studio::Dock_LayerGroups(); + dock_manager->register_dockable(*dock_layer_groups); + + + studio_init_cb.task("Init Color Dialog..."); + dialog_color=new studio::Dialog_Color(); + + studio_init_cb.task("Init Gradient Dialog..."); + dialog_gradient=new studio::Dialog_Gradient(); + + studio_init_cb.task("Init DeviceTracker..."); + device_tracker=new studio::DeviceTracker(); + + studio_init_cb.task("Init Tools..."); + state_manager->add_state(&state_normal); + state_manager->add_state(&state_smooth_move); + state_manager->add_state(&state_scale); + state_manager->add_state(&state_rotate); + + state_manager->add_state(&state_bline); + state_manager->add_state(&state_polygon); + state_manager->add_state(&state_circle); + state_manager->add_state(&state_rectangle); + + state_manager->add_state(&state_draw); + state_manager->add_state(&state_sketch); + + state_manager->add_state(&state_eyedrop); + state_manager->add_state(&state_fill); + + state_manager->add_state(&state_width); + state_manager->add_state(&state_gradient); + + state_manager->add_state(&state_zoom); + + studio_init_cb.task("Init ModPalette..."); + module_list_.push_back(new ModPalette()); module_list_.back()->start(); + + studio_init_cb.task("Init ModMirror..."); + module_list_.push_back(new ModMirror()); module_list_.back()->start(); + + + studio_init_cb.task("Init Setup Dialog..."); + dialog_setup=new studio::Dialog_Setup(); + + studio_init_cb.task("Init Input Dialog..."); + dialog_input=new Gtk::InputDialog(); + + studio_init_cb.task("Init auto recovery..."); + auto_recover=new AutoRecover(); + + studio_init_cb.amount_complete(9250,10000); + studio_init_cb.task("Loading Settings..."); + load_settings(); + studio_init_cb.task("Checking auto-recover..."); + + studio_init_cb.amount_complete(9900,10000); + + if(auto_recover->recovery_needed()) + { + about_window.hide(); + if( + get_ui_interface()->yes_no( + "Auto Recovery", + "SINFG Studio seems to have crashed\n" + "before you could save all your files.\n" + "Would you like to re-open those files\n" + "and recover your unsaved changes?" + )==sinfgapp::UIInterface::RESPONSE_YES + ) + { + if(!auto_recover->recover()) + { + get_ui_interface()->error(_("Unable to fully recover from previous crash")); + } + else + get_ui_interface()->error( + _("SINFG Studio has attempted to recover\n" + "from a previous crash. The files that it has\n" + "recovered are NOT YET SAVED. It would be a good\n" + "idea to review them and save them now.") + ); + } + about_window.show(); + } + + // Look for any files given on the command line, + // and load them if found. + for(;*argc>=1;(*argc)--) + if((*argv)[*argc] && (*argv)[*argc][0]!='-') + { + studio_init_cb.task("Loading files..."); + about_window.hide(); + open((*argv)[*argc]); + about_window.show(); + } + + studio_init_cb.task("Done."); + studio_init_cb.amount_complete(10000,10000); + + toolbox->present(); + } + catch(...) + { + get_ui_interface()->error(_("Unknown exception caught when constructing App.\nThis software may be unstable.")); + } +} + +StateManager* App::get_state_manager() { return state_manager; } + +App::~App() +{ + shutdown_in_progress=true; + + save_settings(); + + sinfgapp::Main::settings().remove_domain("pref"); + + selected_instance=0; + + // Unload all of the modules + for(;!module_list_.empty();module_list_.pop_back()); + + delete state_manager; + + delete ipc; + + delete auto_recover; + + toolbox->hide(); + +// studio::App::iteration(false); + + delete toolbox; + +// studio::App::iteration(false); + +// studio::App::iteration(false); + + delete dialog_setup; + + delete dialog_gradient; + + delete dialog_color; + + delete dialog_input; + + delete dock_manager; + + instance_list.clear(); + +// studio::App::iteration(false); +} + +String +App::get_user_app_directory() +{ + return Glib::build_filename(Glib::get_home_dir(),"sinfg"); +} + +sinfg::String +App::get_config_file(const sinfg::String& file) +{ + return Glib::build_filename(get_user_app_directory(),file); +} + +void +App::add_recent_file(const std::string &file_name) +{ + std::string filename(file_name); + + assert(!filename.empty()); + + if(filename.empty()) + return; + + // Toss out any "hidden" files + if(basename(filename)[0]=='.') + return; + + // If we aren't an absolute path, turn outselves into one + if(!is_absolute_path(filename)) + filename=absolute_path(filename); + + list::iterator iter; + // Check to see if the file is already on the list. + // If it is, then remove it from the list + for(iter=recent_files.begin();iter!=recent_files.end();iter++) + if(*iter==filename) + { + recent_files.erase(iter); + break; + } + + + // Push the filename to the front of the list + recent_files.push_front(filename); + + // Clean out the files at the end of the list. + while(recent_files.size()>(unsigned)get_max_recent_files()) + recent_files.pop_back(); + + signal_recent_files_changed_(); + + return; +} + +static Time::Format _App_time_format(Time::FORMAT_NORMAL); + +Time::Format +App::get_time_format() +{ + return _App_time_format; +} + +void +App::set_time_format(sinfg::Time::Format x) +{ + _App_time_format=x; +} + + +void +App::save_settings() +{ + try + { + { + std::string filename=get_config_file("accelrc"); + Gtk::AccelMap::save(filename); + } + do{ + std::string filename=get_config_file("recentfiles"); + + std::ofstream file(filename.c_str()); + + if(!file) + { + sinfg::warning("Unable to save %s",filename.c_str()); + break; + } + + list::reverse_iterator iter; + + for(iter=recent_files.rbegin();iter!=recent_files.rend();iter++) + file<<*iter<task("Quit Request"); + if(Busy::count) + { + dialog_error_blocking("Cannot quit!","Tasks are currently running.\nPlease cancel the current tasks and try again"); + return; + } + + std::list >::iterator iter; + for(iter=instance_list.begin();!instance_list.empty();iter=instance_list.begin()) + { + if(!(*iter)->safe_close()) + return; + +/* + if((*iter)->sinfgapp::Instance::get_action_count()) + { + handle uim; + uim=(*iter)->find_canvas_view((*iter)->get_canvas())->get_ui_interface(); + assert(uim); + string str=strprintf(_("Would you like to save your changes to %s?"),(*iter)->get_file_name().c_str() ); + switch(uim->yes_no_cancel((*iter)->get_canvas()->get_name(),str,sinfgapp::UIInterface::RESPONSE_YES)) + { + case sinfgapp::UIInterface::RESPONSE_NO: + break; + case sinfgapp::UIInterface::RESPONSE_YES: + (*iter)->save(); + break; + case sinfgapp::UIInterface::RESPONSE_CANCEL: + return; + default: + assert(0); + return; + } + } + + + if((*iter)->sinfgapp::Instance::is_modified()) + { + handle uim; + uim=(*iter)->find_canvas_view((*iter)->get_canvas())->get_ui_interface(); + assert(uim); + string str=strprintf(_("%s has changes not yet on the CVS repository.\nWould you like to commit these changes?"),(*iter)->get_file_name().c_str() ); + switch(uim->yes_no_cancel((*iter)->get_canvas()->get_name(),str,sinfgapp::UIInterface::RESPONSE_YES)) + { + case sinfgapp::UIInterface::RESPONSE_NO: + break; + case sinfgapp::UIInterface::RESPONSE_YES: + (*iter)->dialog_cvs_commit(); + break; + case sinfgapp::UIInterface::RESPONSE_CANCEL: + return; + default: + assert(0); + return; + } + } +*/ + + // This next line causes things to crash for some reason + //(*iter)->close(); + } + + shutdown_in_progress=true; + + instance_list.clear(); + + while(studio::App::events_pending())studio::App::iteration(false); + + Gtk::Main::quit(); + auto_recover->normal_shutdown(); + + get_ui_interface()->task("Quit Request sent"); +} + +void +App::show_setup() +{ + dialog_setup->refresh(); + dialog_setup->show(); +} + +gint Signal_Open_Ok(GtkWidget *widget, int *val){*val=1;return 0;} +gint Signal_Open_Cancel(GtkWidget *widget, int *val){*val=2;return 0;} + +//#ifdef WIN32 +//#define USE_WIN32_FILE_DIALOGS 1 +//#endif + +#ifdef USE_WIN32_FILE_DIALOGS +static OPENFILENAME ofn={}; +#endif + +#ifdef WIN32 +#include +#endif + +bool +App::dialog_open_file(const std::string &title, std::string &filename) +{ +#ifdef USE_WIN32_FILE_DIALOGS + static TCHAR szFilter[] = TEXT ("All Files (*.*)\0*.*\0\0") ; + + GdkWindow *gdkWinPtr=toolbox->get_window()->gobj(); + HINSTANCE hInstance=static_cast(GetModuleHandle(NULL)); + HWND hWnd=static_cast(GDK_WINDOW_HWND(gdkWinPtr)); + + ofn.lStructSize=sizeof(OPENFILENAME); + ofn.hwndOwner = hWnd; + ofn.hInstance = hInstance; + ofn.lpstrFilter = szFilter; +// ofn.lpstrCustomFilter=NULL; +// ofn.nMaxCustFilter=0; +// ofn.nFilterIndex=0; +// ofn.lpstrFile=NULL; + ofn.nMaxFile=MAX_PATH; +// ofn.lpstrFileTitle=NULL; +// ofn.lpstrInitialDir=NULL; +// ofn.lpstrTitle=NULL; + ofn.Flags=OFN_HIDEREADONLY; +// ofn.nFileOffset=0; +// ofn.nFileExtension=0; + ofn.lpstrDefExt=TEXT("sif"); +// ofn.lCustData = 0l; + ofn.lpfnHook=NULL; +// ofn.lpTemplateName=NULL; + + CHAR szFilename[MAX_PATH]; + CHAR szTitle[500]; + strcpy(szFilename,filename.c_str()); + strcpy(szTitle,title.c_str()); + + ofn.lpstrFile=szFilename; + ofn.lpstrFileTitle=szTitle; + + if(GetOpenFileName(&ofn)) + { + filename=szFilename; + return true; + } + return false; + +#else + sinfg::String prev_path; + if(!_preferences.get_value("curr_path",prev_path)) + prev_path="."; + + GtkWidget *ok; + GtkWidget *cancel; + int val=0; + + GtkWidget *fileselection; + fileselection = gtk_file_selection_new(title.c_str()); + + + if(basename(filename)==filename) + { + gtk_file_selection_set_filename(GTK_FILE_SELECTION(fileselection),(prev_path+ETL_DIRECTORY_SEPERATOR).c_str()); + } + else + gtk_file_selection_set_filename(GTK_FILE_SELECTION(fileselection),dirname(filename).c_str()); + + gtk_file_selection_complete(GTK_FILE_SELECTION(fileselection),basename(filename).c_str()); + + ok=GTK_FILE_SELECTION(fileselection)->ok_button; + cancel=GTK_FILE_SELECTION(fileselection)->cancel_button; + + gtk_signal_connect(GTK_OBJECT(ok),"clicked",GTK_SIGNAL_FUNC(Signal_Open_Ok),&val); + gtk_signal_connect(GTK_OBJECT(cancel),"clicked",GTK_SIGNAL_FUNC(Signal_Open_Cancel),&val); + + gtk_widget_show(fileselection); + + while(!val) + iteration(); + + + if(val==1) + { + filename=gtk_file_selection_get_filename(GTK_FILE_SELECTION(fileselection)); + _preferences.set_value("curr_path",dirname(filename)); + } + else + { + gtk_widget_destroy(fileselection); + return false; + } + gtk_widget_destroy(fileselection); + return true; +#endif +} + +bool +App::dialog_save_file(const std::string &title, std::string &filename) +{ +#ifdef USE_WIN32_FILE_DIALOGS + static TCHAR szFilter[] = TEXT ("All Files (*.*)\0*.*\0\0") ; + + GdkWindow *gdkWinPtr=toolbox->get_window()->gobj(); + HINSTANCE hInstance=static_cast(GetModuleHandle(NULL)); + HWND hWnd=static_cast(GDK_WINDOW_HWND(gdkWinPtr)); + + ofn.lStructSize=sizeof(OPENFILENAME); + ofn.hwndOwner = hWnd; + ofn.hInstance = hInstance; + ofn.lpstrFilter = szFilter; +// ofn.lpstrCustomFilter=NULL; +// ofn.nMaxCustFilter=0; +// ofn.nFilterIndex=0; +// ofn.lpstrFile=NULL; + ofn.nMaxFile=MAX_PATH; +// ofn.lpstrFileTitle=NULL; +// ofn.lpstrInitialDir=NULL; +// ofn.lpstrTitle=NULL; + ofn.Flags=OFN_OVERWRITEPROMPT; +// ofn.nFileOffset=0; +// ofn.nFileExtension=0; + ofn.lpstrDefExt=TEXT("sif"); +// ofn.lCustData = 0l; + ofn.lpfnHook=NULL; +// ofn.lpTemplateName=NULL; + + CHAR szFilename[MAX_PATH]; + CHAR szTitle[500]; + strcpy(szFilename,filename.c_str()); + strcpy(szTitle,title.c_str()); + + ofn.lpstrFile=szFilename; + ofn.lpstrFileTitle=szTitle; + + if(GetSaveFileName(&ofn)) + { + filename=szFilename; + return true; + } + return false; +#else + return dialog_open_file(title, filename); +#endif +} + +bool +App::dialog_saveas_file(const std::string &title, std::string &filename) +{ +#if USE_WIN32_FILE_DIALOGS + static TCHAR szFilter[] = TEXT ("All Files (*.*)\0*.*\0\0") ; + + GdkWindow *gdkWinPtr=toolbox->get_window()->gobj(); + HINSTANCE hInstance=static_cast(GetModuleHandle(NULL)); + HWND hWnd=static_cast(GDK_WINDOW_HWND(gdkWinPtr)); + + ofn.lStructSize=sizeof(OPENFILENAME); + ofn.hwndOwner = hWnd; + ofn.hInstance = hInstance; + ofn.lpstrFilter = szFilter; +// ofn.lpstrCustomFilter=NULL; +// ofn.nMaxCustFilter=0; +// ofn.nFilterIndex=0; +// ofn.lpstrFile=NULL; + ofn.nMaxFile=MAX_PATH; +// ofn.lpstrFileTitle=NULL; +// ofn.lpstrInitialDir=NULL; +// ofn.lpstrTitle=NULL; + ofn.Flags=OFN_OVERWRITEPROMPT; +// ofn.nFileOffset=0; +// ofn.nFileExtension=0; + ofn.lpstrDefExt=TEXT("sif"); +// ofn.lCustData = 0l; + ofn.lpfnHook=NULL; +// ofn.lpTemplateName=NULL; + + CHAR szFilename[MAX_PATH]; + CHAR szTitle[500]; + strcpy(szFilename,filename.c_str()); + strcpy(szTitle,title.c_str()); + + ofn.lpstrFile=szFilename; + ofn.lpstrFileTitle=szTitle; + + if(GetSaveFileName(&ofn)) + { + filename=szFilename; + return true; + } + return false; +#else + return dialog_open_file(title, filename); +#endif +} + +void +App::dialog_error_blocking(const std::string &title, const std::string &message) +{ + Gtk::Dialog dialog( + title, // Title + true, // Modal + true // use_separator + ); + Gtk::Label label(message); + label.show(); + + dialog.get_vbox()->pack_start(label); + dialog.add_button(Gtk::StockID("gtk-ok"),1); + dialog.show(); + dialog.run(); +} + +void +App::dialog_warning_blocking(const std::string &title, const std::string &message) +{ + Gtk::Dialog dialog( + title, // Title + true, // Modal + true // use_separator + ); + Gtk::Label label(message); + label.show(); + + dialog.get_vbox()->pack_start(label); + dialog.add_button(Gtk::StockID("gtk-ok"),1); + dialog.show(); + dialog.run(); +} + +bool +App::dialog_yes_no(const std::string &title, const std::string &message) +{ + Gtk::Dialog dialog( + title, // Title + true, // Modal + true // use_separator + ); + Gtk::Label label(message); + label.show(); + + dialog.get_vbox()->pack_start(label); + dialog.add_button(Gtk::StockID("gtk-yes"),1); + dialog.add_button(Gtk::StockID("gtk-no"),0); + dialog.show(); + return dialog.run(); +} + +int +App::dialog_yes_no_cancel(const std::string &title, const std::string &message) +{ + Gtk::Dialog dialog( + title, // Title + true, // Modal + true // use_separator + ); + Gtk::Label label(message); + label.show(); + + dialog.get_vbox()->pack_start(label); + dialog.add_button(Gtk::StockID("gtk-yes"),1); + dialog.add_button(Gtk::StockID("gtk-no"),0); + dialog.add_button(Gtk::StockID("gtk-cancel"),2); + dialog.show(); + return dialog.run(); +} + +void +App::dialog_not_implemented() +{ + Gtk::Dialog dialog( + "Feature not available", // Title + true, // Modal + true // use_separator + ); + Gtk::Label label("Sorry, this feature has not yet been implemented."); + label.show(); + + dialog.get_vbox()->pack_start(label); + dialog.add_button(Gtk::StockID("gtk-ok"),Gtk::RESPONSE_OK); + dialog.show(); + dialog.run(); +} + +bool +App::dialog_entry(const std::string &title, const std::string &message,std::string &text) +{ + Gtk::Dialog dialog( + title, // Title + true, // Modal + true // use_separator + ); + Gtk::Label label(message); + label.show(); + dialog.get_vbox()->pack_start(label); + + Gtk::Entry entry; + entry.set_text(text); + entry.show(); + entry.set_activates_default(true); + dialog.get_vbox()->pack_start(entry); + + dialog.add_button(Gtk::StockID("gtk-ok"),Gtk::RESPONSE_OK); + dialog.add_button(Gtk::StockID("gtk-cancel"),Gtk::RESPONSE_CANCEL); + dialog.set_default_response(Gtk::RESPONSE_OK); + entry.signal_activate().connect(sigc::bind(sigc::mem_fun(dialog,&Gtk::Dialog::response),Gtk::RESPONSE_OK)); + dialog.show(); + + if(dialog.run()!=Gtk::RESPONSE_OK) + return false; + + text=entry.get_text(); + + return true; +} + + + + +bool +App::open(std::string filename) +{ + return open_as(filename,filename); +} + +bool +App::open_as(std::string filename,std::string as) +{ + try + { + OneMoment one_moment; + + etl::handle canvas(open_canvas_as(filename,as)); + if(canvas && get_instance(canvas)) + { + get_instance(canvas)->find_canvas_view(canvas)->present(); + throw (String)strprintf(_("\"%s\" appears to already be open!"),filename.c_str()); + } + if(!canvas) + throw (String)strprintf(_("Unable to open file \"%s\""),filename.c_str()); + + add_recent_file(as); + + handle instance(Instance::create(canvas)); + + if(!instance) + throw (String)strprintf(_("Unable to create instance for \"%s\""),filename.c_str()); + + one_moment.hide(); + + if(instance->is_updated() && App::dialog_yes_no(_("CVS Update"), _("There appears to be a newer version of this file available on the CVS repository.\nWould you like to update now? (It would probably be a good idea)"))) + instance->dialog_cvs_update(); + } + catch(String x) + { + dialog_error_blocking(_("Error"), x); + return false; + } + catch(...) + { + dialog_error_blocking(_("Error"), _("Uncaught error on file open (BUG)")); + return false; + } + + _preferences.set_value("curr_path",dirname(as)); + + return true; +} + + +void +App::new_instance() +{ + handle canvas=sinfg::Canvas::create(); + canvas->set_name(strprintf("Untitled%d",Instance::get_count())); + + String file_name(strprintf("untitled%d.sif",Instance::get_count())); + + canvas->rend_desc().set_frame_rate(24.0); + canvas->rend_desc().set_time_start(0.0); + canvas->rend_desc().set_time_end(00.0); + canvas->rend_desc().set_x_res(DPI2DPM(72.0f)); + canvas->rend_desc().set_y_res(DPI2DPM(72.0f)); + canvas->rend_desc().set_tl(Vector(-4,2.25)); + canvas->rend_desc().set_br(Vector(4,-2.25)); + canvas->rend_desc().set_w(480); + canvas->rend_desc().set_h(270); + canvas->rend_desc().set_antialias(1); + canvas->rend_desc().set_flags(RendDesc::PX_ASPECT|RendDesc::IM_SPAN); + canvas->set_file_name(file_name); + + Instance::create(canvas)->find_canvas_view(canvas)->canvas_properties.present(); +} + +void +App::dialog_open() +{ + string filename="*.sif"; + + while(dialog_open_file("Open", filename)) + { + // If the filename still has wildcards, then we should + // continue looking for the file we want + if(find(filename.begin(),filename.end(),'*')!=filename.end()) + continue; + + if(open(filename)) + break; + + get_ui_interface()->error(_("Unable to open file")); + } +} + +void +App::set_selected_instance(etl::loose_handle instance) +{ +/* if(get_selected_instance()==instance) + { + selected_instance=instance; + signal_instance_selected()(instance); + return; + } + else + { +*/ + selected_instance=instance; + if(get_selected_canvas_view() && get_selected_canvas_view()->get_instance()!=instance) + { + if(instance) + { + instance->focus(instance->get_canvas()); + } + else + set_selected_canvas_view(0); + } + signal_instance_selected()(instance); +} + +void +App::set_selected_canvas_view(etl::loose_handle canvas_view) +{ + selected_canvas_view=canvas_view; + signal_canvas_view_focus()(selected_canvas_view); + if(canvas_view) + { + selected_instance=canvas_view->get_instance(); + signal_instance_selected()(canvas_view->get_instance()); + } +/* + if(get_selected_canvas_view()==canvas_view) + { + signal_canvas_view_focus()(selected_canvas_view); + signal_instance_selected()(canvas_view->get_instance()); + return; + } + selected_canvas_view=canvas_view; + if(canvas_view && canvas_view->get_instance() != get_selected_instance()) + set_selected_instance(canvas_view->get_instance()); + signal_canvas_view_focus()(selected_canvas_view); +*/ +} + +etl::loose_handle +App::get_instance(Canvas::Handle canvas) +{ + if(!canvas) return 0; + canvas=canvas->get_root(); + + std::list >::iterator iter; + for(iter=instance_list.begin();iter!=instance_list.end();++iter) + { + if((*iter)->get_canvas()==canvas) + return *iter; + } + return 0; +} + +void +App::dialog_about() +{ + (new class About())->show(); +} + +void +studio::App::undo() +{ + if(selected_instance) + selected_instance->undo(); +} + +void +studio::App::redo() +{ + if(selected_instance) + selected_instance->redo(); +} + +sinfg::String +studio::App::get_base_path() +{ + return app_base_path_; +} diff --git a/synfig-studio/trunk/src/gtkmm/app.h b/synfig-studio/trunk/src/gtkmm/app.h new file mode 100644 index 0000000..decaaf8 --- /dev/null +++ b/synfig-studio/trunk/src/gtkmm/app.h @@ -0,0 +1,330 @@ +/* === S I N F G =========================================================== */ +/*! \file app.h +** \brief writeme +** +** $Id: app.h,v 1.2 2005/01/13 21:11:16 darco Exp $ +** +** \legal +** Copyright (c) 2002 Robert B. Quattlebaum Jr. +** +** This software and associated documentation +** are CONFIDENTIAL and PROPRIETARY property of +** the above-mentioned copyright holder. +** +** You may not copy, print, publish, or in any +** other way distribute this software without +** a prior written agreement with +** the copyright holder. +** \endlegal +*/ +/* ========================================================================= */ + +/* === S T A R T =========================================================== */ + +#ifndef __SINFG_STUDIO_APP_H +#define __SINFG_STUDIO_APP_H + +/* === H E A D E R S ======================================================= */ + +#include +#include + +#include +#include +#include + +#include + +#include +#include +#include + +#include + +#include +#include "iconcontroler.h" + +/* === M A C R O S ========================================================= */ + +/* === T Y P E D E F S ===================================================== */ + +/* === C L A S S E S & S T R U C T S ======================================= */ + +namespace Gtk +{ + class InputDialog; + class UIManager; + class ActionGroup; +}; + +namespace sinfgapp +{ + class UIInterface; + class Main; +}; + +class Preferences; + +namespace studio { + +typedef Gtk::UIManager UIManager; + +class Toolbox; +class Instance; +class CanvasView; +class Dialog_Setup; +class Dialog_Gradient; +class Dialog_Color; +class Dialog_ToolOptions; +class DeviceTracker; +class AutoRecover; + +class DockManager; + +class Dock_History; +class Dock_Canvases; + +class Dock_Keyframes; +class Dock_Params; +class Dock_Layers; +class Dock_MetaData; +class Dock_Children; +class Dock_Info; +class Dock_Navigator; +class Dock_LayerGroups; +class IPC; + +class Module; + +class StateManager; +class IconControler; + +class App : public Gtk::Main, private IconControler +{ + friend class Preferences; + friend class Dialog_Setup; + + /* + -- ** -- P U B L I C T Y P E S --------------------------------------------- + */ + +public: + + struct Busy + { + static int count; + Busy(){count++;} + ~Busy(){count--;} + }; + + + /* + -- ** -- P R I V A T E D A T A --------------------------------------------- + */ + +private: + //static etl::handle ui_interface_; + //static int max_recent_files; + +/* + static Dock_Keyframes *dock_keyframes; + static Dock_Layers *dock_layers; + static Dock_Params *dock_params; + static Dock_MetaData *dock_meta_data; + static Dock_Children *dock_children; + static Dock_Info *dock_info; + static Dock_Navigator *dock_navigator; + static Dock_History *dock_history; + static Dock_Canvases *dock_canvases; + static Dock_LayerGroups *dock_layer_groups; + + static IPC *ipc; +*/ + + etl::smart_ptr sinfgapp_main; + + + static etl::handle selected_instance; + static etl::handle selected_canvas_view; + + static Glib::RefPtr ui_manager_; + +// static std::list< etl::handle< Module > > module_list_; + + /* + -- ** -- P U B L I C D A T A ----------------------------------------------- + */ + +public: + static Gtk::InputDialog* dialog_input; + + static DeviceTracker* device_tracker; + static AutoRecover* auto_recover; + static DockManager* dock_manager; + + static DockManager* get_dock_manager() { return dock_manager; } + + static Dialog_Setup* dialog_setup; + static Dialog_Gradient* dialog_gradient; + static Dialog_Color* dialog_color; +// static Dialog_Palette* dialog_palette; + static Dialog_ToolOptions *dialog_tool_options; + + static sinfg::Distance::System distance_system; + + static sinfg::Gamma gamma; + + static Toolbox *toolbox; + + static std::list > instance_list; + + static bool shutdown_in_progress; + + static bool use_colorspace_gamma; + + /* + -- ** -- S I G N A L S ------------------------------------------------------- + */ +/* + static sigc::signal< + void, + etl::loose_handle + > signal_canvas_view_focus_; + static sigc::signal< + void, + etl::handle + > signal_instance_selected_; + static sigc::signal< + void, + etl::handle + > signal_instance_created_; + static sigc::signal< + void, + etl::handle + > signal_instance_deleted_; + static sigc::signal signal_recent_files_changed_; + static sigc::signal signal_present_all_; +*/ +public: + + static sigc::signal &signal_present_all(); + + static sigc::signal &signal_recent_files_changed(); + + static sigc::signal< + void, + etl::loose_handle + >& signal_canvas_view_focus(); + + static sigc::signal< + void, + etl::handle + > &signal_instance_selected(); + + static sigc::signal< + void, + etl::handle + > &signal_instance_created(); + + static sigc::signal< + void, + etl::handle + > &signal_instance_deleted(); + + /* + -- ** -- P R I V A T E M E T H O D S --------------------------------------- + */ + +private: + + /* + -- ** -- P U B L I C M E T H O D S ----------------------------------------- + */ + +public: + + App(int *argc, char ***argv); + virtual ~App(); + + /* + -- ** -- S T A T I C P U B L I C M E T H O D S --------------------------- + */ + +public: + + static StateManager* get_state_manager(); + + static Glib::RefPtr& ui_manager() { return ui_manager_; } + + static void add_recent_file(const std::string &filename); + + static sinfg::String get_base_path(); + static void save_settings(); + static void load_settings(); + + static const std::list& get_recent_files(); + + static const etl::handle& get_ui_interface(); + + + static void set_selected_instance(etl::loose_handle instance); + static void set_selected_canvas_view(etl::loose_handle); + + static etl::loose_handle get_instance(etl::handle canvas); + + static etl::loose_handle get_selected_instance() { return selected_instance; } + static etl::loose_handle get_selected_canvas_view() { return selected_canvas_view; } + + static bool open(std::string filename); + + static bool open_as(std::string filename,std::string as); + + static void new_instance(); + + static void dialog_open(); + + static void dialog_about(); + + static void quit(); + + static void show_setup(); + + static void undo(); + static void redo(); + + static int get_max_recent_files(); + static void set_max_recent_files(int x); + + + static sinfg::Time::Format get_time_format(); + static void set_time_format(sinfg::Time::Format x); + + static bool shutdown_request(GdkEventAny*bleh=NULL); + +// static bool dialog_file(const std::string &title, std::string &filename); + + static bool dialog_open_file(const std::string &title, std::string &filename); + static bool dialog_save_file(const std::string &title, std::string &filename); + static bool dialog_saveas_file(const std::string &title, std::string &filename); + + static void dialog_error_blocking(const std::string &title, const std::string &message); + + static void dialog_warning_blocking(const std::string &title, const std::string &message); + + static bool dialog_entry(const std::string &title, const std::string &message,std::string &text); + + static bool dialog_yes_no(const std::string &title, const std::string &message); + + static int dialog_yes_no_cancel(const std::string &title, const std::string &message); + + static void dialog_not_implemented(); + + static sinfg::String get_user_app_directory(); + static sinfg::String get_config_file(const sinfg::String& file); +}; // END of class App + +}; // END namespace studio + +/* === E N D =============================================================== */ + +#endif diff --git a/synfig-studio/trunk/src/gtkmm/asyncrenderer.cpp b/synfig-studio/trunk/src/gtkmm/asyncrenderer.cpp new file mode 100644 index 0000000..9c41444 --- /dev/null +++ b/synfig-studio/trunk/src/gtkmm/asyncrenderer.cpp @@ -0,0 +1,486 @@ +/* === S I N F G =========================================================== */ +/*! \file asyncrenderer.cpp +** \brief Template File +** +** $Id: asyncrenderer.cpp,v 1.5 2005/01/12 07:03:42 darco Exp $ +** +** \legal +** Copyright (c) 2002 Robert B. Quattlebaum Jr. +** +** This software and associated documentation +** are CONFIDENTIAL and PROPRIETARY property of +** the above-mentioned copyright holder. +** +** You may not copy, print, publish, or in any +** other way distribute this software without +** a prior written agreement with +** the copyright holder. +** \endlegal +*/ +/* ========================================================================= */ + +/* === H E A D E R S ======================================================= */ + +#ifdef USING_PCH +# include "pch.h" +#else +#ifdef HAVE_CONFIG_H +# include +#endif + +#include "asyncrenderer.h" +#include +#include + +#ifdef HAVE_UNISTD_H +#include +#endif + +#ifdef HAVE_SYS_TYPES_H +#include +#endif + +#ifdef HAVE_SYS_WAIT_H +#include +#endif + +#ifdef HAVE_SIGNAL_H +#include +#endif + +#include +#include + +#endif + +/* === U S I N G =========================================================== */ + +using namespace std; +using namespace etl; +using namespace sinfg; +using namespace studio; + +#define BOREDOM_TIMEOUT 50 + +#define REJOIN_ON_STOP 1 + +// The Glib::Dispatcher class is broken as of Glibmm 2.4.5. +// Defining this macro enables the workaround. +#define GLIB_DISPATCHER_BROKEN 1 + +/* === C L A S S E S ======================================================= */ + +class AsyncTarget_Tile : public sinfg::Target_Tile +{ +public: + etl::handle warm_target; + + struct tile_t + { + Surface surface; + int x,y; + tile_t(const Surface& surface,int x, int y): + surface(surface), + x(x),y(y) + { + } + }; + std::list tile_queue; + Glib::Mutex mutex; + +#ifndef GLIB_DISPATCHER_BROKEN + Glib::Dispatcher tile_ready_signal; +#endif + Glib::Cond cond_tile_queue_empty; + bool alive_flag; + + sigc::connection ready_connection; + +public: + AsyncTarget_Tile(etl::handle warm_target): + warm_target(warm_target) + { + set_avoid_time_sync(warm_target->get_avoid_time_sync()); + set_tile_w(warm_target->get_tile_w()); + set_tile_h(warm_target->get_tile_h()); + set_canvas(warm_target->get_canvas()); + set_quality(warm_target->get_quality()); + set_remove_alpha(warm_target->get_remove_alpha()); + set_threads(warm_target->get_threads()); + set_clipping(warm_target->get_clipping()); + set_rend_desc(&warm_target->rend_desc()); + alive_flag=true; +#ifndef GLIB_DISPATCHER_BROKEN + ready_connection=tile_ready_signal.connect(sigc::mem_fun(*this,&AsyncTarget_Tile::tile_ready)); +#endif + } + + ~AsyncTarget_Tile() + { + ready_connection.disconnect(); + } + void set_dead() + { + Glib::Mutex::Lock lock(mutex); + alive_flag=false; + } + + virtual int total_tiles()const + { + return warm_target->total_tiles(); + } + + virtual int next_tile(int& x, int& y) + { + if(!alive_flag) + return 0; + + return warm_target->next_tile(x,y); + } + + virtual int next_frame(Time& time) + { + if(!alive_flag) + return 0; + return warm_target->next_frame(time); + } + + virtual bool start_frame(sinfg::ProgressCallback *cb=0) + { + if(!alive_flag) + return false; + return warm_target->start_frame(cb); + } + + virtual bool add_tile(const sinfg::Surface &surface, int gx, int gy) + { + assert(surface); + if(!alive_flag) + return false; + Glib::Mutex::Lock lock(mutex); + tile_queue.push_back(tile_t(surface,gx,gy)); + if(tile_queue.size()==1) + { +#ifdef GLIB_DISPATCHER_BROKEN + ready_connection=Glib::signal_timeout().connect( + sigc::bind_return( + sigc::mem_fun(*this,&AsyncTarget_Tile::tile_ready), + false + ) + ,0 + ); +#else + tile_ready_signal(); +#endif + } + + return alive_flag; + } + + void tile_ready() + { + Glib::Mutex::Lock lock(mutex); + if(!alive_flag) + { + tile_queue.clear(); + cond_tile_queue_empty.signal(); + return; + } + while(!tile_queue.empty() && alive_flag) + { + tile_t& tile(tile_queue.front()); + + alive_flag=warm_target->add_tile(tile.surface,tile.x,tile.y); + + tile_queue.pop_front(); + } + cond_tile_queue_empty.signal(); + } + + virtual void end_frame() + { + while(alive_flag) + { + Glib::Mutex::Lock lock(mutex); + if(!tile_queue.empty() && alive_flag) + { + if(cond_tile_queue_empty.timed_wait(mutex,Glib::TimeVal(0,BOREDOM_TIMEOUT))) + break; + } + else + break; + } + Glib::Mutex::Lock lock(mutex); + if(!alive_flag) + return; + return warm_target->end_frame(); + } +}; + + + +class AsyncTarget_Scanline : public sinfg::Target_Scanline +{ +public: + etl::handle warm_target; + + int scanline_; + Surface surface; + + Glib::Mutex mutex; + +#ifndef GLIB_DISPATCHER_BROKEN + Glib::Dispatcher frame_ready_signal; +#endif + Glib::Cond cond_frame_queue_empty; + bool alive_flag; + bool ready_next; + sigc::connection ready_connection; + + +public: + AsyncTarget_Scanline(etl::handle warm_target): + warm_target(warm_target) + { + set_avoid_time_sync(warm_target->get_avoid_time_sync()); + set_canvas(warm_target->get_canvas()); + set_quality(warm_target->get_quality()); + set_remove_alpha(warm_target->get_remove_alpha()); + set_threads(warm_target->get_threads()); + set_rend_desc(&warm_target->rend_desc()); + alive_flag=true; +#ifndef GLIB_DISPATCHER_BROKEN + ready_connection=frame_ready_signal.connect(sigc::mem_fun(*this,&AsyncTarget_Scanline::frame_ready)); +#endif + surface.set_wh(warm_target->rend_desc().get_w(),warm_target->rend_desc().get_h()); + } + + ~AsyncTarget_Scanline() + { + ready_connection.disconnect(); + } + + virtual int next_frame(Time& time) + { + if(!alive_flag) + return 0; + return warm_target->next_frame(time); + + } + + void set_dead() + { + Glib::Mutex::Lock lock(mutex); + alive_flag=false; + } + + virtual bool start_frame(sinfg::ProgressCallback *cb=0) + { + return alive_flag; + } + + virtual void end_frame() + { + { + Glib::Mutex::Lock lock(mutex); + + if(!alive_flag) + return; + ready_next=false; + +#ifdef GLIB_DISPATCHER_BROKEN + ready_connection=Glib::signal_timeout().connect( + sigc::bind_return( + sigc::mem_fun(*this,&AsyncTarget_Scanline::frame_ready), + false + ) + ,0 + ); +#else + frame_ready_signal(); +#endif + } + + while(alive_flag && !ready_next) + { + Glib::Mutex::Lock lock(mutex); + if(cond_frame_queue_empty.timed_wait(mutex,Glib::TimeVal(0,BOREDOM_TIMEOUT))) + break; + } + } + + + virtual Color * start_scanline(int scanline) + { + Glib::Mutex::Lock lock(mutex); + + return surface[scanline]; + } + + virtual bool end_scanline() + { + return alive_flag; + } + + void frame_ready() + { + Glib::Mutex::Lock lock(mutex); + if(alive_flag) + alive_flag=warm_target->add_frame(&surface); + cond_frame_queue_empty.signal(); + ready_next=true; + } +}; + +/* === G L O B A L S ======================================================= */ + +/* === P R O C E D U R E S ================================================= */ + +/* === M E T H O D S ======================================================= */ + +AsyncRenderer::AsyncRenderer(etl::handle target_,sinfg::ProgressCallback *cb): + error(false), + success(false), + cb(cb) +{ + render_thread=0; + if(etl::handle::cast_dynamic(target_)) + { + etl::handle wrap_target( + new AsyncTarget_Tile(etl::handle::cast_dynamic(target_)) + ); + + signal_stop_.connect(sigc::mem_fun(*wrap_target,&AsyncTarget_Tile::set_dead)); + + target=wrap_target; + } + else if(etl::handle::cast_dynamic(target_)) + { + etl::handle wrap_target( + new AsyncTarget_Scanline( + etl::handle::cast_dynamic(target_) + ) + ); + + signal_stop_.connect(sigc::mem_fun(*wrap_target,&AsyncTarget_Scanline::set_dead)); + + target=wrap_target; + } +} + +AsyncRenderer::~AsyncRenderer() +{ + stop(); +} + +void +AsyncRenderer::stop() +{ + if(target) + { + Glib::Mutex::Lock lock(mutex); + done_connection.disconnect(); + + if(render_thread) + { + signal_stop_(); + +#if REJOIN_ON_STOP + render_thread->join(); +#endif + + // Make sure all the dispatch crap is cleared out + //Glib::MainContext::get_default()->iteration(false); + + if(success) + signal_success_(); + + signal_finished_(); + + target=0; + render_thread=0; + } + } +} + +void +AsyncRenderer::pause() +{ +} + +void +AsyncRenderer::resume() +{ +} + +void +AsyncRenderer::start() +{ + done_connection=Glib::signal_timeout().connect( + sigc::bind_return( + mem_fun(*this,&AsyncRenderer::start_), + false + ) + ,50 + ); +} + +void +AsyncRenderer::start_() +{ + error=false;success=false; + if(target) + { +#ifndef GLIB_DISPATCHER_BROKEN + done_connection=signal_done_.connect(mem_fun(*this,&AsyncRenderer::stop)); +#endif + + render_thread=Glib::Thread::create( + sigc::mem_fun(*this,&AsyncRenderer::render_target), +#if REJOIN_ON_STOP + true +#else + false +#endif + ); + assert(render_thread); + } + else + { + stop(); + } +} + +void +AsyncRenderer::render_target() +{ + etl::handle target(AsyncRenderer::target); + + if(target && target->render()) + { + success=true; + } + else + { + error=true; +#ifndef REJOIN_ON_STOP + return; +#endif + } + + if(mutex.trylock()) + { +#ifdef GLIB_DISPATCHER_BROKEN + done_connection=Glib::signal_timeout().connect( + sigc::bind_return( + mem_fun(*this,&AsyncRenderer::stop), + false + ) + ,0 + ); +#else + signal_done_.emit(); +#endif + mutex.unlock(); + } +} diff --git a/synfig-studio/trunk/src/gtkmm/asyncrenderer.h b/synfig-studio/trunk/src/gtkmm/asyncrenderer.h new file mode 100644 index 0000000..f9721c9 --- /dev/null +++ b/synfig-studio/trunk/src/gtkmm/asyncrenderer.h @@ -0,0 +1,109 @@ +/* === S I N F G =========================================================== */ +/*! \file asyncrenderer.h +** \brief Template Header +** +** $Id: asyncrenderer.h,v 1.3 2005/01/12 07:03:42 darco Exp $ +** +** \legal +** Copyright (c) 2002 Robert B. Quattlebaum Jr. +** +** This software and associated documentation +** are CONFIDENTIAL and PROPRIETARY property of +** the above-mentioned copyright holder. +** +** You may not copy, print, publish, or in any +** other way distribute this software without +** a prior written agreement with +** the copyright holder. +** \endlegal +*/ +/* ========================================================================= */ + +/* === S T A R T =========================================================== */ + +#ifndef __SINFG_ASYNCRENDERER_H +#define __SINFG_ASYNCRENDERER_H + +/* === H E A D E R S ======================================================= */ + +#include +#include +#include +#include + +#include +#include +#include +#include +#include +#include +#include + +/* === M A C R O S ========================================================= */ + +/* === T Y P E D E F S ===================================================== */ + +/* === C L A S S E S & S T R U C T S ======================================= */ + +namespace studio { + +class AsyncRenderer : public etl::shared_object, public sigc::trackable +{ + sigc::signal signal_finished_; + sigc::signal signal_success_; + + std::list activity_connection_list; + + //etl::handle target_scanline; + //etl::handle target_tile; + etl::handle target; + + bool error; + bool success; + + sinfg::ProgressCallback *cb; + + sigc::signal signal_stop_; + + Glib::Thread* render_thread; + Glib::Dispatcher signal_done_; + Glib::Mutex mutex; + sigc::connection done_connection; + + /* + -- ** -- P A R E N T M E M B E R S ----------------------------------------- + */ +public: + + AsyncRenderer(etl::handle target,sinfg::ProgressCallback *cb=0); + virtual ~AsyncRenderer(); + + void start(); + void stop(); + void pause(); + void resume(); + + bool has_error()const { return error; } + bool has_success()const { return success; } + + sigc::signal& signal_finished() { return signal_finished_; } + sigc::signal& signal_success() { return signal_success_; } + +private: + + void render_target(); + void start_(); + + /* + -- ** -- C H I L D M E M B E R S ------------------------------------------- + */ + +protected: + +}; + +}; // END of namespace studio + +/* === E N D =============================================================== */ + +#endif diff --git a/synfig-studio/trunk/src/gtkmm/audiocontainer.cpp b/synfig-studio/trunk/src/gtkmm/audiocontainer.cpp new file mode 100644 index 0000000..dd3b295 --- /dev/null +++ b/synfig-studio/trunk/src/gtkmm/audiocontainer.cpp @@ -0,0 +1,1393 @@ +/* === S I N F G =========================================================== */ +/*! \file audiocontainer.cpp +** \brief Audio Container implementation File +** +** $Id: audiocontainer.cpp,v 1.1.1.1 2005/01/07 03:34:35 darco Exp $ +** +** \legal +** Copyright (c) 2002 Robert B. Quattlebaum Jr. +** +** This software and associated documentation +** are CONFIDENTIAL and PROPRIETARY property of +** the above-mentioned copyright holder. +** +** You may not copy, print, publish, or in any +** other way distribute this software without +** a prior written agreement with +** the copyright holder. +** \endlegal +*/ +/* ========================================================================= */ + +/* === H E A D E R S ======================================================= */ + +#ifdef USING_PCH +# include "pch.h" +#else +#ifdef HAVE_CONFIG_H +# include +#endif + +#include +#include + +#include +#include +//#include +#include + +#include + +#include + +#include "audiocontainer.h" + +#include +#include +#include + +#include +#include + +#ifdef WITH_FMOD +#include +#endif + +#endif + +/* === U S I N G =========================================================== */ + +using namespace std; +using namespace etl; +using namespace sinfg; + +/* === M A C R O S ========================================================= */ +#ifdef __WIN32 +#else //linux... +#define AUDIO_OUTPUT FSOUND_OUTPUT_OSS +#endif + +/* === G L O B A L S ======================================================= */ +const double delay_factor = 3; + +/* === P R O C E D U R E S ================================================= */ + +/* === M E T H O D S ======================================================= */ + +/* === E N T R Y P O I N T ================================================= */ + +//Help constructing stuff +struct FSOUND_SAMPLE; +using studio::AudioContainer; + +bool build_profile(FSOUND_SAMPLE *sample, double &samplerate, std::vector &samples) +{ +#ifdef WITH_FMOD + + float sps = samplerate; + + //trivial rejection... + if(!sample || sps < 1) + { + sinfg::warning("build_profile: Sample rate was too low or sample was invalid"); + return false; + } + + //lock for all samples and process them into a subset + unsigned int mode = FSOUND_Sample_GetMode(sample); + + //make sure that it's 8 bit... I hope this works... + + //sample rate of the actual song... + int allsamplerate = 0; + FSOUND_Sample_GetDefaults(sample,&allsamplerate,0,0,0); + + //get the size of the sample defaults from the mode + int channels = 1; + int channelsize = 1; //number of bytes + + if(mode & FSOUND_16BITS) channelsize = 2; //this shouldn't happen + if(mode & FSOUND_STEREO) channels = 2; + + //Get the sample information + int samplesize = channels*channelsize; //the only two things that increase samplesize + int numsamples = FSOUND_Sample_GetLength(sample); //number of samples in the sound + int sizeall = samplesize*numsamples; //should be the size of the entire song... + + if(sizeall <= 0) + { + sinfg::warning("ProfileAudio: Sample buffer cannot be size smaller than 1 (%X)",FSOUND_GetError()); + return false; + } + + //be sure that the new sample rate is less than or equal to the original + if(sps > allsamplerate) sps = allsamplerate; + + float stride = allsamplerate/(float)sps; + + //down sampling to 8 bit min/max values + sinfg::warning("About to downsample from %d Hz to %.1f Hz, sample stride: %f", allsamplerate, sps, stride); + + char *sampledata=0,*useless = 0; + unsigned int len1,len2; + // vector samples; + { + if(!FSOUND_Sample_Lock(sample,0,sizeall,(void**)&sampledata,(void**)&useless,&len1,&len2)) + { + sinfg::warning("ProfileAudio: Unable to lock the sound buffer... (%X)",FSOUND_GetError()); + return false; + } + sinfg::warning("Locked: %X: %d bytes, %X: %d bytes",sampledata,len1,useless,len2); + + if(channelsize == 1) + { + //process the data + char *iter = sampledata; + char *end = iter + sizeall; + + float curaccum = 0; + float numinc = sps/(float)allsamplerate; + + /* Loop per sample DDA alg. + */ + + int i = 0; + + //HACK - to prevent if statement inside inner loop + //sinfg::warning("wo baby wo baby, inc: %d, stride: %f, size: %d", inc, stride, sizeall); + while(iter < end) + { + int maxs = 0, mins = 0; + + for(;curaccum < 1; curaccum += numinc) + { + for(i = 0; iter < end && i < channels; ++i, iter += channelsize) + { + maxs = std::max(maxs,(int)*iter); + mins = std::min(mins,(int)*iter); + } + } + //insert onto new list + samples.push_back(maxs); + samples.push_back(mins); + + //and flush all the used samples for curaccum + curaccum -= 1; + } + }else if(channelsize == 2) + { + //process the data + char *iter = sampledata; + char *end = iter + sizeall; + + float curaccum = 0; + float numinc = sps/(float)allsamplerate; + + /* Loop per sample DDA alg. + */ + + int i = 0; + + //HACK - to prevent if statement inside inner loop + //sinfg::warning("wo baby wo baby, inc: %d, stride: %f, size: %d", inc, stride, sizeall); + while(iter < end) + { + int maxs = 0, mins = 0; + + for(;curaccum < 1; curaccum += numinc) + { + for(i = 0; iter < end && i < channels; ++i, iter += channelsize) + { + maxs = std::max(maxs,(int)*(short*)iter); + mins = std::min(mins,(int)*(short*)iter); + } + } + //insert onto new list + samples.push_back(maxs / 256); + samples.push_back(mins / 256); + + //and flush all the used samples for curaccum + curaccum -= 1; + } + } + } + + sinfg::warning("Stats: %f seconds with %d bytes now %d bytes", (samples.size()/2)/sps, sizeall, samples.size()); + sinfg::warning(" %f seconds before", numsamples/(float)allsamplerate); + + //we're done yay!, unlock + FSOUND_Sample_Unlock(sample,sampledata,useless,len1,len2); + sinfg::info("Unlocked"); + + //FSOUND_PlaySound(FSOUND_FREE,sound); //test + + //we're done + samplerate = sps*2; //it must be x2 because we are sampling max and min + + return true; + + #else + + return false; + + #endif +} + + +//FMOD Systemwide Specific data mostly here... + +struct scrubinfo; + +#ifdef WITH_FMOD +static double buffer_length_sec = 0; + +//------- Scrubbing -------------- +/* Scrubbing works as follows: + + The sound is played using PlaySoundEx + we specify a user created DSP for scrubbing + set it initially to inactive + + When the program initiates it + we set the initial data in the shared structure and activate the dsp unit + then for each cursor update we get we set the value in the shared structure +*/ + +/* Things to check: + If IsPlaying just governs the channel play/stop value or if it also concerns the pause state + +*/ + +//so we can know where to create all this stuff +struct scrubinfo +{ + /* Linearly fit the frequency to hit the desired zero point... + */ + /*struct scrubelement + { + double pos; + double dt; + //the amount of time left til the cursor hits this one + // it's incremental so that the cursor must pass previous + // ones before decrementing this value + }; + */ + + //the time it should take to get to the next position... + + //to prevent from writing to the same location at once... (pos, deltatime, delaystart) + //Glib::Mutex lock; + + //the queue system would provide a more accurate representation... + volatile double pos; + volatile double deltatime; + + volatile double delaystart; //the amount of time we need to go before we start interpolating... + + volatile int channel; + + /*std::list queue; + + volatile int channel; + + //current position is FSOUND_GetCurrentPosition and current time is always 0... + + void add(const scrubelement &elem) + { + lock.LockWrite(); + + queue.push_back(elem); + + lock.UnlockWrite(); + } + + //Function to safely get rid of all the old samples (dt < 0) + void flush() + { + lock.LockWrite(); + + while(queue.size() && queue.front().dt < 0) + { + queue.pop_front(); + } + + lock.UnlockWrite(); + }*/ + + void Lock() + { + //lock.lock(); + } + + void Unlock() + { + //lock.unlock(); + } + + //All parameters and state should be set by the time we get here... + void scrub_dsp_process() + { + const double epsilon = 1e-5; + + //Trivial reject... we go nowhere if we aren't playing (hit boundary...) + if(!FSOUND_IsPlaying(channel)) return; + + //Get rid of all the old samples + //flush(); + + //Trivial reject #2 - We also go nowhere with no future samples (pause) + /*if(queue.size() <= 0) + { + FSOUND_SetPaused(channel,true); + return; + }*/ + + double dt = buffer_length_sec; + + //Lock ourselves so we don't die + Lock(); + + //printf("DSP data: delay = %.3f s, pos = %d, dt = %.3f\n", delaystart, (int)pos, deltatime); + + //Check delay + if(delaystart > 0) + { + delaystart -= dt; + + if(delaystart < 0) + { + dt = -delaystart; //add time back... + delaystart = 0; + } + } + + //Trivial reject for if we're past current sample... + if(delaystart > 0 || deltatime <= 0) + { + FSOUND_SetPaused(channel,true); + Unlock(); + return; + } + + //Calculate stretched frequency based on delayed future sample... + + //NOTE: BY NOT TRACKING POSITION AS A FLOAT AND JUST USING THE SOUNDS VALUE + // WE ARE LOSING A TINY AMOUNT OF PRECISION ACCURACY EVERY UPDATE + // (THIS SHOULDN'T BE A PROBLEM) + const double p0 = FSOUND_GetCurrentPosition(channel); + double curdp = 0; + + if(!FSOUND_GetPaused(channel)) + { + curdp = FSOUND_GetFrequency(channel) * deltatime; + } + + //need to rescale derivative... + + //Extrapolate from difference in position and deltatime vs dt... + const double pa = p0 + curdp/2; + + const double p1 = pos; + + //const double pb = p0/3 + p1*2/3; + + //will extrapolate if needed... (could be funky on a curve) + double t = 0; + if(deltatime > epsilon) + { + t = dt / deltatime; + } + + //Decrement deltatime (we may have gone past but that's what happens when we don't get input...) + deltatime -= dt; + + //we don't need to look at the current variables anymore... + Unlock(); + + const double invt = 1-t; + //double deltapos = (p1-p0)*t; //linear version + double deltapos = invt*invt*p0 + 2*t*invt*pa + t*t*p1 - p0; //quadratic smoothing version + + //Attempted cubic smoothing + //const double invt2 = invt*invt; + //const double t2 = t*t; + //double deltapos = invt2*invt*p0 + 3*t*invt2*pa + 3*t2*invt*pb + t2*t*p1; + //double deltapos = p0 + t*(3*(pa-p0) + t*(3*(p0+2*pa+pb) + t*((p1-3*pb+3*ba-p0)))); //unwound cubic + + //printf("\ttime = %.2f; p(%d,%d,%d) dp:%d - delta = %d\n",t,(int)p0,(int)p1,(int)p2,(int)curdp,(int)deltapos); + + //Based on the delta info calculate the stretched frequency + const int dest_samplesize = FSOUND_DSP_GetBufferLength(); + + //rounded to nearest frequency... (hopefully...) + int freq = (int)(deltapos * FSOUND_GetOutputRate() / (double)dest_samplesize); + + //NOTE: WE MIGHT WANT TO DO THIS TO BE MORE ACCURATE BUT YEAH... ISSUES WITH SMALL NUMBERS + //double newdp = deltapos / t; + + //printf("\tfreq = %d Hz\n", freq); + + // !If I failed... um assume we have to pause it... ? + if(abs(freq) < 100) + { + FSOUND_SetPaused(channel,true); + }else + { + //sinfg::info("DSP f = %d Hz", freq); + FSOUND_SetPaused(channel,false); + if(!FSOUND_SetFrequency(channel,freq)) + { + //ERROR WILL ROBINSON!!!... + printf("Error in Freq... what do I do?\n"); + } + } + } +}; + +struct scrubuserdata +{ + /* //for use with multiple + //each one is a 'handle' to a pointer that will be effected by something else + typedef scrubinfo** value_type; + typedef std::set< value_type > scrubslist; + scrubslist scrubs; + + //so we can lock access to the list... + ReadWriteLock lock; + + void AddScrub(scrubinfo **i) + { + lock.LockWrite(); + scrubs.insert(i); + lock.UnLockWrite(); + } + + void RemoveScrub(scrubinfo **i) + { + lock.LockWrite(); + scrubs.erase(i); + lock.UnLockWrite(); + }*/ + + scrubinfo * volatile * scrub; +}; + +//Scrubbing data structures +static const int default_scrub_priority = 5; //between clear and sfx/music mix +static scrubuserdata g_scrubdata = {0}; +static FSOUND_DSPUNIT *scrubdspunit = 0; + +void * scrubdspwrap(void *originalbuffer, void *newbuffer, int length, void *userdata) +{ + //std::string dsp = "DSP"; + if(userdata) + { + scrubuserdata &sd = *(scrubuserdata*)userdata; + + /* //For use with multiple scrubs... + //Lock so no one can write to it while we're reading from it... + sd.lock.LockRead(); + + //make a copy of it... + std::vector v(sd.scrubs.begin(),sd.scrubs.end()); + + //other things can do stuff with it again... + sd.lock.UnLockRead(); + + //loop through the list and process all the active scrub units + std::vector::iterator i = v.begin(), + end = v.end(); + for(;i != end; ++i) + { + //check to make sure this object is active... + if(*i && **i) + { + (**i)->scrub_dsp_process(); + } + } + */ + + if(sd.scrub && *sd.scrub) + { + //dsp += " processing..."; + scrubinfo * info = (*sd.scrub); + info->scrub_dsp_process(); + } + } + + //sinfg::info(dsp); + + return newbuffer; +} + +//------- Class for loading fmod on demand ------- + +class FMODInitializer +{ + bool loaded; + int refcount; + +public: + FMODInitializer():loaded(false),refcount(0) {} + ~FMODInitializer() + { + clear(); + } + + void addref() + { + if(!loaded) + { + #ifdef WITH_FMOD + sinfg::info("Initializing FMOD on demand..."); + + { + FSOUND_SetOutput(AUDIO_OUTPUT); + + /*int numdrivers = FSOUND_GetNumDrivers(); + sinfg::info("Num FMOD drivers = %d",numdrivers); + sinfg::info("Current Driver is #%d", FSOUND_GetDriver()); + + for(int i = 0; i < numdrivers; ++i) + { + unsigned int caps = 0; + FSOUND_GetDriverCaps(i,&caps); + + sinfg::info(" Caps for driver %d (%s) = %x",i,FSOUND_GetDriverName(i),caps); + } + + FSOUND_SetDriver(0);*/ + + //Modify buffer size... + //FSOUND_SetBufferSize(100); + + if(!FSOUND_Init(44100, 32, 0)) + { + sinfg::warning("Unable to load FMOD"); + }else + { + loaded = true; + + //Create the DSP for processing scrubbing... + scrubdspunit = FSOUND_DSP_Create(&scrubdspwrap,default_scrub_priority,&g_scrubdata); + + //Load the number of sec per buffer into the global variable... + buffer_length_sec = FSOUND_DSP_GetBufferLength() / (double)FSOUND_GetOutputRate(); + } + } + #endif + } + + //add to the refcount + ++refcount; + //sinfg::info("Audio: increment fmod refcount %d", refcount); + } + + void decref() + { + if(refcount <= 0) + { + sinfg::warning("FMOD refcount is already 0..."); + }else + { + --refcount; + //sinfg::info("Audio: decrement fmod refcount %d", refcount); + + //NOTE: UNCOMMENT THIS IF YOU WANT FMOD TO UNLOAD ITSELF WHEN IT ISN'T NEEDED ANYMORE... + flush(); + } + } + + bool is_loaded() const { return loaded; } + + void clear() + { + refcount = 0; + flush(); + } + + void flush() + { + if(loaded && refcount <= 0) + { + #ifdef WITH_FMOD + sinfg::info("Unloading FMOD"); + if(scrubdspunit) FSOUND_DSP_Free(scrubdspunit); + FSOUND_Close(); + #endif + loaded = false; + } + } +}; + +//The global counter for FMOD.... +FMODInitializer fmodinit; + +#endif + +//----- AudioProfile Implementation ----------- +void studio::AudioProfile::clear() +{ + samplerate = 0; + samples.clear(); +} + +handle studio::AudioProfile::get_parent() const +{ + return parent; +} + +void studio::AudioProfile::set_parent(etl::handle i) +{ + parent = i; +} + +double studio::AudioProfile::get_offset() const +{ + if(parent) + return parent->get_offset(); + return 0; +} + +//---------- AudioContainer definitions --------------------- + +struct studio::AudioContainer::AudioImp +{ + //Sample load time information + FSOUND_SAMPLE * sample; + int channel; + int sfreq; + int length; + + //Time information + double offset; //time offset for playing... + + //We don't need it now that we've adopted the play(t) time schedule... + //current time... and playing info.... + //float seekpost; + //bool useseekval; + + //Make sure to sever our delayed start if we are stopped prematurely + sigc::connection delaycon; + + //Action information + bool playing; + double curscrubpos; + etl::clock timer; //for getting the time diff between scrub input points + + //Scrubbing information... + //the current position of the sound will be sufficient for normal stuff... + #ifdef WITH_FMOD + scrubinfo scrinfo; + #endif + + scrubinfo *scrptr; + + bool is_scrubbing() const {return scrptr != 0;} + void set_scrubbing(bool s) + { + #ifdef WITH_FMOD + if(s) + scrptr = &scrinfo; + else + #endif + scrptr = 0; + } + + //helper to make sure we are actually playing (and to get a new channel...) + bool init_play() + { + #ifdef WITH_FMOD + if(!FSOUND_IsPlaying(channel)) + { + if(sample) + { + //play sound paused etc. + channel = FSOUND_PlaySoundEx(FSOUND_FREE,sample,0,true); + if(channel < 0 || FSOUND_GetError() != FMOD_ERR_NONE) + { + sinfg::warning("Could not play the sample..."); + return false; + } + } + }else + { + FSOUND_SetPaused(channel,true); + FSOUND_SetFrequency(channel,sfreq); + } + return true; + + #else + + return false; + + #endif + } + +public: //structors + AudioImp() + :sample(0), + channel(0), + sfreq(0), + length(0), + offset(0), + playing(false), + scrptr(0) + { + //reuse the channel... + #ifdef WITH_FMOD + channel = FSOUND_FREE; + #endif + } + + ~AudioImp() + { + clear(); + } + +public: //helper/accessor funcs + bool start_playing_now() //callback for timer... + { + #ifdef WITH_FMOD + if(playing) + { + //Make sure the sound is playing and if it is un pause it... + if(init_play()) + FSOUND_SetPaused(channel,false); + } + #endif + + return false; //so the timer doesn't repeat itself + } + + bool isRunning() + { + #ifdef WITH_FMOD + return FSOUND_IsPlaying(channel); + #else + return false; + #endif + } + + bool isPaused() + { +#ifdef WITH_FMOD + return FSOUND_GetPaused(channel); +#else + return false; +#endif + } + + +public: //forward interface + + //Accessors for the offset - in seconds + const double &get_offset() const {return offset;} + void set_offset(const double &d) + { + offset = d; + } + + //Will override the parameter timevalue if the sound is running, and not if it's not... + bool get_current_time(double &out) + { + if(isRunning()) + { + #ifdef WITH_FMOD + unsigned int pos = FSOUND_GetCurrentPosition(channel); + + //adjust back by 1 frame... HACK.... + //pos -= FSOUND_DSP_GetBufferLength(); + + //set the position + out = pos/(double)sfreq + offset; + #endif + + return true; + } + return false; + } + + //Big implementation functions... + bool load(const std::string &filename, const std::string &filedirectory); + void clear(); + + //playing functions + void play(double t); + void stop(); + + //scrubbing functions + void start_scrubbing(double t); + void scrub(double t); + void stop_scrubbing(); + + double scrub_time() + { + return curscrubpos; + } +}; + +//--------------- Audio Container definitions -------------------------- +studio::AudioContainer::AudioContainer() +{ + imp = 0; +} + +studio::AudioContainer::~AudioContainer() +{ + if(imp) delete (imp); +} + +bool studio::AudioContainer::load(const string &filename,const string &filedirectory) +{ + if(!imp) + { + imp = new AudioImp; + } + + profilevalid = false; + return imp->load(filename,filedirectory); +} + +handle studio::AudioContainer::get_profile(float samplerate) +{ + #ifdef WITH_FMOD + + //if we already have done our work, then we're good + if(profilevalid && prof) + { + //sinfg::info("Using already built profile"); + return prof; + } + + //sinfg::info("Before profile"); + //make a new profile at current sample rate + + //NOTE: We might want to reuse the structure already there... + prof = new AudioProfile; + prof->set_parent(this); //Our parent is THIS!!! + + if(!prof) + { + sinfg::warning("Couldn't allocate audioprofile..."); + return handle(); + } + + //setting the info for the sample rate + //sinfg::info("Setting info..."); + + sinfg::info("Building Profile..."); + prof->samplerate = samplerate; + if(build_profile(imp->sample,prof->samplerate,prof->samples)) + { + sinfg::info(" Success!"); + profilevalid = true; + return prof; + }else + { + return handle(); + } + + #else + + return handle(); + + #endif +} + +void studio::AudioContainer::clear() +{ + if(imp) + { + delete imp; + imp = 0; + } + + profilevalid = false; +} + +void studio::AudioContainer::play(double t) +{ + if(imp) imp->play(t); +} + +void studio::AudioContainer::stop() +{ + if(imp) imp->stop(); +} + +bool studio::AudioContainer::get_current_time(double &out) +{ + if(imp) return imp->get_current_time(out); + else return false; +} + +void AudioContainer::set_offset(const double &s) +{ + if(imp) imp->set_offset(s); +} + +double AudioContainer::get_offset() const +{ + static double zero = 0; + if(imp) + return imp->get_offset(); + return zero; +} + +bool AudioContainer::is_playing() const +{ + if(imp) + return imp->playing; + return false; +} + +bool AudioContainer::is_scrubbing() const +{ + if(imp) + return imp->is_scrubbing(); + return false; +} + +void AudioContainer::start_scrubbing(double t) +{ + if(imp) imp->start_scrubbing(t); +} + +void AudioContainer::stop_scrubbing() +{ + if(imp) imp->stop_scrubbing(); +} + +void AudioContainer::scrub(double t) +{ + if(imp) imp->scrub(t); +} + +double AudioContainer::scrub_time() const +{ + if(imp) return imp->scrub_time(); + else return 0; +} + +bool AudioContainer::isRunning() const +{ + if(imp) return imp->isRunning(); + else return false; +} + +bool AudioContainer::isPaused() const +{ + if(imp) return imp->isPaused(); + else return false; +} + +//----------- Audio imp information ------------------- + +bool studio::AudioContainer::AudioImp::load(const std::string &filename, + const std::string &filedirectory) +{ + clear(); + + #ifdef WITH_FMOD + + //And continue with the sound loading... + string file = filename; + + //Trivial reject... (fixes stat call problem... where it just looks at directory and not file...) + if(file.length() == 0) return false; + + //we don't need the file directory? + if(!is_absolute_path(file)) + { + file=filedirectory+filename; + sinfg::warning("Not absolute hoooray"); + } + sinfg::info("Loading Audio file: %s", file.c_str()); + + //check to see if file exists + { + struct stat s; + if(stat(file.c_str(),&s) == -1 && errno == ENOENT) + { + sinfg::info("There was no audio file..."); + return false; + } + } + + //load fmod if we can... + //sinfg::warning("I'm compiled with FMOD!"); + fmodinit.addref(); + + //load the stream + int ch = FSOUND_FREE; + FSOUND_SAMPLE *sm = FSOUND_Sample_Load(FSOUND_FREE,file.c_str(),FSOUND_LOOP_OFF|FSOUND_MPEGACCURATE,0,0); + + if(!sm) + { + sinfg::warning("Could not open the audio file as a sample: %s",file.c_str()); + goto error; + } + + //sinfg::warning("Opened a file as a sample! :)"); + + /*{ + int bufferlen = FSOUND_DSP_GetBufferLength(); + sinfg::info("Buffer length = %d samples, %.3lf s",bufferlen, bufferlen / (double)FSOUND_GetOutputRate()); + }*/ + + //set all the variables since everything has worked out... + //get the length of the stream + { + length = FSOUND_Sample_GetLength(sm); + + int volume = 0; + FSOUND_Sample_GetDefaults(sm,&sfreq,&volume,0,0); + + //double len = length / (double)sfreq; + //sinfg::info("Sound info: %.2lf s long, %d Hz, %d Vol",(double)length,sfreq,volume); + } + + //sinfg::warning("Got all info, and setting up everything, %.2f sec.", length); + //sinfg::warning(" BigSample: composed of %d samples", FSOUND_Sample_GetLength(sm)); + sinfg::info("Successfully opened %s as a sample and initialized it.",file.c_str()); + + //set up the playable info + sample = sm; + channel = ch; + + //the length and sfreq params have already been initialized + + return true; + +error: + if(sm) FSOUND_Sample_Free(sm); + file = ""; + + fmodinit.decref(); + + return false; + + #else + return false; + #endif +} + +void studio::AudioContainer::AudioImp::play(double t) +{ + #ifdef WITH_FMOD + if(!sample) return; + + //stop scrubbing if we are... + if(is_scrubbing()) stop_scrubbing(); + + //t -= offset; + t -= get_offset(); + playing = true; + + if(t < 0) + { + unsigned int timeout = (int)floor(-t * 1000 + 0.5); + //sinfg::info("Playing audio delayed by %d ms",timeout); + //delay for t seconds... + delaycon = Glib::signal_timeout().connect( + sigc::mem_fun(*this,&studio::AudioContainer::AudioImp::start_playing_now),timeout); + + init_play(); + FSOUND_SetFrequency(channel,sfreq); + FSOUND_SetCurrentPosition(channel,0); + return; + } + + unsigned int position = (int)floor(t*sfreq + 0.5); + + if(position >= FSOUND_Sample_GetLength(sample)) + { + sinfg::warning("Can't play audio when past length..."); + return; + } + + init_play(); + FSOUND_SetFrequency(channel,sfreq); + FSOUND_SetCurrentPosition(channel,position); + FSOUND_SetPaused(channel,false); + + //sinfg::info("Playing audio with position %d samples",position); + + #endif +} + +void studio::AudioContainer::AudioImp::stop() +{ + delaycon.disconnect(); + + #ifdef WITH_FMOD + if(fmodinit.is_loaded() && playing && isRunning()) + { + FSOUND_SetPaused(channel,true); + } + #endif + + playing = false; +} + +void studio::AudioContainer::AudioImp::clear() +{ + #ifdef WITH_FMOD + delaycon.disconnect(); + + stop(); + stop_scrubbing(); + + if(sample) + { + if(FSOUND_IsPlaying(channel)) + { + FSOUND_StopSound(channel); + } + channel = FSOUND_FREE; + FSOUND_Sample_Free(sample); + fmodinit.decref(); + } + + playing = false; + + #else + channel = 0; + #endif + + sample = 0; + playing = false; +} + +void AudioContainer::AudioImp::start_scrubbing(double t) +{ + //sinfg::info("Start scrubbing: %lf", t); + if(playing) stop(); + + set_scrubbing(true); + + #ifdef WITH_FMOD + //make sure the other one is not scrubbing... + if(g_scrubdata.scrub) + { + *g_scrubdata.scrub = 0; //nullify the pointer... + } + + //Set up the initial state for the delayed audio position + scrinfo.delaystart = 0; + scrinfo.pos = 0; + scrinfo.deltatime = 0; + + //set it to point to our pointer (dizzy...) + g_scrubdata.scrub = &scrptr; + + //setup position info so we can know what to do on boundary conditions... + curscrubpos = (t - get_offset()) * sfreq; + + //So we can get an accurate difference... + timer.reset(); + + //reposition the sound if it won't be when scrubbed (if it's already in the range...) + int curi = (int)curscrubpos; + if(curi >= 0 && curi < length) + { + init_play(); + FSOUND_SetCurrentPosition(channel,curi); + + //Set the values... + scrinfo.pos = curscrubpos; + scrinfo.delaystart = delay_factor*buffer_length_sec; + + //sinfg::info("\tStarting at %d samps, with %d p %.3f delay", + // FSOUND_GetCurrentPosition(channel), (int)scrinfo.pos, scrinfo.delaystart); + } + + + + //enable the dsp... + //sinfg::info("\tActivating DSP"); + FSOUND_DSP_SetActive(scrubdspunit,true); + #endif +} + +void AudioContainer::AudioImp::stop_scrubbing() +{ + //sinfg::info("Stop scrubbing"); + + if(is_scrubbing()) + { + set_scrubbing(false); + + #ifdef WITH_FMOD + g_scrubdata.scrub = 0; + + //stop the dsp... + //sinfg::info("\tDeactivating DSP"); + FSOUND_DSP_SetActive(scrubdspunit,false); + if(FSOUND_IsPlaying(channel)) FSOUND_SetPaused(channel,true); + #endif + } + + curscrubpos = 0; +} + +void AudioContainer::AudioImp::scrub(double t) +{ + #ifdef WITH_FMOD + //sinfg::info("Scrub to %lf",t); + if(is_scrubbing()) + { + //What should we do? + + /* Different special cases + All outside, all inside, + coming in (left or right), + going out (left or right) + */ + double oldpos = curscrubpos; + double newpos = (t - get_offset()) * sfreq; + + curscrubpos = newpos; + + //Ok the sound is running, now we need to tweek it + if(newpos > oldpos) + { + //Outside so completely stopped... + if(newpos < 0 || oldpos >= length) + { + //sinfg::info("\tOut +"); + if(FSOUND_IsPlaying(channel)) + { + FSOUND_SetPaused(channel,true); + } + + //Zero out the data! + scrinfo.Lock(); + scrinfo.delaystart = 0; + scrinfo.deltatime = 0; + scrinfo.Unlock(); + + return; + } + + //going in? - start the sound at the beginning... + /*else if(oldpos < 0) + { + //Set up the sound to be playing paused at the start... + init_play(); + FSOUND_SetCurrentPosition(channel,0); + + sinfg::info("\tIn + %d", FSOUND_GetCurrentPosition(channel)); + + scrinfo.Lock(); + scrinfo.pos = 0; + scrinfo.delaystart = delay_factor*buffer_length_sec; + scrinfo.deltatime = 0; + scrinfo.Unlock(); + }*/ + //don't need to deal with leaving... automatically dealt with... + + else //We're all inside... + { + //Set new position and decide what to do with time... + scrinfo.Lock(); + scrinfo.pos = newpos; + + //should we restart the delay cycle... (is it done?) + if(!isRunning() || (scrinfo.delaystart <= 0 && scrinfo.deltatime <= 0 && isPaused())) + { + //sinfg::info("Starting + at %d",(int)newpos); + scrinfo.deltatime = 0; + scrinfo.delaystart = delay_factor*buffer_length_sec; + scrinfo.Unlock(); + + //Set up the sound paused at the current position + init_play(); + int setpos = min(max((int)newpos,0),length); + FSOUND_SetCurrentPosition(channel,setpos); + timer.reset(); + return; + } + + //No! just increment the time delta... + scrinfo.deltatime += timer.pop_time(); + + //Nope... continue and just increment the deltatime and reset position... + scrinfo.Unlock(); + + //set channel and unpause + FSOUND_SetPaused(channel,false); + scrinfo.channel = channel; + + } + }else if(newpos < oldpos) + { + //completely stopped... + if(newpos >= length || oldpos < 0) + { + //sinfg::info("Out -"); + if(FSOUND_IsPlaying(channel)) + { + FSOUND_SetPaused(channel,true); + } + + //Zero out the data! + scrinfo.Lock(); + scrinfo.delaystart = 0; + scrinfo.deltatime = 0; + scrinfo.Unlock(); + } + + //going in? - start going backwards at the end... + /*else if(oldpos >= length) + { + sinfg::info("In -"); + //Set up the sound to be playing paused at the start... + init_play(); + FSOUND_SetCurrentPosition(channel,length-1); + + scrinfo.Lock(); + scrinfo.pos = length-1; + scrinfo.delaystart = delay_factor*buffer_length_sec; + scrinfo.deltatime = 0; + scrinfo.Unlock(); + }*/ + //we don't have to worry about the leaving case... + + else //We're all inside... + { + //Set new position and decide what to do with time... + scrinfo.Lock(); + scrinfo.pos = newpos; + + //should we restart the delay cycle... (is it done?) + if(!isRunning() ||(scrinfo.delaystart <= 0 && scrinfo.deltatime <= 0 && isPaused())) + { + //sinfg::info("Starting - at %d",(int)newpos); + scrinfo.deltatime = 0; + scrinfo.delaystart = delay_factor*buffer_length_sec; + scrinfo.Unlock(); + + //reset timing so next update will be a valid diff... + init_play(); + int setpos = min(max((int)newpos,0),length); + FSOUND_SetCurrentPosition(channel,setpos); + timer.reset(); + return; + } + + //No! just increment the time delta... + scrinfo.deltatime += timer.pop_time(); + + //Nope... continue and just increment the deltatime and reset position... + scrinfo.Unlock(); + + //set channel and unpause + FSOUND_SetPaused(channel,false); + scrinfo.channel = channel; + } + } + } + #endif +} diff --git a/synfig-studio/trunk/src/gtkmm/audiocontainer.h b/synfig-studio/trunk/src/gtkmm/audiocontainer.h new file mode 100644 index 0000000..cc449e8 --- /dev/null +++ b/synfig-studio/trunk/src/gtkmm/audiocontainer.h @@ -0,0 +1,138 @@ +/* === S I N F G =========================================================== */ +/*! \file audiocontainer.h +** \brief Sound info header +** +** $Id: audiocontainer.h,v 1.1.1.1 2005/01/07 03:34:35 darco Exp $ +** +** \legal +** Copyright (c) 2002 Robert B. Quattlebaum Jr. +** +** This software and associated documentation +** are CONFIDENTIAL and PROPRIETARY property of +** the above-mentioned copyright holder. +** +** You may not copy, print, publish, or in any +** other way distribute this software without +** a prior written agreement with +** the copyright holder. +** \endlegal +*/ +/* ========================================================================= */ + +/* === S T A R T =========================================================== */ + +#ifndef __SINFG_AUDIOCONTAINER_H +#define __SINFG_AUDIOCONTAINER_H + +/* === H E A D E R S ======================================================= */ +#include + +#include + +#include +#include + +#include + +/* === M A C R O S ========================================================= */ +const float DEF_DISPLAYSAMPLERATE = 400; +/* === T Y P E D E F S ===================================================== */ + +/* === C L A S S E S & S T R U C T S ======================================= */ + +namespace studio { + +class AudioContainer; + +//Note: Might want to abstract something to share data between profile and parent +class AudioProfile : public etl::shared_object +{ +public: + typedef std::vector SampleProfile; + +private: + SampleProfile samples; + double samplerate; //samples / second of the profile + + //reference our parent for any native sound info + etl::loose_handle parent; + +public: //samples interface + + SampleProfile::const_iterator begin() const {return samples.begin();} + SampleProfile::const_iterator end() const {return samples.end();} + + void clear(); + unsigned int size() const {return samples.size();} + + char operator[](int i) const + { + if(i >= 0 && i < (int)samples.size()) return samples[i]; + else return 0; + } + +public: // + + double get_samplerate() const {return samplerate;} + void set_samplerate(double f) {samplerate = f;} + + double get_offset() const; + + etl::handle get_parent() const; + void set_parent(etl::handle i); + friend class AudioContainer; +}; + +/* Audio container actually implements all the cool stuff + Note: May be a bit to monolithic... +*/ +class AudioContainer : public sigc::trackable, public etl::shared_object +{ + etl::handle prof; + + struct AudioImp; + AudioImp *imp; + + bool profilevalid; //this is only half useful + //it makes it so we don't always have to realloc memory when the file switches... + +public: //structors + + AudioContainer(); + ~AudioContainer(); + +public: //accessor interface + void set_offset(const double &s); + double get_offset() const; + +public: //info gather interface + etl::handle get_profile(float samplerate = DEF_DISPLAYSAMPLERATE); + bool get_current_time(double &out); + +public: //operational interface + bool load(const std::string &filename, const std::string &filedirectory = ""); + void clear(); + + //play functions... + void play(double t); + void stop(); + //Note: this refers to the wrapper concept of the audio, the actual sound may or may not be playing... + bool is_playing() const; + + //scrubbing functions... + void start_scrubbing(double t); + void stop_scrubbing(); + void scrub(double t); //!< if we are not currently scrubbing this will not work + bool is_scrubbing() const; + + double scrub_time() const; + + bool isRunning() const; + bool isPaused() const; +}; + +} // END of namespace studio + +/* === E N D =============================================================== */ + +#endif diff --git a/synfig-studio/trunk/src/gtkmm/autorecover.cpp b/synfig-studio/trunk/src/gtkmm/autorecover.cpp new file mode 100644 index 0000000..06c1db3 --- /dev/null +++ b/synfig-studio/trunk/src/gtkmm/autorecover.cpp @@ -0,0 +1,320 @@ +/* === S I N F G =========================================================== */ +/*! \file autorecover.cpp +** \brief Template File +** +** $Id: autorecover.cpp,v 1.1.1.1 2005/01/07 03:34:35 darco Exp $ +** +** \legal +** Copyright (c) 2002 Robert B. Quattlebaum Jr. +** +** This software and associated documentation +** are CONFIDENTIAL and PROPRIETARY property of +** the above-mentioned copyright holder. +** +** You may not copy, print, publish, or in any +** other way distribute this software without +** a prior written agreement with +** the copyright holder. +** \endlegal +*/ +/* ========================================================================= */ + +/* === H E A D E R S ======================================================= */ + +#ifdef USING_PCH +# include "pch.h" +#else +#ifdef HAVE_CONFIG_H +# include +#endif + +#include "autorecover.h" + +//#include +#include "app.h" +#include +#include +#include +#include +#include "instance.h" + +#ifdef HAVE_SYS_STAT_H +#include +#endif + +#ifdef HAVE_SYS_TIME_H +#include +#endif + +#ifdef HAVE_SYS_WAIT_H +#include +#endif + +#ifdef HAVE_SYS_RESOURCE_H +#include +#endif + +#ifdef HAVE_UNISTD_H +#include +#endif + +#endif + +/* === U S I N G =========================================================== */ + +using namespace std; +using namespace etl; +using namespace sinfg; +using namespace studio; + +/* === M A C R O S ========================================================= */ + +#ifdef _WIN32 +#define mkdir(x,y) mkdir(x) +#endif + +/* === G L O B A L S ======================================================= */ + +/* === P R O C E D U R E S ================================================= */ + +/* === M E T H O D S ======================================================= */ + +AutoRecover::AutoRecover() +{ + // Three Minutes + set_timeout(3*60*1000); + + if(mkdir(get_shadow_directory().c_str(),ACCESSPERMS)<0) + { + if(errno!=EEXIST) + sinfg::error("UNABLE TO CREATE \"%s\"",get_shadow_directory().c_str()); + } + else + { + sinfg::info("Created directory \"%s\"",get_shadow_directory().c_str()); + } +} + +AutoRecover::~AutoRecover() +{ +} + +sinfg::String +AutoRecover::get_shadow_directory() +{ + return Glib::build_filename(App::get_user_app_directory(),"tmp"); +} + +int +AutoRecover::pid() +{ +// return getpid(); + return 0; +} + +void +AutoRecover::set_timeout(int milliseconds) +{ + timeout=milliseconds; + auto_backup_connect.disconnect(); + if(timeout) + auto_backup_connect=Glib::signal_timeout().connect(sigc::ptr_fun(&AutoRecover::auto_backup),timeout); +// auto_backup_connect=App::main.get_context()->signal_timeout().connect(sigc::mem_fun(&AutoRecover::auto_backup),timeout); +} + +sinfg::String +AutoRecover::get_shadow_file_name(const sinfg::String& filename) +{ + unsigned int hash1(0xdeadbeef); + unsigned int hash2(0x83502529); + char* str_hash1(reinterpret_cast(&hash1)); + char* str_hash2(reinterpret_cast(&hash2)); + + // First we need to hash up the directory + { + String pool(dirname(filename)); + + while(pool.size()>4) + { + str_hash1[0]^=pool[1];str_hash1[1]^=pool[2];str_hash1[2]^=pool[3];str_hash1[3]^=pool[0]; + str_hash2[3]+=pool[0];str_hash2[2]+=pool[1];str_hash2[1]+=pool[2];str_hash2[0]+=pool[3]; + swap(hash1,hash2); + pool=String(pool,4,pool.size()); + } + while(pool.size()) + { + str_hash1[0]^=pool[0]; + str_hash1[2]^=pool[0]; + str_hash2[1]^=pool[0]; + str_hash2[3]^=pool[0]; + swap(hash1,hash2); + pool=String(pool,1,pool.size()); + } + } + hash1^=hash2; + + return Glib::build_filename(get_shadow_directory(),strprintf("%08X-%s",hash1,basename(filename).c_str())); + +// return dirname(filename) + ETL_DIRECTORY_SEPERATOR + ".shadow_" + basename(filename); +} + +bool +AutoRecover::cleanup_pid(int pid) +{ +#ifdef HAVE_FORK + int status=0; + if(waitpid(pid,&status,WNOHANG)==-1) + { + sinfg::info("PID %d isn't a zombie yet",pid); + return true; + } + if(WEXITSTATUS(status)!=0) + { + sinfg::error("Autobackup seems to have failed! (PID=%d)",pid); + } + else + sinfg::info("PID=%d has been cleaned up",pid); +#endif + return false; +} + +bool +AutoRecover::auto_backup() +{ + int pid(0); + +#ifdef HAVE_FORK + pid=fork(); +#endif + + if(pid<=0) + { +#ifdef HAVE_SETPRIORITY + // make us low priority so that we don't + // cause the machine to slow down too much + setpriority(PRIO_PROCESS,0,15); +#endif + + try + { + std::list >::iterator iter; + + std::string filename=App::get_config_file("autorecovery"); + std::ofstream file(filename.c_str()); + + int savecount(0); + + for(iter=App::instance_list.begin();iter!=App::instance_list.end();++iter) + { + // If this file hasn't even been changed + // since it was last saved, then don't bother + // backing it up. + if((*iter)->get_action_count()==0) + continue; + + Canvas::Handle canvas((*iter)->get_canvas()); + file<get_file_name()<get_file_name()),canvas); + savecount++; + } + + if(savecount) + sinfg::info("AutoRecover::auto_backup(): %d Files backed up.",savecount); + } + catch(...) + { + sinfg::error("AutoRecover::auto_backup(): UNKNOWN EXCEPTION THROWN."); + sinfg::error("AutoRecover::auto_backup(): FILES NOT BACKED UP."); + } + +#ifdef HAVE_FORK + if(pid==0) + { + _exit(0); + } +#endif + } + +#ifdef HAVE_FORK + Glib::signal_timeout().connect( + sigc::bind( + sigc::ptr_fun(&AutoRecover::cleanup_pid), + pid + ), + 60*1000 + ); +#endif + + // Also go ahead and save the settings + App::save_settings(); + + return true; +} + +bool +AutoRecover::recovery_needed()const +{ + std::string filename=App::get_config_file("autorecovery"); + std::ifstream file(filename.c_str()); + if(!file) + return false; + + while(file) + { + std::string filename; + getline(file,filename); + if(!filename.empty()) + return true; + } + + return false; +} + +bool +AutoRecover::recover() +{ + std::string filename=App::get_config_file("autorecovery"); + std::ifstream file(filename.c_str()); + if(!file) + return false; + bool success=true; + + while(file) + { + std::string filename; + getline(file,filename); + if(filename.empty()) + continue; + + // Open the file + if(App::open_as(get_shadow_file_name(filename),filename)) + { + // Correct the file name + App::instance_list.back()->set_file_name(filename); + + // This file isn't saved! mark it as such + App::instance_list.back()->inc_action_count(); + } + else + success=false; + } + + return success; +} + +void +AutoRecover::normal_shutdown() +{ + // Turn off the timer + auto_backup_connect.disconnect(); + + std::string filename=App::get_config_file("autorecovery"); + remove(filename.c_str()); +} + +void +AutoRecover::clear_backup(sinfg::Canvas::Handle canvas) +{ + if(canvas) + remove(get_shadow_file_name(canvas->get_file_name()).c_str()); +} diff --git a/synfig-studio/trunk/src/gtkmm/autorecover.h b/synfig-studio/trunk/src/gtkmm/autorecover.h new file mode 100644 index 0000000..c6a4ed0 --- /dev/null +++ b/synfig-studio/trunk/src/gtkmm/autorecover.h @@ -0,0 +1,73 @@ +/* === S I N F G =========================================================== */ +/*! \file autorecover.h +** \brief Template Header +** +** $Id: autorecover.h,v 1.1.1.1 2005/01/07 03:34:35 darco Exp $ +** +** \legal +** Copyright (c) 2002 Robert B. Quattlebaum Jr. +** +** This software and associated documentation +** are CONFIDENTIAL and PROPRIETARY property of +** the above-mentioned copyright holder. +** +** You may not copy, print, publish, or in any +** other way distribute this software without +** a prior written agreement with +** the copyright holder. +** \endlegal +*/ +/* ========================================================================= */ + +/* === S T A R T =========================================================== */ + +#ifndef __SINFG_AUTORECOVER_H +#define __SINFG_AUTORECOVER_H + +/* === H E A D E R S ======================================================= */ + +#include +#include +#include + +/* === M A C R O S ========================================================= */ + +/* === T Y P E D E F S ===================================================== */ + +/* === C L A S S E S & S T R U C T S ======================================= */ + +namespace studio { + +class AutoRecover +{ + int timeout; + SigC::Connection auto_backup_connect; +public: + AutoRecover(); + ~AutoRecover(); + + static int pid(); + static sinfg::String get_shadow_file_name(const sinfg::String& filename); + + static bool auto_backup(); + + static bool cleanup_pid(int pid); + + void set_timeout(int milliseconds); + int get_timeout()const { return timeout; } + + static sinfg::String get_shadow_directory(); + + bool recovery_needed()const; + bool recover(); + + void normal_shutdown(); + + void clear_backup(sinfg::Canvas::Handle canvas); +}; // END of class AutoRecover + +}; // END of namespace studio + +/* === E N D =============================================================== */ + +#endif diff --git a/synfig-studio/trunk/src/gtkmm/canvasoptions.cpp b/synfig-studio/trunk/src/gtkmm/canvasoptions.cpp new file mode 100644 index 0000000..44d47a7 --- /dev/null +++ b/synfig-studio/trunk/src/gtkmm/canvasoptions.cpp @@ -0,0 +1,182 @@ +/* === S I N F G =========================================================== */ +/*! \file canvasoptions.cpp +** \brief Template File +** +** $Id: canvasoptions.cpp,v 1.1.1.1 2005/01/07 03:34:35 darco Exp $ +** +** \legal +** Copyright (c) 2002 Robert B. Quattlebaum Jr. +** +** This software and associated documentation +** are CONFIDENTIAL and PROPRIETARY property of +** the above-mentioned copyright holder. +** +** You may not copy, print, publish, or in any +** other way distribute this software without +** a prior written agreement with +** the copyright holder. +** \endlegal +*/ +/* ========================================================================= */ + +/* === H E A D E R S ======================================================= */ + +#ifdef USING_PCH +# include "pch.h" +#else +#ifdef HAVE_CONFIG_H +# include +#endif + +#include "canvasoptions.h" +#include +#include +#include +#include +#include "canvasview.h" +#include "workarea.h" + +#endif + +/* === U S I N G =========================================================== */ + +using namespace std; +using namespace etl; +using namespace sinfg; +using namespace studio; + +/* === M A C R O S ========================================================= */ + +/* === G L O B A L S ======================================================= */ + +/* === P R O C E D U R E S ================================================= */ + +/* === M E T H O D S ======================================================= */ + +CanvasOptions::CanvasOptions(loose_handle canvas_view): + Gtk::Dialog(_("Canvas Options"),*canvas_view,false,true), + canvas_view_(canvas_view), + toggle_grid_snap(_("Grid Snap")), + toggle_grid_show(_("Grid Show")), + toggle_time_snap(_("Snap-To-Frame")) +{ + vector_grid_size.set_canvas(canvas_view->get_canvas()); + + Gtk::Notebook *notebook=manage(new class Gtk::Notebook()); + + toggle_grid_snap.signal_toggled().connect(sigc::mem_fun(*this, &studio::CanvasOptions::on_grid_snap_toggle)); + toggle_grid_show.signal_toggled().connect(sigc::mem_fun(*this, &studio::CanvasOptions::on_grid_show_toggle)); + + Gtk::Table *grid_page=manage(new class Gtk::Table(2,2,false)); + notebook->append_page(*grid_page,_("Grids")); + grid_page->attach(vector_grid_size, 0, 2, 0, 1, Gtk::EXPAND|Gtk::FILL, Gtk::EXPAND|Gtk::FILL, 0, 0); + grid_page->attach(toggle_grid_snap, 0, 1, 1, 2, Gtk::EXPAND|Gtk::FILL, Gtk::EXPAND|Gtk::FILL, 0, 0); + grid_page->attach(toggle_grid_show, 1, 2, 1, 2, Gtk::EXPAND|Gtk::FILL, Gtk::EXPAND|Gtk::FILL, 0, 0); + + Gtk::Table *time_page=manage(new class Gtk::Table(2,2,false)); + notebook->append_page(*time_page,_("Time")); + time_page->attach(toggle_time_snap, 0, 1, 0, 1, Gtk::EXPAND|Gtk::FILL, Gtk::EXPAND|Gtk::FILL, 0, 0); + + Gtk::Table *unit_page=manage(new class Gtk::Table(2,2,false)); + notebook->append_page(*unit_page,_("Units")); + unit_page->attach(*manage(new Gtk::Label(_("Not yet implemented"))), 0, 1, 0, 1, Gtk::EXPAND|Gtk::FILL, Gtk::EXPAND|Gtk::FILL, 0, 0); + + + Gtk::Button *ok_button(manage(new class Gtk::Button(Gtk::StockID("gtk-ok")))); + ok_button->show(); + add_action_widget(*ok_button,2); + ok_button->signal_clicked().connect(sigc::mem_fun(*this, &studio::CanvasOptions::on_ok_pressed)); + + Gtk::Button *apply_button(manage(new class Gtk::Button(Gtk::StockID("gtk-apply")))); + apply_button->show(); + add_action_widget(*apply_button,1); + apply_button->signal_clicked().connect(sigc::mem_fun(*this, &studio::CanvasOptions::on_apply_pressed)); + + Gtk::Button *cancel_button(manage(new class Gtk::Button(Gtk::StockID("gtk-close")))); + cancel_button->show(); + add_action_widget(*cancel_button,0); + cancel_button->signal_clicked().connect(sigc::mem_fun(*this, &studio::CanvasOptions::on_cancel_pressed)); + + //set_default_response(1); + + + get_vbox()->pack_start(*notebook); + notebook->show_all(); + + signal_show().connect(sigc::mem_fun(*this, &studio::CanvasOptions::refresh)); + + vector_grid_size.set_digits(5); + + update_title(); +} + +CanvasOptions::~CanvasOptions() +{ +} + +void +CanvasOptions::update_title() +{ + set_title(_("Options")+String(" - ")+canvas_view_->get_canvas()->get_name()); +} + +void +CanvasOptions::refresh() +{ + if(canvas_view_->work_area->grid_status()) + toggle_grid_show.set_active(true); + else + toggle_grid_show.set_active(false); + + if(canvas_view_->work_area->get_grid_snap()) + toggle_grid_snap.set_active(true); + else + toggle_grid_snap.set_active(false); + + vector_grid_size.set_value(canvas_view_->work_area->get_grid_size()); + + tooltips.set_tip(toggle_time_snap,_("Not yet implemented")); + toggle_time_snap.set_sensitive(false); + + update_title(); +} + +void +CanvasOptions::on_grid_snap_toggle() +{ +} + +void +CanvasOptions::on_grid_show_toggle() +{ +} + +void +CanvasOptions::on_apply_pressed() +{ + if(toggle_grid_snap.get_active()) + canvas_view_->work_area->enable_grid_snap(); + else + canvas_view_->work_area->disable_grid_snap(); + + if(toggle_grid_show.get_active()) + canvas_view_->work_area->enable_grid(); + else + canvas_view_->work_area->disable_grid(); + + canvas_view_->work_area->set_grid_size(vector_grid_size.get_value()); +} + +void +CanvasOptions::on_ok_pressed() +{ + on_apply_pressed(); + hide(); +} + +void +CanvasOptions::on_cancel_pressed() +{ + refresh(); + hide(); +} diff --git a/synfig-studio/trunk/src/gtkmm/canvasoptions.h b/synfig-studio/trunk/src/gtkmm/canvasoptions.h new file mode 100644 index 0000000..c34847b --- /dev/null +++ b/synfig-studio/trunk/src/gtkmm/canvasoptions.h @@ -0,0 +1,81 @@ +/* === S I N F G =========================================================== */ +/*! \file canvasoptions.h +** \brief Template Header +** +** $Id: canvasoptions.h,v 1.1.1.1 2005/01/07 03:34:35 darco Exp $ +** +** \legal +** Copyright (c) 2002 Robert B. Quattlebaum Jr. +** +** This software and associated documentation +** are CONFIDENTIAL and PROPRIETARY property of +** the above-mentioned copyright holder. +** +** You may not copy, print, publish, or in any +** other way distribute this software without +** a prior written agreement with +** the copyright holder. +** \endlegal +*/ +/* ========================================================================= */ + +/* === S T A R T =========================================================== */ + +#ifndef __SINFG_GTKMM_CANVASOPTIONS_H +#define __SINFG_GTKMM_CANVASOPTIONS_H + +/* === H E A D E R S ======================================================= */ + +#include +#include +#include +#include +#include +#include "widget_value.h" +#include "widget_vector.h" + +/* === M A C R O S ========================================================= */ + +/* === T Y P E D E F S ===================================================== */ + +/* === C L A S S E S & S T R U C T S ======================================= */ + +namespace studio +{ + +class CanvasView; + +class CanvasOptions : public Gtk::Dialog +{ + Gtk::Tooltips tooltips; + + etl::loose_handle canvas_view_; + + Gtk::CheckButton toggle_grid_snap; + Gtk::CheckButton toggle_grid_show; + + Widget_Vector vector_grid_size; + + Gtk::CheckButton toggle_time_snap; + +public: + CanvasOptions(etl::loose_handle canvas_view); + ~CanvasOptions(); + + void refresh(); + void update_title(); +private: + + void on_grid_snap_toggle(); + void on_grid_show_toggle(); + + void on_ok_pressed(); + void on_apply_pressed(); + void on_cancel_pressed(); +}; // END of class CanvasOptions + +}; // END of namespace studio + +/* === E N D =============================================================== */ + +#endif diff --git a/synfig-studio/trunk/src/gtkmm/canvasproperties.cpp b/synfig-studio/trunk/src/gtkmm/canvasproperties.cpp new file mode 100644 index 0000000..46ecc17 --- /dev/null +++ b/synfig-studio/trunk/src/gtkmm/canvasproperties.cpp @@ -0,0 +1,229 @@ +/* === S I N F G =========================================================== */ +/*! \file canvasproperties.cpp +** \brief Template File +** +** $Id: canvasproperties.cpp,v 1.1.1.1 2005/01/07 03:34:35 darco Exp $ +** +** \legal +** Copyright (c) 2002 Robert B. Quattlebaum Jr. +** +** This software and associated documentation +** are CONFIDENTIAL and PROPRIETARY property of +** the above-mentioned copyright holder. +** +** You may not copy, print, publish, or in any +** other way distribute this software without +** a prior written agreement with +** the copyright holder. +** \endlegal +*/ +/* ========================================================================= */ + +/* === H E A D E R S ======================================================= */ + +#ifdef USING_PCH +# include "pch.h" +#else +#ifdef HAVE_CONFIG_H +# include +#endif + +#include "canvasproperties.h" +#include +#include +#include +#include +#include +#include "metadatatreestore.h" +#include +#include +#include "app.h" + +#endif + +/* === U S I N G =========================================================== */ + +using namespace std; +using namespace etl; +using namespace sinfg; +using namespace studio; + +/* === M A C R O S ========================================================= */ + +/* === G L O B A L S ======================================================= */ + +/* === P R O C E D U R E S ================================================= */ + +/* === M E T H O D S ======================================================= */ + +CanvasProperties::CanvasProperties(Gtk::Window& parent,handle canvas_interface): + Gtk::Dialog(_("Canvas Properties"),parent,false,true), + canvas_interface_(canvas_interface) +{ + widget_rend_desc.show(); + + widget_rend_desc.signal_changed().connect(sigc::mem_fun(*this,&studio::CanvasProperties::on_rend_desc_changed)); + + Gtk::Frame *info_frame=manage(new Gtk::Frame(_("Canvas Info"))); + + Gtk::Table *info_table=manage(new Gtk::Table(2,2,false)); + info_frame->add(*info_table); + + // The root canvas doesn't have an ID, so don't + // display it if this is a root canvas. + if(!canvas_interface_->get_canvas()->is_root()) + { + info_table->attach(*manage(new Gtk::Label(_("ID"))), 0, 1, 0, 1, Gtk::SHRINK|Gtk::FILL, Gtk::SHRINK|Gtk::FILL, 0, 0); + info_table->attach(entry_id, 1, 2, 0, 1, Gtk::EXPAND|Gtk::FILL, Gtk::SHRINK|Gtk::FILL, 0, 0); + } + info_table->attach(*manage(new Gtk::Label(_("Name"))), 0, 1, 1, 2, Gtk::SHRINK|Gtk::FILL, Gtk::SHRINK|Gtk::FILL, 0, 0); + info_table->attach(*manage(new Gtk::Label(_("Description"))), 0, 1, 2, 3, Gtk::SHRINK|Gtk::FILL, Gtk::SHRINK|Gtk::FILL, 0, 0); + info_table->attach(entry_name, 1, 2, 1, 2, Gtk::EXPAND|Gtk::FILL, Gtk::SHRINK|Gtk::FILL, 0, 0); + info_table->attach(entry_description, 1, 2, 2, 3, Gtk::EXPAND|Gtk::FILL, Gtk::SHRINK|Gtk::FILL, 0, 0); + + info_frame->show_all(); + + get_vbox()->pack_start(*info_frame); + + Gtk::Notebook* notebook(manage(new Gtk::Notebook())); + notebook->show(); + notebook->append_page(widget_rend_desc,_("RendDesc")); + //notebook->append_page(create_meta_data_view(),_("MetaData")); + + get_vbox()->pack_start(*notebook); + + canvas_interface_->signal_rend_desc_changed().connect(sigc::mem_fun(*this,&studio::CanvasProperties::refresh)); + + Gtk::Button *ok_button(manage(new class Gtk::Button(Gtk::StockID("gtk-ok")))); + ok_button->show(); + add_action_widget(*ok_button,2); + ok_button->signal_clicked().connect(sigc::mem_fun(*this, &studio::CanvasProperties::on_ok_pressed)); + + Gtk::Button *apply_button(manage(new class Gtk::Button(Gtk::StockID("gtk-apply")))); + apply_button->show(); + add_action_widget(*apply_button,1); + apply_button->signal_clicked().connect(sigc::mem_fun(*this, &studio::CanvasProperties::on_apply_pressed)); + + Gtk::Button *cancel_button(manage(new class Gtk::Button(Gtk::StockID("gtk-close")))); + cancel_button->show(); + add_action_widget(*cancel_button,0); + cancel_button->signal_clicked().connect(sigc::mem_fun(*this, &studio::CanvasProperties::on_cancel_pressed)); + + //set_default_response(1); + + refresh(); + + update_title(); +} + +Gtk::Widget& +CanvasProperties::create_meta_data_view() +{ + MetaDataTreeStore::Model model; + meta_data_tree_view=(manage(new class Gtk::TreeView())); + + meta_data_tree_view->append_column(_("Key"),model.key); + meta_data_tree_view->append_column_editable(_("Data"),model.data); + meta_data_tree_view->set_model(MetaDataTreeStore::create(canvas_interface_)); + meta_data_tree_view->set_rules_hint(); + meta_data_tree_view->show(); + + Gtk::ScrolledWindow *scrolledwindow = manage(new class Gtk::ScrolledWindow()); + scrolledwindow->set_flags(Gtk::CAN_FOCUS); + scrolledwindow->set_policy(Gtk::POLICY_AUTOMATIC, Gtk::POLICY_AUTOMATIC); + scrolledwindow->add(*meta_data_tree_view); + scrolledwindow->set_shadow_type(Gtk::SHADOW_ETCHED_IN); + scrolledwindow->show(); + + + + Gtk::Table *table=manage(new Gtk::Table()); + table->attach(*scrolledwindow, 0, 2, 0, 1, Gtk::EXPAND|Gtk::FILL, Gtk::EXPAND|Gtk::FILL, 0, 0); + + Gtk::Button* button_add(manage(new Gtk::Button(Gtk::StockID("gtk-add")))); + button_add->show(); + button_add->signal_clicked().connect(sigc::mem_fun(*this,&CanvasProperties::on_button_meta_data_add)); + table->attach(*button_add, 0, 1, 1, 2, Gtk::EXPAND|Gtk::FILL, Gtk::SHRINK|Gtk::FILL, 0, 0); + + Gtk::Button* button_delete(manage(new Gtk::Button(Gtk::StockID("gtk-delete")))); + button_delete->show(); + button_delete->signal_clicked().connect(sigc::mem_fun(*this,&CanvasProperties::on_button_meta_data_delete)); + table->attach(*button_delete, 1, 2, 1, 2, Gtk::EXPAND|Gtk::FILL, Gtk::SHRINK|Gtk::FILL, 0, 0); + + table->show(); + return *table; +} + +void +CanvasProperties::on_button_meta_data_add() +{ + sinfg::String key; + if(App::dialog_entry("New MetaData Entry", "Please enter the name of the key",key) && !key.empty()) + { + canvas_interface_->set_meta_data(key," "); + } + +} + +void +CanvasProperties::on_button_meta_data_delete() +{ +} + +void +CanvasProperties::update_title() +{ + set_title(_("Properties")+String(" - ")+canvas_interface_->get_canvas()->get_name()); +} + +void +CanvasProperties::refresh() +{ + widget_rend_desc.set_rend_desc(canvas_interface_->get_canvas()->rend_desc()); + entry_id.set_text(canvas_interface_->get_canvas()->get_id()); + entry_name.set_text(canvas_interface_->get_canvas()->get_name()); + entry_description.set_text(canvas_interface_->get_canvas()->get_description()); + + dirty_rend_desc=false; + + update_title(); +} + +CanvasProperties::~CanvasProperties() +{ +} + +void +CanvasProperties::on_rend_desc_changed() +{ + dirty_rend_desc=true; +} + +void +CanvasProperties::on_apply_pressed() +{ + if(dirty_rend_desc) + canvas_interface_->set_rend_desc(widget_rend_desc.get_rend_desc()); + if(entry_id.get_text()!=canvas_interface_->get_canvas()->get_id()) + canvas_interface_->set_id(entry_id.get_text()); + if(entry_name.get_text()!=canvas_interface_->get_canvas()->get_name()) + canvas_interface_->set_name(entry_name.get_text()); + if(entry_description.get_text()!=canvas_interface_->get_canvas()->get_description()) + canvas_interface_->set_description(entry_description.get_text()); + + dirty_rend_desc=false; +} + +void +CanvasProperties::on_ok_pressed() +{ + on_apply_pressed(); + hide(); +} + +void +CanvasProperties::on_cancel_pressed() +{ + refresh(); + hide(); +} diff --git a/synfig-studio/trunk/src/gtkmm/canvasproperties.h b/synfig-studio/trunk/src/gtkmm/canvasproperties.h new file mode 100644 index 0000000..057ddf1 --- /dev/null +++ b/synfig-studio/trunk/src/gtkmm/canvasproperties.h @@ -0,0 +1,86 @@ +/* === S I N F G =========================================================== */ +/*! \file canvasproperties.h +** \brief Template Header +** +** $Id: canvasproperties.h,v 1.1.1.1 2005/01/07 03:34:35 darco Exp $ +** +** \legal +** Copyright (c) 2002 Robert B. Quattlebaum Jr. +** +** This software and associated documentation +** are CONFIDENTIAL and PROPRIETARY property of +** the above-mentioned copyright holder. +** +** You may not copy, print, publish, or in any +** other way distribute this software without +** a prior written agreement with +** the copyright holder. +** \endlegal +*/ +/* ========================================================================= */ + +/* === S T A R T =========================================================== */ + +#ifndef __SINFG_GTKMM_CANVASPROPERTIES_H +#define __SINFG_GTKMM_CANVASPROPERTIES_H + +/* === H E A D E R S ======================================================= */ + +#include + +#include +#include +#include +#include +#include + +#include "renddesc.h" + +/* === M A C R O S ========================================================= */ + +/* === T Y P E D E F S ===================================================== */ + +/* === C L A S S E S & S T R U C T S ======================================= */ + +namespace Gtk { class TreeView; }; +namespace sinfgapp { class CanvasInterface; }; + +namespace studio +{ +class CanvasProperties : public Gtk::Dialog +{ + Gtk::Tooltips tooltips; + + etl::handle canvas_interface_; + Widget_RendDesc widget_rend_desc; + Gtk::Entry entry_id; + Gtk::Entry entry_name; + Gtk::Entry entry_description; + + bool dirty_rend_desc; + + Gtk::TreeView* meta_data_tree_view; + void on_button_meta_data_add(); + void on_button_meta_data_delete(); + +public: + CanvasProperties(Gtk::Window& parent,etl::handle canvas_interface); + ~CanvasProperties(); + + void refresh(); + void update_title(); +private: + void on_rend_desc_changed(); + + Gtk::Widget& create_meta_data_view(); + + void on_ok_pressed(); + void on_apply_pressed(); + void on_cancel_pressed(); +}; // END of class CanvasProperties + +}; // END of namespace studio + +/* === E N D =============================================================== */ + +#endif diff --git a/synfig-studio/trunk/src/gtkmm/canvastreestore.cpp b/synfig-studio/trunk/src/gtkmm/canvastreestore.cpp new file mode 100644 index 0000000..4a4ea6f --- /dev/null +++ b/synfig-studio/trunk/src/gtkmm/canvastreestore.cpp @@ -0,0 +1,617 @@ +/* === S I N F G =========================================================== */ +/*! \file canvastreestore.cpp +** \brief Template File +** +** $Id: canvastreestore.cpp,v 1.1.1.1 2005/01/07 03:34:35 darco Exp $ +** +** \legal +** Copyright (c) 2002 Robert B. Quattlebaum Jr. +** +** This software and associated documentation +** are CONFIDENTIAL and PROPRIETARY property of +** the above-mentioned copyright holder. +** +** You may not copy, print, publish, or in any +** other way distribute this software without +** a prior written agreement with +** the copyright holder. +** \endlegal +*/ +/* ========================================================================= */ + +/* === H E A D E R S ======================================================= */ + +#ifdef USING_PCH +# include "pch.h" +#else +#ifdef HAVE_CONFIG_H +# include +#endif + +#include "canvastreestore.h" +#include +#include "iconcontroler.h" +#include +#include +#include +#include +#include "cellrenderer_value.h" +#include "cellrenderer_timetrack.h" +#include + +#endif + +/* === U S I N G =========================================================== */ + +using namespace std; +using namespace etl; +using namespace sinfg; +using namespace studio; + +/* === M A C R O S ========================================================= */ + +/* === G L O B A L S ======================================================= */ + +/* === P R O C E D U R E S ================================================= */ + +/* === M E T H O D S ======================================================= */ + +static CanvasTreeStore::Model& ModelHack() +{ + static CanvasTreeStore::Model* model(0); + if(!model)model=new CanvasTreeStore::Model; + return *model; +} + +CanvasTreeStore::CanvasTreeStore(etl::loose_handle canvas_interface_): + Gtk::TreeStore(ModelHack()), + canvas_interface_ (canvas_interface_) +{ +} + +CanvasTreeStore::~CanvasTreeStore() +{ +} + +void +CanvasTreeStore::get_value_vfunc (const Gtk::TreeModel::iterator& iter, int column, Glib::ValueBase& value)const +{ + if(column==model.value.index()) + { + sinfgapp::ValueDesc value_desc((*iter)[model.value_desc]); + + Glib::Value x; + g_value_init(x.gobj(),x.value_type()); + + if(!value_desc) + { + x.set(ValueBase()); + } + else + if(value_desc.is_const()) + x.set(value_desc.get_value()); + else + if(value_desc.is_value_node()) + x.set((*value_desc.get_value_node())(canvas_interface()->get_time())); + else + { + sinfg::error(__FILE__":%d: Unable to figure out value",__LINE__); + return; + } + + g_value_init(value.gobj(),x.value_type()); + g_value_copy(x.gobj(),value.gobj()); + } + else + if(column==model.is_value_node.index()) + { + sinfgapp::ValueDesc value_desc((*iter)[model.value_desc]); + + Glib::Value x; + g_value_init(x.gobj(),x.value_type()); + + x.set(value_desc && value_desc.is_value_node()); + + g_value_init(value.gobj(),x.value_type()); + g_value_copy(x.gobj(),value.gobj()); + } + else + if(column==model.is_shared.index()) + { + sinfgapp::ValueDesc value_desc((*iter)[model.value_desc]); + + Glib::Value x; + g_value_init(x.gobj(),x.value_type()); + + x.set(value_desc.is_value_node() && value_desc.get_value_node()->rcount()>1); + + g_value_init(value.gobj(),x.value_type()); + g_value_copy(x.gobj(),value.gobj()); + } + else + if(column==model.is_exported.index()) + { + sinfgapp::ValueDesc value_desc((*iter)[model.value_desc]); + + Glib::Value x; + g_value_init(x.gobj(),x.value_type()); + + x.set(value_desc.is_value_node() && value_desc.get_value_node()->is_exported()); + + g_value_init(value.gobj(),x.value_type()); + g_value_copy(x.gobj(),value.gobj()); + } + else + if(column==model.is_canvas.index()) + { + sinfgapp::ValueDesc value_desc((*iter)[model.value_desc]); + + Glib::Value x; + g_value_init(x.gobj(),x.value_type()); + + x.set(!value_desc && (Canvas::Handle)(*iter)[model.canvas]); + + g_value_init(value.gobj(),x.value_type()); + g_value_copy(x.gobj(),value.gobj()); + } + else + if(column==model.id.index()) + { + sinfgapp::ValueDesc value_desc((*iter)[model.value_desc]); + + Glib::Value x; + g_value_init(x.gobj(),x.value_type()); + + if(value_desc && value_desc.is_value_node()) + x.set(value_desc.get_value_node()->get_id()); + else if(!value_desc && Canvas::Handle((*iter)[model.canvas])) + x.set(Canvas::Handle((*iter)[model.canvas])->get_id()); + else + return Gtk::TreeStore::get_value_vfunc(iter,column,value); + + g_value_init(value.gobj(),x.value_type()); + g_value_copy(x.gobj(),value.gobj()); + } + else + if(column==model.is_editable.index()) + { + sinfgapp::ValueDesc value_desc((*iter)[model.value_desc]); + + Glib::Value x; + g_value_init(x.gobj(),x.value_type()); + + x.set(!value_desc.is_value_node() || sinfgapp::is_editable(value_desc.get_value_node())); + + g_value_init(value.gobj(),x.value_type()); + g_value_copy(x.gobj(),value.gobj()); + } + else + if(column==model.type.index()) + { + sinfgapp::ValueDesc value_desc((*iter)[model.value_desc]); + + Glib::Value x; + g_value_init(x.gobj(),x.value_type()); + + // Set the type + if(!value_desc) + { + if((*iter)[model.is_canvas]) + x.set(_("Canvas")); + } + else + { + if(!value_desc.is_value_node() || value_desc.get_value_node()->get_name()=="constant") + { + x.set(ValueBase::type_name(value_desc.get_value_type())); + } + else + { + x.set(value_desc.get_value_node()->get_local_name()); + } + } + + g_value_init(value.gobj(),x.value_type()); + g_value_copy(x.gobj(),value.gobj()); + } + else + if(column==model.label.index()) + { + sinfgapp::ValueDesc value_desc((*iter)[model.value_desc]); + + Glib::Value x; + g_value_init(x.gobj(),x.value_type()); + + // Set the type + if(!value_desc) + { + Canvas::Handle canvas((*iter)[model.canvas]); + if(canvas) + { + if(!canvas->get_id().empty()) + x.set(canvas->get_id()); + else + if(!canvas->get_name().empty()) + x.set(canvas->get_name()); + else + x.set(_("[Unnamed]")); + x.set(_("Canvas")); + } + return Gtk::TreeStore::get_value_vfunc(iter,column,value); + } + else + { + ValueNode::Handle value_node=value_desc.get_value_node(); + + // Setup the row's label + if(value_node->get_id().empty()) + x.set(Glib::ustring((*iter)[model.name])); + else if(Glib::ustring((*iter)[model.name]).empty()) + x.set(value_node->get_id()); + else + x.set(Glib::ustring((*iter)[model.name])+" ("+value_node->get_id()+')'); + } + + g_value_init(value.gobj(),x.value_type()); + g_value_copy(x.gobj(),value.gobj()); + } + else + if(column==model.icon.index()) + { + sinfgapp::ValueDesc value_desc((*iter)[model.value_desc]); + if(!value_desc) + return Gtk::TreeStore::get_value_vfunc(iter,column,value); + + Glib::Value > x; + g_value_init(x.gobj(),x.value_type()); + + x.set(get_tree_pixbuf(value_desc.get_value_type())); + + g_value_init(value.gobj(),x.value_type()); + g_value_copy(x.gobj(),value.gobj()); + } + else + Gtk::TreeStore::get_value_vfunc(iter,column,value); +} + +bool +CanvasTreeStore::find_first_value_desc(const sinfgapp::ValueDesc& value_desc, Gtk::TreeIter& iter) +{ + iter=children().begin(); + while(iter && value_desc!=(*iter)[model.value_desc]) + { + if(!iter->children().empty()) + { + Gtk::TreeIter iter2(iter->children().begin()); + if(iter2 && value_desc==(*iter2)[model.value_desc] || find_next_value_desc(value_desc, iter2)) + { + iter=iter2; + return true; + } + } + Gtk::TreeIter iter2(++iter); + if(!iter2) + iter==iter->parent(); + else + iter=iter2; + } + return (bool)iter && value_desc==(*iter)[model.value_desc]; +} + +bool +CanvasTreeStore::find_next_value_desc(const sinfgapp::ValueDesc& value_desc, Gtk::TreeIter& iter) +{ + if(!iter) return find_first_value_desc(value_desc,iter); + + if(iter) do { + if(!iter->children().empty()) + { + Gtk::TreeIter iter2(iter->children().begin()); + if(iter2 && value_desc==(*iter2)[model.value_desc] || find_next_value_desc(value_desc, iter2)) + { + iter=iter2; + return true; + } + } + Gtk::TreeIter iter2(++iter); + if(!iter2) + { + iter==iter->parent(); + if(iter)++iter; + } + else + iter=iter2; + } while(iter && value_desc!=(*iter)[model.value_desc]); + return (bool)iter && value_desc==(*iter)[model.value_desc]; +} + + + + + + +bool +CanvasTreeStore::find_first_value_node(const ValueNode::Handle& value_node, Gtk::TreeIter& iter) +{ + iter=children().begin(); + while(iter && value_node!=(ValueNode::Handle)(*iter)[model.value_node]) + { + if(!iter->children().empty()) + { + Gtk::TreeIter iter2(iter->children().begin()); + if(iter2 && value_node==(ValueNode::Handle)(*iter2)[model.value_node] || find_next_value_node(value_node, iter2)) + { + iter=iter2; + return true; + } + } + Gtk::TreeIter iter2(++iter); + if(!iter2) + iter==iter->parent(); + else + iter=iter2; + } + return (bool)iter && value_node==(ValueNode::Handle)(*iter)[model.value_node]; +} + +bool +CanvasTreeStore::find_next_value_node(const ValueNode::Handle& value_node, Gtk::TreeIter& iter) +{ + if(!iter) return find_first_value_node(value_node,iter); + + if(iter) do { + if(!iter->children().empty()) + { + Gtk::TreeIter iter2(iter->children().begin()); + if(iter2 && value_node==(ValueNode::Handle)(*iter2)[model.value_node] || find_next_value_node(value_node, iter2)) + { + iter=iter2; + return true; + } + } + Gtk::TreeIter iter2(++iter); + if(!iter2) + { + iter==iter->parent(); + if(iter)++iter; + } + else + iter=iter2; + } while(iter && value_node!=(ValueNode::Handle)(*iter)[model.value_node]); + return (bool)iter && value_node==(ValueNode::Handle)(*iter)[model.value_node]; +} + +void +CanvasTreeStore::set_row(Gtk::TreeRow row,sinfgapp::ValueDesc value_desc, bool do_children) +{ + Gtk::TreeModel::Children children = row.children(); + while(!children.empty() && erase(children.begin())); + + row[model.value_desc]=value_desc; + try + { + //row[model.icon] = get_tree_pixbuf(value_desc.get_value_type()); + + if(value_desc.is_value_node()) + { + ValueNode::Handle value_node=value_desc.get_value_node(); + + assert(value_node); + + row[model.value_node] = value_node; + //row[model.is_canvas] = false; + //row[model.is_value_node] = true; + //row[model.is_editable] = sinfgapp::is_editable(value_node); + //row[model.id]=value_node->get_id(); + + // Set the canvas + if(value_desc.parent_is_canvas()) + row[model.canvas]=value_desc.get_canvas(); + else + row[model.canvas]=canvas_interface()->get_canvas(); + + LinkableValueNode::Handle linkable; + linkable=LinkableValueNode::Handle::cast_dynamic(value_node); + + if(linkable && do_children) + { + row[model.link_count] = linkable->link_count(); + for(int i=0;ilink_count();i++) + { + Gtk::TreeRow child_row=*(append(row.children())); + child_row[model.link_id] = i; + child_row[model.canvas] = static_cast(row[model.canvas]); + child_row[model.name] = linkable->link_local_name(i); + set_row(child_row,sinfgapp::ValueDesc(linkable,i)); + } + } + return; + } + else + { + //row[model.is_value_node] = false; + //row[model.is_editable] = true; + //row[model.label] = Glib::ustring(row[model.name]); + return; + } + } + catch(sinfg::Exception::IDNotFound x) + { + sinfg::error(__FILE__":%d: IDNotFound thrown",__LINE__); + erase(row); + return; + } + + // We should never get to this point + assert(0); +} + +void +CanvasTreeStore::refresh_row(Gtk::TreeModel::Row &row, bool do_children) +{ + sinfgapp::ValueDesc value_desc=row[model.value_desc]; + + if(value_desc) + { + if((bool)row[model.is_value_node] != value_desc.is_value_node() || + (!bool(row[model.is_value_node]) && row[model.link_count]!=0)) + { + set_row(row,value_desc,do_children); + return; + } + + if(row[model.is_value_node]) + { + ValueNode::Handle value_node(value_desc.get_value_node()); + + if(ValueNode::Handle(row[model.value_node])!=value_node) + { + rebuild_row(row,do_children); + return; + } + + //row[model.id]=value_node->get_id(); + + // Setup the row's label + /* + if(value_node->get_id().empty()) + row[model.label] = Glib::ustring(row[model.name]); + else if(Glib::ustring(row[model.name]).empty()) + row[model.label] = value_node->get_id(); + else + row[model.label] = Glib::ustring(row[model.name])+" ("+value_node->get_id()+')'; + */ + + LinkableValueNode::Handle linkable; + linkable=LinkableValueNode::Handle::cast_dynamic(value_node); + if(do_children && linkable && ((int)row[model.link_count] != linkable->link_count())) + { + // Gtk::TreeModel::Children children = row.children(); + // while(!children.empty() && erase(children.begin())); + + set_row(row,value_desc); + return; + } + } + else + { + //row[model.label] = Glib::ustring(row[model.name]); + //row[model.is_value_node] = false; + //row[model.is_editable] = true; + } + } + if(!do_children) + return; + + Gtk::TreeModel::Children children = row.children(); + Gtk::TreeModel::Children::iterator iter; + + if(!children.empty()) + for(iter = children.begin(); iter != children.end(); ++iter) + { + Gtk::TreeRow row=*iter; + refresh_row(row); + } +} + +void +CanvasTreeStore::rebuild_row(Gtk::TreeModel::Row &row, bool do_children) +{ + sinfgapp::ValueDesc value_desc=(sinfgapp::ValueDesc)row[model.value_desc]; + + if(value_desc && value_desc.get_value_node()) + { + ValueNode::Handle value_node; + value_node=value_desc.get_value_node(); + + assert(value_node);if(!value_node)return; + + if(value_node && value_node!=(ValueNode::Handle)row[model.value_node]) + { +// Gtk::TreeModel::Children children = row.children(); +// while(!children.empty() && erase(children.begin())); + + set_row(row,value_desc,do_children); + return; + } + + LinkableValueNode::Handle linkable; + linkable=LinkableValueNode::Handle::cast_dynamic(value_node); + + if( do_children && linkable && (int)row[model.link_count] != linkable->link_count()) + { +// Gtk::TreeModel::Children children = row.children(); +// while(!children.empty() && erase(children.begin())); + + set_row(row,value_desc); + return; + } + + //if(!value_node) + // value_node=row[model.value_node]; + + row[model.id]=value_node->get_id(); + + // Setup the row's label + if(value_node->get_id().empty()) + row[model.label] = Glib::ustring(row[model.name]); + else if(Glib::ustring(row[model.name]).empty()) + row[model.label] = value_node->get_id(); + else + row[model.label] = Glib::ustring(row[model.name])+" ("+value_node->get_id()+')'; + } + else + { + row[model.label] = Glib::ustring(row[model.name]); + row[model.is_value_node] = false; + row[model.is_editable] = true; + Gtk::TreeModel::Children children = row.children(); + while(!children.empty() && erase(children.begin())); + } + if(!do_children) + return; + + Gtk::TreeModel::Children children = row.children(); + Gtk::TreeModel::Children::iterator iter; + if(!children.empty()) + for(iter = children.begin(); iter != children.end(); ++iter) + { + Gtk::TreeRow row=*iter; + rebuild_row(row); + } +} + +CellRenderer_ValueBase* +CanvasTreeStore::add_cell_renderer_value(Gtk::TreeView::Column* column) +{ + const CanvasTreeStore::Model model; + + CellRenderer_ValueBase* ret; + + ret=Gtk::manage( new CellRenderer_ValueBase() ); + + column->pack_start(*ret,true); + column->add_attribute(ret->property_value(), model.value); + column->add_attribute(ret->property_editable(), model.is_editable); + column->add_attribute(ret->property_canvas(), model.canvas); + + return ret; +} + +CellRenderer_TimeTrack* +CanvasTreeStore::add_cell_renderer_value_node(Gtk::TreeView::Column* column) +{ + const CanvasTreeStore::Model model; + + CellRenderer_TimeTrack* ret; + + ret = Gtk::manage( new CellRenderer_TimeTrack() ); + + column->pack_start(*ret,true); + //column->add_attribute(ret->property_visible(), model.is_value_node); + column->add_attribute(ret->property_value_desc(), model.value_desc); + column->add_attribute(ret->property_canvas(), model.canvas); + + + return ret; +} diff --git a/synfig-studio/trunk/src/gtkmm/canvastreestore.h b/synfig-studio/trunk/src/gtkmm/canvastreestore.h new file mode 100644 index 0000000..b011fbb --- /dev/null +++ b/synfig-studio/trunk/src/gtkmm/canvastreestore.h @@ -0,0 +1,194 @@ +/* === S I N F G =========================================================== */ +/*! \file canvastreestore.h +** \brief Template Header +** +** $Id: canvastreestore.h,v 1.1.1.1 2005/01/07 03:34:35 darco Exp $ +** +** \legal +** Copyright (c) 2002 Robert B. Quattlebaum Jr. +** +** This software and associated documentation +** are CONFIDENTIAL and PROPRIETARY property of +** the above-mentioned copyright holder. +** +** You may not copy, print, publish, or in any +** other way distribute this software without +** a prior written agreement with +** the copyright holder. +** \endlegal +*/ +/* ========================================================================= */ + +/* === S T A R T =========================================================== */ + +#ifndef __SINFG_STUDIO_CANVASTREESTORE_H +#define __SINFG_STUDIO_CANVASTREESTORE_H + +/* === H E A D E R S ======================================================= */ + +#include +#include +#include +#include +#include + +/* === M A C R O S ========================================================= */ + +/* === T Y P E D E F S ===================================================== */ + +/* === C L A S S E S & S T R U C T S ======================================= */ + +namespace studio { + +class CellRenderer_TimeTrack; +class CellRenderer_ValueBase; + + enum ColumnID + { + COLUMNID_ID, + COLUMNID_VALUE, + COLUMNID_TIME_TRACK, + COLUMNID_TYPE, + + COLUMNID_END //!< \internal + }; +#define COLUMNID_NAME COLUMNID_ID + +class CanvasTreeStore : virtual public Gtk::TreeStore +{ + /* + -- ** -- P U B L I C T Y P E S --------------------------------------------- + */ + +public: + + class Model : public Gtk::TreeModel::ColumnRecord + { + public: + Gtk::TreeModelColumn > icon; + Gtk::TreeModelColumn label; + Gtk::TreeModelColumn name; + Gtk::TreeModelColumn id; + + Gtk::TreeModelColumn canvas; + Gtk::TreeModelColumn is_canvas; + + Gtk::TreeModelColumn value_node; + Gtk::TreeModelColumn is_value_node; + Gtk::TreeModelColumn value; + Gtk::TreeModelColumn type; + Gtk::TreeModelColumn link_id; + Gtk::TreeModelColumn link_count; + + Gtk::TreeModelColumn is_editable; + + Gtk::TreeModelColumn is_shared; + Gtk::TreeModelColumn is_exported; + + Gtk::TreeModelColumn value_desc; + + Gtk::TreeModelColumn tooltip; + + Model() + { + add(value); + add(name); + add(label); + add(icon); + add(type); + add(id); + add(canvas); + add(value_node); + add(is_canvas); + add(is_value_node); + + add(is_shared); + add(is_exported); + add(is_editable); + add(value_desc); + add(link_count); + add(link_id); + + add(tooltip); + } + }; + + /* + -- ** -- P U B L I C D A T A ------------------------------------------------ + */ + +public: + + const Model model; + + //std::multimap, sigc::connection> connection_map; + + /* + -- ** -- P R I V A T E D A T A --------------------------------------------- + */ + +private: + + etl::loose_handle canvas_interface_; + + /* + -- ** -- P R I V A T E M E T H O D S --------------------------------------- + */ + +private: + +protected: + virtual void get_value_vfunc (const Gtk::TreeModel::iterator& iter, int column, Glib::ValueBase& value)const; + + /* + -- ** -- S I G N A L T E R M I N A L S ------------------------------------- + */ + +private: + + /* + -- ** -- P U B L I C M E T H O D S ----------------------------------------- + */ + +public: + + CanvasTreeStore(etl::loose_handle canvas_interface_); + ~CanvasTreeStore(); + + etl::loose_handle canvas_interface() { return canvas_interface_; } + etl::loose_handle canvas_interface()const { return canvas_interface_; } + + virtual void rebuild_row(Gtk::TreeModel::Row &row, bool do_children=true); + + virtual void refresh_row(Gtk::TreeModel::Row &row, bool do_children=true); + + virtual void set_row(Gtk::TreeRow row,sinfgapp::ValueDesc value_desc, bool do_children=true); + + bool find_first_value_desc(const sinfgapp::ValueDesc& value_desc, Gtk::TreeIter& iter); + bool find_next_value_desc(const sinfgapp::ValueDesc& value_desc, Gtk::TreeIter& iter); + + bool find_first_value_node(const sinfg::ValueNode::Handle& value_node, Gtk::TreeIter& iter); + bool find_next_value_node(const sinfg::ValueNode::Handle& value_node, Gtk::TreeIter& iter); + + + static CellRenderer_ValueBase* add_cell_renderer_value(Gtk::TreeView::Column* column); + + static CellRenderer_TimeTrack* add_cell_renderer_value_node(Gtk::TreeView::Column* column); + + etl::loose_handle get_canvas_interface()const { return canvas_interface_; } + + virtual void on_value_node_changed(sinfg::ValueNode::Handle value_node)=0; + + /* + -- ** -- P R O T E C T E D M E T H O D S ----------------------------------- + */ + +public: + +}; // END of class CanvasTreeStore + +}; // END of namespace studio + +/* === E N D =============================================================== */ + +#endif diff --git a/synfig-studio/trunk/src/gtkmm/canvasview.cpp b/synfig-studio/trunk/src/gtkmm/canvasview.cpp new file mode 100644 index 0000000..5d4c96b --- /dev/null +++ b/synfig-studio/trunk/src/gtkmm/canvasview.cpp @@ -0,0 +1,3552 @@ +/* === S I N F G =========================================================== */ +/*! \file canvasview.cpp +** \brief Template File +** +** $Id: canvasview.cpp,v 1.7 2005/01/16 19:55:57 darco Exp $ +** +** \legal +** Copyright (c) 2002 Robert B. Quattlebaum Jr. +** +** This software and associated documentation +** are CONFIDENTIAL and PROPRIETARY property of +** the above-mentioned copyright holder. +** +** You may not copy, print, publish, or in any +** other way distribute this software without +** a prior written agreement with +** the copyright holder. +** \endlegal +*/ +/* ========================================================================= */ + +/* === H E A D E R S ======================================================= */ + +#ifdef USING_PCH +# include "pch.h" +#else +#ifdef HAVE_CONFIG_H +# include +#endif + +#include + +#include +#include + +#include +#include +#include +#include +#include + +#include +#include + +#include +#include +#include +#include +#include +#include +#include +#include +#include + +#include +#include +#include +//#include +//#include + +#include +#include +//#include + +#include "canvasview.h" +#include "instance.h" +#include "app.h" +#include "cellrenderer_value.h" +#include "cellrenderer_timetrack.h" +#include "workarea.h" +#include "dialog_color.h" +#include "eventkey.h" + +#include "state_polygon.h" +#include "state_bline.h" +#include "state_normal.h" +#include "state_eyedrop.h" +#include "state_draw.h" + +#include "ducktransform_scale.h" +#include "ducktransform_translate.h" +#include "ducktransform_rotate.h" + +#include "event_mouse.h" +#include "event_layerclick.h" + +#include "toolbox.h" + +#include "dialog_preview.h" +#include "dialog_soundselect.h" + +#include "preview.h" +#include "audiocontainer.h" +#include "widget_timeslider.h" + +#include +#include + +#endif + +/* === U S I N G =========================================================== */ + +using namespace std; +using namespace etl; +using namespace sinfg; +using namespace studio; +using namespace SigC; + +/* === M A C R O S ========================================================= */ + +#define GRAB_HINT_DATA(y) { \ + String x; \ + if(sinfgapp::Main::settings().get_value(String("pref.")+y+"_hints",x)) \ + { \ + set_type_hint((Gdk::WindowTypeHint)atoi(x.c_str())); \ + } \ + } + +#define DEFAULT_TIME_WINDOW_SIZE (10.0) + +/* +#ifdef DEBUGPOINT +#undef DEBUGPOINT +#endif +#define DEBUGPOINT() +*/ + +#ifndef SMALL_BUTTON +#define SMALL_BUTTON(button,stockid,tooltip) \ + button = manage(new class Gtk::Button()); \ + icon=manage(new Gtk::Image(Gtk::StockID(stockid),iconsize)); \ + button->add(*icon); \ + tooltips.set_tip(*button,tooltip); \ + icon->set_padding(0,0);\ + icon->show(); \ + button->set_relief(Gtk::RELIEF_NONE); \ + button->show() +#endif + +#ifndef NORMAL_BUTTON +#define NORMAL_BUTTON(button,stockid,tooltip) \ + button = manage(new class Gtk::Button()); \ + icon=manage(new Gtk::Image(Gtk::StockID(stockid),Gtk::ICON_SIZE_BUTTON)); \ + button->add(*icon); \ + tooltips.set_tip(*button,tooltip); \ + icon->set_padding(0,0);\ + icon->show(); \ + /*button->set_relief(Gtk::RELIEF_NONE);*/ \ + button->show() +#endif + +#define NEW_SMALL_BUTTON(x,y,z) Gtk::Button *SMALL_BUTTON(x,y,z) + +#define NOT_IMPLEMENTED_SLOT sigc::mem_fun(*reinterpret_cast(get_ui_interface().get()),&studio::CanvasViewUIInterface::not_implemented) + +#define SLOT_EVENT(x) sigc::hide_return(sigc::bind(sigc::mem_fun(*this,&studio::CanvasView::process_event_key),x)) + +/* === C L A S S E S ======================================================= */ + + +class studio::UniversalScrubber +{ + CanvasView *canvas_view; + + bool scrubbing; + etl::clock scrub_timer; + + sigc::connection end_scrub_connection; +public: + UniversalScrubber(CanvasView *canvas_view): + canvas_view(canvas_view), + scrubbing(false) + { + canvas_view->canvas_interface()->signal_time_changed().connect( + sigc::mem_fun(*this,&studio::UniversalScrubber::on_time_changed) + ); + } + + ~UniversalScrubber() + { + end_scrub_connection.disconnect(); + } + + void on_time_changed() + { + // Make sure we are changing the time quickly + // before we enable scrubbing + if(!scrubbing && scrub_timer()>1) + { + scrub_timer.reset(); + return; + } + + // If we aren't scrubbing already, enable it + if(!scrubbing) + { + scrubbing=true; + audio_container()->start_scrubbing(canvas_view->get_time()); + } + + // Reset the scrubber ender + end_scrub_connection.disconnect(); + end_scrub_connection=Glib::signal_timeout().connect( + sigc::bind_return( + sigc::mem_fun(*this,&UniversalScrubber::end_of_scrubbing), + false + ), + 1000 + ); + + // Scrub! + audio_container()->scrub(canvas_view->get_time()); + + scrub_timer.reset(); + } + + void end_of_scrubbing() + { + scrubbing=false; + audio_container()->stop_scrubbing(); + scrub_timer.reset(); + } + + handle audio_container() + { + assert(canvas_view->audio); + return canvas_view->audio; + } +}; + + +class studio::CanvasViewUIInterface : public sinfgapp::UIInterface +{ + CanvasView *view; + +public: + + CanvasViewUIInterface(CanvasView *view): + view(view) + { + + view->statusbar->push("Idle"); + } + + ~CanvasViewUIInterface() + { + //view->statusbar->pop(); + //view->progressbar->set_fraction(0); + } + + virtual Response yes_no(const std::string &title, const std::string &message,Response dflt=RESPONSE_YES) + { + view->present(); + //while(studio::App::events_pending())studio::App::iteration(false); + Gtk::Dialog dialog( + title, // Title + *view, // Parent + true, // Modal + true // use_separator + ); + Gtk::Label label(message); + label.show(); + + dialog.get_vbox()->pack_start(label); + dialog.add_button(Gtk::StockID("gtk-yes"),RESPONSE_YES); + dialog.add_button(Gtk::StockID("gtk-no"),RESPONSE_NO); + + dialog.set_default_response(dflt); + dialog.show(); + return (Response)dialog.run(); + } + virtual Response yes_no_cancel(const std::string &title, const std::string &message,Response dflt=RESPONSE_YES) + { + view->present(); + //while(studio::App::events_pending())studio::App::iteration(false); + Gtk::Dialog dialog( + title, // Title + *view, // Parent + true, // Modal + true // use_separator + ); + Gtk::Label label(message); + label.show(); + + dialog.get_vbox()->pack_start(label); + dialog.add_button(Gtk::StockID("gtk-yes"),RESPONSE_YES); + dialog.add_button(Gtk::StockID("gtk-no"),RESPONSE_NO); + dialog.add_button(Gtk::StockID("gtk-cancel"),RESPONSE_CANCEL); + + dialog.set_default_response(dflt); + dialog.show(); + return (Response)dialog.run(); + } + virtual Response ok_cancel(const std::string &title, const std::string &message,Response dflt=RESPONSE_OK) + { + view->present(); + //while(studio::App::events_pending())studio::App::iteration(false); + Gtk::Dialog dialog( + title, // Title + *view, // Parent + true, // Modal + true // use_separator + ); + Gtk::Label label(message); + label.show(); + + dialog.get_vbox()->pack_start(label); + dialog.add_button(Gtk::StockID("gtk-ok"),RESPONSE_OK); + dialog.add_button(Gtk::StockID("gtk-cancel"),RESPONSE_CANCEL); + + dialog.set_default_response(dflt); + dialog.show(); + return (Response)dialog.run(); + } + + virtual bool + task(const std::string &task) + { + if(!view->is_playing_) + { + view->statusbar->pop(); + view->statusbar->push(task); + } + //while(studio::App::events_pending())studio::App::iteration(false); + if(view->cancel){return false;} + return true; + } + + virtual bool + error(const std::string &err) + { + view->statusbar->push("ERROR"); + + // If we are in the process of canceling, + // then just go ahead and return false -- + // don't bother displaying a dialog + if(view->cancel)return false; + + Gtk::Dialog dialog( + "Error", // Title + *view, // Parent + true, // Modal + true // use_separator + ); + Gtk::Label label(err); + label.show(); + + dialog.get_vbox()->pack_start(label); + dialog.add_button(Gtk::StockID("gtk-ok"),RESPONSE_OK); + dialog.show(); + dialog.run(); + view->statusbar->pop(); + return true; + } + + virtual bool + warning(const std::string &err) + { + view->statusbar->pop(); + view->statusbar->push(err); + + //while(studio::App::events_pending())studio::App::iteration(false); + if(view->cancel)return false; + return true; + } + + virtual bool + amount_complete(int current, int total) + { + if(!view->is_playing_) + { + if(!view->working_depth) + { + if(current) + view->stopbutton->set_sensitive(true); + else + view->stopbutton->set_sensitive(false); + } + float x((float)current/(float)total); + if(x<0)x=0; + else if(x>1)x=1; + view->progressbar->set_fraction(x); + } + //while(studio::App::events_pending())studio::App::iteration(false); + if(view->cancel){/*view->cancel=false;*/return false;} + return true; + } + + void + not_implemented() + { + error("Feature not yet implemented"); + } +}; + +class studio::CanvasViewSelectionManager : public sinfgapp::SelectionManager +{ + CanvasView *view; + CanvasView::LayerTreeModel layer_tree_model; + CanvasView::ChildrenTreeModel children_tree_model; +public: + + CanvasViewSelectionManager(CanvasView *view): view(view) +{ + + } + + +private: + void _set_selected_layer(const sinfg::Layer::Handle &layer) + { + view->layer_tree->select_layer(layer); +/* + // Don't change the selection while we are busy + // I cannot remember exactly why I put this here... + // It musta been for some reason, but I cannot recall. + //if(App::Busy::count) + // return; + + if(view->layer_tree->get_selection()->get_selected()) + { + const Gtk::TreeRow row = *(view->layer_tree->get_selection()->get_selected()); + + // Don't do anything if that layer is already selected + if(layer == static_cast(row[layer_tree_model.layer])) + return; + } + Gtk::TreeModel::Children::iterator iter; + if(view->layer_tree_store()->find_layer_row(layer,iter)) + { + Gtk::TreePath path(iter); + for(int i=path.get_depth();i;i--) + { + int j; + path=Gtk::TreePath(iter); + for(j=i;j;j--) + path.up(); + view->layer_tree->get_tree_view().expand_row(path,false); + } + view->layer_tree->get_tree_view().scroll_to_row(Gtk::TreePath(iter)); + view->layer_tree->get_selection()->select(iter); + } +*/ + } +public: + + //! Returns the number of layers selected. + virtual int get_selected_layer_count()const + { + return get_selected_layers().size(); + } + + //! Returns a list of the currently selected layers. + virtual LayerList get_selected_layers()const + { +// assert(view->layer_tree); + + if(!view->layer_tree) { DEBUGPOINT(); sinfg::error("canvas_view.layer_tree not defined!?"); return LayerList(); } + return view->layer_tree->get_selected_layers(); + } + + //! Returns the first layer selected or an empty handle if none are selected. + virtual sinfg::Layer::Handle get_selected_layer()const + { +// assert(view->layer_tree); + + if(!view->layer_tree) { DEBUGPOINT(); sinfg::error("canvas_view.layer_tree not defined!?"); return 0; } + return view->layer_tree->get_selected_layer(); + } + + //! Sets which layers should be selected + virtual void set_selected_layers(const LayerList &layer_list) + { +// assert(view->layer_tree); + + if(!view->layer_tree) { DEBUGPOINT(); sinfg::error("canvas_view.layer_tree not defined!?"); return; } + view->layer_tree->select_layers(layer_list); + //view->get_smach().process_event(EVENT_REFRESH_DUCKS); + + //view->queue_rebuild_ducks(); + } + + //! Sets which layer should be selected. + virtual void set_selected_layer(const sinfg::Layer::Handle &layer) + { +// assert(view->layer_tree); + + if(!view->layer_tree) { DEBUGPOINT(); sinfg::error("canvas_view.layer_tree not defined!?"); return; } + view->layer_tree->select_layer(layer); + //view->queue_rebuild_ducks(); + } + + //! Clears the layer selection list + virtual void clear_selected_layers() + { + if(!view->layer_tree) return; + view->layer_tree->clear_selected_layers(); + } + + + + //! Returns the number of value_nodes selected. + virtual int get_selected_children_count()const + { + return get_selected_children().size(); + } + + static inline void __child_grabber(const Gtk::TreeModel::iterator& iter, ChildrenList* ret) + { + const CanvasView::ChildrenTreeModel children_tree_model; + sinfgapp::ValueDesc value_desc((*iter)[children_tree_model.value_desc]); + if(value_desc) + ret->push_back(value_desc); + } + + //! Returns a list of the currently selected value_nodes. + virtual ChildrenList get_selected_children()const + { + if(!view->children_tree) return ChildrenList(); + + Glib::RefPtr selection=view->children_tree->get_selection(); + + if(!selection) + return ChildrenList(); + + ChildrenList ret; + + selection->selected_foreach_iter( + sigc::bind( + sigc::ptr_fun( + &studio::CanvasViewSelectionManager::__child_grabber + ), + &ret + ) + ); + + /* + Gtk::TreeModel::Children::iterator iter(view->children_tree_store()->children().begin()); + iter++; + Gtk::TreeModel::Children children = iter->children(); + for(iter = children.begin(); iter != children.end(); ++iter) + { + Gtk::TreeModel::Row row = *iter; + if(selection->is_selected(row)) + ret.push_back((sinfgapp::ValueDesc)row[children_tree_model.value_desc]); + } + */ + return ret; + } + + //! Returns the first value_node selected or an empty handle if none are selected. + virtual ChildrenList::value_type get_selected_child()const + { + if(!view->children_tree) return ChildrenList::value_type(); + + ChildrenList children(get_selected_children()); + + if(children.empty()) + return ChildrenList::value_type(); + + return children.front(); + } + + //! Sets which value_nodes should be selected + virtual void set_selected_children(const ChildrenList &children_list) + { + return; + } + + //! Sets which value_node should be selected. Empty handle if none. + virtual void set_selected_child(const ChildrenList::value_type &child) + { + return; + } + + //! Clears the value_node selection list + virtual void clear_selected_children() + { + return; + } + + + + int get_selected_layer_parameter_count()const + { + return get_selected_layer_parameters().size(); + } + + LayerParamList get_selected_layer_parameters()const + { + if(!view->layer_tree) return LayerParamList(); + + Glib::RefPtr selection=view->layer_tree->get_selection(); + + if(!selection) + return LayerParamList(); + + LayerParamList ret; + + Gtk::TreeModel::Children children = const_cast(view)->layer_tree_store()->children(); + Gtk::TreeModel::Children::iterator iter; + for(iter = children.begin(); iter != children.end(); ++iter) + { + Gtk::TreeModel::Row row = *iter; + Gtk::TreeModel::Children::iterator iter; + for(iter=row.children().begin();iter!=row.children().end();iter++) + { + Gtk::TreeModel::Row row = *iter; + if(selection->is_selected(row)) + ret.push_back(LayerParam(row[layer_tree_model.layer],(Glib::ustring)row[layer_tree_model.id])); + } + } + return ret; + } + + LayerParam get_selected_layer_parameter() const + { + if(!view->layer_tree) return LayerParam(); + return get_selected_layer_parameters().front(); + } + + void set_selected_layer_parameters(const LayerParamList &layer_param_list) + { + return; + } + + void set_selected_layer_param(const LayerParam &layer_param) + { + return; + } + + void clear_selected_layer_parameters() + { + return; + } + +}; // END of class SelectionManager + + +CanvasView::IsWorking::IsWorking(CanvasView &canvas_view_): + canvas_view_(canvas_view_) +{ + if(!canvas_view_.working_depth) + canvas_view_.stopbutton->set_sensitive(true); + canvas_view_.working_depth++; + canvas_view_.cancel=false; +} + +CanvasView::IsWorking::~IsWorking() +{ + canvas_view_.working_depth--; + if(!canvas_view_.working_depth) + canvas_view_.stopbutton->set_sensitive(false); +} + +CanvasView::IsWorking::operator bool()const +{ + if(canvas_view_.cancel) + return false; + return true; +} + +/* === M E T H O D S ======================================================= */ + +CanvasView::CanvasView(etl::loose_handle instance,etl::handle canvas_interface_): + smach_ (this), + instance_ (instance), + canvas_interface_ (canvas_interface_), + //layer_tree_store_ (LayerTreeStore::create(canvas_interface_)), + //children_tree_store_ (ChildrenTreeStore::create(canvas_interface_)), + //keyframe_tree_store_ (KeyframeTreeStore::create(canvas_interface_)), + time_adjustment_ (0,0,25,0,0,0), + time_window_adjustment_ (0,0,25,0,0,0), + statusbar (manage(new class Gtk::Statusbar())), + + timeslider (new Widget_Timeslider), + + ui_interface_ (new CanvasViewUIInterface(this)), + selection_manager_ (new CanvasViewSelectionManager(this)), + is_playing_ (false), + + working_depth (0), + cancel (false), + + canvas_properties (*this,canvas_interface_), + canvas_options (this), + render_settings (*this,canvas_interface_), + waypoint_dialog (*this,canvas_interface_->get_canvas()), + keyframe_dialog (*this,canvas_interface_), + preview_dialog (new Dialog_Preview), + sound_dialog (new Dialog_SoundSelect(*this,canvas_interface_)) +{ + layer_tree=0; + children_tree=0; + duck_refresh_flag=true; + + smach_.set_default_state(&state_normal); + + disp_audio = new Widget_Sound(); + + //sinfg::info("Canvasview: Entered constructor"); + // Minor hack + get_canvas()->set_time(0); + //layer_tree_store_->rebuild(); + + // Set up the UI and Selection managers + canvas_interface()->set_ui_interface(get_ui_interface()); + canvas_interface()->set_selection_manager(get_selection_manager()); + rebuild_ducks_queued=false; + + //notebook=manage(new class Gtk::Notebook()); + //Gtk::VPaned *vpaned = manage(new class Gtk::VPaned()); + //vpaned->pack1(*create_work_area(), Gtk::EXPAND|Gtk::SHRINK); + //vpaned->pack2(*notebook, Gtk::SHRINK); + //vpaned->show_all(); + + + //notebook->show(); + + //notebook->append_page(*create_layer_tree(),"Layers"); + //notebook->append_page(*create_children_tree(),"Children"); + //notebook->append_page(*create_keyframe_tree(),"Keyframes"); + + //sinfg::info("Canvasview: Before big chunk of allocation and tabling stuff"); + //create all allocated stuff for this canvas + audio = new AudioContainer(); + + Gtk::Table *layout_table= manage(new class Gtk::Table(1, 3, false)); + //layout_table->attach(*vpaned, 0, 1, 0, 1, Gtk::EXPAND|Gtk::FILL, Gtk::EXPAND|Gtk::FILL, 0, 0); + layout_table->attach(*create_work_area(), 0, 1, 1, 2, Gtk::EXPAND|Gtk::FILL, Gtk::EXPAND|Gtk::FILL, 0, 0); + init_menus(); + //layout_table->attach(*App::ui_manager()->get_widget("/menu-main"), 0, 1, 0, 1, Gtk::EXPAND|Gtk::FILL, Gtk::SHRINK|Gtk::FILL, 0, 0); + + + layout_table->attach(*create_time_bar(), 0, 1, 3, 4, Gtk::EXPAND|Gtk::FILL, Gtk::SHRINK|Gtk::FILL, 0, 0); + layout_table->attach(*create_status_bar(), 0, 1, 4, 5, Gtk::EXPAND|Gtk::FILL, Gtk::SHRINK|Gtk::FILL, 0, 0); + + update_title(); + + layout_table->show(); + add(*layout_table); + + //set_transient_for(*App::toolbox); + + //sinfg::info("Canvasview: Before Signals"); + /* + -- ** -- Signals ------------------------------------------------------------- + */ + + canvas_interface()->signal_dirty_preview().connect(sigc::mem_fun(*this,&studio::CanvasView::on_dirty_preview)); + canvas_interface()->signal_mode_changed().connect(sigc::mem_fun(*this,&studio::CanvasView::on_mode_changed)); + + canvas_interface()->signal_time_changed().connect(sigc::mem_fun(*this,&studio::CanvasView::on_time_changed)); + + //canvas_interface()->signal_time_changed().connect(sigc::mem_fun(*this,&studio::CanvasView::refresh_tables)); + canvas_interface()->signal_id_changed().connect(sigc::mem_fun(*this,&studio::CanvasView::on_id_changed)); + canvas_interface()->signal_rend_desc_changed().connect(sigc::mem_fun(*this,&studio::CanvasView::refresh_rend_desc)); + waypoint_dialog.signal_changed().connect(sigc::mem_fun(*this,&studio::CanvasView::on_waypoint_changed)); + waypoint_dialog.signal_delete().connect(sigc::mem_fun(*this,&studio::CanvasView::on_waypoint_delete)); + + //MODIFIED TIME ADJUSTMENT STUFF.... + time_window_adjustment().set_child_adjustment(&time_adjustment()); + time_window_adjustment().signal_value_changed().connect(sigc::mem_fun(*this,&studio::CanvasView::refresh_time_window)); + time_adjustment().signal_value_changed().connect(sigc::mem_fun(*this,&studio::CanvasView::time_was_changed)); + + + work_area->signal_layer_selected().connect(sigc::mem_fun(*this,&studio::CanvasView::workarea_layer_selected)); + work_area->signal_input_device_changed().connect(sigc::mem_fun(*this,&studio::CanvasView::on_input_device_changed)); + + canvas_interface()->signal_canvas_added().connect( + sigc::hide( + sigc::mem_fun(*instance,&studio::Instance::refresh_canvas_tree) + ) + ); + canvas_interface()->signal_canvas_removed().connect( + sigc::hide( + sigc::mem_fun(*instance,&studio::Instance::refresh_canvas_tree) + ) + ); + + canvas_interface()->signal_layer_param_changed().connect( + sigc::hide( + sigc::hide( + SLOT_EVENT(EVENT_REFRESH_DUCKS) + ) + ) + ); + + + //MUCH TIME STUFF TAKES PLACE IN HERE + refresh_rend_desc(); + refresh_time_window(); + + /*! \todo We shouldn't need to do this at construction -- + ** This should be preformed at the first time the window + ** becomes visible. + */ + work_area->queue_render_preview(); + + // If the canvas is really big, zoom out so that we can fit it all in the window + /*! \todo In other words, this is a zoom-to-fit, and should be + ** in it's own function. + */ + int w=get_canvas()->rend_desc().get_w()+70; + int h=get_canvas()->rend_desc().get_h()+70; + while(w>700 || h>600) + { + work_area->zoom_out(); + w=round_to_int(get_canvas()->rend_desc().get_w()*work_area->get_zoom()+70); + h=round_to_int(get_canvas()->rend_desc().get_h()*work_area->get_zoom()+70); + } + if(w>700)w=700; + if(h>600)h=600; + set_default_size(w,h); + property_window_position().set_value(Gtk::WIN_POS_NONE); + + + + + std::list listTargets; + listTargets.push_back( Gtk::TargetEntry("STRING") ); + listTargets.push_back( Gtk::TargetEntry("text/plain") ); + listTargets.push_back( Gtk::TargetEntry("image") ); + + drag_dest_set(listTargets); + signal_drag_data_received().connect( sigc::mem_fun(*this, &studio::CanvasView::on_drop_drag_data_received) ); + + + /* + Time length(get_canvas()->rend_desc().get_time_end()-get_canvas()->rend_desc().get_time_start()); + if(length<10.0) + { + time_window_adjustment().set_page_increment(length); + time_window_adjustment().set_page_size(length); + } + else + { + time_window_adjustment().set_page_increment(10.0); + time_window_adjustment().set_page_size(10.0); + } + */ + + //sinfg::info("Canvasview: Before Sound Hookup"); + //load sound info from meta data + { + //sinfg::warning("Should load Audio: %s with %s offset",apath.c_str(),aoffset.c_str()); + + on_audio_file_notify(); //redundant setting of the metadata, but oh well, it's no big deal :) + on_audio_offset_notify(); + + //signal connection - since they are all associated with the canvas view + + //hook in signals for sound options box + sound_dialog->signal_file_changed().connect(sigc::mem_fun(*this,&CanvasView::on_audio_file_change)); + sound_dialog->signal_offset_changed().connect(sigc::mem_fun(*this,&CanvasView::on_audio_offset_change)); + + //attach to the preview when it's visible + //preview_dialog->get_widget().signal_play().connect(sigc::mem_fun(*this,&CanvasView::play_audio)); + //preview_dialog->get_widget().signal_stop().connect(sigc::mem_fun(*this,&CanvasView::stop_audio)); + + //hook to metadata signals + get_canvas()->signal_meta_data_changed("audiofile").connect(sigc::mem_fun(*this,&CanvasView::on_audio_file_notify)); + get_canvas()->signal_meta_data_changed("audiooffset").connect(sigc::mem_fun(*this,&CanvasView::on_audio_offset_notify)); + + //universal_scrubber=std::auto_ptr(new UniversalScrubber(this)); + } + + //sinfg::info("Canvasview: Before Final time set up"); + //MORE TIME STUFF + time_window_adjustment().set_value(get_canvas()->rend_desc().get_time_start()); + time_window_adjustment().value_changed(); + + + GRAB_HINT_DATA("canvas_view"); + /* + { + set_skip_taskbar_hint(true); + set_skip_pager_hint(true); + set_type_hint(Gdk::WINDOW_TYPE_HINT_UTILITY); + } + */ + + refresh_rend_desc(); + hide_tables(); + + on_time_changed(); + //sinfg::info("Canvasview: Constructor Done"); +} + +CanvasView::~CanvasView() +{ + signal_deleted()(); + + App::ui_manager()->remove_action_group(action_group); + + // Shut down the smach + smach_.egress(); + smach_.set_default_state(0); + + // We want to ensure that the UI_Manager and + // the selection manager get destructed right now. + ui_interface_.reset(); + selection_manager_.reset(); + + // Delete any external widgets + for(;!ext_widget_book_.empty();ext_widget_book_.erase(ext_widget_book_.begin())) + { + if(ext_widget_book_.begin()->second) + delete ext_widget_book_.begin()->second; + } + + //delete preview + audio.reset(); + + hide(); + + sinfg::info("CanvasView:~CanvasView(): Destructor Finished"); +} + + + +Gtk::Widget * +CanvasView::create_time_bar() +{ + Gtk::Image *icon; + + Gtk::HScrollbar *time_window_scroll = manage(new class Gtk::HScrollbar(time_window_adjustment())); + //Gtk::HScrollbar *time_scroll = manage(new class Gtk::HScrollbar(time_adjustment())); + //TIME BAR TEMPORARY POSITION + //Widget_Timeslider *time_scroll = manage(new Widget_Timeslider); + timeslider->show(); + timeslider->set_time_adjustment(&time_adjustment()); + timeslider->set_bounds_adjustment(&time_window_adjustment()); + //layout_table->attach(*timeslider, 0, 1, 2, 3, Gtk::EXPAND|Gtk::FILL, Gtk::SHRINK|Gtk::FILL); + + + tooltips.set_tip(*time_window_scroll,_("Moves the time window")); + tooltips.set_tip(*timeslider,_("Changes the current time")); + time_window_scroll->show(); + timeslider->show(); + time_window_scroll->set_flags(Gtk::CAN_FOCUS); + timeslider->set_flags(Gtk::CAN_FOCUS); + + //time_scroll->signal_value_changed().connect(sigc::mem_fun(*work_area, &studio::WorkArea::render_preview_hook)); + //time_scroll->set_update_policy(Gtk::UPDATE_DISCONTINUOUS); + + NORMAL_BUTTON(animatebutton,"gtk-yes","Animate"); + animatebutton->signal_clicked().connect(sigc::mem_fun(*this, &studio::CanvasView::on_animate_button_pressed)); + animatebutton->show(); + + NORMAL_BUTTON(keyframebutton,"sinfg-keyframe_lock_all","All Keyframes Locked"); + keyframebutton->signal_clicked().connect(sigc::mem_fun(*this, &studio::CanvasView::on_keyframe_button_pressed)); + keyframebutton->show(); + + Gtk::Table *table= manage(new class Gtk::Table(2, 3, false)); + + //setup the audio display + disp_audio->set_size_request(-1,32); //disp_audio.show(); + disp_audio->set_time_adjustment(&time_adjustment()); + disp_audio->signal_start_scrubbing().connect( + sigc::mem_fun(*audio,&AudioContainer::start_scrubbing) + ); + disp_audio->signal_scrub().connect( + sigc::mem_fun(*audio,&AudioContainer::scrub) + ); + disp_audio->signal_stop_scrubbing().connect( + sigc::mem_fun(*audio,&AudioContainer::stop_scrubbing) + ); + + table->attach(*manage(disp_audio), 0, 1, 0, 1, Gtk::EXPAND|Gtk::FILL, Gtk::SHRINK); + table->attach(*timeslider, 0, 1, 1, 2, Gtk::EXPAND|Gtk::FILL, Gtk::SHRINK, 0, 0); + table->attach(*time_window_scroll, 0, 1, 2, 3, Gtk::EXPAND|Gtk::FILL, Gtk::SHRINK, 0, 0); + + table->attach(*animatebutton, 1, 2, 0, 3, Gtk::SHRINK, Gtk::SHRINK, 0, 0); + table->attach(*keyframebutton, 2, 3, 0, 3, Gtk::SHRINK, Gtk::SHRINK, 0, 0); + timebar=table; + table->show(); + return table; +} + +Gtk::Widget * +CanvasView::create_work_area() +{ + work_area=std::auto_ptr(new class studio::WorkArea(canvas_interface_)); + work_area->set_instance(get_instance()); + work_area->set_canvas(get_canvas()); + work_area->set_canvas_view(this); + work_area->set_progress_callback(get_ui_interface().get()); + work_area->signal_popup_menu().connect(sigc::mem_fun(*this, &studio::CanvasView::popup_main_menu)); + work_area->show(); + return work_area.get(); +} + + +Gtk::Widget* +CanvasView::create_status_bar() +{ + Gtk::Image *icon; + Gtk::IconSize iconsize=Gtk::IconSize::from_name("sinfg-small_icon"); + cancel=false; + + // Create the status bar at the bottom of the window + Gtk::Table *statusbartable= manage(new class Gtk::Table(7, 1, false)); +// statusbar = manage(new class Gtk::Statusbar()); // This is already done at construction + progressbar =manage(new class Gtk::ProgressBar()); + SMALL_BUTTON(stopbutton,"gtk-stop","Stop"); + SMALL_BUTTON(refreshbutton,"gtk-refresh","Refresh"); + //SMALL_BUTTON(treetogglebutton,"gtk-go-down","Toggle Layer Tree"); +// NEW_SMALL_BUTTON(raisebutton,"gtk-go-up","Raise Layer"); +// NEW_SMALL_BUTTON(lowerbutton,"gtk-go-down","Lower Layer"); + //statusbartable->attach(*treetogglebutton, 0, 1, 0, 1, Gtk::SHRINK, Gtk::SHRINK, 0, 0); +// statusbartable->attach(*lowerbutton, 0, 1, 0, 1, Gtk::SHRINK, Gtk::SHRINK, 0, 0); +// statusbartable->attach(*raisebutton, 1, 2, 0, 1, Gtk::SHRINK, Gtk::SHRINK, 0, 0); + + + current_time_widget=manage(new Widget_Time); + current_time_widget->set_value(get_time()); + current_time_widget->set_fps(get_canvas()->rend_desc().get_frame_rate()); + current_time_widget->signal_value_changed().connect( + sigc::mem_fun(*this,&CanvasView::on_current_time_widget_changed) + ); + + statusbartable->attach(*current_time_widget, 0, 1, 0, 1, Gtk::SHRINK|Gtk::FILL, Gtk::SHRINK|Gtk::FILL, 0, 0); + statusbartable->attach(*statusbar, 3, 4, 0, 1, Gtk::EXPAND|Gtk::FILL, Gtk::EXPAND|Gtk::FILL, 0, 0); + statusbartable->attach(*progressbar, 4, 5, 0, 1, Gtk::SHRINK, Gtk::EXPAND|Gtk::FILL, 0, 0); + statusbartable->attach(*refreshbutton, 5, 6, 0, 1, Gtk::SHRINK, Gtk::SHRINK, 0, 0); + statusbartable->attach(*stopbutton, 6, 7, 0, 1, Gtk::SHRINK, Gtk::SHRINK, 0, 0); + statusbar->set_has_resize_grip(false); + statusbar->show(); + stopbutton->show(); + refreshbutton->show(); + progressbar->show(); + stopbutton->set_sensitive(false); + + //refreshbutton->signal_clicked().connect(sigc::mem_fun(*this, &studio::CanvasView::on_refresh_pressed)); + //stopbutton->signal_clicked().connect(sigc::mem_fun(*this, &studio::CanvasView::stop)); + //treetogglebutton->signal_clicked().connect(sigc::mem_fun(*this, &studio::CanvasView::toggle_tables)); + + refreshbutton->signal_clicked().connect(SLOT_EVENT(EVENT_REFRESH)); + stopbutton->signal_clicked().connect(SLOT_EVENT(EVENT_STOP)); + + + statusbartable->show_all(); + return statusbartable; +} + +void +CanvasView::on_current_time_widget_changed() +{ + set_time(current_time_widget->get_value()); +} + +Gtk::Widget* +CanvasView::create_children_tree() +{ + // Create the layer tree + children_tree=manage(new class ChildrenTree()); + + // Set up the layer tree + //children_tree->set_model(children_tree_store()); + if(children_tree)children_tree->set_time_adjustment(time_adjustment()); + if(children_tree)children_tree->show(); + + // Connect Signals + if(children_tree)children_tree->signal_edited_value().connect(sigc::mem_fun(*this, &studio::CanvasView::on_edited_value)); + if(children_tree)children_tree->signal_user_click().connect(sigc::mem_fun(*this, &studio::CanvasView::on_children_user_click)); + if(children_tree)children_tree->signal_waypoint_clicked().connect(sigc::mem_fun(*this, &studio::CanvasView::on_waypoint_clicked)); + if(children_tree)children_tree->get_selection()->signal_changed().connect(SLOT_EVENT(EVENT_REFRESH_DUCKS)); + + return children_tree; +} + +Gtk::Widget* +CanvasView::create_keyframe_tree() +{ + keyframe_tree=manage(new KeyframeTree()); + + //keyframe_tree->get_selection()->set_mode(Gtk::SELECTION_MULTIPLE); + //keyframe_tree->show(); + //keyframe_tree->set_model(keyframe_tree_store()); + keyframe_tree->set_editable(true); + //keyframe_tree->signal_edited().connect(sigc::hide_return(sigc::mem_fun(*canvas_interface(), &sinfgapp::CanvasInterface::update_keyframe))); + + keyframe_tree->signal_event().connect(sigc::mem_fun(*this, &studio::CanvasView::on_keyframe_tree_event)); + + Gtk::ScrolledWindow *scroll_layer_tree = manage(new class Gtk::ScrolledWindow()); + scroll_layer_tree->set_flags(Gtk::CAN_FOCUS); + scroll_layer_tree->set_policy(Gtk::POLICY_AUTOMATIC, Gtk::POLICY_AUTOMATIC); + scroll_layer_tree->add(*keyframe_tree); + scroll_layer_tree->set_shadow_type(Gtk::SHADOW_ETCHED_IN); + //scroll_layer_tree->show(); + + + Gtk::Table *layout_table= manage(new Gtk::Table(1, 2, false)); + layout_table->attach(*scroll_layer_tree, 0, 1, 0, 1, Gtk::EXPAND|Gtk::FILL, Gtk::EXPAND|Gtk::FILL, 0, 0); + + Gtk::Image *icon; + Gtk::IconSize iconsize(Gtk::IconSize::from_name("sinfg-small_icon")); + + NEW_SMALL_BUTTON(button_add,"gtk-add","New Keyframe"); + NEW_SMALL_BUTTON(button_duplicate,"sinfg-duplicate","Duplicate Keyframe"); + NEW_SMALL_BUTTON(button_delete,"gtk-delete","Delete Keyframe"); + + Gtk::HBox *hbox(manage(new Gtk::HBox())); + layout_table->attach(*hbox, 0, 1, 1, 2, Gtk::EXPAND|Gtk::FILL, Gtk::SHRINK, 0, 0); + + hbox->pack_start(*button_add,Gtk::PACK_SHRINK); + hbox->pack_start(*button_duplicate,Gtk::PACK_SHRINK); + hbox->pack_start(*button_delete,Gtk::PACK_SHRINK); + + /* + button_raise->set_relief(Gtk::RELIEF_HALF); + button_lower->set_relief(Gtk::RELIEF_HALF); + button_duplicate->set_relief(Gtk::RELIEF_HALF); + button_delete->set_relief(Gtk::RELIEF_HALF); + */ + + button_add->signal_clicked().connect(sigc::mem_fun(*this, &studio::CanvasView::on_keyframe_add_pressed)); + button_duplicate->signal_clicked().connect(sigc::mem_fun(*this, &studio::CanvasView::on_keyframe_duplicate_pressed)); + button_delete->signal_clicked().connect(sigc::mem_fun(*this, &studio::CanvasView::on_keyframe_remove_pressed)); + + //layout_table->show_all(); + + keyframe_tab_child=layout_table; + + + layout_table->hide(); + + return layout_table; +} + +Gtk::Widget* +CanvasView::create_layer_tree() +{ + // Create the layer tree + layer_tree=manage(new class LayerTree()); + + // Set up the layer tree + //layer_tree->set_model(layer_tree_store()); + layer_tree->set_time_adjustment(time_adjustment()); + layer_tree->show(); + + // Connect Signals + layer_tree->signal_layer_toggle().connect(sigc::mem_fun(*this, &studio::CanvasView::on_layer_toggle)); + layer_tree->signal_edited_value().connect(sigc::mem_fun(*this, &studio::CanvasView::on_edited_value)); + layer_tree->signal_layer_user_click().connect(sigc::mem_fun(*this, &studio::CanvasView::on_layer_user_click)); + layer_tree->signal_param_user_click().connect(sigc::mem_fun(*this, &studio::CanvasView::on_children_user_click)); + layer_tree->signal_waypoint_clicked().connect(sigc::mem_fun(*this, &studio::CanvasView::on_waypoint_clicked)); + layer_tree->get_selection()->signal_changed().connect(SLOT_EVENT(EVENT_REFRESH_DUCKS)); + + layer_tree->hide(); + return layer_tree; +} + +void +CanvasView::init_menus() +{ +/* + mainmenu.set_accel_group(get_accel_group()); + mainmenu.set_accel_path(""); + + filemenu.set_accel_group(get_accel_group()); + filemenu.set_accel_path("/File"); + + editmenu.set_accel_group(get_accel_group()); + editmenu.set_accel_path("/Edit"); + + layermenu.set_accel_group(get_accel_group()); + layermenu.set_accel_path("/Layer"); +*/ + //cache the position of desired widgets + + /*Menus to worry about: + - filemenu + - editmenu + - layermenu + - duckmaskmenu + - mainmenu + - canvasmenu + - viewmenu + */ + action_group = Gtk::ActionGroup::create(); + + //action_group->add( Gtk::Action::create("MenuFile", "_File") ); + action_group->add( Gtk::Action::create("save", Gtk::Stock::SAVE), + hide_return(sigc::mem_fun(*get_instance().get(), &studio::Instance::save)) + ); + action_group->add( Gtk::Action::create("save-as", Gtk::Stock::SAVE_AS), + sigc::hide_return(sigc::mem_fun(*get_instance().get(), &studio::Instance::dialog_save_as)) + ); + action_group->add( Gtk::Action::create("revert", Gtk::Stock::REVERT_TO_SAVED), + sigc::hide_return(sigc::mem_fun(*get_instance().get(), &studio::Instance::safe_revert)) + ); + action_group->add( Gtk::Action::create("cvs-add", Gtk::StockID("sinfg-cvs_add")), + sigc::hide_return(sigc::mem_fun(*get_instance(), &studio::Instance::dialog_cvs_add)) + ); + action_group->add( Gtk::Action::create("cvs-update", Gtk::StockID("sinfg-cvs_update")), + sigc::hide_return(sigc::mem_fun(*get_instance(), &studio::Instance::dialog_cvs_update)) + ); + action_group->add( Gtk::Action::create("cvs-revert", Gtk::StockID("sinfg-cvs_revert")), + sigc::hide_return(sigc::mem_fun(*get_instance(), &studio::Instance::dialog_cvs_revert)) + ); + action_group->add( Gtk::Action::create("cvs-commit", Gtk::StockID("sinfg-cvs_commit")), + sigc::hide_return(sigc::mem_fun(*get_instance(), &studio::Instance::dialog_cvs_commit)) + ); + action_group->add( Gtk::Action::create("import", _("Import")), + sigc::hide_return(sigc::mem_fun(*this, &studio::CanvasView::image_import)) + ); + action_group->add( Gtk::Action::create("render", _("Render")), + sigc::mem_fun(render_settings,&studio::RenderSettings::present) + ); + action_group->add( Gtk::Action::create("preview", _("Preview")), + sigc::mem_fun(*this,&CanvasView::on_preview_option) + ); + action_group->add( Gtk::Action::create("sound", _("Sound File")), + sigc::mem_fun(*this,&CanvasView::on_audio_option) + ); + action_group->add( Gtk::Action::create("options", _("Options")), + sigc::mem_fun(canvas_options,&studio::CanvasOptions::present) + ); + action_group->add( Gtk::Action::create("close", Gtk::StockID("gtk-close")), + sigc::hide_return(sigc::mem_fun(*this,&studio::CanvasView::close)) + ); + + //action_group->add( Gtk::Action::create("undo", Gtk::StockID("gtk-undo")), + // SLOT_EVENT(EVENT_UNDO) + //); + + //action_group->add( Gtk::Action::create("redo", Gtk::StockID("gtk-redo")), + // SLOT_EVENT(EVENT_REDO) + //); + + action_group->add( Gtk::Action::create("select-all-ducks", _("Select All Ducks")), + sigc::mem_fun(*work_area,&studio::WorkArea::select_all_ducks) + ); + + action_group->add( Gtk::Action::create("unselect-all-layers", _("Unselect All Layers")), + sigc::mem_fun(*this,&CanvasView::on_unselect_layers) + ); + + action_group->add( Gtk::Action::create("stop", Gtk::StockID("gtk-stop")), + SLOT_EVENT(EVENT_STOP) + ); + + action_group->add( Gtk::Action::create("refresh", Gtk::StockID("gtk-refresh")), + SLOT_EVENT(EVENT_REFRESH) + ); + + action_group->add( Gtk::Action::create("properties", Gtk::StockID("gtk-properties")), + sigc::mem_fun(canvas_properties,&studio::CanvasProperties::present) + ); + + // Preview Quality Menu + { + int i; + action_group->add( Gtk::RadioAction::create(quality_group,"quality-00", _("Use Parametric Renderer")), + sigc::bind( + sigc::mem_fun(*work_area, &studio::WorkArea::set_quality), + 0 + ) + ); + for(i=1;i<=10;i++) + { + Glib::RefPtr action(Gtk::RadioAction::create(quality_group,strprintf("quality-%02d",i), strprintf("Set Quality to %d",i))); + if(i==10) + action->property_value()=10; + action_group->add( action, + sigc::bind( + sigc::mem_fun(*work_area, &studio::WorkArea::set_quality), + i + ) + ); + } + } + + action_group->add( Gtk::Action::create("play", Gtk::StockID("sinfg-play")), + sigc::mem_fun(*this, &studio::CanvasView::play) + ); + + action_group->add( Gtk::Action::create("dialog-flipbook", _("Flipbook Dialog")), + sigc::mem_fun(*preview_dialog, &studio::Dialog_Preview::present) + ); + + action_group->add( Gtk::Action::create("toggle-grid-show", _("Toggle Grid Show")), + sigc::mem_fun(*work_area, &studio::WorkArea::toggle_grid) + ); + action_group->add( Gtk::Action::create("toggle-grid-snap", _("Toggle Grid Snap")), + sigc::mem_fun(*work_area, &studio::WorkArea::toggle_grid_snap) + ); + action_group->add( Gtk::Action::create("toggle-guide-show", _("Toggle Guide Show")), + sigc::mem_fun(*work_area, &studio::WorkArea::toggle_guide_snap) + ); + action_group->add( Gtk::Action::create("toggle-low-res", _("Toggle Low-Res")), + sigc::mem_fun(*work_area, &studio::WorkArea::toggle_low_resolution_flag) + ); + action_group->add( Gtk::Action::create("toggle-onion-skin", _("Toggle Onion Skin")), + sigc::mem_fun(*work_area, &studio::WorkArea::toggle_onion_skin) + ); + + + action_group->add( Gtk::Action::create("canvas-zoom-fit", Gtk::StockID("gtk-zoom-fit")), + sigc::mem_fun(*work_area, &studio::WorkArea::zoom_fit) + ); + action_group->add( Gtk::Action::create("canvas-zoom-100", Gtk::StockID("gtk-zoom-100")), + sigc::mem_fun(*work_area, &studio::WorkArea::zoom_norm) + ); + + + { + Glib::RefPtr action; + + action=Gtk::Action::create("seek-next-frame", Gtk::Stock::GO_FORWARD,_("Next Frame"),_("Next Frame")); + action_group->add(action,sigc::bind(sigc::mem_fun(*canvas_interface().get(), &sinfgapp::CanvasInterface::seek_frame),1)); + action=Gtk::Action::create("seek-prev-frame", Gtk::Stock::GO_BACK,_("Prev Frame"),_("Prev Frame")); + action_group->add( action, sigc::bind(sigc::mem_fun(*canvas_interface().get(), &sinfgapp::CanvasInterface::seek_frame),-1)); + + action=Gtk::Action::create("seek-next-second", Gtk::Stock::GO_FORWARD,_("Seek Foward"),_("Seek Foward")); + action_group->add(action,sigc::bind(sigc::mem_fun(*canvas_interface().get(), &sinfgapp::CanvasInterface::seek_time),Time(1))); + action=Gtk::Action::create("seek-prev-second", Gtk::Stock::GO_BACK,_("Seek Backward"),_("Seek Backward")); + action_group->add( action, sigc::bind(sigc::mem_fun(*canvas_interface().get(), &sinfgapp::CanvasInterface::seek_time),Time(-1))); + + // Broken...!? + /* + action=Gtk::Action::create("seek-end", Gtk::Stock::GOTO_LAST,_("Seek to End"),_("Seek to End")); + action_group->add(action,sigc::bind(sigc::mem_fun(*canvas_interface().get(), &sinfgapp::CanvasInterface::seek_time),Time::end())); + */ + action=Gtk::Action::create("seek-begin", Gtk::Stock::GOTO_FIRST,_("Seek to Begin"),_("Seek to Begin")); + action_group->add( action, sigc::bind(sigc::mem_fun(*canvas_interface().get(), &sinfgapp::CanvasInterface::seek_time),Time::begin())); + + action=Gtk::Action::create("jump-next-keyframe", Gtk::Stock::GO_FORWARD,_("Jump to Next Keyframe"),_("Jump to Next Keyframe")); + action_group->add( action,sigc::mem_fun(*canvas_interface().get(), &sinfgapp::CanvasInterface::jump_to_next_keyframe)); + + action=Gtk::Action::create("jump-prev-keyframe", Gtk::Stock::GO_BACK,_("Jump to Prev Keyframe"),_("Jump to Prev Keyframe")); + action_group->add( action,sigc::mem_fun(*canvas_interface().get(), &sinfgapp::CanvasInterface::jump_to_prev_keyframe)); + + action=Gtk::Action::create("canvas-zoom-in", Gtk::Stock::ZOOM_IN); + action_group->add( action,sigc::mem_fun(*work_area, &studio::WorkArea::zoom_in)); + + action=Gtk::Action::create("canvas-zoom-out", Gtk::Stock::ZOOM_OUT); + action_group->add( action, sigc::mem_fun(*work_area, &studio::WorkArea::zoom_out) ); + + action=Gtk::Action::create("time-zoom-in", Gtk::Stock::ZOOM_IN, _("Zoom In on Timeline")); + action_group->add( action, sigc::mem_fun(*this, &studio::CanvasView::time_zoom_in) ); + + action=Gtk::Action::create("time-zoom-out", Gtk::Stock::ZOOM_OUT, _("Zoom Out on Timeline")); + action_group->add( action, sigc::mem_fun(*this, &studio::CanvasView::time_zoom_out) ); + + } + + +#define DUCK_MASK(lower,upper) \ + duck_mask_##lower=Gtk::ToggleAction::create("mask-" #lower "-ducks", _("Mask "#lower" ducks")); \ + duck_mask_##lower->set_active((bool)(work_area->get_type_mask()&Duck::TYPE_##upper)); \ + action_group->add( duck_mask_##lower, \ + sigc::bind( \ + sigc::mem_fun(*this, &studio::CanvasView::toggle_duck_mask), \ + Duck::TYPE_##upper \ + ) \ + ) + DUCK_MASK(position,POSITION); + DUCK_MASK(tangent,TANGENT); + DUCK_MASK(vertex,VERTEX); + DUCK_MASK(radius,RADIUS); + DUCK_MASK(width,WIDTH); + DUCK_MASK(angle,ANGLE); +#undef DUCK_MASK + + add_accel_group(App::ui_manager()->get_accel_group()); + +/* // Here is where we add the actions that may have conflicting + // keyboard accelerators. + { + Glib::RefPtr accel_action_group(Gtk::ActionGroup::create("canvas_view")); + Glib::RefPtr action; + + action=Gtk::Action::create("seek-next-frame", Gtk::StockID("gtk-forward"),_("Next Frame"),_("Next Frame")); + accel_action_group->add(action,sigc::bind(sigc::mem_fun(*canvas_interface().get(), &sinfgapp::CanvasInterface::seek),1)); + + action=Gtk::Action::create("seek-prev-frame", Gtk::StockID("gtk-forward"),_("Prev Frame"),_("Prev Frame")); + accel_action_group->add( action, sigc::bind(sigc::mem_fun(*canvas_interface().get(), &sinfgapp::CanvasInterface::seek),-1)); + + action=Gtk::Action::create("jump-next-keyframe", Gtk::StockID("gtk-forward"),_("Jump to Next Keyframe"),_("Jump to Next Keyframe")); + accel_action_group->add( action,sigc::mem_fun(*canvas_interface().get(), &sinfgapp::CanvasInterface::jump_to_next_keyframe)); + + action=Gtk::Action::create("jump-prev-keyframe", Gtk::StockID("gtk-back"),_("Jump to Prev Keyframe"),_("Jump to Prev Keyframe")); + accel_action_group->add( action,sigc::mem_fun(*canvas_interface().get(), &sinfgapp::CanvasInterface::jump_to_prev_keyframe)); + + action=Gtk::Action::create("canvas-zoom-in", Gtk::StockID("gtk-zoom-in")); + accel_action_group->add( action,sigc::mem_fun(*work_area, &studio::WorkArea::zoom_in)); + + action=Gtk::Action::create("canvas-zoom-out", Gtk::StockID("gtk-zoom-out")); + accel_action_group->add( action, sigc::mem_fun(*work_area, &studio::WorkArea::zoom_out) ); + + action=Gtk::Action::create("time-zoom-in", Gtk::StockID("gtk-zoom-in"), _("Zoom In on Timeline")); + accel_action_group->add( action, sigc::mem_fun(*this, &studio::CanvasView::time_zoom_in) ); + + action=Gtk::Action::create("time-zoom-out", Gtk::StockID("gtk-zoom-out"), _("Zoom Out on Timeline")); + accel_action_group->add( action, sigc::mem_fun(*this, &studio::CanvasView::time_zoom_out) ); + + Glib::RefPtr accel_ui_manager(Gtk::UIManager::create()); + + Glib::ustring ui_info = + " + + + + + + + + + + + "; + + accel_ui_manager->add_ui_from_string(ui_info); + add_accel_group(accel_ui_manager->get_accel_group()); + + accel_ui_manager->insert_action_group(accel_action_group); + set_ref_obj("accel_ui_manager",accel_ui_manager); + set_ref_obj("accel_action_group",accel_action_group); + } +*/ + + + +#if 0 + + //Test some key stuff + + filemenu.items().push_back(Gtk::Menu_Helpers::StockMenuElem(Gtk::StockID("gtk-save"), + hide_return(sigc::mem_fun(*get_instance().get(), &studio::Instance::save)))); + filemenu.items().push_back(Gtk::Menu_Helpers::StockMenuElem(Gtk::StockID("gtk-save-as"),sigc::hide_return(sigc::mem_fun(*get_instance(), &studio::Instance::dialog_save_as)))); + filemenu.items().push_back(Gtk::Menu_Helpers::StockMenuElem(Gtk::StockID("gtk-revert-to-saved"),hide_return(sigc::mem_fun(*get_instance().get(), &studio::Instance::safe_revert)))); + filemenu.items().push_back(Gtk::Menu_Helpers::SeparatorElem()); + + filemenu.items().push_back(Gtk::Menu_Helpers::StockMenuElem(Gtk::StockID("sinfg-cvs_add"),sigc::hide_return(sigc::mem_fun(*get_instance(), &studio::Instance::dialog_cvs_add)))); + filemenu.items().push_back(Gtk::Menu_Helpers::StockMenuElem(Gtk::StockID("sinfg-cvs_update"),sigc::hide_return(sigc::mem_fun(*get_instance(), &studio::Instance::dialog_cvs_update)))); + filemenu.items().push_back(Gtk::Menu_Helpers::StockMenuElem(Gtk::StockID("sinfg-cvs_commit"),sigc::hide_return(sigc::mem_fun(*get_instance(), &studio::Instance::dialog_cvs_commit)))); + + filemenu.items().push_back(Gtk::Menu_Helpers::SeparatorElem()); + filemenu.items().push_back(Gtk::Menu_Helpers::MenuElem(_("Import..."),Gtk::AccelKey('I',Gdk::CONTROL_MASK),sigc::hide_return(sigc::mem_fun(*this, &studio::CanvasView::image_import)))); + filemenu.items().push_back(Gtk::Menu_Helpers::SeparatorElem()); + filemenu.items().push_back(Gtk::Menu_Helpers::MenuElem(_("Render"),Gtk::AccelKey("F9"), + sigc::mem_fun(render_settings,&studio::RenderSettings::present) + )); + filemenu.items().push_back(Gtk::Menu_Helpers::MenuElem(_("Preview"),Gtk::AccelKey("F11"), + sigc::mem_fun(*this,&CanvasView::on_preview_option) + )); + filemenu.items().push_back(Gtk::Menu_Helpers::MenuElem(_("Sound File"), + sigc::mem_fun(*this,&CanvasView::on_audio_option) + )); + + filemenu.items().push_back(Gtk::Menu_Helpers::SeparatorElem()); + filemenu.items().push_back(Gtk::Menu_Helpers::MenuElem(_("Options"),Gtk::AccelKey("F12"), + sigc::mem_fun(canvas_options,&studio::CanvasOptions::present) + )); + filemenu.items().push_back(Gtk::Menu_Helpers::SeparatorElem()); + filemenu.items().push_back(Gtk::Menu_Helpers::StockMenuElem(Gtk::StockID("gtk-close"),sigc::hide_return(sigc::mem_fun(*this,&studio::CanvasView::close)))); + + editmenu.items().push_back(Gtk::Menu_Helpers::StockMenuElem(Gtk::StockID("gtk-undo"),Gtk::AccelKey('Z',Gdk::CONTROL_MASK),SLOT_EVENT(EVENT_UNDO))); + editmenu.items().push_back(Gtk::Menu_Helpers::StockMenuElem(Gtk::StockID("gtk-redo"),Gtk::AccelKey('R',Gdk::CONTROL_MASK),SLOT_EVENT(EVENT_REDO))); + editmenu.items().push_back(Gtk::Menu_Helpers::SeparatorElem()); + editmenu.items().push_back(Gtk::Menu_Helpers::StockMenuElem(Gtk::StockID("gtk-cut"),NOT_IMPLEMENTED_SLOT)); + editmenu.items().push_back(Gtk::Menu_Helpers::StockMenuElem(Gtk::StockID("gtk-copy"),NOT_IMPLEMENTED_SLOT)); + editmenu.items().push_back(Gtk::Menu_Helpers::StockMenuElem(Gtk::StockID("gtk-paste"),NOT_IMPLEMENTED_SLOT)); + editmenu.items().push_back(Gtk::Menu_Helpers::SeparatorElem()); + editmenu.items().push_back(Gtk::Menu_Helpers::MenuElem(_("Select All Ducks"),Gtk::AccelKey('E',Gdk::CONTROL_MASK),sigc::mem_fun(*work_area,&studio::WorkArea::select_all_ducks))); + editmenu.items().push_back(Gtk::Menu_Helpers::MenuElem(_("Unselect All Layers"),Gtk::AccelKey('D',Gdk::CONTROL_MASK),sigc::mem_fun(*this,&CanvasView::on_unselect_layers))); + editmenu.items().push_back(Gtk::Menu_Helpers::SeparatorElem()); + + //editmenu.items().push_back(Gtk::Menu_Helpers::StockMenuElem(Gtk::StockID("gtk-stop"),Gtk::AccelKey(GDK_Escape,static_cast(0)),sigc::hide_return(sigc::mem_fun(*this, &studio::CanvasView::stop)))); + //editmenu.items().push_back(Gtk::Menu_Helpers::StockMenuElem(Gtk::StockID("gtk-refresh"),Gtk::AccelKey('k',Gdk::CONTROL_MASK),sigc::hide_return(sigc::mem_fun(*this, &studio::CanvasView::on_refresh_pressed)))); + editmenu.items().push_back(Gtk::Menu_Helpers::StockMenuElem(Gtk::StockID("gtk-stop"),Gtk::AccelKey(GDK_Escape,static_cast(0)),SLOT_EVENT(EVENT_STOP))); + editmenu.items().push_back(Gtk::Menu_Helpers::StockMenuElem(Gtk::StockID("gtk-refresh"),Gtk::AccelKey('k',Gdk::CONTROL_MASK),SLOT_EVENT(EVENT_REFRESH))); + editmenu.items().push_back(Gtk::Menu_Helpers::SeparatorElem()); + editmenu.items().push_back(Gtk::Menu_Helpers::StockMenuElem(Gtk::StockID("sinfg-rotoscope_bline"), + sigc::mem_fun(*this, &studio::CanvasView::do_rotoscope_bline))); + editmenu.items().push_back(Gtk::Menu_Helpers::StockMenuElem(Gtk::StockID("sinfg-rotoscope_polygon"), + sigc::mem_fun(*this, &studio::CanvasView::do_rotoscope_poly))); + editmenu.items().push_back(Gtk::Menu_Helpers::StockMenuElem(Gtk::StockID("sinfg-eyedrop"), + sigc::mem_fun(*this, &studio::CanvasView::do_eyedrop))); + editmenu.items().push_back(Gtk::Menu_Helpers::SeparatorElem()); + editmenu.items().push_back(Gtk::Menu_Helpers::StockMenuElem(Gtk::StockID("gtk-properties"),Gtk::AccelKey("F8"), + sigc::mem_fun(canvas_properties,&studio::CanvasProperties::present) + )); + + build_new_layer_menu(newlayermenu); + layermenu.items().push_back(Gtk::Menu_Helpers::MenuElem("New",newlayermenu)); + + + { + sinfgapp::Action::ParamList param_list; + param_list.add("canvas",Canvas::Handle(get_canvas())); + param_list.add("canvas_interface",canvas_interface()); + add_actions_to_menu(&canvasmenu, param_list,sinfgapp::Action::CATEGORY_CANVAS); + } + + + //canvasmenu.items().push_back(Gtk::Menu_Helpers::MenuElem("Keyframe Dialog",sigc::mem_fun(keyframe_dialog,&studio::Dialog_Keyframe::present))); + + // Duck Mask Menu + if(1) + { + duckmaskmenu.items().push_back(Gtk::Menu_Helpers::TearoffMenuElem()); + + duckmaskmenu.items().push_back(Gtk::Menu_Helpers::CheckMenuElem(_("Position Ducks"),Gtk::AccelKey('1',Gdk::MOD1_MASK))); + duck_mask_position=static_cast(&duckmaskmenu.items().back()); + duck_mask_position->set_active((bool)(work_area->get_type_mask()&Duck::TYPE_POSITION)); + duck_mask_position->signal_toggled().connect( + sigc::bind( + sigc::mem_fun(*this, &studio::CanvasView::toggle_duck_mask), + Duck::TYPE_POSITION + ) + ); + + duckmaskmenu.items().push_back(Gtk::Menu_Helpers::CheckMenuElem(_("Vertex Ducks"),Gtk::AccelKey('2',Gdk::MOD1_MASK))); + duck_mask_vertex=static_cast(&duckmaskmenu.items().back()); + duck_mask_vertex->set_active((bool)(work_area->get_type_mask()&Duck::TYPE_VERTEX)); + duck_mask_vertex->signal_toggled().connect( + sigc::bind( + sigc::mem_fun(*this, &studio::CanvasView::toggle_duck_mask), + Duck::TYPE_VERTEX + ) + ); + + duckmaskmenu.items().push_back(Gtk::Menu_Helpers::CheckMenuElem(_("Tangent Ducks"),Gtk::AccelKey('3',Gdk::MOD1_MASK))); + duck_mask_tangent=static_cast(&duckmaskmenu.items().back()); + duck_mask_tangent->set_active((bool)(work_area->get_type_mask()&Duck::TYPE_TANGENT)); + duck_mask_tangent->signal_toggled().connect( + sigc::bind( + sigc::mem_fun(*this, &studio::CanvasView::toggle_duck_mask), + Duck::TYPE_TANGENT + ) + ); + + duckmaskmenu.items().push_back(Gtk::Menu_Helpers::CheckMenuElem(_("Radius Ducks"),Gtk::AccelKey('4',Gdk::MOD1_MASK))); + duck_mask_radius=static_cast(&duckmaskmenu.items().back()); + duck_mask_radius->set_active((bool)(work_area->get_type_mask()&Duck::TYPE_RADIUS)); + duck_mask_radius->signal_toggled().connect( + sigc::bind( + sigc::mem_fun(*this, &studio::CanvasView::toggle_duck_mask), + Duck::TYPE_RADIUS + ) + ); + + duckmaskmenu.items().push_back(Gtk::Menu_Helpers::CheckMenuElem(_("Width Ducks"),Gtk::AccelKey('5',Gdk::MOD1_MASK))); + duck_mask_width=static_cast(&duckmaskmenu.items().back()); + duck_mask_width->set_active((bool)(work_area->get_type_mask()&Duck::TYPE_WIDTH)); + duck_mask_width->signal_toggled().connect( + sigc::bind( + sigc::mem_fun(*this, &studio::CanvasView::toggle_duck_mask), + Duck::TYPE_WIDTH + ) + ); + + duckmaskmenu.items().push_back(Gtk::Menu_Helpers::CheckMenuElem(_("Angle Ducks"),Gtk::AccelKey('6',Gdk::MOD1_MASK))); + duck_mask_angle=static_cast(&duckmaskmenu.items().back()); + duck_mask_angle->set_active((bool)(work_area->get_type_mask()&Duck::TYPE_ANGLE)); + duck_mask_angle->signal_toggled().connect( + sigc::bind( + sigc::mem_fun(*this, &studio::CanvasView::toggle_duck_mask), + Duck::TYPE_ANGLE + ) + ); + + viewmenu.items().push_back(Gtk::Menu_Helpers::MenuElem(_("_Mask Ducks"),duckmaskmenu)); + } + + // Preview Quality Menu + if(1) + { + qualitymenu.items().push_back(Gtk::Menu_Helpers::TearoffMenuElem()); + int i; + qualitymenu.items().push_back(Gtk::Menu_Helpers::MenuElem(strprintf(_("Use Parametric Renderer"),0), + sigc::bind( + sigc::mem_fun(*work_area, &studio::WorkArea::set_quality), + 0 + ) + )); + for(i=1;i<=10;i++) + { + qualitymenu.items().push_back(Gtk::Menu_Helpers::MenuElem(strprintf(_("Set Quality to %d"),i),Gtk::AccelKey('0'+(i%10),Gdk::CONTROL_MASK), + sigc::bind( + sigc::mem_fun(*work_area, &studio::WorkArea::set_quality), + i + ) + )); + } + viewmenu.items().push_back(Gtk::Menu_Helpers::MenuElem(_("Preview Quality"),qualitymenu)); + } + + viewmenu.items().push_back(Gtk::Menu_Helpers::StockMenuElem(Gtk::StockID("sinfg-play"), + sigc::mem_fun(*this, &studio::CanvasView::play))); + viewmenu.items().push_back(Gtk::Menu_Helpers::StockMenuElem(Gtk::StockID("Flipbook Dialog"), + sigc::mem_fun(*preview_dialog, &studio::Dialog_Preview::present))); + + viewmenu.items().push_back(Gtk::Menu_Helpers::SeparatorElem()); + + viewmenu.items().push_back(Gtk::Menu_Helpers::MenuElem(_("Toggle Grid Show"),Gtk::AccelKey('g',Gdk::CONTROL_MASK), + sigc::mem_fun(*work_area, &studio::WorkArea::toggle_grid))); + viewmenu.items().push_back(Gtk::Menu_Helpers::MenuElem(_("Toggle Grid Snap"),Gtk::AccelKey('l',Gdk::CONTROL_MASK), + sigc::mem_fun(*work_area, &studio::WorkArea::toggle_grid_snap))); + viewmenu.items().push_back(Gtk::Menu_Helpers::MenuElem(_("Toggle Guide Snap"),Gtk::AccelKey('k',Gdk::CONTROL_MASK), + sigc::mem_fun(*work_area, &studio::WorkArea::toggle_guide_snap))); + viewmenu.items().push_back(Gtk::Menu_Helpers::MenuElem(_("Toggle Low-Res"),Gtk::AccelKey('`',Gdk::CONTROL_MASK), + sigc::mem_fun(*work_area, &studio::WorkArea::toggle_low_resolution_flag))); + + viewmenu.items().push_back(Gtk::Menu_Helpers::SeparatorElem()); + + viewmenu.items().push_back(Gtk::Menu_Helpers::StockMenuElem(Gtk::StockID("gtk-zoom-in"),Gtk::AccelKey('=',static_cast(0)), + sigc::mem_fun(*work_area, &studio::WorkArea::zoom_in))); + viewmenu.items().push_back(Gtk::Menu_Helpers::StockMenuElem(Gtk::StockID("gtk-zoom-out"),Gtk::AccelKey('-',static_cast(0)), + sigc::mem_fun(*work_area, &studio::WorkArea::zoom_out))); + viewmenu.items().push_back(Gtk::Menu_Helpers::StockMenuElem(Gtk::StockID("gtk-zoom-fit"), + sigc::mem_fun(*work_area, &studio::WorkArea::zoom_fit))); + viewmenu.items().push_back(Gtk::Menu_Helpers::StockMenuElem(Gtk::StockID("gtk-zoom-100"),Gtk::AccelKey('`',static_cast(0)), + sigc::mem_fun(*work_area, &studio::WorkArea::zoom_norm))); + viewmenu.items().push_back(Gtk::Menu_Helpers::SeparatorElem()); + + viewmenu.items().push_back(Gtk::Menu_Helpers::StockMenuElem(Gtk::StockID("gtk-zoom-in"),Gtk::AccelKey('+',static_cast(0)), + sigc::mem_fun(*this, &studio::CanvasView::time_zoom_in))); + viewmenu.items().push_back(Gtk::Menu_Helpers::StockMenuElem(Gtk::StockID("gtk-zoom-out"),Gtk::AccelKey('_',static_cast(0)), + sigc::mem_fun(*this, &studio::CanvasView::time_zoom_out))); + + viewmenu.items().push_back(Gtk::Menu_Helpers::MenuElem(_("Jump to Next Keyframe"),Gtk::AccelKey(']',static_cast(0)), + sigc::mem_fun(*canvas_interface().get(), &sinfgapp::CanvasInterface::jump_to_next_keyframe))); + viewmenu.items().push_back(Gtk::Menu_Helpers::MenuElem(_("Jump to Prev Keyframe"),Gtk::AccelKey('[',static_cast(0)), + sigc::mem_fun(*canvas_interface().get(), &sinfgapp::CanvasInterface::jump_to_prev_keyframe))); + + mainmenu.items().push_back(Gtk::Menu_Helpers::TearoffMenuElem()); + mainmenu.items().push_back(Gtk::Menu_Helpers::MenuElem("_File",filemenu)); + mainmenu.items().push_back(Gtk::Menu_Helpers::MenuElem("_Edit",editmenu)); + mainmenu.items().push_back(Gtk::Menu_Helpers::MenuElem("_View",viewmenu)); + mainmenu.items().push_back(Gtk::Menu_Helpers::MenuElem("_Canvas",canvasmenu)); + mainmenu.items().push_back(Gtk::Menu_Helpers::MenuElem("_Layer",layermenu)); + + mainmenu.accelerate(*this); + + { + + trackmenu.items().push_back(Gtk::Menu_Helpers::MenuElem("New Waypoint",NOT_IMPLEMENTED_SLOT)); + trackmenu.items().push_back(Gtk::Menu_Helpers::MenuElem("Delete Waypoint",NOT_IMPLEMENTED_SLOT)); + trackmenu.items().push_back(Gtk::Menu_Helpers::MenuElem("Export",NOT_IMPLEMENTED_SLOT)); + trackmenu.items().push_back(Gtk::Menu_Helpers::SeparatorElem()); + trackmenu.items().push_back(Gtk::Menu_Helpers::MenuElem("Properties",NOT_IMPLEMENTED_SLOT)); + } + mainmenu.show(); + filemenu.show(); + editmenu.show(); + canvasmenu.show(); + layermenu.show(); + + keyframemenu.items().push_back(Gtk::Menu_Helpers::StockMenuElem(Gtk::StockID("gtk-properties"), + sigc::mem_fun(*this,&studio::CanvasView::show_keyframe_dialog) + )); + + + get_accel_group()->unlock(); + + //Set the accelerator paths for all the menus + filemenu.set_accel_path("/File"); + editmenu.set_accel_path("/Edit"); + layermenu.set_accel_path("/Layer"); + //mainmenu.set_accel_path(""); + canvasmenu.set_accel_path("/Canvas"); + viewmenu.set_accel_path("/View"); + duckmaskmenu.set_accel_path("/DuckMask"); +#endif +} + +void +CanvasView::on_unselect_layers() +{ + layer_tree->clear_selected_layers(); +} + +void +CanvasView::show_keyframe_dialog() +{ + Glib::RefPtr selection(keyframe_tree->get_selection()); + if(selection->get_selected()) + { + Gtk::TreeRow row(*selection->get_selected()); + + Keyframe keyframe(row[keyframe_tree->model.keyframe]); + + keyframe_dialog.set_keyframe(keyframe); + keyframe_dialog.present(); + } +} + +void +CanvasView::add_layer(sinfg::String x) +{ + Canvas::Handle canvas; + + sinfgapp::SelectionManager::LayerList layer_list(get_selection_manager()->get_selected_layers()); + + int target_depth(0); + + if(layer_list.empty()) + { + canvas=get_canvas(); + } + else + { + canvas=(*layer_list.begin())->get_canvas(); + target_depth=canvas->get_depth(*layer_list.begin()); + } + + + Layer::Handle layer(canvas_interface()->add_layer_to(x,canvas,target_depth)); + if(layer) + { + get_selection_manager()->clear_selected_layers(); + get_selection_manager()->set_selected_layer(layer); + } +} + +void +CanvasView::popup_layer_menu(sinfg::Layer::Handle layer) +{ + //Gtk::Menu* menu(manage(new Gtk::Menu)); + Gtk::Menu* menu(¶mmenu); + menu->items().clear(); + + sinfgapp::Action::ParamList param_list; + param_list.add("time",canvas_interface()->get_time()); + param_list.add("canvas",Canvas::Handle(layer->get_canvas())); + param_list.add("canvas_interface",canvas_interface()); + param_list.add("layer",layer); + + //Gtk::Menu *newlayers(manage(new Gtk::Menu())); + //build_new_layer_menu(*newlayers); + + //parammenu.items().push_back(Gtk::Menu_Helpers::MenuElem(_("New Layer"),*newlayers)); + + if(layer->get_name()=="PasteCanvas") + { + menu->items().push_back(Gtk::Menu_Helpers::MenuElem(_("Select All Children"), + sigc::bind( + sigc::mem_fun( + *layer_tree, + &studio::LayerTree::select_all_children_layers + ), + layer + ) + )); + } + + add_actions_to_menu(menu, param_list,sinfgapp::Action::CATEGORY_LAYER); + + menu->popup(3,gtk_get_current_event_time()); +} + +void +CanvasView::register_layer_type(sinfg::Layer::Book::value_type &lyr,std::map* category_map) +{ +/* if(lyr.second.category==_("Do Not Use")) + return; + + if(category_map->count(lyr.second.category)==0) + (*category_map)[lyr.second.category]=manage(new Gtk::Menu()); + + (*category_map)[lyr.second.category]->items().push_back(Gtk::Menu_Helpers::MenuElem(lyr.second.local_name, + sigc::hide_return( + sigc::bind( + sigc::mem_fun(*this,&studio::CanvasView::add_layer), + lyr.first + ) + ) + )); +*/ +} + +void +CanvasView::build_new_layer_menu(Gtk::Menu &menu) +{ +/* + std::map category_map; + + std::for_each( + sinfg::Layer::book().begin(), + sinfg::Layer::book().end(), + sigc::bind( + sigc::mem_fun( + *this, + &studio::CanvasView::register_layer_type + ), + &category_map + ) + ); + + menu.items().clear(); + menu.items().push_back(Gtk::Menu_Helpers::TearoffMenuElem()); + + std::map::iterator iter; + for(iter=category_map.begin();iter!=category_map.end();++iter) + menu.items().push_back(Gtk::Menu_Helpers::MenuElem(iter->first,*iter->second)); + + menu.show(); +*/ +} + +void +CanvasView::popup_main_menu() +{ + //mainmenu.popup(0,gtk_get_current_event_time()); + Gtk::Menu* menu = dynamic_cast(App::ui_manager()->get_widget("/menu-main")); + if(menu) + { + //menu->set_accel_group(App::ui_manager()->get_accel_group()); + //menu->accelerate(*this); + menu->popup(0,gtk_get_current_event_time()); + } +} + +void +CanvasView::on_refresh_pressed() +{ + rebuild_tables(); + rebuild_ducks(); + work_area->queue_render_preview(); +} + +void +CanvasView::workarea_layer_selected(sinfg::Layer::Handle layer) +{ + get_selection_manager()->clear_selected_layers(); + if(layer) + get_selection_manager()->set_selected_layer(layer); +} + + +void +CanvasView::refresh_rend_desc() +{ + current_time_widget->set_fps(get_canvas()->rend_desc().get_frame_rate()); + + + //???? + //sinfg::info("Canvasview: Refreshing render desc info"); + if(!get_time().is_equal(time_adjustment().get_value())) + { + time_adjustment().set_value(get_time()); + time_adjustment().value_changed(); + } + + Time length(get_canvas()->rend_desc().get_time_end()-get_canvas()->rend_desc().get_time_start()); + if(lengthset_global_fps(get_canvas()->rend_desc().get_frame_rate()); + + //set the beginning and ending time of the time slider + Time begin_time=get_canvas()->rend_desc().get_time_start(); + Time end_time=get_canvas()->rend_desc().get_time_end(); + + // Setup the time_window adjustment + time_window_adjustment().set_lower(begin_time); + time_window_adjustment().set_upper(end_time); + time_window_adjustment().set_step_increment(sinfg::Time(1.0/get_canvas()->rend_desc().get_frame_rate())); + + //Time length(get_canvas()->rend_desc().get_time_end()-get_canvas()->rend_desc().get_time_start()); + if(length < time_window_adjustment().get_page_size()) + { + time_window_adjustment().set_page_increment(length); + time_window_adjustment().set_page_size(length); + } + + /*sinfg::info("w: %p - [%.3f,%.3f] (%.3f,%.3f) child: %p\n", + &time_window_adjustment_, time_window_adjustment_.get_lower(), + time_window_adjustment_.get_upper(),time_window_adjustment_.get_value(), + time_window_adjustment_.get_page_size(),time_window_adjustment_.get_child_adjustment() + );*/ + + time_window_adjustment().changed(); //only non-value stuff was changed + + // Setup the time adjustment + + //NOTE THESE TWO SHOULD BE CHANGED BY THE changed() CALL ABOVE + //time_adjustment().set_lower(time_window_adjustment().get_value()); + //time_adjustment().set_upper(time_window_adjustment().get_value()+time_window_adjustment().get_page_size()); + +// time_adjustment().set_lower(get_canvas()->rend_desc().get_time_start()); +// time_adjustment().set_upper(get_canvas()->rend_desc().get_time_end()); + time_adjustment().set_step_increment(sinfg::Time(1.0/get_canvas()->rend_desc().get_frame_rate())); + time_adjustment().set_page_increment(sinfg::Time(1.0)); + time_adjustment().set_page_size(0); + + time_adjustment().changed(); + + /*sinfg::info("w: %p - [%.3f,%.3f] (%.3f,%.3f) child: %p\n", + &time_window_adjustment_, time_window_adjustment_.get_lower(), + time_window_adjustment_.get_upper(),time_window_adjustment_.get_value(), + time_window_adjustment_.get_page_size(),time_window_adjustment_.get_child_adjustment() + ); */ + + if(begin_time==end_time) + { + hide_timebar(); + } + else + { + show_timebar(); + } + + //clamp time to big bounds... + if(time_adjustment().get_value() < begin_time) + { + time_adjustment().set_value(begin_time); + time_adjustment().value_changed(); + } + + if(time_adjustment().get_value() > end_time) + { + time_adjustment().set_value(end_time); + time_adjustment().value_changed(); + } + + /*sinfg::info("Time stats: \n" + "w: %p - [%.3f,%.3f] (%.3f,%.3f) child: %p\n" + "t: %p - [%.3f,%.3f] %.3f", + &time_window_adjustment_, time_window_adjustment_.get_lower(), + time_window_adjustment_.get_upper(),time_window_adjustment_.get_value(), + time_window_adjustment_.get_page_size(),time_window_adjustment_.get_child_adjustment(), + &time_adjustment_,time_adjustment_.get_lower(),time_adjustment_.get_upper(), + time_adjustment_.get_value() + );*/ + + work_area->queue_render_preview(); +} + + +bool +CanvasView::close() +{ + hide(); + // I think this is bad..., removing + // get_instance()->canvas_view_list().erase(std::find(get_instance()->canvas_view_list().begin(),get_instance()->canvas_view_list().end(),this)); + return false; +} + +handle +CanvasView::create(loose_handle instance,handle canvas) +{ + etl::handle view(new CanvasView(instance,instance->sinfgapp::Instance::find_canvas_interface(canvas))); + instance->canvas_view_list().push_front(view); + instance->signal_canvas_view_created()(view.get()); + return view; +} + +void +CanvasView::update_title() +{ + string title; + + title+=etl::basename(get_instance()->get_file_name()) + +" : "; + if(get_canvas()->get_name().empty()) + title+='"'+get_canvas()->get_id()+'"'; + else + title+='"'+get_canvas()->get_name()+'"'; + + if(get_instance()->sinfgapp::Instance::get_action_count()) + title+=_(" (Unsaved)"); + + if(get_instance()->sinfgapp::Instance::in_repository()) + { + title+=" (CVS"; + if(get_instance()->sinfgapp::Instance::is_modified()) + title+=_("-MODIFIED"); + if(get_instance()->sinfgapp::Instance::is_updated()) + title+=_("-UPDATED"); + title+=')'; + } + + if(get_canvas()->is_root()) + title+=_(" (Root)"); + + set_title(title); +} + + +void +CanvasView::on_hide() +{ + smach_.egress(); + Gtk::Window::on_hide(); +} + +void +CanvasView::present() +{ + grab_focus();//on_focus_in_event(0); + Gtk::Window::present(); +} + +bool +CanvasView::on_focus_in_event(GdkEventFocus*x) +{ + if(studio::App::get_selected_canvas_view()!=this) + { + if(studio::App::get_selected_canvas_view()) + { + studio::App::get_selected_canvas_view()->get_smach().process_event(EVENT_YIELD_TOOL_OPTIONS); + App::ui_manager()->remove_action_group(App::get_selected_canvas_view()->action_group); + } + + get_smach().process_event(EVENT_REFRESH_TOOL_OPTIONS); + + studio::App::set_selected_canvas_view(this); + + App::ui_manager()->insert_action_group(action_group); + } + + // HACK ... Questionable...? + if(x) + return Gtk::Window::on_focus_in_event(x); + + return true; +} + +bool +CanvasView::on_focus_out_event(GdkEventFocus*x) +{ + //App::ui_manager()->remove_action_group(action_group); + //App::ui_manager()->ensure_update(); + return Gtk::Window::on_focus_out_event(x); +} + +void +CanvasView::refresh_tables() +{ +// if(layer_tree_store_)layer_tree_store_->refresh(); +// if(children_tree_store_)children_tree_store_->refresh(); +} + +void +CanvasView::rebuild_tables() +{ +// layer_tree_store_->rebuild(); +// children_tree_store_->rebuild(); +} + +void +CanvasView::build_tables() +{ +// layer_tree_store_->rebuild(); +// children_tree_store_->rebuild(); +} + +void +CanvasView::on_layer_toggle(sinfg::Layer::Handle layer) +{ + sinfgapp::Action::Handle action(sinfgapp::Action::create("layer_activate")); + assert(action); + + if(!action) + return; + + action->set_param("canvas",Canvas::Handle(layer->get_canvas())); + if(!action->set_param("canvas_interface",canvas_interface())) +// if(!action->set_param("canvas_interface",get_instance()->find_canvas_interface(layer->get_canvas()))) + sinfg::error("LayerActivate didn't like CanvasInterface...?"); + action->set_param("time",get_time()); + action->set_param("layer",layer); + action->set_param("new_status",!layer->active()); + + assert(action->is_ready()); + + canvas_interface()->get_instance()->perform_action(action); +} + + +void +CanvasView::popup_param_menu(sinfgapp::ValueDesc value_desc, float location) +{ + parammenu.items().clear(); + get_instance()->make_param_menu(¶mmenu,get_canvas(),value_desc,location); + + parammenu.popup(3,gtk_get_current_event_time()); +} + +void +CanvasView::add_actions_to_menu(Gtk::Menu *menu, const sinfgapp::Action::ParamList ¶m_list,sinfgapp::Action::Category category)const +{ + get_instance()->add_actions_to_menu(menu, param_list, category); +} + +bool +CanvasView::on_layer_user_click(int button, Gtk::TreeRow row, LayerTree::ColumnID column_id) +{ + switch(button) + { + case 3: + { + + Gtk::MenuItem* menu = dynamic_cast(App::ui_manager()->get_widget("/menu-main/menu-layer")); + if(menu && menu->get_submenu()) + { + //menu->set_accel_group(App::ui_manager()->get_accel_group()); + //menu->accelerate(*this); + menu->get_submenu()->popup(button,gtk_get_current_event_time()); + } + + + #if 0 + bool multiple_selected=true; + + if(layer_tree->get_selection()->count_selected_rows()<=1) + multiple_selected=false; + + // If the clicked row is not selected, then unselect + // everything that isn't selected and select this row + if(multiple_selected && !layer_tree->get_selection()->is_selected(row)) + { + layer_tree->get_selection()->unselect_all(); + layer_tree->get_selection()->select(row); + multiple_selected=false; + } + + if(column_id==COLUMNID_TIME_TRACK) + return false; + + //sinfgapp::ValueDesc value_desc(row[layer_param_tree_model.value_desc]); + //ValueNode::Handle value_node(row[layer_param_tree_model.value_node]); + //ValueNode::Handle parent_value_node; + //ValueBase value=row[layer_param_tree_model.value]; + + //if(row.parent()) + //{ + // parent_value_node=(*row.parent())[layer_tree_model.value_node]; + //} + + { + Layer::Handle layer(row[layer_tree_model.layer]); + sinfgapp::Action::ParamList param_list; + param_list.add("time",canvas_interface()->get_time()); + param_list.add("canvas",Canvas::Handle(row[layer_tree_model.canvas])); + param_list.add("canvas_interface",canvas_interface()); + if(!multiple_selected) + param_list.add("layer",layer); + else + { + sinfgapp::SelectionManager::LayerList layer_list(get_selection_manager()->get_selected_layers()); + sinfgapp::SelectionManager::LayerList::iterator iter; + + for(iter=layer_list.begin();iter!=layer_list.end();++iter) + param_list.add("layer",Layer::Handle(*iter)); + } + + parammenu.items().clear(); + + Gtk::Menu *newlayers(manage(new Gtk::Menu())); + build_new_layer_menu(*newlayers); + + parammenu.items().push_back(Gtk::Menu_Helpers::MenuElem("New Layer",*newlayers)); + if(!multiple_selected && layer->get_name()=="PasteCanvas") + { + parammenu.items().push_back(Gtk::Menu_Helpers::MenuElem(_("Select All Children"), + sigc::bind( + sigc::mem_fun( + *layer_tree, + &studio::LayerTree::select_all_children_layers + ), + layer + ) + )); + } + + add_actions_to_menu(¶mmenu, param_list,sinfgapp::Action::CATEGORY_LAYER); + parammenu.popup(button,gtk_get_current_event_time()); + return true; + } +/* + else if(column_id==LayerTree::COLUMNID_TIME_TRACK && value_node && handle::cast_dynamic(value_node)) + { + // Right-click on time track with animated +// trackmenu.popup(0,0); + return true; + } + else + { + if(!multiple_selected) + { + popup_param_menu(value_desc); + return true; + } + else + { +#warning update me! +#if 0 + parammenu.items().clear(); + parammenu.items().push_back(Gtk::Menu_Helpers::MenuElem("Connect", + hide_return(sigc::mem_fun(*canvas_interface().get(),&sinfgapp::CanvasInterface::connect_selected_layer_params)) + )); + parammenu.items().push_back(Gtk::Menu_Helpers::MenuElem("Disconnect", + hide_return(sigc::mem_fun(*canvas_interface().get(),&sinfgapp::CanvasInterface::disconnect_selected_layer_params)) + )); + parammenu.popup(0,0); +#endif + } + return true; + } + */ +#endif +} + return true; + break; + + default: + return false; + break; + } +} + + + +bool +CanvasView::on_children_user_click(int button, Gtk::TreeRow row, ChildrenTree::ColumnID column_id) +{ + switch(button) + { + case 3: + { + if(column_id==COLUMNID_TIME_TRACK) + return false; + if(!(bool)row[children_tree_model.is_canvas]) + { + sinfgapp::ValueDesc value_desc=row[children_tree_model.value_desc]; + assert(value_desc); + popup_param_menu(value_desc); + return true; + } + } + return true; + break; + + default: + return false; + break; + } +} + +bool +CanvasView::on_keyframe_tree_event(GdkEvent *event) +{ + switch(event->type) + { + case GDK_BUTTON_PRESS: + switch(event->button.button) + { + case 3: + { + //keyframemenu.popup(event->button.button,gtk_get_current_event_time()); + return true; + } + break; + } + break; + case GDK_MOTION_NOTIFY: + break; + case GDK_BUTTON_RELEASE: + break; + default: + break; + } + return false; +} + + +void +CanvasView::refresh_time_window() +{ + //THESE SHOULD AUTOMATICALLY BE TAKEN CARE OF + //time_adjustment().set_lower(time_window_adjustment().get_value()); + //time_adjustment().set_upper(time_window_adjustment().get_value()+time_window_adjustment().get_page_size()); + + time_adjustment().set_page_increment(1.0); // One second + time_adjustment().set_page_size(0); + + if(get_canvas()) + time_adjustment().set_step_increment(1.0/get_canvas()->rend_desc().get_frame_rate()); + time_adjustment().changed(); + + //NOTE THIS SHOULD HOOK INTO THE CORRECT SIGNALS... + if(children_tree) + children_tree->queue_draw(); +} + +void +CanvasView::on_time_changed() +{ + Time time(get_time()); + + current_time_widget->set_value(time); + try { + get_canvas()->keyframe_list().find(time); + current_time_widget->modify_text(Gtk::STATE_NORMAL,Gdk::Color("#FF0000")); + }catch(...){ + current_time_widget->modify_text(Gtk::STATE_NORMAL,Gdk::Color("#000000")); + } + + if(get_time() != time_adjustment().get_value()) + { + + //Recenters the window, causing it to jump (possibly undesirably... but whatever) + if(time < time_window_adjustment().get_value() || + time > time_window_adjustment().get_value()+time_window_adjustment().get_page_size()) + { + time_window_adjustment().set_value( + time-time_window_adjustment().get_page_size()/2 + ); + } + time_adjustment().set_value(time); + time_adjustment().value_changed(); + + // Shouldn't these trees just hook into + // the time changed signal...? + //YES THEY SHOULD... + if(layer_tree)layer_tree->queue_draw(); + if(children_tree)children_tree->queue_draw(); + } +} + +void +CanvasView::time_zoom_in() +{ + time_window_adjustment().set_page_size(time_window_adjustment().get_page_size()*0.75); + time_window_adjustment().changed(); + + refresh_time_window(); +} + +void +CanvasView::time_zoom_out() +{ + time_window_adjustment().set_page_size(time_window_adjustment().get_page_size()/0.75); + time_window_adjustment().changed(); + + refresh_time_window(); +} + +void +CanvasView::time_was_changed() +{ + sinfg::Time time((sinfg::Time)(double)time_adjustment().get_value()); + set_time(time); +} + +void +CanvasView::on_edited_value(sinfgapp::ValueDesc value_desc,sinfg::ValueBase new_value) +{ + canvas_interface()->change_value(value_desc,new_value); +} + +/* +void +CanvasView::on_children_edited_value(const Glib::ustring&path_string,sinfg::ValueBase value) +{ + Gtk::TreePath path(path_string); + + const Gtk::TreeRow row = *(children_tree->get_model()->get_iter(path)); + + assert((bool)row[children_tree_model.is_value_node]); + + sinfgapp::ValueDesc value_desc=row[children_tree_model.value_desc]; + assert(value_desc); + + on_edited_value(value_desc,value); +} +*/ + +void +CanvasView::on_id_changed() +{ + update_title(); +} + + +void +CanvasView::on_mode_changed(sinfgapp::CanvasInterface::Mode mode) +{ + // If the aninimate flag was set in mode... + if(mode&sinfgapp::MODE_ANIMATE) + { + Gtk::Image *icon; + icon=manage(new Gtk::Image(Gtk::StockID("gtk-no"),Gtk::ICON_SIZE_BUTTON)); + animatebutton->remove(); + animatebutton->add(*icon); + tooltips.set_tip(*animatebutton,_("In Animate Editing Mode")); + icon->set_padding(0,0); + icon->show(); + } + else + { + Gtk::Image *icon; + icon=manage(new Gtk::Image(Gtk::StockID("gtk-yes"),Gtk::ICON_SIZE_BUTTON)); + animatebutton->remove(); + animatebutton->add(*icon); + tooltips.set_tip(*animatebutton,_("Not in Animate Editing Mode")); + icon->set_padding(0,0); + icon->show(); + } + + if((mode&sinfgapp::MODE_ANIMATE_FUTURE) && (mode&sinfgapp::MODE_ANIMATE_PAST)) + { + Gtk::Image *icon; + icon=manage(new Gtk::Image(Gtk::StockID("sinfg-keyframe_lock_all"),Gtk::ICON_SIZE_BUTTON)); + keyframebutton->remove(); + keyframebutton->add(*icon); + tooltips.set_tip(*keyframebutton,_("All Keyframes Locked")); + icon->set_padding(0,0); + icon->show(); + } + else if((mode&sinfgapp::MODE_ANIMATE_FUTURE) && !(mode&sinfgapp::MODE_ANIMATE_PAST)) + { + Gtk::Image *icon; + icon=manage(new Gtk::Image(Gtk::StockID("sinfg-keyframe_lock_future"),Gtk::ICON_SIZE_BUTTON)); + keyframebutton->remove(); + keyframebutton->add(*icon); + tooltips.set_tip(*keyframebutton,_("Future Keyframes Locked")); + icon->set_padding(0,0); + icon->show(); + } + else if(!(mode&sinfgapp::MODE_ANIMATE_FUTURE) && (mode&sinfgapp::MODE_ANIMATE_PAST)) + { + Gtk::Image *icon; + icon=manage(new Gtk::Image(Gtk::StockID("sinfg-keyframe_lock_past"),Gtk::ICON_SIZE_BUTTON)); + keyframebutton->remove(); + keyframebutton->add(*icon); + tooltips.set_tip(*keyframebutton,_("Past Keyframes Locked")); + icon->set_padding(0,0); + icon->show(); + } + else if(!(mode&sinfgapp::MODE_ANIMATE_FUTURE) && !(mode&sinfgapp::MODE_ANIMATE_PAST)) + { + Gtk::Image *icon; + icon=manage(new Gtk::Image(Gtk::StockID("sinfg-keyframe_lock_none"),Gtk::ICON_SIZE_BUTTON)); + keyframebutton->remove(); + keyframebutton->add(*icon); + tooltips.set_tip(*keyframebutton,_("No Keyframes Locked")); + icon->set_padding(0,0); + icon->show(); + } + + work_area->queue_draw(); +} + +void +CanvasView::on_animate_button_pressed() +{ + if(get_mode()&sinfgapp::MODE_ANIMATE) + set_mode(get_mode()-sinfgapp::MODE_ANIMATE); + else + set_mode(get_mode()|sinfgapp::MODE_ANIMATE); +} + +void +CanvasView::on_keyframe_button_pressed() +{ + sinfgapp::CanvasInterface::Mode mode(get_mode()); + + if((mode&sinfgapp::MODE_ANIMATE_FUTURE) && (mode&sinfgapp::MODE_ANIMATE_PAST)) + { + set_mode(get_mode()-sinfgapp::MODE_ANIMATE_FUTURE); + } + else if(!(mode&sinfgapp::MODE_ANIMATE_FUTURE) && (mode&sinfgapp::MODE_ANIMATE_PAST)) + { + set_mode(get_mode()-sinfgapp::MODE_ANIMATE_PAST|sinfgapp::MODE_ANIMATE_FUTURE); + } + else if((mode&sinfgapp::MODE_ANIMATE_FUTURE) && !(mode&sinfgapp::MODE_ANIMATE_PAST)) + { + set_mode(get_mode()-sinfgapp::MODE_ANIMATE_FUTURE); + } + else if(!(mode&sinfgapp::MODE_ANIMATE_FUTURE) && !(mode&sinfgapp::MODE_ANIMATE_PAST)) + { + set_mode(get_mode()|sinfgapp::MODE_ANIMATE_FUTURE|sinfgapp::MODE_ANIMATE_PAST); + } +} + +bool +CanvasView::duck_change_param(const Point &value,sinfg::Layer::Handle layer, sinfg::String param_name) +{ + return canvas_interface()->change_value(sinfgapp::ValueDesc(layer,param_name),value); +} + +bool +CanvasView::on_duck_changed(const sinfg::Point &value,const sinfgapp::ValueDesc& value_desc) +{ + switch(value_desc.get_value_type()) + { + case ValueBase::TYPE_REAL: + return canvas_interface()->change_value(value_desc,value.mag()); + break; + case ValueBase::TYPE_ANGLE: + return canvas_interface()->change_value(value_desc,Angle::tan(value[1],value[0])); + break; + default: + return canvas_interface()->change_value(value_desc,value); + break; + } + + return true; +} + +void +CanvasView::selected_layer_color_set(Color color) +{ + sinfgapp::SelectionManager::LayerList selected_list(get_selection_manager()->get_selected_layers()); + sinfgapp::SelectionManager::LayerList::iterator iter; + + // Create the action group + //sinfgapp::PassiveGrouper group(canvas_interface()->get_instance(),_("Set Colors")); + + Layer::Handle layer; + for(iter=selected_list.begin();iter!=selected_list.end();++iter) + { + if(*iter==layer) + continue; + layer=*iter; + on_edited_value(sinfgapp::ValueDesc(layer,"color"),color); + } +} + +void +CanvasView::rebuild_ducks_layer_(sinfg::TransformStack& transform_stack, Canvas::Handle canvas, std::set& selected_list) +{ + int transforms(0); + String layer_name; + +#define QUEUE_REBUILD_DUCKS sigc::mem_fun(*this,&CanvasView::queue_rebuild_ducks) + + if(!canvas) + { + sinfg::warning("CanvasView::rebuild_ducks_layer_(): Layer doesn't have canvas set"); + return; + } + for(Canvas::iterator iter(canvas->begin());iter!=canvas->end();++iter) + { + Layer::Handle layer(*iter); + + if(selected_list.count(layer)) + { + if(!curr_transform_stack_set) + { + curr_transform_stack_set=true; + curr_transform_stack=transform_stack; + } + + // This layer is currently selected. + duck_changed_connections.push_back(layer->signal_changed().connect(QUEUE_REBUILD_DUCKS)); + + // do the bounding box thing + bbox|=transform_stack.perform(layer->get_bounding_rect()); + + // Grab the layer's list pf parameters + Layer::ParamList paramlist(layer->get_param_list()); + + // Grab the layer vocabulary + Layer::Vocab vocab=layer->get_param_vocab(); + Layer::Vocab::iterator iter; + + for(iter=vocab.begin();iter!=vocab.end();iter++) + { + if(!iter->get_hidden() && !iter->get_invisible_duck()) + { + sinfgapp::ValueDesc value_desc(layer,iter->get_name()); + work_area->add_to_ducks(value_desc,this,transform_stack,&*iter); + if(value_desc.is_value_node()) + duck_changed_connections.push_back(value_desc.get_value_node()->signal_changed().connect(QUEUE_REBUILD_DUCKS)); + } + if(iter->get_name()=="color") + { + /* + if(!App::dialog_color->busy()) + { + App::dialog_color->reset(); + App::dialog_color->set_color(layer->get_param("color").get(Color())); + App::dialog_color->signal_edited().connect( + sigc::mem_fun( + *this, + &studio::CanvasView::selected_layer_color_set + ) + ); + } + */ + } + } + } + + layer_name=layer->get_name(); + + if(layer->active()) + { + Transform::Handle trans(layer->get_transform()); + if(trans) + { + transform_stack.push(trans); + transforms++; + } + +/* // Add transforms onto the stack + if(layer_name=="Translate") + { + transform_stack.push(sinfg::Transform_Translate(layer->get_param("origin").get(Vector()))); + transforms++; + }else + if(layer_name=="Zoom") + { + Vector scale; + scale[0]=scale[1]=exp(layer->get_param("amount").get(Real())); + transform_stack.push(sinfg::Transform_Scale(scale,layer->get_param("center").get(Vector()))); + transforms++; + }else + if(layer_name=="stretch") + { + Vector scale(layer->get_param("amount").get(Vector())); + transform_stack.push(sinfg::Transform_Scale(scale,layer->get_param("center").get(Vector()))); + transforms++; + }else + if(layer_name=="Rotate") + { + transform_stack.push(sinfg::Transform_Rotate(layer->get_param("amount").get(Angle()),layer->get_param("origin").get(Vector()))); + transforms++; + } +*/ + } + + // If this is a paste canvas layer, then we need to + // descend into it + if(layer_name=="PasteCanvas") + { + Vector scale; + scale[0]=scale[1]=exp(layer->get_param("zoom").get(Real())); + Vector origin(layer->get_param("origin").get(Vector())); + + Canvas::Handle child_canvas(layer->get_param("canvas").get(Canvas::Handle())); + + if(!scale.is_equal_to(Vector(1,1))) + transform_stack.push(new Transform_Scale(scale,origin)); + if(!scale.is_equal_to(Vector(0,0))) + transform_stack.push(new Transform_Translate(origin)); + + rebuild_ducks_layer_(transform_stack,child_canvas,selected_list); + + if(!scale.is_equal_to(Vector(0,0))) + transform_stack.pop(); + if(!scale.is_equal_to(Vector(1,1))) + transform_stack.pop(); + } + } + // Remove all of the transforms we have added + while(transforms--) { transform_stack.pop(); } + +#undef QUEUE_REBUILD_DUCKS +} + +void +CanvasView::queue_rebuild_ducks() +{ +#if 0 + if(rebuild_ducks_queued) + return; +#else + if(rebuild_ducks_queued) + queue_rebuild_ducks_connection.disconnect(); +#endif + + queue_rebuild_ducks_connection=Glib::signal_timeout().connect( + sigc::bind_return( + sigc::mem_fun(*this,&CanvasView::rebuild_ducks), + false + ), + 50 + ); + + rebuild_ducks_queued=true; +} + +void +CanvasView::rebuild_ducks() +{ + /*static int i=0; + i++; + if(i>30) + sinfg::info("%d",i/(i-i)); + */ + + rebuild_ducks_queued=false; + //queue_rebuild_ducks_connection.disconnect(); + + if(work_area->is_dragging()) + { + queue_rebuild_ducks(); + return; + } + + if(!duck_refresh_flag) + { + duck_refresh_needed=true; + return; + } + + bbox=Rect::zero(); + + work_area->clear_ducks(); + work_area->set_time(get_time()); + get_canvas()->set_time(get_time()); + curr_transform_stack.clear(); + //curr_transform_stack.push(new Transform_Translate(Point(0,0))); + curr_transform_stack_set=false; + + for(;!duck_changed_connections.empty();duck_changed_connections.pop_back())duck_changed_connections.back().disconnect(); + + //get_canvas()->set_time(get_time()); + bool not_empty(false); + + // First do the layers... + do{ + sinfgapp::SelectionManager::LayerList selected_list(get_selection_manager()->get_selected_layers()); + std::set layer_set(selected_list.begin(),selected_list.end()); + + if(!layer_set.empty()) + not_empty=true; + + sinfg::TransformStack transform_stack; + + rebuild_ducks_layer_(transform_stack, get_canvas(), layer_set); + + }while(0); + + // Now do the children + do{ + sinfgapp::SelectionManager::ChildrenList selected_list(get_selection_manager()->get_selected_children()); + sinfgapp::SelectionManager::ChildrenList::iterator iter; + sinfg::TransformStack transform_stack; + + if(selected_list.empty()) + { + break; + } + else + { + not_empty=true; + for(iter=selected_list.begin();iter!=selected_list.end();++iter) + { + work_area->add_to_ducks(*iter,this,transform_stack); + } + } + }while(0); + work_area->refresh_selected_ducks(); + work_area->queue_draw_preview(); +} + +void +CanvasView::on_dirty_preview() +{ + if(!is_playing_) + { + IsWorking is_working(*this); + + work_area->queue_render_preview(); + } +} + +void +CanvasView::play() +{ + assert(get_canvas()); + + // If we are already busy, don't play! + if(working_depth)return; + + // Set us up as working + IsWorking is_working(*this); + + etl::clock timer; + Time + time=work_area->get_time(), + endtime=get_canvas()->rend_desc().get_time_end(); + + // If we are already at the end of time, start over + if(time==endtime) + time=get_canvas()->rend_desc().get_time_start(); + + is_playing_=true; + + work_area->clear_ducks(); + + for(timer.reset(); time + timer() < endtime;) + { + //Clamp the time window so we can see the time value as it races across the horizon + bool timewindreset = false; + + while( time + timer() > Time(time_window_adjustment().get_sub_upper()) ) + { + time_window_adjustment().set_value( + min( + time_window_adjustment().get_value()+time_window_adjustment().get_page_size()/2, + time_window_adjustment().get_upper()-time_window_adjustment().get_page_size() ) + ); + timewindreset = true; + } + + while( time + timer() < Time(time_window_adjustment().get_sub_lower()) ) + { + time_window_adjustment().set_value( + max( + time_window_adjustment().get_value()-time_window_adjustment().get_page_size()/2, + time_window_adjustment().get_lower()) + ); + + timewindreset = true; + } + + //we need to tell people that the value changed + if(timewindreset) time_window_adjustment().value_changed(); + + //update actual time to next step + time_adjustment().set_value(time+timer()); + time_adjustment().value_changed(); + + if(!work_area->sync_render_preview()) + break; + + studio::App::iteration(false); + + if(get_cancel_status()) + return; + } + is_playing_=false; + + time_adjustment().set_value(endtime); + time_adjustment().value_changed(); +} + +void +CanvasView::show_tables() +{ +/* + Smach::event_result x(process_event_key(EVENT_TABLES_SHOW)); + if(x==Smach::RESULT_OK || x==Smach::RESULT_ACCEPT) + { + Gtk::IconSize iconsize=Gtk::IconSize::from_name("sinfg-small_icon"); + treetogglebutton->remove(); + treetogglebutton->add(*manage(new Gtk::Image(Gtk::StockID("gtk-go-down"),iconsize))); + treetogglebutton->show_all(); + notebook->show(); + } +*/ +} + +void +CanvasView::hide_tables() +{ +/* + Smach::event_result x(process_event_key(EVENT_TABLES_HIDE)); + if(x==Smach::RESULT_OK || x==Smach::RESULT_ACCEPT) + { + Gtk::IconSize iconsize=Gtk::IconSize::from_name("sinfg-small_icon"); + treetogglebutton->remove(); + treetogglebutton->add(*manage(new Gtk::Image(Gtk::StockID("gtk-go-up"),iconsize))); + treetogglebutton->show_all(); + notebook->hide(); + } +*/ +} + +bool +CanvasView::tables_are_visible() +{ +// return notebook->is_visible(); + return false; +} + +void +CanvasView::toggle_tables() +{ +// if(tables_are_visible()) +// hide_tables(); +// else +// show_tables(); +} + +void +CanvasView::do_rotoscope_bline() +{ + smach_.enter(&state_bline); +} + +void +CanvasView::do_rotoscope() +{ + smach_.enter(&state_draw); +} + +void +CanvasView::do_rotoscope_poly() +{ + smach_.enter(&state_polygon); +} + +void +CanvasView::do_eyedrop() +{ + smach_.enter(&state_eyedrop); +} + +void +CanvasView::show_timebar() +{ + timebar->show(); + current_time_widget->show(); + + //keyframe_tab_child->show(); + if(layer_tree) + layer_tree->set_show_timetrack(true); + if(children_tree) + children_tree->set_show_timetrack(true); +} + +void +CanvasView::hide_timebar() +{ + timebar->hide(); + current_time_widget->hide(); + //keyframe_tab_child->hide(); + if(layer_tree) + layer_tree->set_show_timetrack(false); + if(children_tree) + children_tree->set_show_timetrack(false); +} + + + +void +CanvasView::on_waypoint_clicked(sinfgapp::ValueDesc value_desc,sinfg::Waypoint waypoint,int button) +{ + waypoint_dialog.set_value_desc(value_desc); + waypoint_dialog.set_waypoint(waypoint); + + switch(button) + { + case -1: + waypoint_dialog.show(); + break; + case 2: + { + Gtk::Menu* waypoint_menu(manage(new Gtk::Menu())); + + waypoint_menu->items().push_back(Gtk::Menu_Helpers::StockMenuElem(Gtk::StockID("gtk-jump-to"), + sigc::bind( + sigc::mem_fun( + *canvas_interface(), + &sinfgapp::CanvasInterface::set_time + ), + waypoint.get_time() + ) + )); + + waypoint_menu->items().push_back(Gtk::Menu_Helpers::StockMenuElem(Gtk::StockID("Edit Waypoint"), + sigc::mem_fun( + waypoint_dialog, + &Gtk::Widget::show + ) + )); + + waypoint_menu->items().push_back(Gtk::Menu_Helpers::StockMenuElem(Gtk::StockID("sinfg-duplicate"), + sigc::bind( + sigc::bind( + sigc::mem_fun( + *canvas_interface(), + &sinfgapp::CanvasInterface::waypoint_duplicate + ), + waypoint + ), + value_desc + ) + )); + waypoint_menu->items().push_back(Gtk::Menu_Helpers::StockMenuElem(Gtk::StockID("gtk-delete"), + sigc::bind( + sigc::bind( + sigc::mem_fun( + *canvas_interface(), + &sinfgapp::CanvasInterface::waypoint_remove + ), + waypoint + ), + value_desc + ) + )); + waypoint_menu->popup(button+1,gtk_get_current_event_time()); + } + break; + default: + break; + } +} + +void +CanvasView::on_waypoint_changed() +{ + sinfgapp::Action::ParamList param_list; + param_list.add("canvas",get_canvas()); + param_list.add("canvas_interface",canvas_interface()); + param_list.add("value_node",waypoint_dialog.get_value_desc().get_value_node()); + param_list.add("waypoint",waypoint_dialog.get_waypoint()); +// param_list.add("time",canvas_interface()->get_time()); + + get_instance()->process_action("waypoint_set_smart", param_list); +} + +void +CanvasView::on_waypoint_delete() +{ + sinfgapp::Action::ParamList param_list; + param_list.add("canvas",get_canvas()); + param_list.add("canvas_interface",canvas_interface()); + param_list.add("value_node",waypoint_dialog.get_value_desc().get_value_node()); + param_list.add("waypoint",waypoint_dialog.get_waypoint()); +// param_list.add("time",canvas_interface()->get_time()); + + get_instance()->process_action("waypoint_remove", param_list); +} + +void +CanvasView::on_drop_drag_data_received(const Glib::RefPtr& context, int x, int y, const Gtk::SelectionData& selection_data_, guint info, guint time) +{ + // We will make this true once we have a solid drop + bool success(false); + //sinfg::info("Droped data of type \"%s\"",selection_data.get_data_type()); + //sinfg::info("Droped data of target \"%s\"",gdk_atom_name(selection_data->target)); + //sinfg::info("selection=\"%s\"",gdk_atom_name(selection_data->selection)); + + if ((selection_data_.get_length() >= 0) && (selection_data_.get_format() == 8)) + { + if(sinfg::String(selection_data_.get_data_type())=="STRING")do + { + sinfg::String selection_data((gchar *)(selection_data_.get_data())); + + Layer::Handle layer(sinfg::Layer::create("Text")); + if(!layer) + break; + if(!layer->set_param("text",ValueBase(selection_data))) + break; + + sinfgapp::Action::Handle action(sinfgapp::Action::create("layer_add")); + + assert(action); + if(!action) + break; + + action->set_param("canvas",get_canvas()); + action->set_param("canvas_interface",canvas_interface()); + action->set_param("new",layer); + + if(!get_instance()->perform_action(action)) + break; + + // Ok, we have successfuly imported at least one item. + success=true; + } while(0); // END of "STRING" + + if(sinfg::String(selection_data_.get_data_type())=="text/plain") + { + sinfg::String selection_data((gchar *)(selection_data_.get_data())); + + // For some reason, GTK hands us a list of URL's seperated + // by not only Carrage-Returns, but also Line-Feeds. + // Line-Feeds will mess us up. Remove all the line-feeds. + while(selection_data.find_first_of('\r')!=sinfg::String::npos) + selection_data.erase(selection_data.begin()+selection_data.find_first_of('\r')); + + std::stringstream stream(selection_data); + + //sinfgapp::PassiveGrouper group(canvas_interface()->get_instance(),_("Insert Image")); + while(stream) + { + sinfg::String filename,URI; + getline(stream,filename); + + // If we don't have a filename, move on. + if(filename.empty()) + continue; + + // Make sure this URL is of the "file://" type. + URI=String(filename.begin(),filename.begin()+sizeof("file://")-1); + if(URI!="file://") + { + sinfg::warning("Unknown URI (%s) in \"%s\"",URI.c_str(),filename.c_str()); + continue; + } + + // Strip the "file://" part from the filename + filename=sinfg::String(filename.begin()+sizeof("file://")-1,filename.end()); + + String ext; + try{ext=(String(filename.begin()+filename.find_last_of('.')+1,filename.end()));}catch(...){continue;} + + // If this is a SIF file, then we need to do things slightly differently + if(ext=="sketch") + { + if(work_area->load_sketch(filename)) + { + success=true; + work_area->queue_draw(); + } + } + else + { + if(canvas_interface()->import(filename)) + success=true; + } + + continue; + } + } // END of "text/plain" + } + else + ui_interface_->error("Drop failed: bad selection data"); + + // Finish the drag + context->drag_finish(success, false, time); +} + +void +CanvasView::on_keyframe_add_pressed() +{ + sinfgapp::Action::Handle action(sinfgapp::Action::create("keyframe_add")); + + if(!action) + { + ui_interface_->error("I am unable to find the appropriate action"); + return; + } + + action->set_param("canvas",get_canvas()); + action->set_param("canvas_interface",canvas_interface()); + action->set_param("keyframe",Keyframe(get_time())); + + canvas_interface()->get_instance()->perform_action(action); +} + +void +CanvasView::on_keyframe_duplicate_pressed() +{ + const KeyframeTreeStore::Model model; + const Gtk::TreeRow row(*keyframe_tree->get_selection()->get_selected()); + Keyframe keyframe; + if(!row) + { + ui_interface_->error("I am unable to duplicate the keyframe"); + return; + } + keyframe=row[model.keyframe]; + + sinfgapp::Action::Handle action(sinfgapp::Action::create("keyframe_duplicate")); + + if(!action) + { + ui_interface_->error("I am unable to find the appropriate action"); + return; + } + + action->set_param("canvas",get_canvas()); + action->set_param("canvas_interface",canvas_interface()); + action->set_param("keyframe",keyframe); + action->set_param("time",get_time()); + + canvas_interface()->get_instance()->perform_action(action); +} + +void +CanvasView::on_keyframe_remove_pressed() +{ + const KeyframeTreeStore::Model model; + const Gtk::TreeRow row(*keyframe_tree->get_selection()->get_selected()); + Keyframe keyframe; + if(!row) + { + ui_interface_->error("I am unable to remove the keyframe"); + return; + } + keyframe=row[model.keyframe]; + + sinfgapp::Action::Handle action(sinfgapp::Action::create("keyframe_remove")); + + if(!action) + { + ui_interface_->error("I am unable to find the appropriate action"); + return; + } + + action->set_param("canvas",get_canvas()); + action->set_param("canvas_interface",canvas_interface()); + action->set_param("keyframe",keyframe); + + canvas_interface()->get_instance()->perform_action(action); +} + + +void +CanvasView::toggle_duck_mask(Duckmatic::Type type) +{ + bool is_currently_on(work_area->get_type_mask()&type); + + switch(type) + { + case Duck::TYPE_POSITION: + if(duck_mask_position) + duck_mask_position->set_active(!is_currently_on); + break; + + case Duck::TYPE_VERTEX: + if(duck_mask_vertex) + duck_mask_vertex->set_active(!is_currently_on); + break; + + case Duck::TYPE_TANGENT: + if(duck_mask_tangent) + duck_mask_tangent->set_active(!is_currently_on); + break; + + case Duck::TYPE_RADIUS: + if(duck_mask_radius) + duck_mask_radius->set_active(!is_currently_on); + break; + + case Duck::TYPE_WIDTH: + if(duck_mask_width) + duck_mask_width->set_active(!is_currently_on); + break; + + case Duck::TYPE_ANGLE: + if(duck_mask_angle) + duck_mask_angle->set_active(!is_currently_on); + break; + + default: + sinfg::warning("CanvasView::toggle_duck_mask():Unknown duck type!"); + break; + } + + if(is_currently_on) + work_area->set_type_mask(work_area->get_type_mask()-type); + else + work_area->set_type_mask(work_area->get_type_mask()|type); + + work_area->queue_draw(); +} + + +void +CanvasView::image_import() +{ + String filename(dirname(get_canvas()->get_file_name())); + if(App::dialog_open_file(_("Import Image"), filename)) + canvas_interface()->import(filename); +} + +Smach::event_result +CanvasView::process_event_key(EventKey x) +{ + return smach_.process_event(x); +} + +void +CanvasView::on_input_device_changed(GdkDevice* device) +{ + if(!device) + { + get_smach().egress(); + } + assert(device); + + sinfgapp::InputDevice::Handle input_device; + input_device=sinfgapp::Main::select_input_device(device->name); + App::toolbox->change_state(input_device->get_state()); + process_event_key(EVENT_INPUT_DEVICE_CHANGED); +} + +void +CanvasView::on_preview_option() +{ + Dialog_PreviewOptions *po = dynamic_cast(get_ext_widget("prevoptions")); + + Canvas::Handle canv = get_canvas(); + + if(canv) + { + RendDesc &r = canv->rend_desc(); + if(r.get_frame_rate()) + { + float rate = 1/r.get_frame_rate(); + float beg = r.get_time_start() + r.get_frame_start()*rate; + float end = r.get_time_start() + r.get_frame_end()*rate; + + if(!po) + { + po = new Dialog_PreviewOptions; + po->set_zoom(work_area->get_zoom()/2); + po->set_fps(r.get_frame_rate()/2); + po->set_begintime(beg); + po->set_begin_override(false); + po->set_endtime(end); + po->set_end_override(false); + + set_ext_widget("prevoptions",po); + } + /*po->set_zoom(work_area->get_zoom()/2); + po->set_fps(r.get_frame_rate()/2); + po->set_begintime(beg); + po->set_begin_override(false); + po->set_endtime(end); + po->set_end_override(false);*/ + + po->set_global_fps(r.get_frame_rate()); + po->signal_finish().connect(sigc::mem_fun(*this,&CanvasView::on_preview_create)); + po->present(); + } + } +} + +void +CanvasView::on_preview_create(const PreviewInfo &info) +{ + //set all the options + etl::handle prev = new Preview; + + prev->set_canvasview(this); + prev->set_zoom(info.zoom); + prev->set_fps(info.fps); + prev->set_overbegin(info.overbegin); + prev->set_begintime(info.begintime); + prev->set_overend(info.overend); + prev->set_endtime(info.endtime); + prev->set_quality(work_area->get_quality()); + + //render it out... + prev->render(); + + Dialog_Preview *pd = preview_dialog.get(); + assert(pd); + + pd->set_preview(prev.get()); + pd->present(); +} + +void +CanvasView::on_audio_option() +{ + sinfg::warning("Launching Audio Options"); + sound_dialog->set_global_fps(get_canvas()->rend_desc().get_frame_rate()); + sound_dialog->present(); +} + +void +CanvasView::on_audio_file_change(const std::string &f) +{ + //save in meta data - always even when not valid... + canvas_interface()->set_meta_data("audiofile",f); +} + +void +CanvasView::on_audio_offset_change(const Time &t) +{ + canvas_interface()->set_meta_data("audiooffset",t.get_string()); +} + +void +CanvasView::on_audio_file_notify() +{ + std::string file(get_canvas()->get_meta_data("audiofile")); + if(!file.c_str()) return; + + if(!audio->load(file,dirname(get_canvas()->get_file_name())+string("/"))) + { + if(file != "") sinfg::warning("Could not load the file: %s", file.c_str()); + get_canvas()->erase_meta_data("audiofile"); + disp_audio->hide(); + disp_audio->set_profile(etl::handle()); + }else + { + //save in canvasview + sinfg::warning("Getting the profile of the music stuff"); + + //profile specific stuff for the preview widget + //similar for other attachments + Dialog_Preview *pd = preview_dialog.get(); + pd->get_widget().set_audio(audio); + + handle prof = audio->get_profile(); + + if(!prof) + { + sinfg::warning("Agh, I couldn't build the profile captain!"); + } + pd->get_widget().set_audioprofile(prof); + + disp_audio->set_profile(audio->get_profile()); + disp_audio->show(); + + sinfg::warning("successfully set the profiles and stuff"); + } + disp_audio->queue_draw(); +} + +void +CanvasView::on_audio_offset_notify() +{ + Time t(get_canvas()->get_meta_data("audiooffset"),get_canvas()->rend_desc().get_frame_rate()); + audio->set_offset(t); + sound_dialog->set_offset(t); + disp_audio->queue_draw(); + + sinfg::info("CanvasView::on_audio_offset_notify(): offset time set to %s",t.get_string(get_canvas()->rend_desc().get_frame_rate()).c_str()); +} + +void +CanvasView::play_audio(float t) +{ + if(audio.get()) + { + sinfg::info("Playing audio at %f s",t); + audio->play(t); + } +} + +void +CanvasView::stop_audio() +{ + if(audio.get()) + { + audio->stop(); + } +} + +bool +CanvasView::on_audio_scrub() +{ + disp_audio->draw(); + return true; +} + + + +Glib::RefPtr +CanvasView::get_ref_obj(const sinfg::String& x) +{ + return ref_obj_book_[x]; +} + +Glib::RefPtr +CanvasView::get_ref_obj(const sinfg::String& x)const +{ + return ref_obj_book_.find(x)->second; +} + +void +CanvasView::set_ref_obj(const sinfg::String& x, Glib::RefPtr y) +{ + ref_obj_book_[x]=y; +} + +Glib::RefPtr +CanvasView::get_tree_model(const sinfg::String& x) +{ + return Glib::RefPtr::cast_dynamic(ref_obj_book_["_tree_model_"+x]); +} + +Glib::RefPtr +CanvasView::get_tree_model(const sinfg::String& x)const +{ + return Glib::RefPtr::cast_dynamic(ref_obj_book_.find("_tree_model_"+x)->second); +} + +void +CanvasView::set_tree_model(const sinfg::String& x, Glib::RefPtr y) +{ + ref_obj_book_["_tree_model_"+x]=Glib::RefPtr::cast_static(y); +} + +Gtk::Widget* +CanvasView::get_ext_widget(const sinfg::String& x) +{ + return ext_widget_book_[x]; +} + +void +CanvasView::set_ext_widget(const sinfg::String& x, Gtk::Widget* y) +{ + ext_widget_book_[x]=y; + if(x=="layers_cmp") + { + layer_tree=dynamic_cast(y); + + layer_tree->get_selection()->signal_changed().connect(SLOT_EVENT(EVENT_LAYER_SELECTION_CHANGED)); + layer_tree->get_selection()->signal_changed().connect(SLOT_EVENT(EVENT_REFRESH_DUCKS)); + layer_tree->signal_layer_user_click().connect(sigc::mem_fun(*this, &studio::CanvasView::on_layer_user_click)); + layer_tree->signal_param_user_click().connect(sigc::mem_fun(*this, &studio::CanvasView::on_children_user_click)); + layer_tree->signal_waypoint_clicked().connect(sigc::mem_fun(*this, &studio::CanvasView::on_waypoint_clicked)); + } + if(x=="children") + { + children_tree=dynamic_cast(y); + if(children_tree)children_tree->signal_user_click().connect(sigc::mem_fun(*this, &studio::CanvasView::on_children_user_click)); + if(children_tree)children_tree->signal_waypoint_clicked().connect(sigc::mem_fun(*this, &studio::CanvasView::on_waypoint_clicked)); + if(children_tree)children_tree->get_selection()->signal_changed().connect(SLOT_EVENT(EVENT_REFRESH_DUCKS)); + } + if(x=="keyframes") + keyframe_tree=dynamic_cast(y); +} + +static bool _close_instance(etl::handle instance) +{ + etl::handle argh(instance); + instance->safe_close(); + sinfg::info("closed"); + return false; +} + +bool +CanvasView::on_delete_event(GdkEventAny* event) +{ + if(get_instance()->get_visible_canvases()==1) + { + // Schedule a close to occur in a few moments + Glib::signal_timeout().connect( + sigc::bind( + sigc::ptr_fun(_close_instance), + (etl::handle)get_instance() + ) + ,250 + ); + } + if(event) + return Gtk::Window::on_delete_event(event); + + return true; +} diff --git a/synfig-studio/trunk/src/gtkmm/canvasview.h b/synfig-studio/trunk/src/gtkmm/canvasview.h new file mode 100644 index 0000000..887e622 --- /dev/null +++ b/synfig-studio/trunk/src/gtkmm/canvasview.h @@ -0,0 +1,697 @@ +/* === S I N F G =========================================================== */ +/*! \file canvasview.h +** \brief Template Header +** +** $Id: canvasview.h,v 1.2 2005/01/13 18:37:30 darco Exp $ +** +** \legal +** Copyright (c) 2002 Robert B. Quattlebaum Jr. +** +** This software and associated documentation +** are CONFIDENTIAL and PROPRIETARY property of +** the above-mentioned copyright holder. +** +** You may not copy, print, publish, or in any +** other way distribute this software without +** a prior written agreement with +** the copyright holder. +** \endlegal +*/ +/* ========================================================================= */ + +/* === S T A R T =========================================================== */ + +#ifndef __SINFG_STUDIO_GTKMM_CANVASVIEW_H +#define __SINFG_STUDIO_GTKMM_CANVASVIEW_H + +/* === H E A D E R S ======================================================= */ + +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include + +#include +#include + +#include +#include +#include + +#include "instance.h" +#include "canvasproperties.h" +#include "canvasoptions.h" +#include "render.h" +#include "cellrenderer_timetrack.h" +#include "app.h" + +#include "layertreestore.h" +#include "layertree.h" +#include "childrentreestore.h" +#include "childrentree.h" +#include "keyframetreestore.h" +#include "keyframetree.h" + +#include "dialog_waypoint.h" +#include "dialog_keyframe.h" + +#include "duckmatic.h" +#include + +#include + +#include "smach.h" + +#include +#include +#include +#include +#include +#include + +#include "adjust_window.h" + +#include + +/* === M A C R O S ========================================================= */ + +#ifndef DEBUGPOINT_CLASS +#if _DEBUG +#define DEBUGPOINT_CLASS(x) struct debugpointclass_ ## x { debugpointclass_ ## x () { DEBUGPOINT(); } ~debugpointclass_ ## x () { DEBUGPOINT(); } } badfthguae_ ## x ; +#else +#define DEBUGPOINT_CLASS(x) +#endif +#endif + +/* === T Y P E D E F S ===================================================== */ + +/* === C L A S S E S & S T R U C T S ======================================= */ + +namespace studio { + +class CanvasViewUIInterface; +class CanvasViewSelectionManager; + +class CellRenderer_TimeTrack; +class CellRenderer_ValueBase; +class UniversalScrubber; +class WorkArea; + +class Duckmatic; + +class Preview; +struct PreviewInfo; +class AudioContainer; + +class Widget_Sound; +class Widget_Timeslider; +class Widget_Time; + +class Dialog_SoundSelect; +class Dialog_Preview; + +class sinfg::TransformStack; +class Dock_Layers; +class Dock_Children; +class Dock_Keyframes; + +class CanvasView : public Gtk::Window, public etl::shared_object +{ + friend class UniversalScrubber; + friend class Dock_Layers; + friend class Dock_Children; + friend class Dock_Keyframes; + + friend class CanvasViewUIInterface; + friend class CanvasViewSelectionManager; + + friend class Duckmatic; + + /* + -- ** -- P U B L I C T Y P E S --------------------------------------------- + */ + +public: + + typedef etl::handle Handle; + + typedef etl::handle ConstHandle; + + typedef etl::loose_handle LooseHandle; + + typedef LayerTreeStore::Model LayerTreeModel; + + typedef ChildrenTreeStore::Model ChildrenTreeModel; + + //! Create an instance of this class whenever doing a longer task. + /*! Make sure that you check the bool value of this class occasionaly + ** to make sure the action has not been canceled. */ + class IsWorking + { + CanvasView &canvas_view_; + + public: + IsWorking(CanvasView &canvas_view_); + ~IsWorking(); + operator bool()const; + }; + friend class IsWorking; + + typedef sinfgapp::CanvasInterface::Mode Mode; + + /* + -- ** -- P R I V A T E D A T A --------------------------------------------- + */ + +public: + std::auto_ptr work_area; + + WorkArea* get_work_area() { return work_area.get(); } +private: + + sinfg::TransformStack curr_transform_stack; + bool curr_transform_stack_set; + + sinfg::Rect bbox; + + DEBUGPOINT_CLASS(1); + + //! State Machine + Smach smach_; + + DEBUGPOINT_CLASS(2); + + etl::loose_handle instance_; + etl::handle canvas_interface_; + + DEBUGPOINT_CLASS(3); + + //! Sound and information to play it + etl::handle audio; + studio::Widget_Sound *disp_audio; //should this be put into thing too? + + SigC::Connection playcon; + SigC::Connection stopcon; + + std::auto_ptr universal_scrubber; + + //! Tooltip controler + Gtk::Tooltips tooltips; + + DEBUGPOINT_CLASS(4); + + //! TreeModel for the layers + LayerTreeModel layer_tree_model; + + //! TreeModel for the the children + ChildrenTreeModel children_tree_model; + + //Glib::RefPtr layer_tree_store_; + + //Glib::RefPtr children_tree_store_; + + //Glib::RefPtr keyframe_tree_store_; + + DEBUGPOINT_CLASS(5); + + //std::map > tree_model_book_; + std::map > ref_obj_book_; + std::map ext_widget_book_; + + + //! The time adjustment's scope is defined by the time_window adjustment + Gtk::Adjustment time_adjustment_; + + //! The time_window adjustment governs the position of the time window on the whole time line + //Gtk::Adjustment time_window_adjustment_; + studio::Adjust_Window time_window_adjustment_; + + + LayerTree *layer_tree; + + ChildrenTree *children_tree; + + KeyframeTree *keyframe_tree; + + Gtk::Widget *keyframe_tab_child; + + Gtk::ProgressBar *progressbar; + Gtk::Statusbar *statusbar; + + Gtk::TreeRow children_canvas_row; + Gtk::TreeRow children_valuenode_row; + + Gtk::Button *stopbutton; + Gtk::Button *refreshbutton; + Gtk::Button *treetogglebutton; + Gtk::Notebook *notebook; + Gtk::Widget *timebar; + + Widget_Time *current_time_widget; + void on_current_time_widget_changed(); + + std::auto_ptr timeslider; + + std::list duck_changed_connections; + + + + Gtk::Button *animatebutton; + Gtk::Button *keyframebutton; + +/* DEBUGPOINT_CLASS(8); + + Gtk::Menu duckmaskmenu; + DEBUGPOINT_CLASS(77); + Gtk::Menu qualitymenu; + DEBUGPOINT_CLASS(6); + + Gtk::Menu filemenu; + DEBUGPOINT_CLASS(777); + Gtk::Menu editmenu; + DEBUGPOINT_CLASS(71); + Gtk::Menu canvasmenu; + DEBUGPOINT_CLASS(73); +public: + Gtk::Menu layermenu; +private: + DEBUGPOINT_CLASS(74); + Gtk::Menu newlayermenu; + DEBUGPOINT_CLASS(76); + Gtk::Menu viewmenu; + + DEBUGPOINT_CLASS(99); + Gtk::Menu keyframemenu; + + Gtk::Menu parammenu; + DEBUGPOINT_CLASS(9); + Gtk::Menu trackmenu; + DEBUGPOINT_CLASS(7); + + Gtk::CheckMenuItem* duck_mask_position; + Gtk::CheckMenuItem* duck_mask_vertex; + Gtk::CheckMenuItem* duck_mask_tangent; + Gtk::CheckMenuItem* duck_mask_radius; + Gtk::CheckMenuItem* duck_mask_width; + Gtk::CheckMenuItem* duck_mask_angle; +*/ + Gtk::Menu parammenu; + + + Glib::RefPtr duck_mask_position; + Glib::RefPtr duck_mask_vertex; + Glib::RefPtr duck_mask_tangent; + Glib::RefPtr duck_mask_radius; + Glib::RefPtr duck_mask_width; + Glib::RefPtr duck_mask_angle; + + Gtk::RadioButtonGroup quality_group; + + Glib::RefPtr action_group; + + + etl::handle ui_interface_; + etl::handle selection_manager_; + + bool is_playing_; + + sigc::signal signal_deleted_; + + bool rebuild_ducks_queued; + sigc::connection queue_rebuild_ducks_connection; + + /* + -- ** -- P U B L I C D A T A ----------------------------------------------- + */ + +public: + void queue_rebuild_ducks(); + sigc::signal& signal_deleted() { return signal_deleted_; } + + Gtk::Menu mainmenu; + + bool duck_refresh_flag; + bool duck_refresh_needed; + + //! This is for the IsWorking class. + int working_depth; + + bool cancel; + + + /* + -- ** -- D I A L O G S ------------------------------------------------------- + */ + +public: + + CanvasProperties canvas_properties; + CanvasOptions canvas_options; + RenderSettings render_settings; + Dialog_Waypoint waypoint_dialog; + Dialog_Keyframe keyframe_dialog; + + std::auto_ptr preview_dialog; + //std::auto_ptr previewoption_dialog; + std::auto_ptr sound_dialog; + + /* + -- ** -- P R I V A T E M E T H O D S --------------------------------------- + */ + +private: + + // Constructor is private to force the use of the "create()" constructor + CanvasView(etl::loose_handle instance,etl::handle canvas_interface); + + //! Constructor Helper + Gtk::Widget* create_layer_tree(); + + //! Constructor Helper + Gtk::Widget* create_children_tree(); + + //! Constructor Helper + Gtk::Widget* create_keyframe_tree(); + + //! Constructor Helper + Gtk::Widget* create_status_bar(); + + //! Constructor Helper - Initializes all of the menus + void init_menus(); + + bool duck_change_param(const sinfg::Point &value,sinfg::Layer::Handle layer, sinfg::String param_name); + + void refresh_time_window(); + + void time_was_changed(); + + void refresh_rend_desc(); + + void toggle_duck_mask(Duckmatic::Type type); + + Gtk::Widget *create_work_area(); + + Gtk::Widget *create_time_bar(); + + + + void popup_param_menu_bezier(float location, sinfgapp::ValueDesc value_desc) + { popup_param_menu(value_desc,location); } + + void popup_param_menu(sinfgapp::ValueDesc value_desc, float location=0); + + + void workarea_layer_selected(sinfg::Layer::Handle layer); + + void selected_layer_color_set(sinfg::Color color); + + + + void register_layer_type(sinfg::Layer::Book::value_type &lyr,std::map*); + + //! Rebuilds the "new layer" menu + void build_new_layer_menu(Gtk::Menu &menu); + + void rebuild_ducks_layer_(sinfg::TransformStack& transform_stack, sinfg::Canvas::Handle canvas, std::set& selected_list); + + /* + -- ** -- P U B L I C M E T H O D S ----------------------------------------- + */ + +public: + const sinfg::TransformStack& get_curr_transform_stack()const { return curr_transform_stack; } + + const sinfg::Rect& get_bbox()const { return bbox; } + + Glib::RefPtr get_ref_obj(const sinfg::String& x); + Glib::RefPtr get_ref_obj(const sinfg::String& x)const; + void set_ref_obj(const sinfg::String& x, Glib::RefPtr y); + + Glib::RefPtr get_tree_model(const sinfg::String& x); + Glib::RefPtr get_tree_model(const sinfg::String& x)const; + void set_tree_model(const sinfg::String& x, Glib::RefPtr y); + + Gtk::Widget* get_ext_widget(const sinfg::String& x); + void set_ext_widget(const sinfg::String& x, Gtk::Widget* y); + + //std::map& tree_view_book() { return tree_view_book_; } + //std::map& ext_widget_book() { return tree_view_book_; } + + void popup_main_menu(); + + Smach& get_smach() { return smach_; } + + const Smach& get_smach()const { return smach_; } + + Smach::event_result process_event_key(EventKey x); + + void popup_layer_menu(sinfg::Layer::Handle layer); + + virtual ~CanvasView(); + + void set_mode(Mode x) { canvas_interface()->set_mode(x); } + + Mode get_mode()const { return canvas_interface()->get_mode(); } + + Gtk::Adjustment &time_adjustment() { return time_adjustment_; } + + const Gtk::Adjustment &time_adjustment()const { return time_adjustment_; } + + studio::Adjust_Window &time_window_adjustment() { return time_window_adjustment_; } + + const studio::Adjust_Window &time_window_adjustment()const { return time_window_adjustment_; } + + etl::handle get_ui_interface() { return ui_interface_;} + + etl::handle get_selection_manager() { return selection_manager_; } + + Glib::RefPtr layer_tree_store() { return get_tree_model("layers"); } + + Glib::RefPtr layer_tree_store()const { return get_tree_model("layers"); } + + Glib::RefPtr children_tree_store() { return get_tree_model("children"); } + + Glib::RefPtr children_tree_store()const { return get_tree_model("children"); } + + Glib::RefPtr keyframe_tree_store() { return get_tree_model("keyframes"); } + + Glib::RefPtr keyframe_tree_store()const { return get_tree_model("keyframes"); } + + void set_time(sinfg::Time t) { canvas_interface_->set_time(t); } + + sinfg::Time get_time() { return canvas_interface_->get_time(); } + + etl::handle get_canvas()const { return canvas_interface_->get_canvas(); } + + etl::handle get_instance()const { return instance_; } + + etl::handle canvas_interface() { return canvas_interface_; } + + etl::handle canvas_interface()const { return canvas_interface_; } + + void add_actions_to_menu(Gtk::Menu *menu, const sinfgapp::Action::ParamList ¶m_list, sinfgapp::Action::Category category=sinfgapp::Action::CATEGORY_ALL)const; + + //! Updates the title of the window + void update_title(); + + //! Closes this canvas view + bool close(); + + //! Stops the currently executing action + /*! \see get_cancel_status(), reset_cancel_status(), IsWorking */ + void stop() { cancel=true; } + + //! Returns the cancel status + /*! \see stop(), reset_cancel_status(), IsWorking */ + bool get_cancel_status()const { return cancel; } + + //! Resets the cancel status + /*! \see stop(), get_cancel_status(), IsWorking */ + void reset_cancel_status() { cancel=false; } + + void new_child_canvas(); + + //! Rebuilds layer_tree_store_ from the Canvas. Maintains selected items. + void rebuild_tables(); + + //! Builds layer_tree_store_ from the Canvas. Does not maintain selected items. + void build_tables(); + + //! Refreshes the data for the tables + void refresh_tables(); + + //void rebuild_layer_table(); + //void build_layer_table(); + //void refresh_layer_table(); + +// void rebuild_canvas_table(); +// void build_canvas_table(); +// void refresh_canvas_table(); + +// void rebuild_valuenode_table(); +// void build_valuenode_table(); +// void refresh_valuenode_table(); + + //! \writeme + void rebuild_ducks(); + + //bool add_to_ducks(sinfgapp::ValueDesc value_desc, sinfg::ParamDesc *param_desc=NULL); + + //! Starts "playing" the animation in real-time + void play(); + + //! Shows the tables (Layer/Children) + void show_tables(); + + //! Hides the tables (Layer/Children) + void hide_tables(); + + //! Toggles the tables + void toggle_tables(); + + //! Gets the table status + bool tables_are_visible(); + + //! Shows the time bar + void show_timebar(); + + //! Hides the time bar + void hide_timebar(); + + void do_rotoscope_bline(); + + void do_rotoscope(); + + void do_rotoscope_poly(); + + void do_eyedrop(); + + void time_zoom_in(); + void time_zoom_out(); + + void add_layer(sinfg::String x); + + void show_keyframe_dialog(); + + void play_audio(float t); + void stop_audio(); + + void image_import(); + + void on_waypoint_clicked(sinfgapp::ValueDesc,sinfg::Waypoint, int button); + + void preview_option() {on_preview_option();} + + void present(); + + /* + -- ** -- S I G N A L T E R M I N A L S ------------------------------------- + */ + +private: + + void on_unselect_layers(); + + void on_input_device_changed(GdkDevice*); + + virtual void on_hide(); + + virtual bool on_focus_in_event(GdkEventFocus*); + virtual bool on_focus_out_event(GdkEventFocus*); + + //bool on_children_tree_event(GdkEvent *event); + + bool on_keyframe_tree_event(GdkEvent *event); + + //void on_children_edited_value(const Glib::ustring&path_string,sinfg::ValueBase value); + + void on_dirty_preview(); + + bool on_children_user_click(int, Gtk::TreeRow, ChildrenTree::ColumnID); + + bool on_layer_user_click(int, Gtk::TreeRow, LayerTree::ColumnID); + +// void on_layer_toggle(const Glib::ustring& path_string, Gtk::TreeModelColumn column); + + void on_mode_changed(sinfgapp::CanvasInterface::Mode mode); + +// void on_layer_waypoint_clicked(const Glib::ustring &, sinfg::ValueNode_Animated::WaypointList::iterator); + + //void on_children_waypoint_clicked(const Glib::ustring &, sinfg::ValueNode_Animated::WaypointList::iterator); + + void on_waypoint_changed(); + + void on_waypoint_delete(); + + void on_refresh_pressed(); + + void on_id_changed(); + + void on_time_changed(); + + /* + void on_layer_raise_pressed(); + void on_layer_lower_pressed(); + void on_layer_duplicate_pressed(); + void on_layer_delete_pressed(); + */ + + void on_keyframe_add_pressed(); + + void on_keyframe_duplicate_pressed(); + + void on_keyframe_remove_pressed(); + + void on_animate_button_pressed(); + + void on_keyframe_button_pressed(); + + void on_preview_option(); + void on_preview_create(const PreviewInfo &); + + void on_audio_option(); + void on_audio_file_change(const std::string &f); + void on_audio_offset_change(const sinfg::Time &t); + + void on_audio_file_notify(); + void on_audio_offset_notify(); + + bool on_duck_changed(const sinfg::Point &value,const sinfgapp::ValueDesc& value_desc); + + void on_layer_toggle(sinfg::Layer::Handle); + + void on_edited_value(sinfgapp::ValueDesc,sinfg::ValueBase); + + //void on_waypoint_clicked(sinfgapp::ValueDesc,sinfg::ValueNode_Animated::WaypointList::iterator, int button); + + void on_drop_drag_data_received(const Glib::RefPtr& context, int x, int y, const Gtk::SelectionData& selection_data, guint info, guint time); + + //void on_audio_play(); + bool on_audio_scrub(); + +protected: + bool on_delete_event(GdkEventAny* event); + + /* + -- ** -- S T A T I C P U B L I C M E T H O D S --------------------------- + */ + +public: + + static etl::handle create(etl::loose_handle instance,etl::handle canvas); +}; // END of class CanvasView + +}; // END of namespace studio + +/* === E N D =============================================================== */ + +#endif diff --git a/synfig-studio/trunk/src/gtkmm/cellrenderer_gradient.cpp b/synfig-studio/trunk/src/gtkmm/cellrenderer_gradient.cpp new file mode 100644 index 0000000..07d81f1 --- /dev/null +++ b/synfig-studio/trunk/src/gtkmm/cellrenderer_gradient.cpp @@ -0,0 +1,96 @@ +/* === S I N F G =========================================================== */ +/*! \file cellrenderer_gradient.cpp +** \brief Template File +** +** $Id: cellrenderer_gradient.cpp,v 1.1.1.1 2005/01/07 03:34:35 darco Exp $ +** +** \legal +** Copyright (c) 2002 Robert B. Quattlebaum Jr. +** +** This software and associated documentation +** are CONFIDENTIAL and PROPRIETARY property of +** the above-mentioned copyright holder. +** +** You may not copy, print, publish, or in any +** other way distribute this software without +** a prior written agreement with +** the copyright holder. +** \endlegal +*/ +/* ========================================================================= */ + +/* === H E A D E R S ======================================================= */ + +#ifdef USING_PCH +# include "pch.h" +#else +#ifdef HAVE_CONFIG_H +# include +#endif + +#include +#include +#include "cellrenderer_gradient.h" +#include "widget_gradient.h" +#include "app.h" + +#endif + +/* === U S I N G =========================================================== */ + +using namespace std; +//using namespace etl; +using namespace sinfg; +using namespace studio; + +/* === M A C R O S ========================================================= */ + +#if ! defined(_) +#define _(x) (x) +#endif + +/* === G L O B A L S ======================================================= */ + +/* === P R O C E D U R E S ================================================= */ + +/* === M E T H O D S ======================================================= */ + +CellRenderer_Gradient::CellRenderer_Gradient(): + Glib::ObjectBase (typeid(CellRenderer_Gradient)), + Gtk::CellRendererText (), + property_gradient_(*this,"gradient",sinfg::Gradient()) +{ + //CellRendererText::signal_edited().connect(sigc::mem_fun(*this,&studio::CellRenderer_Gradient::string_edited_)); +} + +CellRenderer_Gradient::~CellRenderer_Gradient() +{ +} + + +void +CellRenderer_Gradient::render_vfunc( + const Glib::RefPtr& window, + Gtk::Widget& widget, + const Gdk::Rectangle& background_area, + const Gdk::Rectangle& ca, + const Gdk::Rectangle& expose_area, + Gtk::CellRendererState flags) +{ + if(!window) + return; + render_gradient_to_window(window,ca,property_gradient_.get_value()); +} + + +Gtk::CellEditable* +CellRenderer_Gradient::start_editing_vfunc( + GdkEvent* event, + Gtk::Widget& widget, + const Glib::ustring& path, + const Gdk::Rectangle& background_area, + const Gdk::Rectangle& cell_area, + Gtk::CellRendererState flags) +{ + return 0; +} diff --git a/synfig-studio/trunk/src/gtkmm/cellrenderer_gradient.h b/synfig-studio/trunk/src/gtkmm/cellrenderer_gradient.h new file mode 100644 index 0000000..99ecfce --- /dev/null +++ b/synfig-studio/trunk/src/gtkmm/cellrenderer_gradient.h @@ -0,0 +1,87 @@ +/* === S I N F G =========================================================== */ +/*! \file cellrenderer_gradient.h +** \brief Template Header +** +** $Id: cellrenderer_gradient.h,v 1.1.1.1 2005/01/07 03:34:35 darco Exp $ +** +** \legal +** Copyright (c) 2002 Robert B. Quattlebaum Jr. +** +** This software and associated documentation +** are CONFIDENTIAL and PROPRIETARY property of +** the above-mentioned copyright holder. +** +** You may not copy, print, publish, or in any +** other way distribute this software without +** a prior written agreement with +** the copyright holder. +** \endlegal +*/ +/* ========================================================================= */ + +/* === S T A R T =========================================================== */ + +#ifndef __SINFG_STUDIO_CELLRENDERER_GRADIENT_H +#define __SINFG_STUDIO_CELLRENDERER_GRADIENT_H + +/* === H E A D E R S ======================================================= */ + +#include +#include + +#include +#include + +#include + +/* === M A C R O S ========================================================= */ + +/* === T Y P E D E F S ===================================================== */ + +/* === C L A S S E S & S T R U C T S ======================================= */ + +namespace Gtk { class Entry; class Button; }; + +namespace studio { + +class CellRenderer_Gradient : public Gtk::CellRendererText +{ + sigc::signal signal_secondary_click_; + sigc::signal signal_edited_; + + Glib::Property property_gradient_; + +public: + sigc::signal &signal_edited() + {return signal_edited_; } + + Glib::PropertyProxy property_gradient() { return property_gradient_.get_proxy();} + + CellRenderer_Gradient(); + ~CellRenderer_Gradient(); + +protected: + + virtual void + render_vfunc( + const Glib::RefPtr& window, + Gtk::Widget& widget, + const Gdk::Rectangle& background_area, + const Gdk::Rectangle& ca, + const Gdk::Rectangle& expose_area, + Gtk::CellRendererState flags); + + virtual Gtk::CellEditable* start_editing_vfunc(GdkEvent* event, + Gtk::Widget& widget, + const Glib::ustring& path, + const Gdk::Rectangle& background_area, + const Gdk::Rectangle& cell_area, + Gtk::CellRendererState flags); + +}; // END of class CellRenderer_Gradient + +}; // END of namespace studio + +/* === E N D =============================================================== */ + +#endif diff --git a/synfig-studio/trunk/src/gtkmm/cellrenderer_time.cpp b/synfig-studio/trunk/src/gtkmm/cellrenderer_time.cpp new file mode 100644 index 0000000..e7fe1fa --- /dev/null +++ b/synfig-studio/trunk/src/gtkmm/cellrenderer_time.cpp @@ -0,0 +1,132 @@ +/* === S I N F G =========================================================== */ +/*! \file cellrenderer_time.cpp +** \brief Template File +** +** $Id: cellrenderer_time.cpp,v 1.1.1.1 2005/01/07 03:34:35 darco Exp $ +** +** \legal +** Copyright (c) 2002 Robert B. Quattlebaum Jr. +** +** This software and associated documentation +** are CONFIDENTIAL and PROPRIETARY property of +** the above-mentioned copyright holder. +** +** You may not copy, print, publish, or in any +** other way distribute this software without +** a prior written agreement with +** the copyright holder. +** \endlegal +*/ +/* ========================================================================= */ + +/* === H E A D E R S ======================================================= */ + +#ifdef USING_PCH +# include "pch.h" +#else +#ifdef HAVE_CONFIG_H +# include +#endif + +#include +#include +#include "cellrenderer_time.h" +#include "app.h" +#include "widget_time.h" + +#endif + +/* === U S I N G =========================================================== */ + +using namespace std; +//using namespace etl; +using namespace sinfg; +using namespace studio; + +/* === M A C R O S ========================================================= */ + +#if ! defined(_) +#define _(x) (x) +#endif + +/* === G L O B A L S ======================================================= */ + +/* === P R O C E D U R E S ================================================= */ + +/* === M E T H O D S ======================================================= */ + +CellRenderer_Time::CellRenderer_Time(): + Glib::ObjectBase (typeid(CellRenderer_Time)), + Gtk::CellRendererText (), + property_time_(*this,"time",sinfg::Time(0)), + property_fps_(*this,"fps", float(0)) +{ + CellRendererText::signal_edited().connect(sigc::mem_fun(*this,&studio::CellRenderer_Time::string_edited_)); +} + +CellRenderer_Time::~CellRenderer_Time() +{ + sinfg::info("CellRenderer_Time::~CellRenderer_Time(): deleted"); +} + +void +CellRenderer_Time::string_edited_(const Glib::ustring&path,const Glib::ustring&str) +{ + signal_edited_(path,Time((String)str,(Real)Time(property_fps_))); +} + +void +CellRenderer_Time::render_vfunc( + const Glib::RefPtr& window, + Gtk::Widget& widget, + const Gdk::Rectangle& background_area, + const Gdk::Rectangle& ca, + const Gdk::Rectangle& expose_area, + Gtk::CellRendererState flags) +{ + if(!window) + return; + //int height = ca.get_height(); + + Gtk::StateType state = Gtk::STATE_INSENSITIVE; + if(property_editable()) + state = Gtk::STATE_NORMAL; + if((flags & Gtk::CELL_RENDERER_SELECTED) != 0) + state = (widget.has_focus()) ? Gtk::STATE_SELECTED : Gtk::STATE_ACTIVE; + + const Time time(property_time_); + const float fps((Real)Time(property_fps_)); + + property_text()=(Glib::ustring)time.get_string(fps,App::get_time_format()); + + CellRendererText::render_vfunc(window,widget,background_area,ca,expose_area,flags); +} + + +Gtk::CellEditable* +CellRenderer_Time::start_editing_vfunc( + GdkEvent* event, + Gtk::Widget& widget, + const Glib::ustring& path, + const Gdk::Rectangle& background_area, + const Gdk::Rectangle& cell_area, + Gtk::CellRendererState flags) +{ + // If we aren't editable, then there is nothing to do + if(!property_editable()) + return 0; + + const Time time(property_time_); + const float fps((Real)Time(property_fps_)); + + property_text()=(Glib::ustring)time.get_string(fps,App::get_time_format()|Time::FORMAT_FULL); +#if 0 + Widget_Time* widget_time(manage(new Widget_Time)); + widget_time->set_fps(fps); + widget_time->set_value(time); + widget_time->signal_editing_done().connect(sigc::mem_fun(*this, &CellRenderer_Time::on_value_editing_done)); + return widget_time; +#else + return CellRendererText::start_editing_vfunc(event,widget,path,background_area,cell_area,flags); +#endif +} diff --git a/synfig-studio/trunk/src/gtkmm/cellrenderer_time.h b/synfig-studio/trunk/src/gtkmm/cellrenderer_time.h new file mode 100644 index 0000000..c024723 --- /dev/null +++ b/synfig-studio/trunk/src/gtkmm/cellrenderer_time.h @@ -0,0 +1,93 @@ +/* === S I N F G =========================================================== */ +/*! \file cellrenderer_time.h +** \brief Template Header +** +** $Id: cellrenderer_time.h,v 1.1.1.1 2005/01/07 03:34:35 darco Exp $ +** +** \legal +** Copyright (c) 2002 Robert B. Quattlebaum Jr. +** +** This software and associated documentation +** are CONFIDENTIAL and PROPRIETARY property of +** the above-mentioned copyright holder. +** +** You may not copy, print, publish, or in any +** other way distribute this software without +** a prior written agreement with +** the copyright holder. +** \endlegal +*/ +/* ========================================================================= */ + +/* === S T A R T =========================================================== */ + +#ifndef __SINFG_STUDIO_CELLRENDERER_TIME_H +#define __SINFG_STUDIO_CELLRENDERER_TIME_H + +/* === H E A D E R S ======================================================= */ + +#include +#include + +#include +#include + +#include + +/* === M A C R O S ========================================================= */ + +/* === T Y P E D E F S ===================================================== */ + +/* === C L A S S E S & S T R U C T S ======================================= */ + +namespace Gtk { class Entry; class Button; }; + +namespace studio { + +class CellRenderer_Time : public Gtk::CellRendererText +{ + sigc::signal signal_secondary_click_; + sigc::signal signal_edited_; + + Glib::Property property_time_; + Glib::Property property_fps_; + + void string_edited_(const Glib::ustring&,const Glib::ustring&); + + void on_value_editing_done(); + +public: + sigc::signal &signal_edited() + {return signal_edited_; } + + Glib::PropertyProxy property_time() { return property_time_.get_proxy();} + Glib::PropertyProxy property_fps() { return property_fps_.get_proxy();} + + CellRenderer_Time(); + ~CellRenderer_Time(); + +protected: + + virtual void + render_vfunc( + const Glib::RefPtr& window, + Gtk::Widget& widget, + const Gdk::Rectangle& background_area, + const Gdk::Rectangle& ca, + const Gdk::Rectangle& expose_area, + Gtk::CellRendererState flags); + + virtual Gtk::CellEditable* start_editing_vfunc(GdkEvent* event, + Gtk::Widget& widget, + const Glib::ustring& path, + const Gdk::Rectangle& background_area, + const Gdk::Rectangle& cell_area, + Gtk::CellRendererState flags); + +}; // END of class CellRenderer_Time + +}; // END of namespace studio + +/* === E N D =============================================================== */ + +#endif diff --git a/synfig-studio/trunk/src/gtkmm/cellrenderer_timetrack.cpp b/synfig-studio/trunk/src/gtkmm/cellrenderer_timetrack.cpp new file mode 100644 index 0000000..b3c9a66 --- /dev/null +++ b/synfig-studio/trunk/src/gtkmm/cellrenderer_timetrack.cpp @@ -0,0 +1,993 @@ +/* === S I N F G =========================================================== */ +/*! \file cellrenderer_timetrack.cpp +** \brief Template Header +** +** $Id: cellrenderer_timetrack.cpp,v 1.4 2005/01/13 20:23:01 darco Exp $ +** +** \legal +** Copyright (c) 2002 Robert B. Quattlebaum Jr. +** +** This software and associated documentation +** are CONFIDENTIAL and PROPRIETARY property of +** the above-mentioned copyright holder. +** +** You may not copy, print, publish, or in any +** other way distribute this software without +** a prior written agreement with +** the copyright holder. +** \endlegal +*/ +/* ========================================================================= */ + +/* === H E A D E R S ======================================================= */ + +#ifdef USING_PCH +# include "pch.h" +#else +#ifdef HAVE_CONFIG_H +# include +#endif + +#include +#include "cellrenderer_timetrack.h" +#include +#include +#include +#include +#include "widget_value.h" +#include "app.h" +#include +#include +#include "widget_time.h" +#include "widget_timeslider.h" + +#include +#include "instance.h" + +#include + +#endif + +using namespace sinfg; +using namespace std; +using namespace etl; +using namespace studio; + +/* === M A C R O S ========================================================= */ + +/* === G L O B A L S ======================================================= */ + +static char stipple_xpm[] = { 2, 0 }; + +//mode for modifier keys +enum MODMODE +{ + NONE = 0, + SELECT_MASK = Gdk::CONTROL_MASK, + COPY_MASK = Gdk::SHIFT_MASK, + DELETE_MASK = Gdk::MOD1_MASK +}; + +/* === P R O C E D U R E S ================================================= */ + +/* === M E T H O D S ======================================================= */ + +CellRenderer_TimeTrack::CellRenderer_TimeTrack(): + Glib::ObjectBase (typeid(CellRenderer_TimeTrack)), + Gtk::CellRenderer (), + adjustment_ (10,10,20,0,0,0), + + property_valuedesc_ (*this,"value_desc",sinfgapp::ValueDesc()), + property_canvas_ (*this,"canvas",sinfg::Canvas::Handle()), + property_adjustment_(*this,"adjustment",&adjustment_), + property_enable_timing_info_(*this,"enable-timing-info", false) +{ + dragging=false; + selection=false; +} + +CellRenderer_TimeTrack::~CellRenderer_TimeTrack() +{ + sinfg::info("CellRenderer_TimeTrack::~CellRenderer_TimeTrack(): deleted"); +} + +void +CellRenderer_TimeTrack::set_adjustment(Gtk::Adjustment &x) +{ + property_adjustment_=&x; +// x.signal_value_changed().connect(sigc::mem_fun(*this,&Gtk::Widget::queue_draw)); +} + +sinfg::Canvas::Handle +CellRenderer_TimeTrack::get_canvas()const +{ + return const_cast(this)->property_canvas().get_value(); +} + +Gtk::Adjustment * +CellRenderer_TimeTrack::get_adjustment() +{ + return (Gtk::Adjustment*)property_adjustment_; +} + +const Gtk::Adjustment * +CellRenderer_TimeTrack::get_adjustment()const +{ + return (const Gtk::Adjustment*)property_adjustment_; +} + +bool +CellRenderer_TimeTrack::is_selected(const Waypoint& waypoint)const +{ + return selected==waypoint; +} + +//kind of a hack... pointer is ugly +const sinfg::Node::time_set *get_times_from_vdesc(const sinfgapp::ValueDesc &v) +{ + if(v.get_value_type() == sinfg::ValueBase::TYPE_CANVAS) + { + sinfg::Canvas::Handle canvasparam = v.get_value().get(Canvas::Handle()); + + if(canvasparam) + { + return &canvasparam->get_times(); + } + } + + ValueNode *base_value = v.get_value_node().get(); + + ValueNode_DynamicList *parent_value_node = + v.parent_is_value_node() ? + dynamic_cast(v.get_parent_value_node().get()) : + 0; + + //we want a dynamic list entry to override the normal... + if(parent_value_node) + { + return &parent_value_node->list[v.get_index()].get_times(); + }else if(base_value) //don't render stuff if it's just animated... + { + return &base_value->get_times(); + } + return 0; +} + +bool get_closest_time(const sinfg::Node::time_set &tset, const Time &t, const Time &range, Time &out) +{ + Node::time_set::const_iterator i,j,end = tset.end(); + + //TODO add in RangeGet so it's not so damn hard to click on points + + i = tset.upper_bound(t); //where t is the lower bound, t < [first,i) + j = i; --j; + + double dist = Time::end(); + double closest = 0; + + if(i != end) + { + closest = i->get_time(); + dist = abs(i->get_time() - t); + } + + if(j != end && (abs(j->get_time() - t) < dist) ) + { + closest = j->get_time(); + dist = abs(j->get_time() - t); + } + + if( dist <= range/2 ) + { + out = closest; + return true; + } + + return false; +} + +void +CellRenderer_TimeTrack::render_vfunc( + const Glib::RefPtr& window, + Gtk::Widget& widget, + const Gdk::Rectangle& background_area, + const Gdk::Rectangle& area_, + const Gdk::Rectangle& expose_area, + Gtk::CellRendererState flags) +{ + if(!window) + return; + + Glib::RefPtr gc(Gdk::GC::create(window)); + Glib::RefPtr inactive_gc(Gdk::GC::create(window)); + Gtk::Adjustment *adjustment=get_adjustment(); + Gtk::StateType state = Gtk::STATE_ACTIVE; + Gtk::ShadowType shadow; + + Gdk::Color + curr_time_color("#0000ff"), + inactive_color("#000000"), + keyframe_color("#a07f7f"); + Gdk::Color activepoint_color[2]; + + activepoint_color[0]=Gdk::Color("#ff0000"); + activepoint_color[1]=Gdk::Color("#00ff00"); + + inactive_gc->set_rgb_fg_color(inactive_color); + inactive_gc->set_stipple(Gdk::Bitmap::create(stipple_xpm,2,2)); + inactive_gc->set_fill(Gdk::STIPPLED); + + sinfg::Canvas::Handle canvas(property_canvas().get_value()); + + sinfgapp::ValueDesc value_desc = property_value_desc().get_value(); + sinfg::ValueNode *base_value = value_desc.get_value_node().get(); + sinfg::ValueNode_Animated *value_node=dynamic_cast(base_value); + + sinfg::ValueNode_DynamicList *parent_value_node(0); + if(property_value_desc().get_value().parent_is_value_node()) + parent_value_node=dynamic_cast(property_value_desc().get_value().get_parent_value_node().get()); + + // If the canvas is defined, then load up the keyframes + if(canvas) + { + const sinfg::KeyframeList& keyframe_list(canvas->keyframe_list()); + sinfg::KeyframeList::const_iterator iter; + + for(iter=keyframe_list.begin();iter!=keyframe_list.end();++iter) + { + if(!iter->get_time().is_valid()) + continue; + + const int x((int)((float)area_.get_width()/(adjustment->get_upper()-adjustment->get_lower())*(iter->get_time()-adjustment->get_lower()))); + if(iter->get_time()>=adjustment->get_lower() && iter->get_time()get_upper()) + { + gc->set_rgb_fg_color(keyframe_color); + window->draw_rectangle(gc, true, area_.get_x()+x, area_.get_y(), 1, area_.get_height()+1); + } + } + } + + //render all the time points that exist + { + const sinfg::Node::time_set *tset = get_times_from_vdesc(value_desc); + + if(tset) + { + sinfg::Node::time_set::const_iterator i = tset->begin(), end = tset->end(); + + float lower = adjustment->get_lower(), + upper = adjustment->get_upper(); + + Glib::RefPtr gc = Gdk::GC::create(widget.get_window()); + + Gdk::Rectangle area(area_); + gc->set_clip_rectangle(area); + gc->set_line_attributes(1,Gdk::LINE_SOLID,Gdk::CAP_BUTT,Gdk::JOIN_MITER); + + bool valselected = sel_value.get_value_node() == base_value && !sel_times.empty(); + + float cfps = get_canvas()->rend_desc().get_frame_rate(); + + vector