shutter-0.90.1/0000755000175000017500000000000012206477321012303 5ustar mariomarioshutter-0.90.1/README0000644000175000017500000000737012206477313013173 0ustar mariomarioShutter Copyright (C) 2008-2013 Mario Kemper --------------------- http://shutter-project.org/ Installation ------------ http://shutter-project.org/downloads/ Contact ------------ Via E-Mail : http://shutter-project.org/contact/ Via Launchpad.net : https://answers.launchpad.net/shutter/+addquestion Found a bug? ------------ https://bugs.launchpad.net/shutter/+filebug Shutter Licence ------------ Licence: GPL 3 or (at your option) any later version. Shutter is free software; you can redistribute it and/or modify it under the terms of the GNU General Public Licence as published by the Free Software Foundation; either version 3 of the Licence, or (at your option) any later version. Shutter is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program. If not, see . Cursors License ------------ Licence: GPL2 or (at your option) any later version. Some cursors (share/shutter/resources/icons/drawing_tool/cursor) are based on/taken from the inkscape project http://inkscape.sourceforge.net/ Gnome Icons ------------ Licence: GPL2 or (at your option) any later version. Tango Icons ------------ In the preparation of the 0.8.90 release Novell took care of tracking down all the contributors to get them to relicense their artwork into Public Domain. The COPYING file of the tarball states the following: | The icons in this repository are herefore released into the Public Domain. Additionally the copyright status of the files was tracked in the CVS and the rdf properties of the SVGs adjusted for all files that were put into Public Domain (see rdf:about and rdf:resource). Both fields contain a link to the Creative Commons Public Domain Dediciation[0] as reproduced below: | Public Domain Dedication | | Copyright-Only Dedication (based on United States law) or Public Domain | Certification | | The person or persons who have associated work with this document (the | "Dedicator" or "Certifier") hereby either (a) certifies that, to the best | of his knowledge, the work of authorship identified is in the public | domain of the country from which the work is published, or (b) | hereby dedicates whatever copyright the dedicators holds in the work | of authorship identified below (the "Work") to the public domain. A | certifier, moreover, dedicates any copyright interest he may have in | the associated work, and for these purposes, is described as a | "dedicator" below. | | A certifier has taken reasonable steps to verify the copyright | status of this work. Certifier recognizes that his good faith efforts | may not shield him from liability if in fact the work certified is not | in the public domain. | | Dedicator makes this dedication for the benefit of the public at | large and to the detriment of the Dedicator's heirs and successors. | Dedicator intends this dedication to be an overt act of relinquishment | in perpetuity of all present and future rights under copyright law, | whether vested or contingent, in the Work. Dedicator understands that | such relinquishment of all rights includes the relinquishment of all | rights to enforce (by lawsuit or otherwise) those copyrights in the | Work. | | Dedicator recognizes that, once placed in the public domain, the Work | may be freely reproduced, distributed, transmitted, used, modified, | built upon, or otherwise exploited by anyone for any purpose, commercial | or non-commercial, and in any way, including by methods that have not | yet been invented or conceived. [0] http://creativecommons.org/licenses/publicdomain/ shutter-0.90.1/CHANGES0000644000175000017500000010552012206477313013302 0ustar mariomarioshutter (0.90.1) * Fixed bugs / minor improvements -- LP: #1092522 [Shutter doesn't recognize the command-line option "-d"] -- LP: #1191521 [--delay=0 doesn't work from command-line] -- LP: #1216619 [Drawing Tool: encoding problems when using chinese fonts] * updated translations -- Mario Kemper Sun, 25 Aug 2013 21:45:08 +0200 shutter (0.90) * Fixed bugs / minor improvements -- LP: #1035259 [No way to activate the main window when using the appindicator] -- LP: #1081917 [Quicklist no more working] -- LP: #1083033 [Needs a high contrast app icon] -- LP: #1083586 [Remove keybinding code] -- LP: #1083588 [Remove Simple Selection Tool] -- LP: #1087367 [File extension .png] -- LP: #1092054 [desktop-file-validate complains again] * updated translations -- Mario Kemper Wed, 19 Dec 2012 12:21:39 +0100 shutter (0.89.1) * Fixed bugs / minor improvements -- LP: #1007712 [imageshack plug in fails] -- LP: #1020600 [bug on save output image in cyrillic keybord layout] -- LP: #1021158 [Imgur plugin doesn't work] -- LP: #1033931 [libgtk2-appindicator-perl not available for lucid (Ubuntu 10.04)] -- LP: #1035332 [desktop-file-validate complains] * updated translations -- Mario Kemper Mon, 13 Aug 2012 22:52:36 +0200 shutter (0.89) * Fixed bugs / minor improvements -- LP: #664292 [Feature Request: Please make use of appindicators] -- LP: #1012235 [Advanced Selection Capture entries do not work] -- LP: #1018791 [Change fsf-address] * updated translations -- Mario Kemper Wed, 01 Aug 2012 22:46:10 +0200 shutter (0.88.3) * Fixed bugs / minor improvements -- LP: #965589 [Dropbox upload should urlencode the resuting link] -- LP: #966159 [Wrong image format in save dialogue] -- LP: #975247 [Editor: icon tool fails to add image] -- LP: #976316 [Add include/exclude cursor option for command-line] -- LP: #976322 [Add --delay command line option] * updated translations -- Mario Kemper Mon, 23 Apr 2012 01:10:03 +0200 shutter (0.88.2) * Fixed bugs / minor improvements -- LP: #625291 [Edit menu items should be shown in right-click popup for object] -- LP: #812182 [save image to jpg extension] -- LP: #903305 [Add no_session parameter] -- LP: #909195 ['Updating plugins' dialogue appears on every startup] -- LP: #917158 [FTP upload plugin recently stopped working] * updated translations -- Mario Kemper Thu, 23 Feb 2012 11:56:50 +0100 shutter (0.88.1) * Fixed bugs / minor improvements -- LP: #894416 [Some upload plugins fail with unicode characters in filename] -- LP: #894577 [Minus service doesn't work] * updated translations -- Mario Kemper Thu, 01 Dec 2011 22:01:50 +0100 shutter (0.88) * New Features -- Refactored the uploading code (added support for plugins) -- Added new upload plugins -- Public links are now saved when a screenshot was uploaded -- New command line option: specify filename * New Upload Plugins -- Dropbox -- ImageBanana -- ImageShack -- Imgur -- ImmIO -- ITmages -- Minus -- Omploader -- ToileLibre -- TwitPic -- UbuntuPics * Fixed bugs / minor improvements -- LP: #342622 [Remember upload links] -- LP: #841328 [black corners if window is selected from the window list] -- LP: #888441 [dialog not clickable when renaming a file] -- LP: #889031 [Package should'nt provide own perl libraries] -- LP: #892703 [After unlinking from Dropbox there is no way to relink it again] -- LP: #650701 [retrieve Public URL if screenshot is already uploaded] -- LP: #675911 [Url not selected when i do single click] -- LP: #793462 [Short URL in imageshack.us] -- LP: #870556 [specify file name on command line] -- LP: #374024 [http://omploader.org/ as new image hoster] -- LP: #486490 [Feature Request: Upload to imgur] -- LP: #489598 [Wish: Add Twitpic support] -- LP: #598818 [feature request: extensible imagehost/upload tools] -- LP: #602209 [Add integration with Dropbox] -- LP: #619748 [Add ubuntuusers.de thumbnail code to any of the hosting plugins] -- LP: #651029 [Feature Request: Upload to ITmages] -- LP: #703299 [Add upload to http://pix.toile-libre.org/] -- LP: #785032 [min.us uploading support] -- LP: #793463 [More image services to upload] * improved support for Gnome-Shell * several smaller bugfixes * updated translations -- Mario Kemper Mon, 21 Nov 2011 15:54:45 +0100 shutter (0.87.3) * New Features -- Show "real" cursor (instead of standard cursor) -- Locate on disk * Fixed bugs / minor improvements -- LP: #695629 [locate on disk feature] -- LP: #781235 [shutter.1.gz isn't gzipped] -- LP: #769902 [shutter --man displays source code] -- LP: #752846 [Application doesn't work on windows with certain titles] -- LP: #749442 [UI improvements to the timeout menu] -- LP: #779252 [Support gnome-web-photo >= 0.10] -- LP: #744397 [It doesn't save the selected profile between sessions] -- LP: #388475 [Showing standard cursor (left-ptr) instead of current cursor] * updated translations -- Mario Kemper Sun, 03 Jul 2011 15:35:08 +0200 shutter (0.87.2) * Fixed bugs / minor improvements -- LP: #737428 ['Open with' does not work when filename contains german umlauts] -- LP: #738710 [Needs quicklists for Natty] * updated translations -- Mario Kemper Fri, 25 Mar 2011 11:59:51 +0100 shutter (0.87.1) * Fixed bugs / minor improvements -- LP: #657585 [Shutter ignores typed-in save location] -- LP: #695295 [Section: Encoding problems in non-english version of Shutter] -- LP: #697483 [Initial image in DrawingTool shouldn't be locked by default] -- LP: #705094 [Enter and Escape keys don't work any more] -- LP: #705315 [Shutter failed to take screenshot on seamless mode of virtualbox] -- LP: #708753 [Tab closing crashes in some circumstances] -- LP: #723075 [Error while opening image 'sel_window_list.svg'] -- LP: #730883 [Profiles doesn't save some information] -- LP: #731495 [Uploading to ImageShack broken] * updated translations -- Mario Kemper Thu, 10 Mar 2011 01:20:30 +0100 shutter (0.87) * New Features -- Capture active window -- Uniqueness via libunique (single instance) -- Support for rounded window corners when using Compiz -- Automatically resize windows before capture -- New option: don't save screenshot to disk -- Advanced startup-options -- EXIF orientation flag is now supported -- Compatible with global menu (unity) -- Export to PostScript -- Faster application startup (load session in background task) * Fixed Bugs / Improvements -- LP: #336132 [Load last session in a background task] -- LP: #348161 [Option not to save screenshots to disk by default] -- LP: #371555 [Add advanced startup-options to the settings dialog] -- LP: #388478 [multiple instances running] -- LP: #419137 [keyboard shortcuts and hidden main window] -- LP: #429677 [Add option to capture last active window] -- LP: #481096 [hotkeys and Compiz' flat-file backend] -- LP: #486659 [Pressing Enter in the image editor doesn't save image] -- LP: #517267 [shortcut keys with abbreviations can reset compiz shortcut keys] -- LP: #577040 [Add a --version command line argument] -- LP: #632042 [Disable re-save file warnings] -- LP: #638588 [Image name overlapping error with $nb_name format] -- LP: #643675 [Editor window opens too large] -- LP: #643683 [Can't capture cursor anymore] -- LP: #644084 [Moving files to trash doesn't work with KDE] -- LP: #644168 [Rotation in Shotwell is incomp. with some other applications] -- LP: #644847 [Shutter does not respect the EXIF orientation flag] -- LP: #654185 [Crop tool - Offset when zooming] -- LP: #658740 ['Open with' does not work with global menu (unity)] -- LP: #658745 [Unreadable (built-in) notifications: Text is highlighted] -- LP: #661424 [Plugins fails if ' in filename] -- LP: #657585 [Shutter ignores typed-in save location] -- LP: #666854 [Auto-resize windows] -- LP: #666858 [Opaque window corners when using compiz] -- LP: #671749 [Feature Request: Redo hotkey] -- LP: #671914 [Zoom window does not update when modifying selection] -- LP: #671917 [Use filename for notebook pages (instead of [no] - [date])] -- LP: #671918 [autoincrement does not work (in rare cases)] -- LP: #677745 [non-HIG complient menu tooltip] -- LP: #681008 [Add feature 'Export to PostScript'] -- LP: #685235 [Double click doesn't work when selecting a selection] * updated translations -- Mario Kemper Tue, 08 Feb 2011 07:15:28 +0100 shutter (0.86.4) * New Features -- Automatically add a border -- Capture all workspaces as one image * New Plugins -- Hard Shadow -- Autocrop * Fixed Bugs / Minor Improvements -- LP: #342628 [Make selection capture 'rounded grey box' less intrusive] -- LP: #497050 [Direction/Color on Shadow Plugin] -- LP: #535481 [Need an autocrop tool] -- LP: #583988 [JPEG export: file size too big] -- LP: #588188 [Add DrawingTool to Preferences>Actions>Open with] -- LP: #590348 [Need "border" feature] -- LP: #608683 [capture ALL desktops as one image] -- LP: #611832 [Advanced selection tool - Enable numpad enter] -- LP: #618008 [Non-latin filenames] -- LP: #620136 [Keyboard should be able to be used for fine grain movements] -- LP: #620397 [Adv. Selection Tool: no update when using the keyboard] -- LP: #622638 [shutter launches ubuntuone also, at startup] * updated translations -- Mario Kemper Wed, 01 Sep 2010 22:36:16 +0200 shutter (0.86.3) * New features -- Publish via Ubuntu One -- New humanity icons (ubuntu-mono-dark and ubuntu-mono-light) * Fixed bugs / minor improvements -- LP: #361971 [Rename Redo to Retry in upload failure dialog] -- LP: #506181 [Would like integration with Ubuntu One] -- LP: #552842 [function to hash the file name] -- LP: #577040 [Add a --version command line argument] -- LP: #582134 [Cannot export photos to imageshack] -- LP: #610042 [Ubuntu-pics.de is dead] -- LP: #610784 [Cannot export photos to imagebanana] * updated translations -- Mario Kemper Thu, 29 Jul 2010 17:47:59 +0200 shutter (0.86.2) * Fixed bugs / minor improvements -- LP: #470403 [Drag & drop the image after taking screenshot] -- LP: #543446 [Transparent parts... show as ] -- LP: #561097 [Profiles are broken] -- LP: #566597 [imageshack.us direct link is messed up] -- LP: #568961 [Desktop may crash when canceling web-capture] * updated translations -- Mario Kemper Wed, 28 Apr 2010 11:34:02 +0200 shutter (0.86.1) * Fixed bugs / minor improvements -- LP: #541751 [Add support for Thunderbird when sending via email] -- LP: #543058 [No error reporting on 'Send by mail'] -- LP: #549732 [print gives blank page] * updated translations -- Mario Kemper Wed, 31 Mar 2010 23:39:34 +0200 shutter (0.86) * New features -- Repeat last screenshots easily -- DrawingTool: New Pixelize tool -- DrawingTool: PDF + SVG Export -- DrawingTool: new shapes (e.g. callouts) -- Improved PDF export -- Copy URL to clipboard (FTP) -- Built-in notification windows -- Option to ask for a name and directory before saving -- Many usability improvements * Screenshot Tools -- LP: #344754 [Keep selection for screenshots] -- LP: #507465 [implement a workaround if some window doesn't deliver the correct type hint] -- #515944 [Can't take window screenshots when using fluxbox and styles that use the XShape extension] * Upload / Export -- LP: #339920 [Copy URL to clipboard after uploading to a FTP Server] -- LP: #341810 [Remember last used 'Upload' tab] -- LP: #513778 [ImageShack direct link incorrect] * Drawing Tool -- LP: #349048 [Add a callout editing tool for quick annotations] -- LP: #482791 [Text Tool should allow me to edit the text immediately] -- LP: #486680 [Shapes can't be moved with keyboard] -- LP: #493308 [Should be able to move around the original image] -- LP: #511919 [Add an svg export to DrawingTool] -- LP: #519869 [Line width not changes, in Shutter editor, if I use "draw arrow" tool after "censor" tool] * Fixed bugs / minor improvements -- LP: #264623 [Add pdf export to File Menu] -- LP: #340762 [Send by email] -- LP: #412917 [Remember the path to last opened folder in "Save as" dialog] -- LP: #500352 [Shutter closes down completely when attempting web capture] -- LP: #501969 [Ctrl N does nothing, even though it is listed in the File menu] -- LP: #509546 [Option to ask for a name and location before saving the screenshots to disk] -- LP: #510404 [Keybindings do not work correctly when optional command line parameters are used] -- LP: #511942 [Default directory for saved screenshots is /home instead of /home/login] -- LP: #512130 [Shutter doesn't start if $icontheme->load_icon fails] -- LP: #513616 [File mask %T non compatible and $name] -- LP: #522508 [Several problems with comma as decimal separator] -- LP: #533764 [I'd like an option "Copy nothing to clipboard"] -- LP: #543052 [Close buttons are right-aligned instead of left on tabs] -- LP: #543063 [Layout overlap on bottom] * updated translations -- Mario Kemper Fri, 26 Mar 2010 00:21:52 +0100 shutter (0.85.1) * Fixed bugs -- LP: #471895 [Unable to set Shutter as default screenshot tool when using compiz] -- LP: #488845 [check gtk version before calling gtk-image-menu-...] -- LP: #488895 [capture menu / tooltip doesn't work with gtk2-perl 1.161] -- LP: #488897 [duplicate file after capturing a webpage and using $name in th...] -- LP: #486322 [copy filename / copy screenshot to clipboard should be xor] -- LP: #486659 [Pressing Enter in the image editor doesn't save image] -- LP: #486691 [copy and copy filename do not work in session tab] -- LP: #488702 [can't shot localhost web] * updated translations -- Mario Kemper Tue, 01 Dec 2009 20:26:49 +0100 shutter (0.85) * New features -- Undo/Redo functionality -- Drag and drop pics into Shutter -- Functionality to capture menus -- Functionality to capture tooltips -- Improved Advanced Selection Tool -- Improved Window Selection -- Improved right-click menu in preview tab -- Many UI improvements -- Change backgound color in Drawing Tool -- New multi-purpose wildcard $name -- Import images from clipboard -- Use system's notification system -- Send screenshots via email or instant messenger -- Autocopy filename to clipboard -- Shutter registers itself as an app to open images with * Screenshot Tools -- LP: #371550 [Advanced selection tool: Specify pixel values of selection area] -- LP: #392002 [Add gnome-web-photo's --width parameter to the webphoto settings] -- LP: #412466 [gnome-web-photo "Unknown option -q"] -- LP: #454266 [Cursor does not display] -- LP: #457218 [Combine the advanced and the simple selection tool into one tool] * Drawing Tool -- LP: #311582 [Make the properties dialog function as "instant apply"] -- LP: #394367 [change and mark hot spot of mouse pointer icons] -- LP: #396431 [Properties of the marker tool aren't updated instantly] -- LP: #403469 [DrawingTool: Add an option to change the background color when...] -- LP: #466067 [no icos in the 'Screenshot-Edit-Insert image' menu] * User Interface -- LP: #279271 [Allow easy profile switching] -- LP: #338800 [Drag and drop pics into shutter] -- LP: #342643 [Provide easier access to actions in the preview tab] -- LP: #344828 [Remove MIME type info from general window] -- LP: #365373 [screenshot info should be summarized] * Fixed bugs / minor improvements -- LP: #328663 [Give the screenshot title of window when capturing window only] -- LP: #338796 [Shutter should register itself as an app to open pictures with] -- LP: #339728 [Need an 'undo' for image editing and plugin operations] -- LP: #339924 [Rename strings] -- LP: #340762 [Send by email] -- LP: #345382 [add indicator for running countdown] -- LP: #350660 [Add an option to keep the shutter window hidden after a capture] -- LP: #415917 [Capture menus more easily] -- LP: #421832 [Import image from clipboard] -- LP: #426348 [JPG is a default format] -- LP: #428661 [X crashes if no instance of Shutter is running while capture s...] -- LP: #436504 [Screenshot looks fuzzy after printing] -- LP: #440526 [Files remain in folder even if put in trash] -- LP: #453210 [Shutter signals in Multi User Env] -- LP: #457209 [Add a 'delete-on-tab-close' option to the preferences] -- LP: #457211 [Add an option for a delete prompt to preferences] * updated translations -- Mario Kemper Sat, 21 Nov 2009 15:01:45 +0100 shutter (0.80.1) * Fixed bugs -- LP: #363708 [small lines at the edge of small screenshots] -- LP: #388532 [Respect stacking order of windows when selecting] -- LP: #396795 [Jigsaw plugins are broken] -- LP: #396797 [gnome-web-photo errors not properly handled in all cases] -- LP: #397873 [check permissions when saving to directory] -- LP: #397875 [Don't install anything to /usr/share/app-install] -- LP: #404860 [Paths with whitespaces in them aren't properly treated] -- LP: #406017 [settings could not be restored] * DrawingTool: new cursors * DrawingTool: improved 'insert image' functionality * updated translations -- Mario Kemper Thu, 06 Aug 2009 22:43:41 +0200 shutter (0.80) * New features -- Undo/Redo functionality in Drawing Tool -- Added arrow shape to Drawing Tool -- Added highlighter/marker to Drawing Tool -- Added numbered tags to Drawing Tool -- Added crop tool to Drawing Tool -- Functionality to resize the canvas -- Zoomable image preview -- New 'Copy filename' action -- Added access to 'Recent files' -- New watermark plugin -- New reflection plugin -- New distortion plugin -- New 3D rotate plugin * Drawing Tool -- LP: #310704 [object property changes should take immediate effect] -- LP: #311578 [resize canvas] -- LP: #312405 [added numbered tags] -- LP: #312965 [Drawing tool should have an Undo feature] -- LP: #318452 [save and restore last used tool] -- LP: #322811 [Add crop tool to drawing tool] -- LP: #338809 [keep tool focus after one usage] -- LP: #360254 [added highlighter/marker] -- LP: #364815 [added arrow shape] -- LP: #380790 [Fullscreen mode] * User Interface -- Show screenshot menu on right-button click in each tab -- Show default application in separate menu item -- Show progress dialog when updating plugin information -- LP: #338528 [use icon theme and toolbar style wherever it is possible] * Plugins -- LP: #264622 [new watermark plugin] -- LP: #342034 [new reflection plugin] -- LP: #374192 [new distortion plugin] -- LP: #375069 [new 3D rotate plugin] * Fixed bugs / minor improvements -- Use File::HomeDir instead of $ENV{ 'HOME' } -- Use xdg-open instead of gnome-open -- LP: #312221 [Item is drawn in bottom-right point of the cursor] -- LP: #336122 [Ctrl+resize in editor moves the shape] -- LP: #338812 [Better timeout options] -- LP: #340503 [Show item properties on double-click] -- LP: #341458 [Allow zooming in editor via ctrl+scrollwheel] -- LP: #348595 [keybindings don't work in ubuntu jaunty when using compiz] -- LP: #353819 [check window border option when calculating shape] -- LP: #353824 [fix advanced selection tool when using compiz] -- LP: #353830 [do not capture the zoom window when using the simple selection] -- LP: #356324 [Stutter doesn't remember preference for screenshot location] -- LP: #362508 [File - Open with gets broken sometimes] -- LP: #363708 [lines of selected area get captured sometimes] -- LP: #340635 [Preview in plugin dialogs takes too long] -- LP: #364165 [dialogs should set the window title] -- LP: #365365 [polaroid plugin text doesn't allow apostrophes] -- LP: #366695 [control advanced selection tool with arrow keys] -- LP: #367513 [desktop entry contains deprecated encoding key] -- LP: #370359 [Watermark plugin doesn't say the allowed syntax] -- LP: #370367 [DrawingTool -> View has multiple same options] -- LP: #384352 [Save settings to file when closing preferences dialog] -- LP: #386304 [Rename Edit -> Quick select to Quick profile select] -- LP: #386316 ['Delete objects' and 'Delete all objects' are too similar] -- LP: #386318 [New highlighter icon] -- LP: #386766 [Text of '3D rotate' plugin is malformated] -- LP: #386769 [quick profile selector is even sensitive when empty] -- LP: #389837 [Invalid chars in japanese translation] -- LP: #390853 [Workaround for upstream bug http://trac.bjourne.webfactional.com/ticket/21] -- LP: #394283 [query new libgoocanvas properties and methods] * code cleanup * updated translations -- Mario Kemper Sun, 05 Jul 2009 14:39:53 +0200 shutter (0.70.2) * fixed bugs -- LP: #339139 [Shutter selects incorrect target window] -- LP: #340855 + LP: #340864 [fixed save-as function] -- LP: #340856 [main window is partly visible on screenshots] -- LP: #340990 [Shutter crashes when xserver grab fails] -- LP: #341459 [Ctrl+ + doesn't zoom in drawing area] -- LP: #347821 [decode filesize properly] * updated translations -- Mario Kemper Tue, 24 Mar 2009 21:41:37 +0100 shutter (0.70.1) * fixed bugs -- LP: #260771 [Detect 'window-manager-changed' event] -- LP: #328654 [Weird paths after uploading] -- LP: #338829 [Uploading to imageshack is broken] -- LP: #338990 [Open with dialog freezes shutter and desktop] -- LP: #340253 [Capture Website creates two files] -- LP: #340459 [Use fallback icons if icon does not exist] * updated translations -- Mario Kemper Tue, 10 Mar 2009 23:06:25 +0100 shutter (0.701) * General changes -- Rebranding from GScrot to Shutter -- Exports to and opens all file formats supported by gdk-pixbuf -- Added native printing support (instead of gtklp) -- Watch opened files via GnomeVFS File Monitor to monitor changes -- Integration of GNOME Virtual File System and GNOME authentication manager (LP: #310780) -- Respect non-rectangular windows (XSHAPE) when using metacity (LP: #260771) -- Use themeable icons wherever its is possible -- Use systemwide MIME Information instead of config file -- Move screenshots to trash instead of deleting them (LP: #313003) -- Faster thumbail creation and caching (improves gui startup when a lot of files are in last session) -- Improved Dialogs (e.g. Settings Dialog) -- Show context menu for each file in session tab (right click) * Gui improvements Show current profile in statusbar (LP: #279271) Second toolbar removed (LP: #311626) Progress bars (LP: #310299) -- LP: #311627 -- LP: #312966 -- LP: #313346 -- LP: #326758 * Drawing Tool Scale uniformly (LP: #310708) Added standard actions (copy, cut, paste, delete) (LP: #313343) Added censor tool to hide private data (LP: #317659) -- LP: #310717 -- LP: #310721 -- LP: #311574 -- LP: #311576 -- LP: #311577 -- LP: #311580 * Miscellaneous Shutter shows up in GNOME add/remove (LP: #322388) Repository is not signed (thanks to the LP Team) (LP: #312681) * Plugins New hard shadow plugin (thanks to Tualatrix) (LP: #331914) * Fixed bugs -- LP: #303090 -- LP: #313761 -- LP: #316917 -- LP: #336120 -- LP: #336126 -- LP: #336121 -- LP: #336118 -- LP: #336133 -- LP: #336124 * updated translations -- Mario Kemper Thu, 05 Mar 2009 12:23:51 +0100 gscrot (0.642) * fixed bugs -- LP: #313351 -- LP: #318226 -- LP: #318227 -- LP: #313351 * updated translations -- Mario Kemper Sun, 18 Jan 2009 15:10:27 +0100 gscrot (0.640) * fixed bugs -- LP: #312866 -- LP: #313005 * updated translations -- Mario Kemper Fri, 02 Jan 2009 14:33:27 +0100 gscrot (0.64) * new goo-canvas based drawing tool (LP: #264617, LP: #278999, LP: #279001) * added ftp-upload (LP: #291286) * improved startup time (LP: #296341) * improved advanced selection tool (LP: #311185) * improved plugin interface and error handling (LP: #296091) * fixed bugs/smaller feature requests -- LP: #306420 -- LP: #264616 -- LP: #277040 -- LP: #279271 -- LP: #280161 -- LP: #291284 -- LP: #310871 * new plugin: torned-paper (Edwood Ocasio) * updated translations * massive code cleanup -- Mario Kemper Tue, 30 Dec 2008 09:48:36 +0100 gscrot (0.63) * added new "advanced" selection-tool (see LP: #273763, depends on Gtk2::ImageView) * added new keybinding-mode option * ported to Gtk2::StatusIcon (Gtk2::TrayIcon supported for older Gtk2 Versions) * faster plugin checks * minor changes (human interface guidelines) * fixed (LP: #286632, LP: #293091, LP: #291753, LP: #293616) * updated translations * code cleanup -- Mario Kemper Thu, 06 Nov 2008 13:45:57 +0100 gscrot (0.62) * display session information on startup (see LP: #277121) * minor changes related to upload dialog (see LP: #280154 and LP: #280165) * new file->save as and file->close menu entries (see LP: #280155 and LP: #280886) * new command line parameters (see LP: #280868 and LP: #281793) * deleted hard dependencies of gnome-web-photo and gtklp in source code for more flexibility (e.g. packaging) * updated translations -- Mario Kemper Wed, 22 Oct 2008 15:10:33 +0200 gscrot (0.61) * added new feature "include cursor" (default cursor) * added imageshack.us as hosting-partner * save and restore session automatically (restore tabs/screenshots) * improved plugin-dialog and upload-dialog * redesigned polaroid plugin * fixed wrong utf8-encoding in profile names * fixed wrong utf8-encoding in about dialog * improved auto incrementing of filenames (see LP: #275352) * improved thumbs (session tab) * updated translations -- Mario Kemper Mon, 06 Oct 2008 22:47:58 +0200 gscrot (0.60) * added new feature "grab window-section" * added settings-profiles * added new plugin interface * added new plugins -- pdf-export -- negate -- sepia (perl) -- resize * gui redesign -- scaling of main window -- auto-scaling of preview -- new toolbar -- new menu entries -- settings moved to menu * updated translations -- Mario Kemper Wed, 24 Sep 2008 22:00:18 +0200 gscrot (0.51.1) * minor changes * added/updated translations * fixed bugs -- 264637 -- Mario Kemper Fri, 05 Sep 2008 18:29:35 +0200 gscrot (0.51) * new features -- capture window by name -- select specific workspace to capture * minor changes -- several performance improvements -- some options added * added/updated translations -- Danish -- Dutch -- French -- German -- Italian -- Korean -- Norwegian Bokmal -- Polish -- Russian -- Serbian -- Simplified Chinese -- Spanish -- Swedish -- Traditional Chinese -- Ukrainian * fixed bugs -- 262165 -- 262206 -- 262207 -- 262263 -- Mario Kemper Mon, 01 Sep 2008 03:25:16 +0200 gscrot (0.50.1) * minor changes -- partly rewritten window-selection -- changed .po/.mo naming of plugins -- added new svg icon * added/updated translations -- Brazilian Portuguese -- Catalan -- Spanish -- Italian -- Polish -- Russian -- Swedish -- Traditional Chinese -- Ukrainian * fixed bugs -- 260146 -- 260142 -- 260736 -- Mario Kemper Tue, 26 Aug 2008 00:13:09 +0200 gscrot (0.50) * implemented new backend (gscrot does not depend on scrot anymore) * zoom for free-hand screenshot * gui changes -- added a detachable toolbar (buttons are replaced) * added translations -- spanish -- catalan -- Mario Kemper Tue, 19 Aug 2008 22:00:58 +0200 gscrot (0.405) * fixed bug https://bugs.launchpad.net/gscrot/+bug/252549 -- Mario Kemper Mon, 28 Jul 2008 16:42:19 +0200 gscrot (0.404) * gui changes (added expanders) * session collection -- added file infos -- added thumbnails * save settings automatically when exiting * added url-column to accounts treeview * included gscrot-plugins-bash in base-package -- Mario Kemper Fri, 25 Jul 2008 21:07:44 +0200 gscrot (0.39) * drawing-tool -- it's a canvas now ;-) -- zoom-factor and width of brush configurable -- fixed drawing glitches due to fast mouse movement * added new wildcard (%NN = counter) * added keybindings (using gconf, configurable via gui) * added libgnome2-perl and libgnome2-gconf-perl to dependencies -- Mario Kemper Fri, 11 Jul 2008 00:57:11 +0200 gscrot (0.385) * added simple drawing tool * added plugin-interface and gui structure * added support for image-hoster imagebanana.com * added support for upload-accounts (ubuntu-pics.de && imagebanana.com) -- gui structure and accounts.xml * internal changes -- upload-functionality swapped out to perl-modules -- changed settings-format to xml -- Mario Kemper Thu, 03 Jul 2008 19:39:35 +0200 gscrot (0.370) * added functionality to capture websites using gnome-web-photo * added upload functionality to ubuntu-pics.de --upload a file and automatically retrieve all links generated by ubuntu-pics.de * moved configuration to /home//.gscrot/settings.conf * modified program-selector --switched simple entry to combobox with tree-model --predefined or custom programs/scripts --overwrite settings individually by setting up /home//.gscrot/programs.conf * added custom icon-set * smaller changes --solved deprecation warning in about-dialog --fixed wrong time format in debian/changelog --added all new dependencies to debian/control * added russian translation files -- Mario Kemper Mon, 19 May 2008 12:49:27 +0200 gscrot (0.36.2) * unset "reduce colors" by default -- Mario Kemper Thu, 08 May 2008 22:43:38 +0200 gscrot (0.36) * added functionalities to "session collection" --remove screenshots from session (but do not delete them) --reopen screenshot with specified program --rename screenshot * new arrangement of settings area * new feature -- reduce colors -- * added dependency perlmagick -- Mario Kemper Wed, 07 May 2008 19:55:10 +0200 gscrot (0.35) * added feature "session collection" --keep track of all screenshots during session --copy screeners to clipboard --print screenshots --delete screenshots * added command line args --min_at_startup - starts gscrot minimized to tray --beeper_off - turns audible feedback off --debug - prints a lot of debugging information to STDOUT --help - displays this help * start of localization using gettext --english is now default language --german translation added * fixed typo in info_message * changed hbox/vbox arrangement -- Mario Kemper Thu, 17 Apr 2008 13:17:37 +0200 gscrot (0.34) * new features * added keybindings in menubar * added save and revert settings * reimplemented message dialogs * added support for grabbing window border when not using compiz or beryl * added debian folder to source directory * load settings automatically at startup * added statusbar to main window -- Mario Kemper Thu, 10 Apr 2008 21:00:10 +0200 gscrot (0.33) * added homepage to about box -- Mario Kemper Wed, 09 Apr 2008 13:19:30 +0200 gscrot (0.33) * initial release -- Mario Kemper Wed, 09 Apr 2008 12:50:28 +0200 shutter-0.90.1/COPYING0000644000175000017500000010437412206477313013350 0ustar mariomario GNU GENERAL PUBLIC LICENSE Version 3, 29 June 2007 Copyright (C) 2007 Free Software Foundation, Inc. Everyone is permitted to copy and distribute verbatim copies of this license document, but changing it is not allowed. Preamble The GNU General Public License is a free, copyleft license for software and other kinds of works. The licenses for most software and other practical works are designed to take away your freedom to share and change the works. By contrast, the GNU General Public License is intended to guarantee your freedom to share and change all versions of a program--to make sure it remains free software for all its users. We, the Free Software Foundation, use the GNU General Public License for most of our software; it applies also to any other work released this way by its authors. You can apply it to your programs, too. When we speak of free software, we are referring to freedom, not price. Our General Public Licenses are designed to make sure that you have the freedom to distribute copies of free software (and charge for them if you wish), that you receive source code or can get it if you want it, that you can change the software or use pieces of it in new free programs, and that you know you can do these things. To protect your rights, we need to prevent others from denying you these rights or asking you to surrender the rights. Therefore, you have certain responsibilities if you distribute copies of the software, or if you modify it: responsibilities to respect the freedom of others. For example, if you distribute copies of such a program, whether gratis or for a fee, you must pass on to the recipients the same freedoms that you received. You must make sure that they, too, receive or can get the source code. And you must show them these terms so they know their rights. Developers that use the GNU GPL protect your rights with two steps: (1) assert copyright on the software, and (2) offer you this License giving you legal permission to copy, distribute and/or modify it. For the developers' and authors' protection, the GPL clearly explains that there is no warranty for this free software. For both users' and authors' sake, the GPL requires that modified versions be marked as changed, so that their problems will not be attributed erroneously to authors of previous versions. Some devices are designed to deny users access to install or run modified versions of the software inside them, although the manufacturer can do so. This is fundamentally incompatible with the aim of protecting users' freedom to change the software. The systematic pattern of such abuse occurs in the area of products for individuals to use, which is precisely where it is most unacceptable. Therefore, we have designed this version of the GPL to prohibit the practice for those products. If such problems arise substantially in other domains, we stand ready to extend this provision to those domains in future versions of the GPL, as needed to protect the freedom of users. Finally, every program is threatened constantly by software patents. States should not allow patents to restrict development and use of software on general-purpose computers, but in those that do, we wish to avoid the special danger that patents applied to a free program could make it effectively proprietary. To prevent this, the GPL assures that patents cannot be used to render the program non-free. The precise terms and conditions for copying, distribution and modification follow. TERMS AND CONDITIONS 0. Definitions. "This License" refers to version 3 of the GNU General Public License. "Copyright" also means copyright-like laws that apply to other kinds of works, such as semiconductor masks. "The Program" refers to any copyrightable work licensed under this License. Each licensee is addressed as "you". "Licensees" and "recipients" may be individuals or organizations. To "modify" a work means to copy from or adapt all or part of the work in a fashion requiring copyright permission, other than the making of an exact copy. The resulting work is called a "modified version" of the earlier work or a work "based on" the earlier work. A "covered work" means either the unmodified Program or a work based on the Program. To "propagate" a work means to do anything with it that, without permission, would make you directly or secondarily liable for infringement under applicable copyright law, except executing it on a computer or modifying a private copy. Propagation includes copying, distribution (with or without modification), making available to the public, and in some countries other activities as well. To "convey" a work means any kind of propagation that enables other parties to make or receive copies. Mere interaction with a user through a computer network, with no transfer of a copy, is not conveying. An interactive user interface displays "Appropriate Legal Notices" to the extent that it includes a convenient and prominently visible feature that (1) displays an appropriate copyright notice, and (2) tells the user that there is no warranty for the work (except to the extent that warranties are provided), that licensees may convey the work under this License, and how to view a copy of this License. If the interface presents a list of user commands or options, such as a menu, a prominent item in the list meets this criterion. 1. Source Code. The "source code" for a work means the preferred form of the work for making modifications to it. "Object code" means any non-source form of a work. A "Standard Interface" means an interface that either is an official standard defined by a recognized standards body, or, in the case of interfaces specified for a particular programming language, one that is widely used among developers working in that language. The "System Libraries" of an executable work include anything, other than the work as a whole, that (a) is included in the normal form of packaging a Major Component, but which is not part of that Major Component, and (b) serves only to enable use of the work with that Major Component, or to implement a Standard Interface for which an implementation is available to the public in source code form. A "Major Component", in this context, means a major essential component (kernel, window system, and so on) of the specific operating system (if any) on which the executable work runs, or a compiler used to produce the work, or an object code interpreter used to run it. The "Corresponding Source" for a work in object code form means all the source code needed to generate, install, and (for an executable work) run the object code and to modify the work, including scripts to control those activities. However, it does not include the work's System Libraries, or general-purpose tools or generally available free programs which are used unmodified in performing those activities but which are not part of the work. For example, Corresponding Source includes interface definition files associated with source files for the work, and the source code for shared libraries and dynamically linked subprograms that the work is specifically designed to require, such as by intimate data communication or control flow between those subprograms and other parts of the work. The Corresponding Source need not include anything that users can regenerate automatically from other parts of the Corresponding Source. The Corresponding Source for a work in source code form is that same work. 2. Basic Permissions. All rights granted under this License are granted for the term of copyright on the Program, and are irrevocable provided the stated conditions are met. This License explicitly affirms your unlimited permission to run the unmodified Program. The output from running a covered work is covered by this License only if the output, given its content, constitutes a covered work. This License acknowledges your rights of fair use or other equivalent, as provided by copyright law. You may make, run and propagate covered works that you do not convey, without conditions so long as your license otherwise remains in force. You may convey covered works to others for the sole purpose of having them make modifications exclusively for you, or provide you with facilities for running those works, provided that you comply with the terms of this License in conveying all material for which you do not control copyright. Those thus making or running the covered works for you must do so exclusively on your behalf, under your direction and control, on terms that prohibit them from making any copies of your copyrighted material outside their relationship with you. Conveying under any other circumstances is permitted solely under the conditions stated below. Sublicensing is not allowed; section 10 makes it unnecessary. 3. Protecting Users' Legal Rights From Anti-Circumvention Law. No covered work shall be deemed part of an effective technological measure under any applicable law fulfilling obligations under article 11 of the WIPO copyright treaty adopted on 20 December 1996, or similar laws prohibiting or restricting circumvention of such measures. When you convey a covered work, you waive any legal power to forbid circumvention of technological measures to the extent such circumvention is effected by exercising rights under this License with respect to the covered work, and you disclaim any intention to limit operation or modification of the work as a means of enforcing, against the work's users, your or third parties' legal rights to forbid circumvention of technological measures. 4. Conveying Verbatim Copies. You may convey verbatim copies of the Program's source code as you receive it, in any medium, provided that you conspicuously and appropriately publish on each copy an appropriate copyright notice; keep intact all notices stating that this License and any non-permissive terms added in accord with section 7 apply to the code; keep intact all notices of the absence of any warranty; and give all recipients a copy of this License along with the Program. You may charge any price or no price for each copy that you convey, and you may offer support or warranty protection for a fee. 5. Conveying Modified Source Versions. You may convey a work based on the Program, or the modifications to produce it from the Program, in the form of source code under the terms of section 4, provided that you also meet all of these conditions: a) The work must carry prominent notices stating that you modified it, and giving a relevant date. b) The work must carry prominent notices stating that it is released under this License and any conditions added under section 7. This requirement modifies the requirement in section 4 to "keep intact all notices". c) You must license the entire work, as a whole, under this License to anyone who comes into possession of a copy. This License will therefore apply, along with any applicable section 7 additional terms, to the whole of the work, and all its parts, regardless of how they are packaged. This License gives no permission to license the work in any other way, but it does not invalidate such permission if you have separately received it. d) If the work has interactive user interfaces, each must display Appropriate Legal Notices; however, if the Program has interactive interfaces that do not display Appropriate Legal Notices, your work need not make them do so. A compilation of a covered work with other separate and independent works, which are not by their nature extensions of the covered work, and which are not combined with it such as to form a larger program, in or on a volume of a storage or distribution medium, is called an "aggregate" if the compilation and its resulting copyright are not used to limit the access or legal rights of the compilation's users beyond what the individual works permit. Inclusion of a covered work in an aggregate does not cause this License to apply to the other parts of the aggregate. 6. Conveying Non-Source Forms. You may convey a covered work in object code form under the terms of sections 4 and 5, provided that you also convey the machine-readable Corresponding Source under the terms of this License, in one of these ways: a) Convey the object code in, or embodied in, a physical product (including a physical distribution medium), accompanied by the Corresponding Source fixed on a durable physical medium customarily used for software interchange. b) Convey the object code in, or embodied in, a physical product (including a physical distribution medium), accompanied by a written offer, valid for at least three years and valid for as long as you offer spare parts or customer support for that product model, to give anyone who possesses the object code either (1) a copy of the Corresponding Source for all the software in the product that is covered by this License, on a durable physical medium customarily used for software interchange, for a price no more than your reasonable cost of physically performing this conveying of source, or (2) access to copy the Corresponding Source from a network server at no charge. c) Convey individual copies of the object code with a copy of the written offer to provide the Corresponding Source. This alternative is allowed only occasionally and noncommercially, and only if you received the object code with such an offer, in accord with subsection 6b. d) Convey the object code by offering access from a designated place (gratis or for a charge), and offer equivalent access to the Corresponding Source in the same way through the same place at no further charge. You need not require recipients to copy the Corresponding Source along with the object code. If the place to copy the object code is a network server, the Corresponding Source may be on a different server (operated by you or a third party) that supports equivalent copying facilities, provided you maintain clear directions next to the object code saying where to find the Corresponding Source. Regardless of what server hosts the Corresponding Source, you remain obligated to ensure that it is available for as long as needed to satisfy these requirements. e) Convey the object code using peer-to-peer transmission, provided you inform other peers where the object code and Corresponding Source of the work are being offered to the general public at no charge under subsection 6d. A separable portion of the object code, whose source code is excluded from the Corresponding Source as a System Library, need not be included in conveying the object code work. A "User Product" is either (1) a "consumer product", which means any tangible personal property which is normally used for personal, family, or household purposes, or (2) anything designed or sold for incorporation into a dwelling. In determining whether a product is a consumer product, doubtful cases shall be resolved in favor of coverage. For a particular product received by a particular user, "normally used" refers to a typical or common use of that class of product, regardless of the status of the particular user or of the way in which the particular user actually uses, or expects or is expected to use, the product. A product is a consumer product regardless of whether the product has substantial commercial, industrial or non-consumer uses, unless such uses represent the only significant mode of use of the product. "Installation Information" for a User Product means any methods, procedures, authorization keys, or other information required to install and execute modified versions of a covered work in that User Product from a modified version of its Corresponding Source. The information must suffice to ensure that the continued functioning of the modified object code is in no case prevented or interfered with solely because modification has been made. If you convey an object code work under this section in, or with, or specifically for use in, a User Product, and the conveying occurs as part of a transaction in which the right of possession and use of the User Product is transferred to the recipient in perpetuity or for a fixed term (regardless of how the transaction is characterized), the Corresponding Source conveyed under this section must be accompanied by the Installation Information. But this requirement does not apply if neither you nor any third party retains the ability to install modified object code on the User Product (for example, the work has been installed in ROM). The requirement to provide Installation Information does not include a requirement to continue to provide support service, warranty, or updates for a work that has been modified or installed by the recipient, or for the User Product in which it has been modified or installed. Access to a network may be denied when the modification itself materially and adversely affects the operation of the network or violates the rules and protocols for communication across the network. Corresponding Source conveyed, and Installation Information provided, in accord with this section must be in a format that is publicly documented (and with an implementation available to the public in source code form), and must require no special password or key for unpacking, reading or copying. 7. Additional Terms. "Additional permissions" are terms that supplement the terms of this License by making exceptions from one or more of its conditions. Additional permissions that are applicable to the entire Program shall be treated as though they were included in this License, to the extent that they are valid under applicable law. If additional permissions apply only to part of the Program, that part may be used separately under those permissions, but the entire Program remains governed by this License without regard to the additional permissions. When you convey a copy of a covered work, you may at your option remove any additional permissions from that copy, or from any part of it. (Additional permissions may be written to require their own removal in certain cases when you modify the work.) You may place additional permissions on material, added by you to a covered work, for which you have or can give appropriate copyright permission. Notwithstanding any other provision of this License, for material you add to a covered work, you may (if authorized by the copyright holders of that material) supplement the terms of this License with terms: a) Disclaiming warranty or limiting liability differently from the terms of sections 15 and 16 of this License; or b) Requiring preservation of specified reasonable legal notices or author attributions in that material or in the Appropriate Legal Notices displayed by works containing it; or c) Prohibiting misrepresentation of the origin of that material, or requiring that modified versions of such material be marked in reasonable ways as different from the original version; or d) Limiting the use for publicity purposes of names of licensors or authors of the material; or e) Declining to grant rights under trademark law for use of some trade names, trademarks, or service marks; or f) Requiring indemnification of licensors and authors of that material by anyone who conveys the material (or modified versions of it) with contractual assumptions of liability to the recipient, for any liability that these contractual assumptions directly impose on those licensors and authors. All other non-permissive additional terms are considered "further restrictions" within the meaning of section 10. If the Program as you received it, or any part of it, contains a notice stating that it is governed by this License along with a term that is a further restriction, you may remove that term. If a license document contains a further restriction but permits relicensing or conveying under this License, you may add to a covered work material governed by the terms of that license document, provided that the further restriction does not survive such relicensing or conveying. If you add terms to a covered work in accord with this section, you must place, in the relevant source files, a statement of the additional terms that apply to those files, or a notice indicating where to find the applicable terms. Additional terms, permissive or non-permissive, may be stated in the form of a separately written license, or stated as exceptions; the above requirements apply either way. 8. Termination. You may not propagate or modify a covered work except as expressly provided under this License. Any attempt otherwise to propagate or modify it is void, and will automatically terminate your rights under this License (including any patent licenses granted under the third paragraph of section 11). However, if you cease all violation of this License, then your license from a particular copyright holder is reinstated (a) provisionally, unless and until the copyright holder explicitly and finally terminates your license, and (b) permanently, if the copyright holder fails to notify you of the violation by some reasonable means prior to 60 days after the cessation. Moreover, your license from a particular copyright holder is reinstated permanently if the copyright holder notifies you of the violation by some reasonable means, this is the first time you have received notice of violation of this License (for any work) from that copyright holder, and you cure the violation prior to 30 days after your receipt of the notice. Termination of your rights under this section does not terminate the licenses of parties who have received copies or rights from you under this License. If your rights have been terminated and not permanently reinstated, you do not qualify to receive new licenses for the same material under section 10. 9. Acceptance Not Required for Having Copies. You are not required to accept this License in order to receive or run a copy of the Program. Ancillary propagation of a covered work occurring solely as a consequence of using peer-to-peer transmission to receive a copy likewise does not require acceptance. However, nothing other than this License grants you permission to propagate or modify any covered work. These actions infringe copyright if you do not accept this License. Therefore, by modifying or propagating a covered work, you indicate your acceptance of this License to do so. 10. Automatic Licensing of Downstream Recipients. Each time you convey a covered work, the recipient automatically receives a license from the original licensors, to run, modify and propagate that work, subject to this License. You are not responsible for enforcing compliance by third parties with this License. An "entity transaction" is a transaction transferring control of an organization, or substantially all assets of one, or subdividing an organization, or merging organizations. If propagation of a covered work results from an entity transaction, each party to that transaction who receives a copy of the work also receives whatever licenses to the work the party's predecessor in interest had or could give under the previous paragraph, plus a right to possession of the Corresponding Source of the work from the predecessor in interest, if the predecessor has it or can get it with reasonable efforts. You may not impose any further restrictions on the exercise of the rights granted or affirmed under this License. For example, you may not impose a license fee, royalty, or other charge for exercise of rights granted under this License, and you may not initiate litigation (including a cross-claim or counterclaim in a lawsuit) alleging that any patent claim is infringed by making, using, selling, offering for sale, or importing the Program or any portion of it. 11. Patents. A "contributor" is a copyright holder who authorizes use under this License of the Program or a work on which the Program is based. The work thus licensed is called the contributor's "contributor version". A contributor's "essential patent claims" are all patent claims owned or controlled by the contributor, whether already acquired or hereafter acquired, that would be infringed by some manner, permitted by this License, of making, using, or selling its contributor version, but do not include claims that would be infringed only as a consequence of further modification of the contributor version. For purposes of this definition, "control" includes the right to grant patent sublicenses in a manner consistent with the requirements of this License. Each contributor grants you a non-exclusive, worldwide, royalty-free patent license under the contributor's essential patent claims, to make, use, sell, offer for sale, import and otherwise run, modify and propagate the contents of its contributor version. In the following three paragraphs, a "patent license" is any express agreement or commitment, however denominated, not to enforce a patent (such as an express permission to practice a patent or covenant not to sue for patent infringement). To "grant" such a patent license to a party means to make such an agreement or commitment not to enforce a patent against the party. If you convey a covered work, knowingly relying on a patent license, and the Corresponding Source of the work is not available for anyone to copy, free of charge and under the terms of this License, through a publicly available network server or other readily accessible means, then you must either (1) cause the Corresponding Source to be so available, or (2) arrange to deprive yourself of the benefit of the patent license for this particular work, or (3) arrange, in a manner consistent with the requirements of this License, to extend the patent license to downstream recipients. "Knowingly relying" means you have actual knowledge that, but for the patent license, your conveying the covered work in a country, or your recipient's use of the covered work in a country, would infringe one or more identifiable patents in that country that you have reason to believe are valid. If, pursuant to or in connection with a single transaction or arrangement, you convey, or propagate by procuring conveyance of, a covered work, and grant a patent license to some of the parties receiving the covered work authorizing them to use, propagate, modify or convey a specific copy of the covered work, then the patent license you grant is automatically extended to all recipients of the covered work and works based on it. A patent license is "discriminatory" if it does not include within the scope of its coverage, prohibits the exercise of, or is conditioned on the non-exercise of one or more of the rights that are specifically granted under this License. You may not convey a covered work if you are a party to an arrangement with a third party that is in the business of distributing software, under which you make payment to the third party based on the extent of your activity of conveying the work, and under which the third party grants, to any of the parties who would receive the covered work from you, a discriminatory patent license (a) in connection with copies of the covered work conveyed by you (or copies made from those copies), or (b) primarily for and in connection with specific products or compilations that contain the covered work, unless you entered into that arrangement, or that patent license was granted, prior to 28 March 2007. Nothing in this License shall be construed as excluding or limiting any implied license or other defenses to infringement that may otherwise be available to you under applicable patent law. 12. No Surrender of Others' Freedom. If conditions are imposed on you (whether by court order, agreement or otherwise) that contradict the conditions of this License, they do not excuse you from the conditions of this License. If you cannot convey a covered work so as to satisfy simultaneously your obligations under this License and any other pertinent obligations, then as a consequence you may not convey it at all. For example, if you agree to terms that obligate you to collect a royalty for further conveying from those to whom you convey the Program, the only way you could satisfy both those terms and this License would be to refrain entirely from conveying the Program. 13. Use with the GNU Affero General Public License. Notwithstanding any other provision of this License, you have permission to link or combine any covered work with a work licensed under version 3 of the GNU Affero General Public License into a single combined work, and to convey the resulting work. The terms of this License will continue to apply to the part which is the covered work, but the special requirements of the GNU Affero General Public License, section 13, concerning interaction through a network will apply to the combination as such. 14. Revised Versions of this License. The Free Software Foundation may publish revised and/or new versions of the GNU General Public License from time to time. Such new versions will be similar in spirit to the present version, but may differ in detail to address new problems or concerns. Each version is given a distinguishing version number. If the Program specifies that a certain numbered version of the GNU General Public License "or any later version" applies to it, you have the option of following the terms and conditions either of that numbered version or of any later version published by the Free Software Foundation. If the Program does not specify a version number of the GNU General Public License, you may choose any version ever published by the Free Software Foundation. If the Program specifies that a proxy can decide which future versions of the GNU General Public License can be used, that proxy's public statement of acceptance of a version permanently authorizes you to choose that version for the Program. Later license versions may give you additional or different permissions. However, no additional obligations are imposed on any author or copyright holder as a result of your choosing to follow a later version. 15. Disclaimer of Warranty. THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING, REPAIR OR CORRECTION. 16. Limitation of Liability. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES. 17. Interpretation of Sections 15 and 16. If the disclaimer of warranty and limitation of liability provided above cannot be given local legal effect according to their terms, reviewing courts shall apply local law that most closely approximates an absolute waiver of all civil liability in connection with the Program, unless a warranty or assumption of liability accompanies a copy of the Program in return for a fee. END OF TERMS AND CONDITIONS How to Apply These Terms to Your New Programs If you develop a new program, and you want it to be of the greatest possible use to the public, the best way to achieve this is to make it free software which everyone can redistribute and change under these terms. To do so, attach the following notices to the program. It is safest to attach them to the start of each source file to most effectively state the exclusion of warranty; and each file should have at least the "copyright" line and a pointer to where the full notice is found. Copyright (C) This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program. If not, see . Also add information on how to contact you by electronic and paper mail. If the program does terminal interaction, make it output a short notice like this when it starts in an interactive mode: Copyright (C) This program comes with ABSOLUTELY NO WARRANTY; for details type `show w'. This is free software, and you are welcome to redistribute it under certain conditions; type `show c' for details. The hypothetical commands `show w' and `show c' should show the appropriate parts of the General Public License. Of course, your program's commands might be different; for a GUI interface, you would use an "about box". You should also get your employer (if you work as a programmer) or school, if any, to sign a "copyright disclaimer" for the program, if necessary. For more information on this, and how to apply and follow the GNU GPL, see . The GNU General Public License does not permit incorporating your program into proprietary programs. If your program is a subroutine library, you may consider it more useful to permit linking proprietary applications with the library. If this is what you want to do, use the GNU Lesser General Public License instead of this License. But first, please read . shutter-0.90.1/share/0000755000175000017500000000000012206477312013405 5ustar mariomarioshutter-0.90.1/share/shutter/0000755000175000017500000000000012206477313015104 5ustar mariomarioshutter-0.90.1/share/shutter/update-notifier-shutter0000644000175000017500000000045112206477313021622 0ustar mariomarioName: GScrot is now Shutter Priority: High Terminal: False DontShowAfterReboot: True Description: GScrot has been renamed to Shutter! You can now use Application → Accessories → Shutter to start it. We also have a brand-new website available at http://shutter-project.org . Go check it out! shutter-0.90.1/share/shutter/resources/0000755000175000017500000000000012206477312017115 5ustar mariomarioshutter-0.90.1/share/shutter/resources/conf/0000755000175000017500000000000012206477313020043 5ustar mariomarioshutter-0.90.1/share/shutter/resources/conf/shape.conf0000644000175000017500000000043512206477313022014 0ustar mariomario#top rounded 5 0 width-10 1 3 1 width-6 1 2 2 width-4 1 1 3 width-2 2 0 5 width height-5 #top and bottom rounded #5 0 width-10 1 #3 1 width-6 1 #2 2 width-4 1 #1 3 width-2 2 #0 5 width height-10 #1 height-5 width-2 2 #2 height-3 width-4 1 #3 height-2 width-6 1 #5 height-1 width-10 1 shutter-0.90.1/share/shutter/resources/license/0000755000175000017500000000000012206477313020540 5ustar mariomarioshutter-0.90.1/share/shutter/resources/license/gplv3_hint0000644000175000017500000000011212206477313022532 0ustar mariomarioShutter - Featureful Screenshot Tool Copyright © 2008-2013 Mario Kemper shutter-0.90.1/share/shutter/resources/license/gplv30000644000175000017500000000113212206477313021513 0ustar mariomarioShutter is free software; you can redistribute it and/or modify it under the terms of the GNU General Public Licence as published by the Free Software Foundation; either version 3 of the Licence, or (at your option) any later version. Shutter is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program. If not, see . shutter-0.90.1/share/shutter/resources/icons/0000755000175000017500000000000012206477313020231 5ustar mariomarioshutter-0.90.1/share/shutter/resources/icons/fullscreen.svg0000644000175000017500000004162012206477313023117 0ustar mariomario image/svg+xml Jakub Steiner http://jimmac.musichall.cz View Fullscreen shutter-0.90.1/share/shutter/resources/icons/shutter_cursor_frame.png0000644000175000017500000000036712206477313025212 0ustar mariomario‰PNG  IHDR©¥–sRGB®ÎébKGDÿÿÿ ½§“ pHYs  šœtIMEÙ  1ë{à tEXtCommentCreated with GIMPWRIDAT8Ëí•1 À0ÃäÒÿïÝóOeI×&…:œÁÜ"´™ çP3%Yà’x°!%-éZ®7b· ÷‘½ªÊ´ÐV8À iÍ´¤–fÇêÝÑqKø IEND®B`‚shutter-0.90.1/share/shutter/resources/icons/Image.svg0000644000175000017500000003743512206477313022010 0ustar mariomario image/svg+xml Genric Image Jakub Steiner imagepicturesnapshotphoto shutter-0.90.1/share/shutter/resources/icons/web_image.svg0000644000175000017500000012525212206477313022700 0ustar mariomario image/svg+xml Globe Jakub Steiner Tuomas Kuosmanen http://jimmac.musichall.cz globe international web www internet network shutter-0.90.1/share/shutter/resources/icons/logo-imagebanana.png0000644000175000017500000002235612206477313024130 0ustar mariomario‰PNG  IHDRhUëéE pHYs.#.#x¥?vtIME× .¼ul IDATxÚíw¸\U¹ÿ?k—içÌœÞÓÒ $”@àB €H©"*ݨ€—.F¤ ¨\áŠ" Â… ^Š”Ò!`)'='§·i{vYë÷ÇÌ䔜œ„„ØßgžóœÙ³gï=«|×û~ßw­%”RøðáÃÇ` ùEàÇŸ8|øðá‡>|âðáÇO>|øð‰cË ÛžõVÿÎ/;>¾²0ýÔ|wÎé$\qÔx­üP¿}øð-ŽÍ@u½è.:_‹„õÑÃTú¿ø|øð-Ž- Žä«"ÐÆNSnR”Îò‹Ï‡Ÿ8¶À>©ºBj:™ùxI¼v¿ø|øøjB :å\fä§£”c뻽헠_A >ª¢1‹FE¦Û«¿Ð/A>|âØ"(§[h†(£Z_ô–\е »Å/Ê!™$ý(κg½_>v «îGûé%墸iÙ¼\®_­¼Xà„z„áèNÄ܉ ûX Bù¥âcY"z JµbÚ°©úø=„‘vß=Æ/ÍÊ!xOŽ5€èßI=ï—ŠGúØŸã¥ðR(…ôDa™1eº4¸söV­ïúeº³—î^½ÞBðBì5~ÁøØAĤâ\Õ¶†t³²ÚPFV=^µ6ÚþÆ/Ó–9Pçàö:`t`/óËÅÇÖ4¦­^Ì™{°L¯ð<3,Ðô`H‹ì¯×\&bãýbÝiÝ’?¢à×=¬>î‹S>vqH§aÝüCœÌzÛ–]×Í’á{~ eÛø@MiÖ&™RJÀŸ¸»=^ˆØ•Pþ­[ˆ\@`„_0>¶¿«’ý¦Y[2òæ”tmݳ ;¥(kŸæ“v‹³w+â~Õl„'c_Ú«¸­~©øØqÄ–žŽŒ˜B)J‡LûEâc‡ ï¢RâzŽ^±-—ú} {±&‰íùµ³}Üë伫 øsŽ|ìpâE&I©PHI&ùïm¹Tý X†ÝȘ#–óè ¿v¶„ޏ¬×{Ÿ¡}|Çd”¢»óõm¹Ôµ”¾/à ºŽý*ýÚÙžF‡]E/«Ã‡Aa[ãpRÆMC×EgÇÇŽµÄ me8ö jÞ>š7š¨ qôp4¿=oÇj/'~:»ý’ðñÅX¶µ0tÍÐ…'“­ënÝ–«/âœñ;Âg€c|‹ÃÇFŽUoz,bT›ÅFKãcñ–ÿö‹u(Uä2x~aøØá‡½<ÔŠÃFID¯*†ƒbÍò+Ò÷Kvg‡Y‰ªC€lö ÃÇ%ÏY©Ü¦h0lêD8l†Š"a¥ÔšeçÙ‰üÂÝ©¡—áN~Š®Á¬ÛòåLâ Óð"˜ÐBTq•Ì$S޵fñwGLø“YxøøÛvÒjÒ™^1$ýxO!¦Æ‡ðoh„2‡±-L-¥<´ù¯K…#Y­óTÃ^Vßo o/xatïN2+ñ:ô"Ì:Ì*¿·øø|ˆÃK¿ šfz± ®®%Ëb!»½Ûr’+5rÂýè×nš›e%ɦ”` ~D´=^ïäkEƒ ÷¬âÿ2U¢@ÀÓp³à½~„çÀzîîà‡»næ"i à/.d@‚ .s™YÝûj£ÑÀë›9*3t? ³a \ —£¾Fà4¢£ûY½>¶1ëµbB+Z9Zå)Œb)­½]¦ÜIJ¹g™ò@¨ä„>Øk»’Y&¯u2­tp_lNs§Ã­eàP‘¡%ÌÅQïf—¾‹]9’Æ4º 6²Õ‡Téò¢ðÀÎ÷ü4,çdÁŸÉ67¯áöp! nŽ8^ˆõ%+Íjˆ-¤7¬ÿ)·¢•‰VÔ_ñþŠ1žÚ›(9ù ¢Ó¡õ¥Œ[mq„M!DHˆ´BDá!t¤^^ª[–HÅe&Ù½fÁEçE§ ¶ø A¬€GGk’œjðNŒi üÌez9/µrvkûÇê×è<a|š‡[Ù»üs(J[’vé°U¸•ŽÉÍõ\ß„ççµL/£2„åÑáÐb‘tÉxŒÍqŸ«þ •ÓÞayœ}‹8o¶äûÿÎ5Ý€àÔcûžm'^¯©‰2IûCØýt°¢3 M¢û%ÒóX~ µ³©ùé-Økáݶ¦ )‡µ—Ñý%§Qû³Ï:ÓY‡“zF9aÛZ£NNZ˜ÐÄ­ªÑnV_@j.•—RqÁg6•¸9½É¨Â¬Þ涸 ·=FpìÎHš²ŠÜ𤃆hšnheÅʳ\ݱµd·³öÒàøç„^08ñNcŠÇ]1.Œ3&º¥¶ÆÄRi®XÌ¥#¨œàîT®Ë½×¾&HH²Ä`zœç,ŽÚÚfæ)þÕÄ_ZxÖ¢1M´™O¾Îèè ¯s뿹~.xíI(?wSûQppTöôê¥.^²×È0•’S(9…lRŸÓÄâÿ SOÃl´ª~¼™Š¿LËH¼ŽÓ0þU¢o͈Ýù öjÖß@ìP gpJâMšMüeÜü¼½„ÐЧìÛ˜u[sÇÖûI¾Û†bÒÇ„& ÞzLÒù42ÍÚˈÎbÀÄÈîçiþ ‰7ðòóÁ »Qr¥ßB/äƒgèxœÖ?‘z¯³ŠÉó0*v>Wi)ÝÊAJGhhz$BEر=Ks2nÓ»náFÝ/…\9¤p#¼¸† 7×?íäo-Ì`ó×ßìU˃ëº9©™ìYÆ ë8rhDÒã_Išàį˜ì?xùoN#×|À[M½: ´Xƒ&ŽyÜ0<¦–~k´g˜ÛÆAÕè>sÛ8éeÊ‚<÷u¦”,é↹¹OÇñó½6ºœYƒô™V¯G©ºkÁ±ÄŽ `ß>ú”YŰ;©? ×SüMhéy¬»–®¿÷·¶"@p öj€¦_ö'k! 7Ðñô]VÆë ùÉwhº“šk¨üÑ–Þ.ñ& ןӫÿ[¸M0xâ0J ŒÀZŒLÑrÃÝçÓä{¬ŸM×ÿ ` Å_%þ*wP{eßÞÒÛu>ÃúÙ¤æö*ð&ÜŽ’8”‡J!“h„ € @ÓLaF]e[ÒKHÛN­¼¿ 8Ö¨¸dË…R¡ˆ/›:8µŽÒàÀ§-éâÞ¥ü¶+asÏ ¾9¦ÿ9ûUú7&8 ’ÿœ‹ò8~7Mgמ_Ëñ/‘‘üðÞ>vBlÊeöGür>²W‹™ÜºÓ7ª©qæ¶‘ö( rP ះ–‘ñöÝô WøÑ;Ìëà†=ùÉ}…d³ç`{üýðk4§9ñeÖ¥Š<|ð@hTbÖô]vT£æºÏúÙEGµ™¦ëT^2áw7 ×÷ ¡€Ð©º‚’S6òI}€×…¡ð ŒM8¥¡ÉÄ_èþ'ö*#¼8ÍwÑt'^WÏ]ÂSˆìMpfhÄ_¡íϬ¹”ô¥ÏÁåqΞÛ½ ÉÅ5œs'ô_IäõFîšÏKëHº=ƒÿÉ£øæØ\ß ¹d±¬{€ç_ÔÉíóx`Iîí»mbóüZæupí´œ3Òisü?YБc§¿¶ G˜„v!ñ&n[¸t›ÐÑò޽Ñüe¯‹UçÒñ?½¼¡Ñħì{ìÓ×$™Oó]t>Û–7gê(>²3(دÿe£Ñò[™¢ó)*.¢ýo4ÞŒõi¾{RvåçžÚG†/;‹ÂýYý}Zÿˆ1â¿6m:¯aåwˆ¿Ò‹­&Rt$åçšÜ×$y‹æ»é~¾‡ƒã(9‰ÒÓ OÝèÉgÒõlÎÚŠ¿LôPÚ¤ñ¶œ•uLÊ¿GÙYýïRö]ÖßHÃOhüzÕWnòÉÓóXy©7ÔáÝ):šŠóŒêë½@Ó]$æ óªVx7JN¡äÔ­q¶~é@@5Ÿ.“¯ £szZTˆ ÀSÒrãméæµ2µF:íh™py,4îq­`ærÇÙsxpÀE“øíþ}>zl—½“QÚ;„>Ó×øÝ"žZÅ·Ærö.ý?úí".~‹É%¼xDŸ Ë{-Ì|Žá,í5XÎïàØY™˜VƱ#8r{–ìkG¬N0{nOoïï%hœ6†Û÷É 1ÿµ‹óÛiÞ³ÿ/ߊ>lå÷Ÿòç¥8’ò®¤Óæ¨á<×7?椗yjóNdr16§¾ÂKëÆÅøóÌÏtÁÖ\Bó=Œ™è![Tå±â ” PwKŸí6³ì’ow¡øbGQ8£‡h68·Ðü›M. ;‚awÞµõ¾`RŽbÌZôb¬…=Ÿ–~“šŸôïx}, {Xs Àا)>n€¬%,;†ÌR€ðŠŽ¥èH"{Óϳvh˜MëýýÝ¢\O2(>‰awôe­…,œ–3a‚£AYÞs~ùyT_™3 ĺ«i¼a2ñ-"{pBòm–€Û P°EÇPt$áiým+ëS®§ãñMH•!ʾCÝ-ƒ ´oq´^*»Â(F-f5¢Hha0òâ¹-n§³)ÓºÖË´(·KhN¸²,8îµÈô-Ø®çÌ×NŇöt9§¿ÚóvJ Âäâm2ž©çìש ñýIL-ÅÔø¤ë>¤&ŸgrpMî´¥ÝúÖ$™PÄmûpÔ°¼Gò»EÜü Mù®qp çŒgR1ï·òãw{¬ÝKyå(Ê‚¤\ΚÃ+sÇgÕ0¼€O»x¯ ¤sù~0™'Vòý·Ø¿ŠõÚÄ&á0ñhÍP*uæ4rðs”9s,×LËÓf:Uå¾3eãs¨?/oM|·ÇŽpÛYvÉw1*¨»…Òo¢Eæ†ësÖ;™Fù¹ìKf9kÜã4™UŒ­Ï0¸ê‚þ¦8š@Ý­¿ù'_ñmÚ"2‰ïõ7Îí•,9ŒL=Á1ÔÝFñqXïÊ£õ>Öߨ#Ó@ù¹„w#õ1k/ïq—BÿZŸd¹¥GÒ½Ñþ5ÓvÇÀBo¿û.=Œøkø¦q¤>d鸭Dö¤îVb‡ЧdŠæ»i¼¯3ïlIÙw Ž!>‡uWæÆ p&cŸd‹× Þ6âèþ“l¹½XêЫÐË„(@˜9ƒBy¨¤´Û3íMv{“´;”—𮩠yB„÷Ø|Cu8æEºlþ4“i½~ÑÏö¸ Ç侨±íx»™³ç°´—³púXn›Î°¼kKýo61¡ˆ—Ždø@Ží\ù>oçç̨äÚ©Ók1à'Wrê+xùRÿÅÞ\55+åóÔ*žZÉGm¬OáH‚:ÕafÖpÁÄœ_Óe3æ1Ê‚,>¥§¬O1åIÚ2ܸ×N#íñò:v/eÄ–D…ã/³ä0ŒJv]¸™FÓù +Ïêé!¥ßbôÃ=Ÿ®üm`”1îÿ(˜>E½€†kè|¦§ƒU_Ié鈼ô’ú€%‡çrU²o3êÁ^cæbí‰LõøÈ•—Ps͖ƼHzã_#zPŸ(Ò²#éþ'ÁÑìòO‚cÕ×^Eâõž>_}5ÅÇ÷L×èzŽúoô(#5×÷ '^gq¯;êET_Aåela  ³‚Åûá¶2yaÁ‹³xÒó‰ìÍ.Ï\wÝϳîê/&:‹šk‰ö[ïcÕù=oë~AõU;Bã‘Cd/Ce” t”† §’êf (¬TÔns”’ÊK¦×iâQá}?Ûg‰šÌ9OåôˆA¡„7›ˆš\=•+wÿÜæàïWÉ'ð§%ÔÇ) rôðþÒÀ³«s„uã^°ÆÚ$7}Ì}‹s¤PáÚiœ7³ïO04FnðMùÆH¾12ǘÙ(waßÁ¯(Àq#xr%i—H¾êÂà–sÄ0ö*ïÃS›AÁ~„w%½€õ70üW›ðÿ×Òz?7õŒNÓûX(éOh ò‡°†×MÓ4ß™ô(•—RuyÿÝ'#{3ò,Ïû„¡Iý‹ÚXûc€¢c©ùÉÀô´IÁ¬„ѲøÚèCÝ/ÒýO€šÙ°†³žÆ_Ðòû)˜UT_EÅE=d·A0vk.Í©ËÁ¾j\áL*Hó¯@£ì ª¯\d78šÑ³äktüšŸô °=Bz>BgØm°Ff ³iÏ3{p 5³ДŸ‡õ)Mwæt¢À Ò«·M5FˆÀTe½¯d\x]h…¨HvÒJÎjR „n‚±!L‡'ñ¤'“ Ò;>8꿵£7«wèñÂ=ûñ­±ÔFú'ƒn;b&?Øt^æ‹ë M¾V×ß2úý§Ü9Ƽorî~¶ç&sR¯žJPçÝf.œÄ¬šsS8q­ Ãî!Žâ³jx¤ž„É/óÌ×6Ê×ø h†ÝÅÒ#hþ5a”_˜Sþ•Ó@⺞¦û¥ ˆƨ‡úù⯡¼\—îgi·?Hã­=¾IñqÔÞÜG¿è’“ý0OQr%§õÿ´êr"{¢…PO·áÝ÷ ™ú¾còK9û%öõ¾~’Öûh¼£Ç7);›ÚŸ>ðÅ+:‰7(?§ÿ¥€a·St4F‘=·æÉ£‡2öÉþÂJ÷‹FUÇm¥å¿hþu.¥E˜T|Ÿšë06‘ãXwzé…T]Ö_ÀÞ~®  ’ÿðÖ*´ˆVaÖ U =†.*—€”’iå$ì®n«µ]Úq%Óš.Õ¡àˆÛ´â †ÊÍsÞàK05ʼn£Ö$y¤žÿ^ÜãàìWÉ{qHíöz†¦4{>ų‡³G¯afi7ÓŸ¦Ë¨ñ«œ>¨ŒÁö‡Y}^³–Ð. ã6“YÞã䤇Zª.§r£˜zÓ¬ýÏ\Éf…¹mt>A˽¤>Ê› 㩽a:øb‘Õ†…Ψ)ýV.üÑþ(­÷÷„l"{SwãtðÅ¢þx:ŸA+`Ü39a;SOûC´þ±'d=”º)˜±=î¿­Äx«¦)k©0‹E°½½Lˆ0èe£2È ØJ¥•“°ãé¦NeÇ•²5C…Êô`Ý%zÅÍ[OÞ‘¸o1ç¿™s1fÕ àýV:2¹OÇD¹j*ß?€‰ôùâ?žåÚ©ÕwðûÇN•î¼£}xçOä˜áýc=›„µˆæ{è|§i#«$Lx¥§RrúÀsd{»ñ…¢ÇH}Ü3V›UTþ€Š‹ûû&;ÚfÅ™9#: aú Ç¼ Œ¤ú ÊÏEvº'_ ×åb"…£’ï"óQýÐdj®ÍQáöÁç@*ù¬·æ$ô0Ë„Y‰^*´("ˆR…rP¸([) 7á$»RMÒJ)ek:fT„j3jþ ÌšÜôè´Ùïï|ÚÙÿøÞå|wöð ÃwÙ+ :ÓÈx´Y>qøørˆØÙº³Òkžc!”ÈÊ š‡ô"„0{­ÖÛôašFȈ$¥“ñÛK9®%QR„f # tÓÓôZh( tDaB0Oٗٳ(ä–Р4Ƞ̬ÿ"]Q\¨fìñõÒqÇ„Cá¡Rm ‡Ûo½>¾,Ĉ²ŸêÞz¯í^Bdá¢eÌç»´èå¶äL!‚B k¦e([8J:JzY­ЄYÅD ¡ÂDÀ̲í´6Ž‘¹ ²H§ÕšUjþÛ»yH0R.´¡‘ÀšñhÏwüÖëãKD€¨ü½¦2²ãϵ1AJ„!Ñ<ˆ y·¥Ÿêa¢Bà ¡9•¥•ÏÕÏ­0†yúÈr‡&ÂaäYIË%Kå R¨4ÊN§eý2õæãÄFL+6Ñ …úa—‚„O>¾dÄhU Ùùš#4ÐR¡TFzJDÞ‚Ð&J"¼\è4Ûá¡/wl`ÑËôÐòÔz}J> ëB™DÆQñŒ•Y¹Üyýql«êÀcXTV¥iúP©³†TîWùðñe#@Tݧé%²ãWWd›¹hÙ6ġçÈB=6BŽ ûµž,ŒûË©ucÊÈžï¢lT™D%ÉtÚZ¾4óÚc*ÑÙ÷{—¿{0Bu¶¤  Íò[¯/#q¢ü6ͮگGeÀMAÖÉÚ P¼ ¢å)`ÃUz“…ÚèzüÜKõzyÈ4*ŽŒ£’JZ©dfÉ"çÕÇ”ÝbL8þ´)• ­:û¨  ,ä·^_RâDñ%"¸«j½¹•…”/'s%svƒ²i¦ý¸cÐwq´=zøByà ,d•@&<7ÓÕiÏÿØ}û!»ô³Ž˜qÜÅ%å5CEÍÂòx£]ôYëØ‡/q„5¯¨¶ °^Ee÷2uQùPÁœÉ°ÁÜPYoEö¥1“Òcâ¢2(+ÿJ¢ÒvÆnXg¿ûš\ù¶PŽ1ê°£:ýúÊactÝZv×|V%8qãb~ëõñ…ásšä¶%P6]?£û. oVä#©"Œ#Bˆ lÐ>ô|R¹èkYô¿n{¢\”…JåC'iTÆsxÜ©_â¾ùw•\¥‰``ÒñgÎ8æ5#uÃZµõ¿«8õ":ïÇÄb¿õúø*Géçi¿o]¯˜ˆ ByúÈfd˜ù «‘›l¬znø+óK~X¨2ŽJ¡,é9©”ÛØàÍ}[Ö¿­ÉFUÉþg]·Û¾ÇEK+‡Ä|6 é²>ÅÂN^iàž…xЇ挱~Óõñ%!…²qdR©üMZD‹­‘_LÆk¡ëzî%Rèì•ÄÈ¿ Û«E§wžEnž¾$›ë¡lÈ ÓYÇÄsítÊiivÏcÑ[¤…6‡ïwàôã¯>v·P$:$R6[Á£õ|ÒÎÚ$¶Ì¼s_.ÝÍo·>†:q(Ù­d^«’]Èn”…L£,TZ) iDÐbB+1uB¯Äþ„®ÙdÞÉ_hC6—žÏæ ‚9ÿEs¦GÎÊP½¬ ìì…Jf}V¨;IDAT‡îõh¡`õÔ©ÓŽøÑð]¦ÇJ*†„{²>ÅyoòÜš>uÁûò£]ýFëcH‡²Q)%³jB†ì =*ƒ²”´6üŸMÓT*“{+Ó¨ Z­Bµ¨6‘~N8e×ê!²ÙTŽÜ ” sO´œc‚BÉsÔ§U˜+­0ŒÀP©•ÛçqÅ{}ŽŒq÷¾ƒÙ÷À‡’8T>Þé ¥lpPvž>lT&·Ø—Úp<Ëi¥RȬ~™R2 ²]ÚK¤Ó¨ëhºN^Ñ{rÉûYH”©”'¥LtËÆ5¢e]©#F„Ê÷*sD´dL¬¸"T*rÆ|ÔÆ×Ÿ§ÕBŒ/âô1|²?ÖÇ—JãÈfs{9É¥iÚ9¾È±Iv¥âìñ4ÊB¦ …L*™D&² b§ãÝšeé‘"ÂÁ¦p°ÍÐÒà䣳"?;N!‚ ÐbhÅR”{T§­ZË.Ì‘pi „"C.Ôº)—沬›ƒ«9fÄævrôác¨ÇxyÑÁË»NöŸÜ+gždÔ/F&‘)T"KÒK¤SÉæ5‰–5iaF«ÆM() F =·&B"‚ Ð¢ˆ0Z1"†E+U¢Tκ:ChÖ‰>qä]˜œléåW)wƒSƒròZ¦“NU •D&”LH7îd­ñ ÒíkÝ‚êcö=­¢vb¸°hȹ>|øÄ±Í ¢\•µ>zleƒÌ(²ÖGW²Ûµ‰x|õ’ôêy)וU“w»÷)åÕ#Ì€ïåûðñ%'Ž~ âæ¥¬õáªç%LUidGvK/i¥-MÉe¦SÍ–Qž4ëŒÚQ»CCkj‰>ql#}¨Üúy\••N{"2id W2‰Œ»Nº³=Q??Õ¹2ãiîèý5ñÀH´x¨¬¸ãÇOŸ¯"{ɨ.8J¹yë#›ú‘B&”L*/™Œ'W.MµÕ[®kWï>}Ìî‡D }îðáã«E›Ar³Z…“ËøiT •^ÊJ%×­Hµ.O»Ž]5eúˆ‰3BáBŸ;|øø G/ÉÒG.dÃÕùÄS™R2•±’kS«-Çuê¦ì_5b¢ð—²ñáã«KýD kðd“A2Ù òJ¦;ÕÒêjÈx¨aS(.«Ò†lŠ—>ql?ÄͯšQÊB¦ìL¦­)j³´p¸zì‘‚(¾ÃâÃLJ²;Õì¯ÜM` $ÊCQ!¡ÂJD¡LyÕaXvÂNÇÛƒ¡ð[ŒÇ‡/qÈúÎ9mtƒd÷v e#3”)®Ì$ÌŒ´-ÇÉhºá«¤>|ìpâ þT~§%å ‚-µ­¤ã9é¾ÒáÃÇŽ&Ž!3Zg×é€)4Ï ¹Bw=ÇEù;ùðñXC.ƒ[ ! 3¨tÓC‰M¬îÇíHC·Ë Mó>¾hþXíÇÁ‡’ðáÃÇ ñÿ»¾Ò„oõ#IEND®B`‚shutter-0.90.1/share/shutter/resources/icons/document-send.svg0000644000175000017500000002202112206477313023514 0ustar mariomario image/svg+xml Jakub Steiner http://jimmac.musichall.cz shutter-0.90.1/share/shutter/resources/icons/shutter_cursor.png0000644000175000017500000000036012206477313024031 0ustar mariomario‰PNG  IHDR©¥–sRGB®ÎébKGDÿÿÿ ½§“ pHYs  šœtIMEÙ  -ÆÚ”tEXtCommentCreated with GIMPWKIDAT8Ë퓱 À@ Ääì¿@úßSiébáâÁ‡!®14$Ô¢‘cÁÕ±t¤#­åÞ2 &]B¼÷—ý¤šV…›7é)Ò–<] hMPn"ßIEND®B`‚shutter-0.90.1/share/shutter/resources/icons/selection.svg0000644000175000017500000006153612206477313022752 0ustar mariomario image/svg+xmlGo Homejakub Steinerhttp://jimmac.musichall.czhomereturngodefaultuserdirectory shutter-0.90.1/share/shutter/resources/icons/Normal.cur0000644000175000017500000001027612206477313022202 0ustar mariomario ¨( @ 1EC+*! ¤ÿÿ CÿBB'BÿÆÆÆÿØØØÿÿGÿÿ[JŽkkkÿøøøÿøøøÿö?ÿÐÐÐÿÿb£ÿøøøÿ°°°ÿÏ5ÿùùùÿÑÑÑÿÿ===ÿøøøÿøøøÿJJJÿ«:#ÿøøøÿøøøÿÑÑÑÿ¢¢¢ÿøøøÿÑÑÑÿÿdWL7ÿøøøÿøøøÿøøøÿøøøÿøøøÿ°°°ÿÿÿÿÿ@ÿøøøÿøøøÿøøøÿøøøÿøøøÿøøøÿøøøÿøøøÿÐÐÐÿÿ,ÿøøøÿøøøÿøøøÿøøøÿøøøÿøøøÿøøøÿÑÑÑÿÿlÿøøøÿøøøÿøøøÿøøøÿøøøÿøøøÿÑÑÑÿÿlÿøøøÿøøøÿøøøÿøøøÿøøøÿÑÑÑÿÿlÿøøøÿøøøÿøøøÿøøøÿÑÑÑÿÿlÿøøøÿøøøÿøøøÿÑÑÑÿÿlÿøøøÿøøøÿÑÑÑÿÿlÿøøøÿÑÑÑÿÿlÿÑÑÑÿÿkÿÿb–1ÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÆÿÿ€ÿÿ€ÿÿ€ÿÿ€ÿÿ€ÿÿ€ÿÿ€ÿÿ€ÿÿ€ÿÿ€ÿÿ€ÿÿ€ÿÿ€ÿÿ€ÿÿ€?ÿÿ€ÿÿ€ÿÿÿÿÿÿÃÿÿÿïÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿshutter-0.90.1/share/shutter/resources/icons/desktop.svg0000644000175000017500000007235212206477313022434 0ustar mariomario image/svg+xml Lapo Calamandrei shutter-0.90.1/share/shutter/resources/icons/sel_window_tooltip.svg0000644000175000017500000003735612206477313024714 0ustar mariomario image/svg+xml Group Chat Jakub Steiner group chat IRC internet network shutter-0.90.1/share/shutter/resources/icons/sel_window_menu.svg0000644000175000017500000004213612206477313024156 0ustar mariomario image/svg+xml shutter-0.90.1/share/shutter/resources/icons/throbber.gif0000644000175000017500000001524412206477313022535 0ustar mariomarioGIF89aBBóÿÿÿLLLzzzÜÜÜ   øøøÂÂÂ!ÿ NETSCAPE2.0!þCreated with ajaxload.info!ù ,BBÿÈI«½TÌ»ÿqÖ±UÅa€lK‰'e–áÞ aÚr,Á+œ0X4¤^epXÁ!Gw@ š•YfT1xRNJ•*à…†;±gh%ˆ»¤]~[ò5LIXLs{_}RŒru“•l_^ŒLd!;a|]_k,qM§ƒ£šmn8© i-¹¯¦·9§~¥‹o³½Å±Å˜ÂiÄ.)Œ^ϺÃÁ)MÎ×.^ÊÛ?ªàáÉÊÇxæèmëìiÍðpÉË-Éôàœø²p%PX¶_ +˜O]{¿š XÈP‚‹ šA0à—“ŠÿB9F@!È)ûNª\ɲ¥K?b6‰ó¥$Œ89zlr ‘Íœ8m J´hÅ’ßV Y cLŸ-À¸"M&mŠ›:U™§Sý©”7U‘Q8bÏ~(™Ö`Ê)Â+Õ¤˜Ô”"UÈN'Ö¶ÿ¤N]q@R–“kjkÓágoÅÉÝÔqòòú1Ðñ>ÌuGu|´f!œxÞÓXÊRÖ™I³Âp©ÎÇÆaoõÊ£2ŸýxÊéC _LìPr`Dz/8ò͘BfI¶ëeýÜÑY‘5E^%—´Gßœ}‡¯‡^8÷åØ }…ÊñÝèÊÖöNÿz…‹cÑÇzi$„Ÿ0ÓY@àMèR B€Tä<!ù ,BBÿÈI«½TÌ»ÿ!ÖqXÅa€lKfyV&áÞ a®Tüd0° ¤Þl’*VˆBAp@Tš´¥„êœ |QNJÀ“ÀTJŠî`›¬»áËY¡¶%`Àù Œs¾lGI[GpkV~ze‡t"‹”G†/˜,cz5a€wo8S¦)„Aˆ!&h©Tdj¡7k´Aª·ŒgÀBsÃÄj&ÊaªžË€º#ºÑ˹Ô­ÚÛ9¬/ìçàéáÖ\âò§ôéú¼Êí›·ÎÞ uÿä}K8°¡žxƒñÐ `@ˆçÑ['¡ÀŠÿàeì°q]Á>†É!]Áo\d‰Cš8sêÜɳƒJ{JB@´èºŸ áðTg”(F¡P£JF¦9–6c¦T©4§Q<&Ù\SŽ™*èFµä"pT5Æe„gÖ]bŸÊcÊöC¶o.ËVÔ`KÀŽx&ªÏ½#Õ­…˜²¯ÈU±©Ã¬æñ@¦‚¥I¼/ÛÚÐ5G£N…àtªq­h€iË-` U¹êZ€­qƒðHZ’ç×z'ë‚—.˜d>•N!¸·ÚUwWïö•U5É9#âÉã#‹/’‡p½/¥r7Ú™$JøæÇ{B_ù)úíEã#+­M:4ñRܯØ`OðVWá ÅK4JòÞ\êí!ù ,BBÿÈI«½TÌ»ÿ!ÖqX…`€lKÇV™åA¸8hö|¾¦Un*ƒ‘¯R8 ,ƒ'±³ ˜Î%ep8N´i'¥¢bBIXrîMÚ^ñ¥ðn“5&›4Ër`€MqIMRl&W{x[‹{’—[1Ž.di"›S0no&•,U˜†bŠm§8U„¤9½¤"ASŸ¿f&ȹI»ÉŒhơу±)ÈÚ×¾žµd ×D`¬ϰè-ÚÝðT\¬ÍsdÖøXœðë@@À~ÿ* nax’DèÐ˰=Ó`¤aEšÿ–-ÃÔ«€»D 0pE”ž ´„I³¦Í›8¡PÚ)1g©•@FáI©•Í‚H!¾ôÉ´©Ó§æüÖ²d”(9“²$…àjÑHS*])ájƒNe®|ù *™nƒI˜Éw({Aœù¦ëD¾×¾!€ÈÒÃÅ(÷l ÞËá.XŸ‹vEûÆ#5o@s™´,F/àL&†§—òÐF>Y¬z\j3…‹Åf3Ø´+Ñ¿œ#ÕLíÖG³éØY÷/Áœ/DfÒZhËË_ ö4[ÎEáº1é~±»ïRÒ›™/'ô¿‚¶“éz|y㾿GûôøKw?u²Û: œ…|÷RzõQ{¿·_zy)(žðáô u¸Ô_EÓá!ù ,BBÿÈI«½tÌ»ÿ! –pX…`€lK‰[%Ä”I¸8hÌk}¾¼œPR(X4ÆM‚8 PÏag'¸Q‚èÄTH×ÃRzÁz*0£P­iS’Œ1 eUßK\)ˆ×t0k)sZ)‰;_€‡†`Xp‡Nvœ,‹€od"¡§‰,vY€)™B~†*B­gn“.¼@R¹½qÂdÄÆŸ&·­¡ËMÎ-˜“ÑËÀ³šY˜ÛCXž—YÚäé&b±š’îS^çö:fí÷ŠçtáøUìß7ÿNȦÐ+ˆêukØ"¼"FdG±CÆs ÿúe ­Ž>ÎUBHà!Êy_ÊœI³¦Í%5Ö»9!¤ÏœOÒ„çs Ï£H“*5Ö2fÃŒò¼!(b’gÈ•W¬•,0±æGŸQ´²+XÓ"È4d•pº”UWŠâæ Éñe¶µiN•˜wÛ]¼i#ykw-^S‹°mø·ØT Êõvw bƒ‡Ÿ î‹«)gߊ|îœ×f7FšœÆ³iÑ!êiêͰjn\IÁÖ’T﹄ï"Kð…ËÚ·ÓåÎÊ A,Ú œjêç»äýJý/R×o]±ëý\h@-åq q\/wwk-8¯.¯|t»Ö+ˆŸ|xù'9ן 1ÛÉUimíGN!ù ,BBÿÈI«½t Ì»ÿ•1– XÅ`€lKÂV™¥@¸8( +E¿¦^nX U ÄìDAÄPÆaG4P6QÉo2HVœLi¡ 1óölºMЇ¬ø²³rm¾0¦ ys0*Hv…Xh^fHYn—‡]2Œ˜9)„/™C|¦lO8¢“†sHžp€9T£´“¬f¶C­eSÁR¸¼ÅªÉbéÍÈÌcU¼ÒÓ{Úqd¥ÝRNᚢÜåšèŽØ’îSðÈõ:ãíöÔȹZðåC«~žA¨°7)ŠlØ">&DÑÓGñ™cèÿò1"‘^G Œ@8¡ÂŒ.OÊœI³¦ÍEFè,rsBÊù"FÑS Ð}Š*]Ê´)´‡=ɲ°-c93Sb1eõj‰6ÉMwØ¥‘RÒºæt—ÓbÛØÚ3„ÕºÍÀYc±íªÛ“"BrÔdõ¬L!§¾ˆ· ^•âØikœjp³ö îVíeƒ O3R®fÑÝH£ûü&ô¯¿Ê üiô×I$Y¿!Jµç‘ ÜÌŠ÷$Õ™uÀž`ÖÔ@¹q_𦠮Y3¹_ʾ{y¹á©®79´-oïÓHžxÖìÈõÆçŠ×~*ÉãkŸ’ÆùÔ–Té&Ì|þÙ…žLìYà^÷õàŠE÷Öz!ù ,BBÿÈI«½t Ì»ÿ•1 –f!ƒ®,E˜•°Uƒ@´8(¦ô<2Un@*…QÌ'A –”ØÙÝ(¨é6I'N&õò*%»3@F Ôníøbðö®.€ÀÆç/<`J[LYm_sjvxd–Ou–+YVc|6!Šr+uR(Œ9N®nƒ8ufm´‰Dª·€²ž9µÁ¦¾sªÅÉ|³Ÿ¼!ÎÉ{ºu›R•×TN§”Þºà5Š®dÞÔèÚ§çtÝßðOôUïøœXHWÁd#IØï JêHpämaC‡/íÛ'ÇEoÿ;h”ŒN®äî¡\ɲ¥Ë—+ºƒIAãûºéœ6æ7•賨ѣHáyRgG:Ù±zÀ–%ŠQÿ¹Ìx3è#FN&­”¨‹G 0MÚÂ#Zp"Öš4òöš¾ªrÑ@eÈRD×’õÀÖ…÷"¨Ô‰‚:¹)f߃‡hPçªè¼yXØÎ,€ìËûô1@AIþwt›’¢¸Îl±ê ªVà3:‡#±?jû¾éŠwcÌÀ[rÛA£²^Üö—\íÕLûÚܼ|Í£VµjÔb¹‰ä¦k¿á8 ¿üær Çy‡d}·' ¨8ãK>‘¿x d‡D|ø,EŸ'˜ç“wÑCÜ‚üíQL Ó¡ô<!ù ,BBÿÈI«½´Ì»ÿ•Q Ö0XÈ`€lKÃV™å@¸8(ªóI¦Un@*šã„FIÉšO"FT¸½b=ä@)!|RB#” eÓü™¸a ^à-Á¾ØŽsdM[QNnV~iI/h€‰uQfU9c‘?u8_”@—:›cp8†‡v ©?Ÿ.´¯µ,sº~l_½»œ¾!&°a‹™Å^È “ŸÁ~¸!¦€#£Ì.)ÙS›ŒÞ¶á6Û#Ôæ"éÄ·ÝæئîrÖ÷ãöþ^˜&+«ô+ØbGº.«FÙ'F¸‹âÌ1‚¡téÿÊq¸E1à$(Sª\Ér¥‘—0[–8€ñ¢Ž eΠÉSÀ=:ƒ JÔ#I¡cj$3¨Ïx”˜ÂTXÒŸÅžâ^¬j´ÎS3\e.,ªh,CJG25[ÁŸoIe+°Ô[yç†-ã­VôÅvWÛV9{[ˆì”qÓÄÜ €<‹jÀP4Óê8H·fDRnYž0²ˆ4Ÿ÷Ê{XJŸ!žj¾À¹‘\ÊÞŽÂ ôÃÑf›<—4å¨óu›r<É'¼Æcà-qæ+è¦ðVø$4)whømšî¤·“öÙ[Ñè%Ñ' Ÿàó’Ûâ§|ª¯ý{†øÒR—zòùW~HÍW Ö •Û) :YøP!ù ,BBÿÈI«½´Ì»ÿ•Q–f!…®,%n•jko=C8¤· „€8b° aP¬ šBŽ¥ Ù1 Q–½h‡p­æ(?ÏÌÊ-Óc¸K i —þÆœ·rYvKX"]}SUO…^dU{p,D‹Bx4!m7q™dA\nž¡f‹6l?°,¢¶ˆ‰¼¹·­º•µˆq¾o`ÆD³pÉǰSL‘ÀÁB`ySÔÕ+d¼‡˜ÎÕ†¼£ ²OäÁ\ñÌÜS¦òö8ì÷Ý^ñú6ˆÀkˆ¸'ÿrðF ¶;ê)ôÀ‹`™y 'Z(¥±£Ç ÿC<ØOd…Rª$¸ì‘Ëz"Q6TƤ͛8sz”•Ï ˜.d-êQ&ÁG_ZúËÌJ0–Îê9‘ˆÌ0¯t†£ªu^Ö–V¼òÇU ‚”«ðI-J>~Öš\¢ÒMR²9Ϧ´ãbj%€èÔ@uà€]]zÙ’*|@±p|‡1åÇ*°¬Æ±3*‰>æŒæ@Í OßÉ|c@áE› ‹‰]ò¾ ¸À*|úìá-°È¬$Ú‚¦\ŸN™Á´‹È¿‰拜Bá/’cH¾Œ¡Àkì­pQ}äÁò vã]õõÒ|O¶÷PBdê㛫 e¢úõ¼gÞw6Åf€DV\Uè‰W‚ šÄœ=!ù ,BBÿÈI«½!Ì»ÿ•VQXDa€lK‰[…œ²êÞ hSE<¦n *„Q Ù³hˆ˜p’ôILµ# íT§i†&îÊ&m÷SfàæO¾=¯ÙpRýÜZÍnP`{/…!J3VeŒ.{…b‚A!&9_H‘CŽ˜—8ƒ#`§]ƒ¦v7¤‰wf®£“²l&µC¤Š¸)»³‰Š¨¸„:š†·ÆD)ËeUÈÎ-@ÑÉ{Ö×"Ú±›I¾àTÑä.§çèaßïòáîó7ÖFFÅöØ3ÑÔFŒÐÇÏ‹‰­þœÈ­à•=ê©rˆáÅ‹3jÜ%ŸG#ÿ' ùÑcȇ¤TIæ¤Ë—0c®A -¤††† 8Àó@Èh){¨г眡¥\£§€m2u¨X)Ìx2;¨ˆU6D´ä‡ (×al½D€ÛuÊòðõ]Û”Ó¤ÍK‘€Ê§ˆÖ1.¤V¯xòíB åYxÌë/åps/WvÜq'ÝÁXˆ0e™Wæ ‚»èë—ó ¢Ÿ)àY—CãØhß[[a'U eù–šTYx‚I=Á-â?ÞÊ3°sìN5;38>ù]ÉzÀSàùb'iÝ× (®ðý·„ìXÊp«¹—øb+HfÇØyÔày/ˆÇÑlX°_o¸iÔØ>WFý]!ù ,BBÿÈI«½!Ì»ÿ•–fˆ®,%n•jko=!EX¤· „@ª Š;Ø¥Ü!…J7ÅšÍ@(ô š£ü\<2o ¯T™Äp¦tmNyiMÚ Ot€ysc'}sxQŠYr"T+D†.S`‚‘‚X R#‘–P][š‘+RDd¥-Rj^«¦G°„‚4m§”´.^ŒP³¸?Á¨¥ª»ÅÇ<›…žÉB]½z“ºÐ8^^l¹Ö×Ü<½Ä“ãÉÃ7ªæ»­ßð’ÍñÑ5÷ƒô6"^éî < `Þ>>Ò Hפ‹vH˜P0 J%±£Ç ÿCÂHRdŠ SxH’ I3)c~yI³¦Í›ô0j<ø†ƒCˆ4e2 H2#Í.1€¨g¿”C¶á\Ònê‡.U ‰Y7àÞL‰óµ£#p@Ö#ä¿y±`Zyv ÖÏðˆþ@¤öKÄ÷†w€ÐÑ„Þm×”™Uú]!ù ,BBÿÈI«½”Ì»ÿ•¡Ybˆ®,%nz¦m Š4U†¥jÿщà›È2XF ļŠC²²C2ƒÕ&çéÒ@Ñž«tÕ†¼±œ$‹5!Õæ w"ý2QL)\‹”5yD"_lQ‚5Ws@zPXe—‘/Zx<{+–—y‘5¤PzŸ,¡¥qcž®-¬²q©µ³n¯!±‰¥`½!¥"“Š—ÅM(É—‹”Î[ѪÕ¸ØAÛˆ˼âä“áÚï΄ëõ+ÄöfˆßÒù³ÐÑ$ÐU-˜:r´E[xgà7„z2ÇnÀAˆ]äaÜȱ£Ç,ÿ\’‚Ä“" (9!Ú€/_6cI³¦Í›â´]äȉ¹e$KÂde@J~XB‹ùÒ Á—1êzç–¨V;ÃjkŠ©t<XÔhÀá\ÍH;Ö‚§×–ÛÏ‚·E;;þ´ˆÁÛ')ù(†á›K@Þ8脽2  \=tÓÆ@Yò*¶–ƒ4FÅ œ¹Šm ì˜‚Ñ™@ú Ž‚Ù†ÑÒF(Çvª5Е¢< a è˜Àìí+3•Ê&¬›|5ä¤)¯ ›eH‡7ÐöhÛ×éE%ö°ÆŒ´WßÒðäíÎV0zýå$ÌcCžfø}g5Bè\D`ÆÙÃÜ:!ù ,BBÿÈI«½”Ì»ÿq–f„®,…G¹UHÚÞ Ï“I¡6œ0X£O” =º$¥p(CÕ¯öôPZ‰œYÃà²{‚‘(0DF>AÑ{54Ûò:,‘F=KfY{k€w(h†Œ“8Uz}Œ-vz\7Hd™C† •z+¦h¯ž³¢‡C¥UˆL®lQ¶ˆ¡¢Æ¤H‘ÀLy7™µ'ÍÎL¯v¿_Ö¼º¿¦àÝÔºÊÛéæv¢A™Üæ†Ð7Óö—ý=  —S ”#( _:LÁ0 Ã-¢>4S€^•‹ÿ2ÖˆwaŸEiH¢\ɲ¥Ë—8$˜s‚8s>€¤' U0o Õx²¦Ñ£H“²Z“U‡}zZ š3Ÿ„ˆUªP\H0”Nœ3xRä—ÔNN1\TŠh_»n¡Þžˆ* ¨½}妉ȓìÅP ¶ÇsÑKÀ`9ð­{ïC ý> ¨2åã¢Úí’Y2¯ÂzqÐÂÚ耴–®Pjë–Õ¬I¦öœãôo†(j6vDÃxÂÎPdMêÍ%=GÍ s¹}K16ü‚8v·#q‘ðGq€ó£"‡ hf ÍU÷û=‹"ŠÞ±×éˆ\Hë5â¦ÃŸR1D‘ê^TQ#3Ûq7]8õ•ûÕñ_S N•ßÁ4O5&BÛQõ;shutter-0.90.1/share/shutter/resources/icons/lpi-help.png0000644000175000017500000000172512206477313022456 0ustar mariomario‰PNG  IHDRóÿabKGDÿÿÿ ½§“ pHYs  šœtIME×añLÔbIDAT8Ë=’OL›e‡Ÿ÷ëŸïkKK ”Mt™HŒ ù3`ó 1“D˜‡Ä‹‰;oó@[ׯ£ªýq+@åÙ–'‹¢øî˵µè@.Ÿ¥§«ÇÙòñ'Îì³gemoâêì¦T*a¼T(þ*³ãí®[ÒZûë›rÇØ­à0œ¨D‚Û‹‹NŸfòéSd<Ža8Xß’¯­§ý‰FëAGÂèë}‹ïÆÇy»·d"ÉÊÌCîÇbè{{ü²‡±qNõàõy¹?=ÉçÏ‘››±‰ÁÁÁo^©´ö—„~,µ["—Ïó×/‡ùúÊ•ÿw«ÕB™aÅa+­CCCÏQòW«ÜsHa?,…Mû{y…`0B°¹¹ÉòÊ >Ÿššêêjij|]ij?UúŒuxxX$ð°>ÀX]]%’L&I&“,--©‰‰Û&ÿ©›þÖé”!IEND®B`‚shutter-0.90.1/share/shutter/resources/icons/lpi-bug.png0000644000175000017500000000154112206477313022277 0ustar mariomario‰PNG  IHDRóÿasBIT|dˆIDAT8m“oL•uÇ?¿ßsÿ<Ïå"èX/jA+c‰ÙÝ\cI‰– [/lØV½È^äæo¬åzQ¹ÎÞ±ø[nn¶ÖlÓ{ §9%H Cø{¹<÷>÷Þçô‚pnp^í{Îçì윯b·p\Á»’¢ü…w|X»ÐF¾v9‚ð^2@¦Z ÐÝÆÄãÛ¾Ü8òÇvÚžútÌ䨦EBÊÇaocÈðæšñhÿoÛö³cUs¤…­7~~.&"’vîÊHOnFúχ£“'EDäÚÙ§–.6Q±ÖpzZiš¹ýkß?* ‡$¿)igBRöuq¢ç$±xM"­ô¯Ô{ÂÍÜQÚ[äñ)gÎ#heì#6¶‹ÂŠ+x=åŒ\.ERS6ýÀÄÀ×qqùê@ Õ†?ójeÝ´ éœù6HOPTàÁ45JlÐÞàKŒ¾a*ÅÍ€®ªg íÌù}·í&G‰Ý®"9׈6,Š ü”ûц…6L’ÑNž®9…Ç\ÿk¸…}`ë0Ç&‡Ï ,MGÄŸ{­M´¶(*´(+  µ…Ö&‰© =CeÝt ¸þÉ–H+ß?8cø;j̬Í?=S{‘øx JùPÊ €H¨Å—sØôù+ò‘Ž+€®FüërÔŸ/ÿ¸Ùë›Wéù(m±ãµ^Îw–#®YØÍåŽGp{‰¤4„ê¹¥rr8QúìÇ%¼=Ê“±#óM”Ò€Ôÿ¹ÆuúØPüb<íÊ/¡zn¨p+o:£½¬òý·Ïž¾{)cËÞ~œ‰½(åÁ“õ>Ê !É¡åUTW:{~HJÔ'¸—v7³‡{Ž~~oðÔΔ3~#¹Ô‡¶ªñæÇ^räÒÉbF¯~³îàñ—±.{n÷£ìZþƒª:lp—}Ðâžµç®?‘]xHÿÓ{ÐëývXpk'‡N—Ý9s@«ý¯þü Nj•™"ÍT7léR’pb³}í³³î5’XÑ»ñggñ*Ðà¦9° n"ƒQ¼¾ým:×4ÌCñŸX7 ûZIEND®B`‚shutter-0.90.1/share/shutter/resources/icons/executable.svg0000644000175000017500000002313512206477313023077 0ustar mariomario image/svg+xml Executable Jakub Steiner http://jimmac.musichall.cz/ executable program binary bin script shell shutter-0.90.1/share/shutter/resources/icons/notify.svg0000644000175000017500000000622712206477313022271 0ustar mariomario image/svg+xml shutter-0.90.1/share/shutter/resources/icons/drawing_tool/0000755000175000017500000000000012206477313022721 5ustar mariomarioshutter-0.90.1/share/shutter/resources/icons/drawing_tool/draw-eraser.png0000644000175000017500000000147612206477313025653 0ustar mariomario‰PNG  IHDRÄ´l;bKGDÿÿÿ ½§“ pHYs  šœtIMEÖ  OžØïËIDAT8ËÕ•ÏoLQÅ?÷¾÷†¶ÓaT…µ°èDÄBðˆ ;+aCJ$DXÙvcg#ØÒ……Ø  kiR©¥U”vª3¥5“¾éÜw¿ï>óÚ”ÖFâ&7'ïGÎ÷Üs¿÷\øß†Zá›Z៥Cû[âo…Â^ 8´ž›jIaÈp¸œ/§üÔÞÎíÛ¼mí»Ãõ=»NËÅóDaˆJ,bA©X—JJXK­^§óÒ•@ pl‘â ¹œž™›³ß …ãr`_ýìiæ'Ç!²M2$F‘X²"Ý;hxIãúMòŢР±#Ý ôÏŸÏsXk‘ç9ûƒ™¯1àlÏ^9— ”$‰ff]–%Z23úþTŒ™ÁÌAk½Ü„ΕRØr1äb—¤–ÑÉ·Á¯ŸžáC _ÕÛµªáC5ˆ…ÐÚ|¨qwu¹¢4M?‹¢¸˜oÁïÄ@´!Aǧ}¬µ’eÙŸ†¨Œ1ï~FtQ­÷NžHZ[7r« €¯CÉD$"B$"Sçf+w1cÌ›ssn°6ö«sî¶‘ˆpø'öѵؼâ¡óÿE…>ŽVaŒ£T˜Â/+ƒt6öIEND®B`‚shutter-0.90.1/share/shutter/resources/icons/drawing_tool/draw-callouts.png0000644000175000017500000000167712206477313026223 0ustar mariomario‰PNG  IHDRàw=øbKGDùC»tIDATxÚí•OH#WÇ?/‰Ô•-ekKOƃ BEÌRj=E£‘ºz®PèA<÷¤'O^¡,(ˆG]Z1j–Zܦ!©Ä–ÂÒÔh£c4ÆÉ˜ÌüzØ™éŒh¥·úà1ïÍÌïûç÷{àÿvOS÷|ÿøèéèèè7Mó ¥ÔE&“y¤€ àÀü7ÄŸÛ###²´´${{{R­VåòòR*•ŠT*ÙÝÝ•ÅÅEà7à3ÀðàÙÔÔ”¤Ói©Õj¢iš\]]9àR.—¥T*9=Ëää¤1àÑ]™yÐÕÕµ»±±!µZÍw“T«U©T*r~~.gggrzz*…BAòù¼‹E‰ÅbìoÙ$SOOÏÚôôt¤¯¯+ÏÄb1”Rˆ¦i""ÎÓ‡ÃaLÓÄï÷ljF£ßO€+ÿ£‰‰ G¥¦i¢ëºÔëui4R¯×E×uÑ4Íã¢T*I±X”““9>>–\.'ù|^FGG^ twwF¥J)”R¬¬¬à÷û1 ãØvÐßßÿ÷rT¯’q}}M0øø& iÚ{ˆˆ“axxØ™ÛÀîn†C`‹°Ò^èºþ¦cŸÏç,//ßZƒH$ÂêꪧžÍõÊÍ# Ùv‘ l y¹D"Û…ˆËåÎÀçóýžL&C½½½ˆRеµ5O ‰Åbˆbwб–«( +›››OZ[[ikksЉD<nå7Áí~pp@:Xj+~{aaáY(ú¸½½Ã0PJ±¾¾î!°UÚãp8ìÏf³$ æç翳ΨŠ{Kþøñã‰ÙÙÙw‚Á ³ìÜíf-Ü5Ùßß'‘H066ö«u./®ø§Fã+{èºNSSÓ6x6›%›Í²µµÅÌÌÌ÷À—@(×7e ðn*•úÅýR×u£\.G¹\æèèˆL&ÃÜÜÜ:ð#ð5pa\â&T*EKKK=™Læwvvš“ÉdóöööC×?ö™ÿ'ðøxühÀ¹E [bQÀû;@8´Ø_ àç[\Úd×XÕŠ©Æm7ÚCàm ðY/­ç]M¬nZ æ?]™~ É5·ÕÉþÒÿ „(¶N£QIEND®B`‚shutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/0000755000175000017500000000000012206477313024352 5ustar mariomarioshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/information-red.svg0000644000175000017500000007311512206477313030177 0ustar mariomario image/svg+xml shutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/error-round.svg0000644000175000017500000004324412206477313027360 0ustar mariomario image/svg+xml Rodney Dawes Jakub Steiner, Garrett LeSage Dialog Error shutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/warning.svg0000644000175000017500000002205612206477313026545 0ustar mariomario image/svg+xml Dialog Warning 2005-10-14 Andreas Nilsson Jakub Steiner dialog warning shutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Forms/0000755000175000017500000000000012206477312025437 5ustar mariomarioshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Forms/Callouts/0000755000175000017500000000000012206477313027226 5ustar mariomario././@LongLink0000000000000000000000000000015300000000000011564 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Forms/Callouts/Callout_circle_center.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Forms/Callouts/Callout_circle_cent0000644000175000017500000000756712206477313033125 0ustar mariomario Clipart by Nicu Buculei - segmented Nicu Buculei image/svg+xml ././@LongLink0000000000000000000000000000015600000000000011567 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Forms/Callouts/Callout_rectangle_center.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Forms/Callouts/Callout_rectangle_c0000644000175000017500000000547512206477313033115 0ustar mariomario Clipart by Nicu Buculei - segmented Nicu Buculei image/svg+xml ././@LongLink0000000000000000000000000000015700000000000011570 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Forms/Callouts/Callout_ubuntu_center_top.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Forms/Callouts/Callout_ubuntu_cent0000644000175000017500000000665212206477313033200 0ustar mariomario Nicu Buculei image/svg+xml ././@LongLink0000000000000000000000000000015100000000000011562 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Forms/Callouts/Callout_ubuntu_left.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Forms/Callouts/Callout_ubuntu_left0000644000175000017500000000660312206477313033175 0ustar mariomario Nicu Buculei image/svg+xml ././@LongLink0000000000000000000000000000015600000000000011567 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Forms/Callouts/Callout_ubuntu_right_top.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Forms/Callouts/Callout_ubuntu_righ0000644000175000017500000000657112206477313033200 0ustar mariomario Nicu Buculei image/svg+xml ././@LongLink0000000000000000000000000000015400000000000011565 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Forms/Callouts/Callout_segmented_left.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Forms/Callouts/Callout_segmented_l0000644000175000017500000000712012206477313033122 0ustar mariomario Clipart by Nicu Buculei - segmented Nicu Buculei image/svg+xml ././@LongLink0000000000000000000000000000015500000000000011566 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Forms/Callouts/Callout_ubuntu_left_top.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Forms/Callouts/Callout_ubuntu_left0000644000175000017500000000660312206477313033175 0ustar mariomario Nicu Buculei image/svg+xml ././@LongLink0000000000000000000000000000015200000000000011563 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Forms/Callouts/Callout_cloud_center.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Forms/Callouts/Callout_cloud_cente0000644000175000017500000001151012206477313033116 0ustar mariomario Clipart by Nicu Buculei - segmented Nicu Buculei image/svg+xml ././@LongLink0000000000000000000000000000015000000000000011561 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Forms/Callouts/Callout_cloud_left.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Forms/Callouts/Callout_cloud_left.0000644000175000017500000001147312206477313033040 0ustar mariomario Clipart by Nicu Buculei - segmented Nicu Buculei image/svg+xml ././@LongLink0000000000000000000000000000015000000000000011561 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Forms/Callouts/Callout_star_right.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Forms/Callouts/Callout_star_right.0000644000175000017500000001206112206477313033060 0ustar mariomario Clipart by Nicu Buculei - segmented Nicu Buculei image/svg+xml ././@LongLink0000000000000000000000000000015200000000000011563 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Forms/Callouts/Callout_ubuntu_right.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Forms/Callouts/Callout_ubuntu_righ0000644000175000017500000000657412206477313033203 0ustar mariomario Nicu Buculei image/svg+xml ././@LongLink0000000000000000000000000000016500000000000011567 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Forms/Callouts/Callout_rounded_rectangle_right.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Forms/Callouts/Callout_rounded_rec0000644000175000017500000000652612206477313033136 0ustar mariomario Clipart by Nicu Buculei - segmented Nicu Buculei image/svg+xml ././@LongLink0000000000000000000000000000015100000000000011562 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Forms/Callouts/Callout_cloud_right.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Forms/Callouts/Callout_cloud_right0000644000175000017500000001215012206477313033136 0ustar mariomario Clipart by Nicu Buculei - segmented Nicu Buculei image/svg+xml ././@LongLink0000000000000000000000000000015500000000000011566 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Forms/Callouts/Callout_rectangle_right.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Forms/Callouts/Callout_rectangle_r0000644000175000017500000000573512206477313033133 0ustar mariomario Clipart by Nicu Buculei - segmented Nicu Buculei image/svg+xml ././@LongLink0000000000000000000000000000016400000000000011566 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Forms/Callouts/Callout_rounded_rectangle_left.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Forms/Callouts/Callout_rounded_rec0000644000175000017500000000652712206477313033137 0ustar mariomario Clipart by Nicu Buculei - segmented Nicu Buculei image/svg+xml ././@LongLink0000000000000000000000000000015100000000000011562 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Forms/Callouts/Callout_circle_left.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Forms/Callouts/Callout_circle_left0000644000175000017500000000756712206477313033126 0ustar mariomario Clipart by Nicu Buculei - segmented Nicu Buculei image/svg+xml ././@LongLink0000000000000000000000000000015400000000000011565 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Forms/Callouts/Callout_rectangle_left.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Forms/Callouts/Callout_rectangle_l0000644000175000017500000000574012206477313033121 0ustar mariomario Clipart by Nicu Buculei - segmented Nicu Buculei image/svg+xml ././@LongLink0000000000000000000000000000015100000000000011562 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Forms/Callouts/Callout_round_right.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Forms/Callouts/Callout_round_right0000644000175000017500000000655012206477313033166 0ustar mariomario Clipart by Nicu Buculei - segmented Nicu Buculei image/svg+xml ././@LongLink0000000000000000000000000000015000000000000011561 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Forms/Callouts/Callout_round_left.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Forms/Callouts/Callout_round_left.0000644000175000017500000000701512206477313033056 0ustar mariomario Clipart by Nicu Buculei - segmented Nicu Buculei image/svg+xml shutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Forms/Callouts/Callout_star.svg0000644000175000017500000001243212206477313032405 0ustar mariomario Clipart by Nicu Buculei - segmented Nicu Buculei image/svg+xml ././@LongLink0000000000000000000000000000015100000000000011562 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Forms/Callouts/Callout_star_center.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Forms/Callouts/Callout_star_center0000644000175000017500000001205312206477313033146 0ustar mariomario Clipart by Nicu Buculei - segmented Nicu Buculei image/svg+xml ././@LongLink0000000000000000000000000000016200000000000011564 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Forms/Callouts/Callout_ubuntu_center_bottom.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Forms/Callouts/Callout_ubuntu_cent0000644000175000017500000000664312206477313033200 0ustar mariomario Nicu Buculei image/svg+xml ././@LongLink0000000000000000000000000000014700000000000011567 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Forms/Callouts/Callout_star_left.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Forms/Callouts/Callout_star_left.s0000644000175000017500000001202512206477313033060 0ustar mariomario Clipart by Nicu Buculei - segmented Nicu Buculei image/svg+xml shutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Forms/Callouts/Callout_cloud.svg0000644000175000017500000001043012206477313032536 0ustar mariomario Clipart by Nicu Buculei - segmented Nicu Buculei image/svg+xml ././@LongLink0000000000000000000000000000015200000000000011563 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Forms/Callouts/Callout_round_center.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Forms/Callouts/Callout_round_cente0000644000175000017500000000726112206477313033147 0ustar mariomario Clipart by Nicu Buculei - segmented Nicu Buculei image/svg+xml ././@LongLink0000000000000000000000000000015500000000000011566 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Forms/Callouts/Callout_segmented_right.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Forms/Callouts/Callout_segmented_r0000644000175000017500000000713012206477313033131 0ustar mariomario Clipart by Nicu Buculei - segmented Nicu Buculei image/svg+xml ././@LongLink0000000000000000000000000000014700000000000011567 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Forms/Callouts/Callout_segmented.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Forms/Callouts/Callout_segmented.s0000644000175000017500000000656212206477313033061 0ustar mariomario Clipart by Nicu Buculei - segmented Nicu Buculei image/svg+xml ././@LongLink0000000000000000000000000000016600000000000011570 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Forms/Callouts/Callout_rounded_rectangle_center.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Forms/Callouts/Callout_rounded_rec0000644000175000017500000000676112206477313033137 0ustar mariomario Clipart by Nicu Buculei - segmented Nicu Buculei image/svg+xml ././@LongLink0000000000000000000000000000015600000000000011567 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Forms/Callouts/Callout_segmented_center.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Forms/Callouts/Callout_segmented_c0000644000175000017500000000665212206477313033122 0ustar mariomario Clipart by Nicu Buculei - segmented Nicu Buculei image/svg+xml ././@LongLink0000000000000000000000000000015200000000000011563 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Forms/Callouts/Callout_circle_right.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Forms/Callouts/Callout_circle_righ0000644000175000017500000000757012206477313033117 0ustar mariomario Clipart by Nicu Buculei - segmented Nicu Buculei image/svg+xml shutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/cssed.svg0000644000175000017500000031603312206477313026202 0ustar mariomario image/svg+xml bug-buddy 2007-11-02 Sebastian Kraft Sebastian Kraft de-DE bug-buddy bug-buddy icon for the Tango Desktop Project Sebastian Kraft shutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/stop-hand.svg0000644000175000017500000002077212206477313027000 0ustar mariomario shutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Cursors/0000755000175000017500000000000012206477313026012 5ustar mariomarioshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Cursors/Diagonal Resize 1.cur0000644000175000017500000001027612206477313031614 0ustar mariomario ¨( @ ÿÿÿÿÿÿÿÿÿÅÿáááÿáááÿáááÿáááÿáááÿáááÿÝÝÝÿÆÆÆÿÿJÿùùùÿ÷÷÷ÿ÷÷÷ÿ÷÷÷ÿ÷÷÷ÿïïïÿáááÿÿ>ÿþþþÿÿÿÿÿÿÿÿÿÿÿÿÿ÷÷÷ÿáááÿÿ~ÿûûûÿÿÿÿÿÿÿÿÿ÷÷÷ÿáááÿÿ333222€ÿÿÿÿÿÿÿÿÿûûûÿÿÿÿÿ÷÷÷ÿáááÿÿ AAA ¬¬¬ÝÝݬ¬¬AAAYÿÿÿÿÿÿÿÿÿáááÿÿþþþÿ÷÷÷ÿáááÿÿ.9?555*“““¯¯¯ “““Zÿÿÿÿÿÿÿÿÿáááÿÿˆÿùùùÿáááÿÿÿÿ‰LMMM.sss \ÿÿÿÿÿÿÿÿÿáááÿÿ €SSS>ÿáááÿÿÿáááÿÿƒPyÿÿÿÿÿÿÿÿÿáááÿÿgVVVÝÝÝJÿÿÿÿÿÿÿáááÿÿ ÿÿÿÿÿÿÿÿÿáááÿÿh333ÿÿÿÿÿÿÿÿÿáááÿÿÿÿÿÿÿÿÿÿáááÿÿiÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿáááÿÿxÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿ˜P.222ÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿáááÿÿƒL* ÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿáááÿÿ‰?ÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿáááÿÿ:¶ÿÿÿÿÿÿÿÿÿ2!ÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿüÿüÿþÿþÿþþþþþþþþÿþÿþÿþÿþÿþÿþÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Cursors/Normal.cur0000644000175000017500000001027612206477313027763 0ustar mariomario ¨( @ 1EC+*! ¤ÿÿ CÿBB'BÿÆÆÆÿØØØÿÿGÿÿ[JŽkkkÿøøøÿøøøÿö?ÿÐÐÐÿÿb£ÿøøøÿ°°°ÿÏ5ÿùùùÿÑÑÑÿÿ===ÿøøøÿøøøÿJJJÿ«:#ÿøøøÿøøøÿÑÑÑÿ¢¢¢ÿøøøÿÑÑÑÿÿdWL7ÿøøøÿøøøÿøøøÿøøøÿøøøÿ°°°ÿÿÿÿÿ@ÿøøøÿøøøÿøøøÿøøøÿøøøÿøøøÿøøøÿøøøÿÐÐÐÿÿ,ÿøøøÿøøøÿøøøÿøøøÿøøøÿøøøÿøøøÿÑÑÑÿÿlÿøøøÿøøøÿøøøÿøøøÿøøøÿøøøÿÑÑÑÿÿlÿøøøÿøøøÿøøøÿøøøÿøøøÿÑÑÑÿÿlÿøøøÿøøøÿøøøÿøøøÿÑÑÑÿÿlÿøøøÿøøøÿøøøÿÑÑÑÿÿlÿøøøÿøøøÿÑÑÑÿÿlÿøøøÿÑÑÑÿÿlÿÑÑÑÿÿkÿÿb–1ÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÆÿÿ€ÿÿ€ÿÿ€ÿÿ€ÿÿ€ÿÿ€ÿÿ€ÿÿ€ÿÿ€ÿÿ€ÿÿ€ÿÿ€ÿÿ€ÿÿ€ÿÿ€?ÿÿ€ÿÿ€ÿÿÿÿÿÿÃÿÿÿïÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Cursors/Precision.cur0000644000175000017500000001027612206477313030466 0ustar mariomario ¨( @ ÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿ6ÿÿÿEÿÿÿ6ÿÿÿÿÿÿÿÿÿEÿÿÿÿEÿÿÿÿÿÿÿÿÿEÿÿÿÿEÿÿÿÿÿÿÿÿÿEÿÿÿÿEÿÿÿÿÿÿÿÿÿÿÿÿEÿÿÿÿEÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿ;ÿÿÿEÿÿÿ;ÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿ6ÿÿÿEÿÿÿEÿÿÿEÿÿÿEÿÿÿ;ÿÿÿÿÿÿÿÿÿÿÿÿ;ÿÿÿEÿÿÿEÿÿÿEÿÿÿEÿÿÿ6ÿÿÿÿÿÿÿÿÿEÿÿÿÿÿÿÿEÿÿÿ²ÿÿÿÿÿÿEÿÿÿÿÿÿÿEÿÿÿÿÿÿÿÿÿ6ÿÿÿEÿÿÿEÿÿÿEÿÿÿEÿÿÿ;ÿÿÿÿÿÿÿÿÿÿÿÿ;ÿÿÿEÿÿÿEÿÿÿEÿÿÿEÿÿÿ6ÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿ;ÿÿÿEÿÿÿ;ÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿEÿÿÿÿEÿÿÿÿÿÿÿÿÿÿÿÿEÿÿÿÿEÿÿÿÿÿÿÿÿÿEÿÿÿÿEÿÿÿÿÿÿÿÿÿEÿÿÿÿEÿÿÿÿÿÿÿÿÿ6ÿÿÿEÿÿÿ6ÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿø?ÿÿø?ÿÿø?ÿÿø?ÿÿø?ÿÿðÿþÿþÿþÿþÿþÿÿðÿÿø?ÿÿø?ÿÿø?ÿÿø?ÿÿø?ÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Cursors/Vertical Resize.cur0000644000175000017500000001027612206477313031526 0ustar mariomario ¨( @ € pR3pÿpR3pÿÿpR3pÿïïïÿÿÿÿÿÜÜÜÿÿ“R3 mÿïïïÿÿÿÿÿÿÿÿÿïïïÿØØØÿÿ‘N/ kÿïïïÿÿÿÿÿÿÿÿÿÿÿÿÿ÷÷÷ÿóóóÿØØØÿÿ‘N,\ÿðððÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿòòòÿäääÿÓÓÓÿÿ@ÿÿÿÿÿÿÿÿÿÿÿÿÿûûûÿÿÿÿÿÿÿÿÿãããÿçççÿòòòÿâââÿÏÏÏÿÿ7ÿÿÿÿÿÿÿÿÿÿÿÿÿÏÏÏÿÿÿÿÿÿ ÿÿÿÿÿÿÿÿÿÏÏÏÿÿB6 ÿÿÿÿÿÿÿÿÿÏÏÏÿÿLÿÿÿÿÿÿÿÿÿÏÏÏÿÿNÿÿÿÿÿÿÿÿÿÏÏÏÿÿNÿÿÿÿÿÿÿÿÿÏÏÏÿÿNÿÿÿÿÿÿÿÿÿÏÏÏÿÿO  ÿÿÿÿÿÿÿÿÿÏÏÏÿÿV3 7JNÿÿÿÿÿÿÿÿÿÏÏÏÿÿdVOJ7ÿÿÿÿÿÿÿÿÿÿÿÿÿæææÿÿÿÿÿÿ@ÿóóóÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿîîîÿÞÞÞÿÁÁÁÿÿ,OÿóóóÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿîîîÿÞÞÞÿÁÁÁÿÿmRÿòòòÿÿÿÿÿÿÿÿÿÿÿÿÿîîîÿÞÞÞÿÁÁÁÿÿpdÿòòòÿÿÿÿÿÿÿÿÿîîîÿÁÁÁÿÿ€1OÿòòòÿÿÿÿÿÁÁÁÿÿ”OÿüüüÿÿmOÿmmÿÿÿÿÿÿÿÿÿþÿÿüÿÿøßÿñÿÿÿ€ÿÿÿÿÿÿ€ÿÿðÿÿðÿÿðÿÿðÿÿ€ÿÿÿÿÿÿ€ÿÿÿÿàÿÿðÿÿøÿÿü?ÿÿþÿÿÿÿÿÿÿÿÿÿÿÿÿshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Cursors/Horizontal Resize.cur0000644000175000017500000001027612206477313032106 0ustar mariomario ¨( @ €,@77@, ,mÿÿJÿÿN/uÿÈÈÈÿÿO" ÿÁÁÁÿÿ‘N/„ÿÓÓÓÿÜÜÜÿÿY  ÿÞÞÞÿÁÁÁÿÿ‘R/˜ÿØØØÿäääÿßßßÿÿl)BLNNNOÿîîîÿÞÞÞÿÁÁÁÿÿ“R/—ÿØØØÿóóóÿòòòÿäääÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿîîîÿÞÞÞÿÁÁÁÿÿ“R/—ÿÜÜÜÿïïïÿ÷÷÷ÿÿÿÿÿñññÿëëëÿÏÏÏÿÏÏÏÿÏÏÏÿÏÏÏÿÏÏÏÿÏÏÏÿÏÏÏÿÏÏÏÿÿÿÿÿÿÿÿÿÿÿÿÿîîîÿîîîÿÁÁÁÿÿ“R—ÿÞÞÞÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÞÞÞÿÿ“ÿïïïÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿîîîÿÿ““ÿïïïÿÿÿÿÿÿÿÿÿáááÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿîîîÿÿ“†ÿïïïÿÿÿÿÿáááÿÿNÿÿÿÿÿÿÿÿÿîîîÿÿpdÿðððÿáááÿÿJÿÿÿÿÿîîîÿÿmRÿÒÒÒÿÿ7ÿîîîÿÿkOÿÿÿÿ\ ÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿCð¿ÿà?ÿà?þà?ü?øðàààðøüþàÿà?ÿà?ÿCð¿ÿÿÿÿïÿÿóÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Cursors/Unavailable.cur0000644000175000017500000001027612206477313030756 0ustar mariomario ¨( @     +AA+ +AA+ hÿÿM/ kÿÿL+ Yÿ¼¼¼ÿ¼¼¼ÿÿPzÿ¼¼¼ÿ¼¼¼ÿÿAÿÿÿÿÿÿÿÿÿÿÿÿÿ¼¼¼ÿÿÿÛÛÛÿÿÿÿÿÿÿÿÿ¼¼¼ÿÿAÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿ¼¼¼ÿÿÛÛÛÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿ+ LÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿkOÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿz kÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿP0 hÿ¼¼¼ÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿ¼¼¼ÿÿM+ Yÿ¼¼¼ÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿ¼¼¼ÿÿAÿÛÛÛÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿ¼¼¼ÿÿAÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿkÿÿÿÿÿÿÿÿÿÿÿÿÿÛÛÛÿÿ+ LÿÿÿÿÿÿÿÿÿÿhOÿÿÿÿÿÿÿÿÿÿhLÿÿY LÿÿY ÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿáÃÿÿÀÿÿ€ÿÿÿÿÿÿ€ÿÿ€ÿÿ€ÿÿÿÿÿÿ€ÿÿÀÿÿáÃÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Cursors/Diagonal Resize 2.cur0000644000175000017500000001027612206477313031615 0ustar mariomario ¨( @ ¶ÿÿÿÿÿÿÿÿÿ?ÿÿÿÿÿÝÝÝÿáááÿáááÿáááÿáááÿáááÿáááÿÿ* ÿÿÿÿÿÿÿÿÿÿÿÿÿ÷÷÷ÿ÷÷÷ÿ÷÷÷ÿùùùÿÿh222ÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿm ! ÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿšX> ÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÝÝÝÿÿ 7(222333ÿÿÿÿÿÿÿÿÿÿÿÿÿÿþþþÿÿÿÿÿáááÿÿ}J+AAA¬¬¬ÝÝݬ¬¬AAA ÿÿÿÿÿùùùÿÿ~ÿÿÿÿÿÿÿÿÿáááÿÿƒL555,“““ÅÅÅ“““555*?ÿÿÿÿÿÿX“““NÿÿÿÿÿÿÿÿÿáááÿÿƒLMMM/sss hÿÿÿÿXAAA JÿÿÿÿÿÿÿÿÿáááÿÿQmÿáááÿÿKÿÿÿÿÿÿÿÿÿáááÿÿ ÿáááÿáááÿÿKÿÿÿÿÿÿÿÿÿáááÿÿáááÿùùùÿáááÿÿMÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿùùùÿáááÿÿ222tÿÿÿÿÿÿÿÿÿÿÿÿÿùùùÿáááÿÿ XÿáááÿÿÿÿÿÿÿÿÿÿÿÿÿùùùÿáááÿÿXÿáááÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿùùùÿáááÿÿÿõõõÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿõõõÿÿÿÿÿÿÿÿÿÿÿµÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿþÿþÿþÿþ?ÿþÿþþþþþþ<ÿþÿþÿþÿüÿüÿüÿøÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Cursors/Text.cur0000644000175000017500000001027612206477313027457 0ustar mariomario ¨( @ €‰ÿÿ¡ÿÿ‰ÿÿÿÿÿÑÑÑÿgggÿÑÑÑÿÿÿÿÿÿ‰ÿxxxÿÿÿÿÿxxxÿÿ‰‰ÿÿÿÿÿÿ‰ÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿ‰ÿÿÿÿÿÿ‰‰ÿ†††ÿÿÿÿÿ………ÿÿ‰ÿÿÿÿÿÓÓÓÿÿÚÚÚÿÿÿÿÿÿ‰ÿð¡êÿ‰ÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿøÿÿøÿÿøÿÿüÿÿþ?ÿÿþ?ÿÿþ?ÿÿþ?ÿÿþ?ÿÿþ?ÿÿüÿÿøÿÿøÿÿøÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Cursors/Help.cur0000644000175000017500000001027612206477313027423 0ustar mariomario ¨( @   )6'SÿwJ+Sÿ²²²ÿÿK+ Pÿìììÿãããÿ¥¥¥ÿÿJ( Bÿìììÿüüüÿüüüÿãããÿ¸¸¸ÿÿ{?ÿèèèÿüüüÿüüüÿüüüÿüüüÿãããÿ¸¸¸ÿÿ8ÿÿÿüüüÿüüüÿãããÿÿÿÿ! ÿãããÿüüüÿãããÿÿbI'ÿÌÌÌÿÿÿÿÿãããÿ|||ÿÿ]E)É   ÿÿÿÿÿÿÿÿÿæææÿ“““ÿáG$ Mÿœœœÿæææÿÿÿÿÿæææÿºººÿÿt57JLGkÍCCCÿ¯¯¯ÿÿÿÿÿæææÿ~~~ÿÀAÿÿÿÿÌK;eCCCÿÿÿÿÿæææÿ¥¥¥ÿÒEÿæææÿæææÿÏÏÏÿÿi;BÿÿÿÿÿÿÿÿÿÏÏÏÿÿAòüüüÿÿÿÿÿæææÿ[[[ÿi‚LLLÿÿÿÿÿÿÿÿÿÌÌÌÿÒ7ÏŸŸŸÿÿÿÿÿæææÿŸŸŸÿUUUÿÿCCCÿ´´´ÿÿÿÿÿÿÿÿÿœœœÿ·( NAAAÿìììÿÿÿÿÿæææÿÏÏÏÿÏÏÏÿÏÏÏÿÿÿÿÿÿÿÿÿÿÿÿÿ\\\ÿp¼ÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿƒƒƒÿÄÃcccÿÂÂÂÿüüüÿÿÿÿÿüüüÿáááÿ\\\ÿÁ}ÐóÿñÈ…ÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿþÿÿüÿÿøÿÿðÿÿàÿÿàÿÿàÿÿàÿÿðÿÿøÿÀ?ÿ€?ÿ€?ÿ€?ÿ€?ÿ€?ÿ€?ÿÀÿÀÿàÿÿðÿÿüÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Cursors/Link.cur0000644000175000017500000001027612206477313027430 0ustar mariomario ¨( @  4FLMMMMMMMMMLB) #¥ÿÿÿÿÿÿÿÿÿÿÿÿÿŽBštttÿÉÉÉÿÚÚÚÿÚÚÚÿÚÚÚÿÚÚÚÿÚÚÚÿÚÚÚÿÚÚÚÿÚÚÚÿÚÚÚÿÚÚÚÿÚÚÚÿ“““ÿÿLÿìììÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿìììÿìììÿÚÚÚÿÚÚÚÿÿMÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿìììÿìììÿÚÚÚÿÿMÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿìììÿÚÚÚÿÿMÿÿÿÿÿÿÿÿÿÀÀÀÿÿÿÿÿÉÉÉÿÚÚÚÿÿÿÿÿÉÉÉÿìììÿÿÿÿÿÉÉÉÿìììÿìììÿÚÚÚÿÿMÿãããÿÿÿÿÿÿÿÿÿÿÿÿÿÿÉÉÉÿÿÿÿÿÿÿÿÿÉÉÉÿÿÿÿÿÿÿÿÿÉÉÉÿÿÿÿÿÚÚÚÿÿLGÿÜÜÜÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÚÚÚÿÿBGÿÿÿÿÿÿÿÿÿÿvvvÿÿÿÿÿÿÿÿÿDDDÿÿÿÿÿÿÿÿÿXXXÿÿÿÿÿÚÚÚÿÿ( ÿÿÿÿÿÿÿÿÿ111ÿÉÉÉÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿV ÿÿÿÿÿÿÿÿÿÿÿÿVÿÿUÿÿÿÿÿÿÿÿÿÿLÿÿÿÿÿÿÿÿÿÿ?ÿÿÿÿÿÿÿÿÿÿ" Oÿÿ ÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÀÿ?ÿþþþþþþþÿÿ€ÿÀ?ÿÀÿÀÿÿÀ?ÿÿÀ?ÿÿàÿÿðÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Cursors/Alternate.cur0000644000175000017500000001027612206477313030452 0ustar mariomario ¨( @ +CE1 vÿÿ½M'  ÿáááÿ­­­ÿÿv;,(ñøøøÿËËËÿFFFÿ¦P=ÿÿ@º×××ÿøøøÿ|||ÿðcÿÐÐÐÿÿNTTTÿøøøÿÙÙÙÿ555ÿÿÑÑÑÿÐÐÐÿÿN7Lÿáááÿøøøÿ¢¢¢ÿÑÑÑÿøøøÿÐÐÐÿÿN´Úÿÿÿ¼¼¼ÿøøøÿøøøÿøøøÿøøøÿÐÐÐÿÿN&ÿøøøÿøøøÿøøøÿøøøÿøøøÿøøøÿøøøÿøøøÿÐÐÐÿÿNNÿøøøÿøøøÿøøøÿøøøÿøøøÿøøøÿøøøÿÐÐÐÿÿNOÿøøøÿøøøÿøøøÿøøøÿøøøÿøøøÿÐÐÐÿÿNOÿøøøÿøøøÿøøøÿøøøÿøøøÿÐÐÐÿÿNOÿøøøÿøøøÿøøøÿøøøÿÐÐÐÿÿNOÿøøøÿøøøÿøøøÿÐÐÐÿÿNOÿøøøÿøøøÿÐÐÐÿÿNOÿøøøÿÐÐÐÿÿKOÿÐÐÐÿÿ>Nÿÿ#,— ÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿøÿÿð1ÿÿàÿÿàÿÿàÿÿàÿÿÀÿÿ€ÿÿ€ÿÿ€ÿÿ€ÿÿÀÿÿàÿÿðÿÿøÿÿüÿÿþÿÿÿÿÿÿ€ÿÿÿÀÿÿÿáÿÿÿûÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Cursors/Move.cur0000644000175000017500000001027612206477313027441 0ustar mariomario ¨( @  4FMNNNNNNNNNMC) #¥ÿÿÿÿÿÿÿÿÿÿÿÿÿCštttÿÉÉÉÿÚÚÚÿÚÚÚÿÚÚÚÿÚÚÚÿÚÚÚÿÚÚÚÿÚÚÚÿÚÚÚÿÚÚÚÿÚÚÚÿÚÚÚÿÉÉÉÿÿMÿìììÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿìììÿìììÿÚÚÚÿÚÚÚÿÿNÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿìììÿìììÿÚÚÚÿÿNÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿìììÿÚÚÚÿÿNÿÿÿÿÿÿÿÿÿÀÀÀÿÿÿÿÿÉÉÉÿÚÚÚÿÿÿÿÿÉÉÉÿìììÿÿÿÿÿÉÉÉÿìììÿìììÿÚÚÚÿÿNÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÉÉÉÿÿÿÿÿÿÿÿÿÉÉÉÿÿÿÿÿÿÿÿÿÉÉÉÿÿÿÿÿÚÚÚÿÿNÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÚÚÚÿÿNÿëëëÿÓÓÓÿÿÿÿÿÿÿÿÿÿÀÀÀÿÿÿÿÿÿÿÿÿÀÀÀÿÿÿÿÿÿÿÿÿÀÀÀÿÿÿÿÿÚÚÚÿÿN‹ÿ½ÿÿÿÿÿÿÿÿÿ¦¦¦ÿÿÿÿÿÿÿÿÿ¦¦¦ÿÿÿÿÿÿÿÿÿ¦¦¦ÿÿÿÿÿÚÚÚÿÿLÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÚÚÚÿÿCÿÿÿÿÿÿÿÿÿLLLÿÿÿÿÿÿÿÿÿLLLÿÿÿÿÿÿÿÿÿLLLÿÿÿÿÿÚÚÚÿÿ) ÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿ^ ÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿ*Oÿÿÿÿÿÿÿÿÿÿÿÿÿÿ^ Pÿÿ\ÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿ€ÿþþ?ü?ü?ü?ü?ü?ü?ü?ü?ü?þ?ÿ?ÿ€?ÿ€ÿ€ÿÿÀÿÿàÿÿü?ÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Cursors/Handwriting.cur0000644000175000017500000001027612206477313031011 0ustar mariomario ¨( @ € ,(ÿ‡G+ÿÿI,ÿ€€€ÿÿ„L0:::ÿ¶¶¶ÿèèèÿÿOOO£N0"""ÿíííÿñññÿùùùÿÿJJJ£L,///ÿöööÿðððÿðððÿ÷÷÷ÿÿ666“D(((ÿðððÿíííÿèèèÿýýýÿÐÐÐÿÿU2²ÁÁÁÿóóóÿîîîÿåååÿýýýÿÿ)))£EV~~~þýýýÿòòòÿÛÛÛÿñññÿÑÑÑÿÿU2AAAÿàààÿ÷÷÷ÿãããÿòòòÿýýýÿÿ)))£G Q„„„üýýýÿóóóÿÜÜÜÿòòòÿÓÓÓÿÿV5...ÿÛÛÛÿøøøÿåååÿóóóÿøøøÿÿCCCºGQgggÿüüüÿôôôÿÝÝÝÿòòòÿÏÏÏÿÿU2ÿúúúöøøøÿæææÿóóóÿúúúÿÿ%%%£EGNNNÈÿÿÿÿüüüÿ÷÷÷ÿüüüÿÎÎÎÿÿU1ÿýýýûûûûÿòòòÿíííÿñññÿÿ"""£BGhhh¾üüüÿêêêÿÍÍÍÿäääÿzzzÿÿIÿ÷÷÷îãããÿÖÖÖÿÔÔÔÿ¹¹¹ÿÿHGPPP­úúúÿÜÜÜÿ½½½ÿŽŽŽÿÿ>ÿÉÉÉÔÁÁÁÿ¥¥¥ÿðÿ- Cÿÿÿÿ$ÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿƒÿÿÿÿÿÿ€ÿÿ€?ÿÿ€ÿÿ€ÿÿ€ÿÿ€ÿÿ€ÿÿÀÿÿÀÿÿÀÿÿàÿÿàÿÿðÿÿðÿÿøÿøÿüÿüÿþÿþÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/star.svg0000644000175000017500000000572512206477313026055 0ustar mariomario shutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/information-yellow.svg0000644000175000017500000004301612206477313030735 0ustar mariomario shutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/question.svg0000644000175000017500000001575212206477313026754 0ustar mariomario shutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/error.svg0000644000175000017500000002506312206477313026232 0ustar mariomario image/svg+xml Rodney Dawes Jakub Steiner, Garrett LeSage Dialog Error shutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/notice.svg0000644000175000017500000001215012206477313026353 0ustar mariomario shutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/0000755000175000017500000000000012206477312027757 5ustar mariomarioshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/MimeTypes/0000755000175000017500000000000012206477313031674 5ustar mariomario././@LongLink0000000000000000000000000000015500000000000011566 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/MimeTypes/text-html.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/MimeTypes/text-0000644000175000017500000021421112206477313032661 0ustar mariomario image/svg+xml HTML Document Jakub Steiner http://jimmac.musichall.cz HTML hypertext web ././@LongLink0000000000000000000000000000016200000000000011564 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/MimeTypes/font-x-generic.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/MimeTypes/font-0000644000175000017500000010472612206477313032654 0ustar mariomario image/svg+xml Generic font Andreas Nilsson the oxygen guys http://tango-project.org font type letter ././@LongLink0000000000000000000000000000016200000000000011564 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/MimeTypes/text-x-generic.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/MimeTypes/text-0000644000175000017500000005636712206477313032701 0ustar mariomario image/svg+xml Generic Text text plaintext regular document Jakub Steiner http://jimmac.musichall.cz ././@LongLink0000000000000000000000000000017300000000000011566 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/MimeTypes/application-certificate.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/MimeTypes/appli0000644000175000017500000003567412206477313032743 0ustar mariomario image/svg+xml CertificateJakub Steinercertificate ././@LongLink0000000000000000000000000000016100000000000011563 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/MimeTypes/text-x-script.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/MimeTypes/text-0000644000175000017500000005244712206477313032674 0ustar mariomario image/svg+xml Generic Script text plaintext regular script shell bash python perl php ruby Jakub Steiner http://jimmac.musichall.cz ././@LongLink0000000000000000000000000000017100000000000011564 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/MimeTypes/x-office-address-book.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/MimeTypes/x-off0000644000175000017500000005254712206477313032653 0ustar mariomario image/svg+xml Addess Book Jakub Steiner http://jimmac.musichall.cz address contact book office ././@LongLink0000000000000000000000000000017600000000000011571 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/MimeTypes/x-office-document-template.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/MimeTypes/x-off0000644000175000017500000011670412206477313032647 0ustar mariomario image/svg+xml Office Document rich text document pdf openoffice word rtf Jakub Steiner http://jimmac.musichall.cz ././@LongLink0000000000000000000000000000016300000000000011565 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/MimeTypes/video-x-generic.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/MimeTypes/video0000644000175000017500000003537112206477313032736 0ustar mariomario image/svg+xml Jakub Steiner http://jimmac.musichall.cz Generic Video video audio multimedia movie ././@LongLink0000000000000000000000000000020200000000000011557 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/MimeTypes/x-office-presentation-template.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/MimeTypes/x-off0000644000175000017500000012711012206477313032640 0ustar mariomario image/svg+xml Jakub Steiner http://jimmac.musichall.cz ././@LongLink0000000000000000000000000000016300000000000011565 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/MimeTypes/audio-x-generic.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/MimeTypes/audio0000644000175000017500000002135512206477313032726 0ustar mariomario image/svg+xml Generic Audio Jakub Steiner ././@LongLink0000000000000000000000000000016500000000000011567 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/MimeTypes/x-office-calendar.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/MimeTypes/x-off0000644000175000017500000012300512206477313032637 0ustar mariomario image/svg+xml Jakub Steiner http://jimmac.musichall.cz ././@LongLink0000000000000000000000000000017300000000000011566 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/MimeTypes/text-x-generic-template.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/MimeTypes/text-0000644000175000017500000007274412206477313032676 0ustar mariomario image/svg+xml Document Template template Jakub Steiner http://jimmac.musichall.cz ././@LongLink0000000000000000000000000000016500000000000011567 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/MimeTypes/package-x-generic.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/MimeTypes/packa0000644000175000017500000005131212206477313032700 0ustar mariomario image/svg+xml Package Jakub Steiner http://jimmac.musichall.cz/ package archive tarball tar bzip gzip zip arj tar jar ././@LongLink0000000000000000000000000000017400000000000011567 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/MimeTypes/application-x-executable.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/MimeTypes/appli0000644000175000017500000002312612206477313032730 0ustar mariomario image/svg+xml Executable Jakub Steiner http://jimmac.musichall.cz/ executable program binary bin script shell ././@LongLink0000000000000000000000000000017500000000000011570 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/MimeTypes/x-office-drawing-template.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/MimeTypes/x-off0000644000175000017500000011243712206477313032646 0ustar mariomario image/svg+xml Office Document rich text document pdf openoffice word rtf Jakub Steiner http://jimmac.musichall.cz ././@LongLink0000000000000000000000000000017100000000000011564 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/MimeTypes/x-office-presentation.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/MimeTypes/x-off0000644000175000017500000005623012206477313032644 0ustar mariomario image/svg+xml Jakub Steiner http://jimmac.musichall.cz ././@LongLink0000000000000000000000000000017000000000000011563 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/MimeTypes/x-office-spreadsheet.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/MimeTypes/x-off0000644000175000017500000006764512206477313032660 0ustar mariomario image/svg+xml Spreadsheet Jakub Steiner http://jimmac.musichall.cz spreadheet document office ././@LongLink0000000000000000000000000000016300000000000011565 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/MimeTypes/image-x-generic.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/MimeTypes/image0000644000175000017500000004644612206477313032717 0ustar mariomario image/svg+xml Genric Image Jakub Steiner imagepicturesnapshotphoto ././@LongLink0000000000000000000000000000016500000000000011567 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/MimeTypes/x-office-document.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/MimeTypes/x-off0000644000175000017500000006101612206477313032642 0ustar mariomario image/svg+xml Office Document rich text document pdf openoffice word rtf Jakub Steiner http://jimmac.musichall.cz ././@LongLink0000000000000000000000000000016400000000000011566 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/MimeTypes/x-office-drawing.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/MimeTypes/x-off0000644000175000017500000006460712206477313032653 0ustar mariomario image/svg+xml Office Document rich text document pdf openoffice word rtf Jakub Steiner http://jimmac.musichall.cz ././@LongLink0000000000000000000000000000020100000000000011556 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/MimeTypes/x-office-spreadsheet-template.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/MimeTypes/x-off0000644000175000017500000013216012206477313032641 0ustar mariomario image/svg+xml Spreadsheet Jakub Steiner http://jimmac.musichall.cz spreadheet document office shutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Apps/0000755000175000017500000000000012206477313030663 5ustar mariomario././@LongLink0000000000000000000000000000015400000000000011565 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Apps/internet-mail.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Apps/internet-m0000644000175000017500000004504412206477313032677 0ustar mariomario image/svg+xml Mail Jakub Steiner Andreas Nilsson mail e-mail MUA ././@LongLink0000000000000000000000000000016200000000000011564 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Apps/internet-group-chat.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Apps/internet-g0000644000175000017500000003735612206477313032700 0ustar mariomario image/svg+xml Group Chat Jakub Steiner group chat IRC internet network ././@LongLink0000000000000000000000000000017700000000000011572 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Apps/preferences-system-network-proxy.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Apps/preference0000644000175000017500000016352212206477313032735 0ustar mariomario image/svg+xml Globe Jakub Steiner Tuomas Kuosmanen http://jimmac.musichall.cz globe international web www internet network ././@LongLink0000000000000000000000000000016200000000000011564 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Apps/system-file-manager.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Apps/system-fil0000644000175000017500000003305712206477313032712 0ustar mariomario image/svg+xml File Manager Jakub Steiner http://jimmac.musichall.cz file manager copy move filesystem ././@LongLink0000000000000000000000000000015600000000000011567 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Apps/office-calendar.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Apps/office-cal0000644000175000017500000004323012206477313032600 0ustar mariomario image/svg+xml Calendar Jakub Steiner http://jimmac.musichall.cz calendar date time cal ././@LongLink0000000000000000000000000000017000000000000011563 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Apps/accessories-character-map.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Apps/accessorie0000644000175000017500000003676512206477313032747 0ustar mariomario image/svg+xml Jakub Steiner http://jimmac.musichall.cz Character Map key map character accessory ././@LongLink0000000000000000000000000000017600000000000011571 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Apps/preferences-desktop-screensaver.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Apps/preference0000644000175000017500000010362312206477313032731 0ustar mariomario image/svg+xml Screensacer Jakub Steiner video display screensaver saver http://jimmac.musichall.cz/ ././@LongLink0000000000000000000000000000015700000000000011570 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Apps/system-installer.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Apps/system-ins0000644000175000017500000005641612206477313032735 0ustar mariomario image/svg+xml System - Installer jakub Steiner http://jimmac.musichall.cz ././@LongLink0000000000000000000000000000016700000000000011571 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Apps/preferences-desktop-font.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Apps/preference0000644000175000017500000003557212206477313032740 0ustar mariomario image/svg+xml Jakub Steiner http://jimmac.musichall.cz Wi-Fi network ././@LongLink0000000000000000000000000000017100000000000011564 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Apps/preferences-desktop-locale.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Apps/preference0000644000175000017500000007450412206477313032736 0ustar mariomario image/svg+xml Jakub Steiner http://jimmac.musichall.cz Locale Preferences locale preferences ././@LongLink0000000000000000000000000000020500000000000011562 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Apps/preferences-desktop-keyboard-shortcuts.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Apps/preference0000644000175000017500000011612212206477313032727 0ustar mariomario image/svg+xml Jakub Steiner http://jimmac.musichall.cz Character Map key map character accessory ././@LongLink0000000000000000000000000000016300000000000011565 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Apps/internet-news-reader.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Apps/internet-n0000644000175000017500000004373512206477313032705 0ustar mariomario image/svg+xml News 2005-03-11 Jakub Steiner http://jimmac.musichall.cz/ news usenet new N E W S ././@LongLink0000000000000000000000000000017100000000000011564 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Apps/preferences-system-windows.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Apps/preference0000644000175000017500000003775312206477313032743 0ustar mariomario image/svg+xml Jakub Steiner http://jimmac.musichall.cz Windows window manager decoration behavior ././@LongLink0000000000000000000000000000020100000000000011556 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Apps/preferences-desktop-remote-desktop.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Apps/preference0000644000175000017500000022265412206477313032737 0ustar mariomario image/svg+xml Remote Desktop Jakub Steiner Tuomas Kuosmanen http://jimmac.musichall.cz vnc remote desktop control ././@LongLink0000000000000000000000000000016100000000000011563 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Apps/utilities-terminal.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Apps/utilities-0000644000175000017500000005143212206477313032703 0ustar mariomario image/svg+xml Terminal 2005-10-15 Andreas Nilsson terminal emulator term command line Jakub Steiner ././@LongLink0000000000000000000000000000016500000000000011567 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Apps/system-software-update.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Apps/system-sof0000644000175000017500000020237712206477313032732 0ustar mariomario image/svg+xml Software Update Jakub Steiner http://jimmac.musichall.cz network update software synchronize ././@LongLink0000000000000000000000000000016600000000000011570 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Apps/accessories-text-editor.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Apps/accessorie0000644000175000017500000006704212206477313032737 0ustar mariomario image/svg+xml Jakub Steiner http://jimmac.musichall.cz Text Editor ././@LongLink0000000000000000000000000000020700000000000011564 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Apps/preferences-desktop-assistive-technology.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Apps/preference0000644000175000017500000004645312206477313032740 0ustar mariomario image/svg+xml Jakub Steiner http://jimmac.musichall.cz Assistive Technology accessibility assist assistive technology ././@LongLink0000000000000000000000000000020000000000000011555 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Apps/preferences-desktop-accessibility.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Apps/preference0000644000175000017500000002554412206477313032736 0ustar mariomario image/svg+xml Jakub Steiner http://jimmac.musichall.cz Accessibility accessibility assist ././@LongLink0000000000000000000000000000015300000000000011564 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Apps/help-browser.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Apps/help-brows0000644000175000017500000003224012206477313032671 0ustar mariomario image/svg+xml Help Browser 2005-11-06 Tuomas Kuosmanen help browser documentation docs man info Jakub Steiner, Andreas Nilsson http://tigert.com ././@LongLink0000000000000000000000000000017400000000000011567 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Apps/preferences-desktop-wallpaper.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Apps/preference0000644000175000017500000011635712206477313032741 0ustar mariomario image/svg+xml Wallpaper Jakub Steiner wallpaper background http://jimmac.musichall.cz/ ././@LongLink0000000000000000000000000000017500000000000011570 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Apps/preferences-desktop-multimedia.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Apps/preference0000644000175000017500000005601612206477313032734 0ustar mariomario image/svg+xml Jakub Steiner http://jimmac.musichall.cz ././@LongLink0000000000000000000000000000017000000000000011563 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Apps/preferences-desktop-theme.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Apps/preference0000644000175000017500000013755212206477313032741 0ustar mariomario image/svg+xml Jakub Steiner http://jimmac.musichall.cz Themes skin color theme customize flavor ././@LongLink0000000000000000000000000000016500000000000011567 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Apps/accessories-calculator.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Apps/accessorie0000644000175000017500000007756612206477313032753 0ustar mariomario image/svg+xml Calculator Jakub Steiner calc calculator ././@LongLink0000000000000000000000000000016700000000000011571 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Apps/utilities-system-monitor.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Apps/utilities-0000644000175000017500000004757512206477313032720 0ustar mariomario image/svg+xml System Monitor 2005-10-10 Andreas Nilsson system monitor performance Jakub Steiner ././@LongLink0000000000000000000000000000017100000000000011564 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Apps/preferences-system-session.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Apps/preference0000644000175000017500000005521212206477313032731 0ustar mariomario image/svg+xml Jakub Steiner http://jimmac.musichall.cz Preferences Session session restart ././@LongLink0000000000000000000000000000016300000000000011565 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Apps/internet-web-browser.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Apps/internet-w0000644000175000017500000014256012206477313032712 0ustar mariomario image/svg+xml Globe Jakub Steiner Tuomas Kuosmanen http://jimmac.musichall.cz globe international web www internet network ././@LongLink0000000000000000000000000000015300000000000011564 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Apps/system-users.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Apps/system-use0000644000175000017500000006705512206477313032741 0ustar mariomario image/svg+xml People Jakub Steiner http://jimmac.musichall.cz users people shutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Status/0000755000175000017500000000000012206477313031243 5ustar mariomario././@LongLink0000000000000000000000000000017200000000000011565 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Status/weather-showers-scattered.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Status/weather-0000644000175000017500000057202012206477313032710 0ustar mariomario image/svg+xml weather-scattered-showers January 2006 Ryan collier (pseudo) http://www.tango-project.org http://www.pseudocode.org weather appplet notify ././@LongLink0000000000000000000000000000015600000000000011567 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Status/weather-storm.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Status/weather-0000644000175000017500000047365312206477313032724 0ustar mariomario image/svg+xml weather-storm January 2006 Ryan Collier http://www.tango-project.org http://www.pseudocode.org weather applet notify ././@LongLink0000000000000000000000000000015700000000000011570 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Status/dialog-warning.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Status/dialog-w0000644000175000017500000003352512206477313032701 0ustar mariomario image/svg+xml Dialog Warning 2005-10-14 Andreas Nilsson Jakub Steiner, Garrett LeSage dialog warning ././@LongLink0000000000000000000000000000016300000000000011565 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Status/dialog-information.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Status/dialog-i0000644000175000017500000013153412206477313032662 0ustar mariomario image/svg+xml Info Jakub Steiner dialog info http://jimmac.musichall.cz Garrett LeSage ././@LongLink0000000000000000000000000000016000000000000011562 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Status/battery-caution.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Status/battery-0000644000175000017500000006154012206477313032723 0ustar mariomario image/svg+xml Battery - Caution Jakub Steiner http://jimmac.musichall.cz battery apm acpi power management caution Garrett LeSage ././@LongLink0000000000000000000000000000015400000000000011565 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Status/folder-open.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Status/folder-o0000644000175000017500000006247712206477313032715 0ustar mariomario image/svg+xml Folder Icon Accept 2005-01-31 Jakub Steiner http://jimmac.musichall.cz Active state - when files are being dragged to. Novell, Inc. Garrett LeSage ././@LongLink0000000000000000000000000000015600000000000011567 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Status/image-missing.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Status/image-mi0000644000175000017500000003276012206477313032663 0ustar mariomario image/svg+xml Jakub Steiner http://jimmac.musichall.cz Broken Image image picture photo missing broken 404 Garrett LeSage ././@LongLink0000000000000000000000000000016000000000000011562 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Status/network-receive.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Status/network-0000644000175000017500000017244712206477313032753 0ustar mariomario image/svg+xml Computer 2005-03-08 Jakub Steiner workstation computer node client http://jimmac.musichall.cz/ ././@LongLink0000000000000000000000000000015500000000000011566 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Status/dialog-error.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Status/dialog-e0000644000175000017500000002560512206477313032657 0ustar mariomario image/svg+xml Rodney Dawes Jakub Steiner, Garrett LeSage Dialog Error ././@LongLink0000000000000000000000000000016000000000000011562 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Status/network-offline.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Status/network-0000644000175000017500000022047412206477313032745 0ustar mariomario image/svg+xml Computer 2005-03-08 Jakub Steiner workstation computer node client http://jimmac.musichall.cz/ ././@LongLink0000000000000000000000000000016000000000000011562 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Status/folder-visiting.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Status/folder-v0000644000175000017500000002233612206477313032712 0ustar mariomario image/svg+xml Folder Icon Accept 2005-01-31 Jakub Steiner http://jimmac.musichall.cz Active state - when files are being dragged to. Novell, Inc. Garrett LeSage ././@LongLink0000000000000000000000000000017100000000000011564 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Status/weather-few-clouds-night.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Status/weather-0000644000175000017500000052277412206477313032723 0ustar mariomario image/svg+xml weather-few-clouds-night January 2006 Ryan Collier (pseudo) http://www.tango-project.org http://www.pseudocode.org weather applet notify ././@LongLink0000000000000000000000000000016200000000000011564 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Status/audio-volume-high.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Status/audio-vo0000644000175000017500000007125612206477313032724 0ustar mariomario image/svg+xml Volume - High Jakub Steiner Lapo Calamandrei http://www.tango-project.org ././@LongLink0000000000000000000000000000017200000000000011565 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Status/software-update-available.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Status/software0000644000175000017500000002221612206477313033023 0ustar mariomario image/svg+xml Jakub Steiner http://jimmac.musichall.cz ././@LongLink0000000000000000000000000000016100000000000011563 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Status/network-transmit.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Status/network-0000644000175000017500000017211112206477313032737 0ustar mariomario image/svg+xml Computer 2005-03-08 Jakub Steiner workstation computer node client http://jimmac.musichall.cz/ ././@LongLink0000000000000000000000000000015600000000000011567 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Status/image-loading.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Status/image-lo0000644000175000017500000011257712206477313032675 0ustar mariomario image/svg+xml Loading Thumbnail thumbnail preview render wait load Jakub Steiner http://jimmac.musichall.cz Garrett LeSage ././@LongLink0000000000000000000000000000016300000000000011565 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Status/weather-few-clouds.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Status/weather-0000644000175000017500000011552212206477313032710 0ustar mariomario image/svg+xml weather-clear January 2006 Ryan Collier (pseudo) http://www.tango-project.org http://www.pseudocode.org weather applet notification Garrett LeSage ././@LongLink0000000000000000000000000000016700000000000011571 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Status/software-update-urgent.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Status/software0000644000175000017500000002037712206477313033031 0ustar mariomario image/svg+xml Jakub Steiner http://jimmac.musichall.cz ././@LongLink0000000000000000000000000000016000000000000011562 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Status/mail-attachment.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Status/mail-att0000644000175000017500000001610212206477313032676 0ustar mariomario image/svg+xml Mail Attachment 2005-11-04 Andreas Nilsson http://tango-project.org attachment file Garrett LeSage ././@LongLink0000000000000000000000000000015600000000000011567 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Status/weather-clear.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Status/weather-0000644000175000017500000012707712206477313032720 0ustar mariomario image/svg+xml weather-clear January 2006 Ryan Collier (pseudo) http://www.tango-project.org http://www.pseudocode.org weather applet notification Garrett LeSage ././@LongLink0000000000000000000000000000016100000000000011563 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Status/weather-overcast.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Status/weather-0000644000175000017500000034545512206477313032722 0ustar mariomario image/svg+xml weather-overcast January 2006 Ryan Collier (pseudo) http://www.tango-project.org http://www.pseudocode.org weather applet notify ././@LongLink0000000000000000000000000000015600000000000011567 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Status/printer-error.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Status/printer-0000644000175000017500000006664712206477313032751 0ustar mariomario image/svg+xml Printer Error Jakub Steiner http://jimmac.musichall.cz printer error cups lpd halt Andreas Nilsson ././@LongLink0000000000000000000000000000016100000000000011563 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Status/folder-visiting.iconshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Status/folder-v0000644000175000017500000000007112206477313032702 0ustar mariomario[Icon Data] AttachPoints=200,200|800,200|800,800|200,800 ././@LongLink0000000000000000000000000000016500000000000011567 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Status/weather-severe-alert.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Status/weather-0000644000175000017500000052300612206477313032710 0ustar mariomario image/svg+xml weather-severe-alert January 2006 Ryan Collier (pseudo) http://www.tango-project.org http://www.pseudocode.org weather applet notify ././@LongLink0000000000000000000000000000015500000000000011566 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Status/weather-snow.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Status/weather-0000644000175000017500000024670012206477313032713 0ustar mariomario image/svg+xml weather-snow January 2006 Ryan Collier (pseudo) http://www.tango-project.org http://www.pseudocode.org weather applet notification ././@LongLink0000000000000000000000000000016400000000000011566 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Status/folder-drag-accept.iconshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Status/folder-d0000644000175000017500000000007112206477313032660 0ustar mariomario[Icon Data] AttachPoints=200,200|800,200|800,800|200,800 ././@LongLink0000000000000000000000000000017100000000000011564 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Status/network-transmit-receive.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Status/network-0000644000175000017500000017124112206477313032742 0ustar mariomario image/svg+xml Computer 2005-03-08 Jakub Steiner workstation computer node client http://jimmac.musichall.cz/ ././@LongLink0000000000000000000000000000015600000000000011567 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Status/network-error.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Status/network-0000644000175000017500000022451112206477313032741 0ustar mariomario image/svg+xml Computer 2005-03-08 Jakub Steiner workstation computer node client http://jimmac.musichall.cz/ ././@LongLink0000000000000000000000000000015500000000000011566 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Status/network-idle.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Status/network-0000644000175000017500000021325612206477313032745 0ustar mariomario image/svg+xml Computer 2005-03-08 Jakub Steiner workstation computer node client http://jimmac.musichall.cz/ ././@LongLink0000000000000000000000000000016300000000000011565 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Status/folder-drag-accept.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Status/folder-d0000644000175000017500000006322312206477313032670 0ustar mariomario image/svg+xml Folder Icon Accept 2005-01-31 Jakub Steiner http://jimmac.musichall.cz Active state - when files are being dragged to. Novell, Inc. Garrett LeSage ././@LongLink0000000000000000000000000000016000000000000011562 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Status/weather-showers.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Status/weather-0000644000175000017500000052673712206477313032726 0ustar mariomario image/svg+xml weather-showers January 2006 Ryan collier (pseudo) http://www.tango-project.org http://www.pseudocode.org weather appplet notify ././@LongLink0000000000000000000000000000016100000000000011563 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Status/audio-volume-low.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Status/audio-vo0000644000175000017500000006734412206477313032727 0ustar mariomario image/svg+xml Volume - Low Jakub Steiner Lapo Calamandrei http://www.tango-project.org volume sound level low ././@LongLink0000000000000000000000000000017300000000000011566 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Status/network-wireless-encrypted.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Status/network-0000644000175000017500000012453612206477313032747 0ustar mariomario image/svg+xml Jakub Steiner http://jimmac.musichall.cz Novell AppArmor apparmor novell Garrett LeSage ././@LongLink0000000000000000000000000000016400000000000011566 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Status/weather-clear-night.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Status/weather-0000644000175000017500000023447012206477313032714 0ustar mariomario image/svg+xml weather-clear-night January 2006 Ryan Collier (pseudo) http://www.tango-project.org http://www.pseudocode.org weather applet notification ././@LongLink0000000000000000000000000000016300000000000011565 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Status/audio-volume-muted.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Status/audio-vo0000644000175000017500000011605712206477313032723 0ustar mariomario image/svg+xml Volume - Muted Jakub Steiner Lapo Calamandrei http://www.tango-project.org volume sound level none mute muted ././@LongLink0000000000000000000000000000016400000000000011566 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Status/audio-volume-medium.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Status/audio-vo0000644000175000017500000007050012206477313032713 0ustar mariomario image/svg+xml Volume - Medium Jakub Steiner Lapo Calamandrei http://www.tango-project.org volume sound level medium ././@LongLink0000000000000000000000000000016000000000000011562 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Status/user-trash-full.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Status/user-tra0000644000175000017500000012552512206477313032742 0ustar mariomario image/svg+xml Trash Full 2003-02-03 Jakub Steiner trash delete deleted files waste recycle bin full Novell, Inc. shutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Emblems/0000755000175000017500000000000012206477313031344 5ustar mariomario././@LongLink0000000000000000000000000000015700000000000011570 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Emblems/emblem-system.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Emblems/emblem-0000644000175000017500000002460512206477313032614 0ustar mariomario image/svg+xml Jakub Steiner http://jimmac.musichall.cz Emblem System emblem system library crucial base ././@LongLink0000000000000000000000000000016300000000000011565 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Emblems/emblem-unreadable.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Emblems/emblem-0000644000175000017500000003301012206477313032602 0ustar mariomario image/svg+xml Jakub Steiner http://jimmac.musichall.cz Unreadable emblem access denied unreadable ././@LongLink0000000000000000000000000000016600000000000011570 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Emblems/emblem-symbolic-link.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Emblems/emblem-0000644000175000017500000002400512206477313032606 0ustar mariomario image/svg+xml Jakub Steiner http://jimmac.musichall.cz Symbolic Link emblem symbolic link pointer io file ././@LongLink0000000000000000000000000000016100000000000011563 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Emblems/emblem-readonly.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Emblems/emblem-0000644000175000017500000003002412206477313032604 0ustar mariomario image/svg+xml Jakub Steiner http://jimmac.musichall.cz Read Only Emblem emblem read-only nowrite ././@LongLink0000000000000000000000000000016200000000000011564 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Emblems/emblem-important.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Emblems/emblem-0000644000175000017500000001737012206477313032615 0ustar mariomario image/svg+xml Emblem Important Jakub Steiner emblem photos pictures raw jpeg ././@LongLink0000000000000000000000000000016100000000000011563 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Emblems/emblem-favorite.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Emblems/emblem-0000644000175000017500000002371212206477313032612 0ustar mariomario image/svg+xml Favourites (emblem) 2005-02-01 Jakub Steiner http://jimmac.musichall.cz/ Andreas Nilsson <nisses.mail@home.se> ././@LongLink0000000000000000000000000000015700000000000011570 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Emblems/emblem-photos.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Emblems/emblem-0000644000175000017500000006532612206477313032621 0ustar mariomario image/svg+xml Emblem Photos Jakub Steiner emblem photos pictures raw jpeg 800 shutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/0000755000175000017500000000000012206477313031360 5ustar mariomario././@LongLink0000000000000000000000000000016000000000000011562 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/system-log-out.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/system-0000644000175000017500000004526712206477313032722 0ustar mariomario image/svg+xml Jakub Steiner http://jimmac.musichall.cz System Log Out log out logout exit ././@LongLink0000000000000000000000000000015500000000000011566 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/media-eject.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/media-e0000644000175000017500000003625612206477313032620 0ustar mariomario image/svg+xml Media Playback Start Jakub Steiner media eject ././@LongLink0000000000000000000000000000015400000000000011565 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/edit-clear.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/edit-cl0000644000175000017500000004605312206477313032634 0ustar mariomario image/svg+xml Edit Clear Andreas Nilsson http://www.tango-project.org clear reset blank edit Jakub Steiner (although minimally ;) ././@LongLink0000000000000000000000000000015600000000000011567 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/document-new.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/documen0000644000175000017500000004177612206477313032754 0ustar mariomario image/svg+xml New Document Jakub Steiner http://jimmac.musichall.cz ././@LongLink0000000000000000000000000000015300000000000011564 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/edit-find.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/edit-fi0000644000175000017500000010512412206477313032627 0ustar mariomario image/svg+xml Edit Find edit find locate search Steven Garrity Jakub Steiner ././@LongLink0000000000000000000000000000017300000000000011566 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/format-text-strikethrough.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/format-0000644000175000017500000003427512206477313032663 0ustar mariomario image/svg+xml Strikeout 2006-01-04 Lapo Calamandrei http://tango-project.org text a strikeout strike-out write letter ././@LongLink0000000000000000000000000000016200000000000011564 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/mail-message-new.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/mail-me0000644000175000017500000004747112206477313032641 0ustar mariomario image/svg+xml Mail New Jakub Steiner Andreas Nilsson, Steven Garrity mail e-mail MUA ././@LongLink0000000000000000000000000000015300000000000011564 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/go-bottom.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/go-bott0000644000175000017500000002276512206477313032672 0ustar mariomario image/svg+xml Jakub Steiner http://jimmac.musichall.cz Go to Bottom go bottom Andreas Nilsson ././@LongLink0000000000000000000000000000016600000000000011570 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/media-playback-pause.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/media-p0000644000175000017500000005517312206477313032632 0ustar mariomario image/svg+xml Media Playback Pause Lapo Calamandrei media pause playback video music Jakub Steiner ././@LongLink0000000000000000000000000000015300000000000011564 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/edit-redo.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/edit-re0000644000175000017500000002216312206477313032640 0ustar mariomario image/svg+xml Jakub Steiner http://jimmac.musichall.cz Edit Redo edit redo again reapply ././@LongLink0000000000000000000000000000017000000000000011563 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/document-print-preview.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/documen0000644000175000017500000010202512206477313032735 0ustar mariomario image/svg+xml Print Preview Jakub Steiner http://jimmac.musichall.cz printer local laser bubblejet inkjet print output cups lpd preview Corey Woodworth ././@LongLink0000000000000000000000000000015400000000000011565 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/folder-new.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/folder-0000644000175000017500000005707612206477313032652 0ustar mariomario image/svg+xml New Folder Jakub Steiner http://jimmac.musichall.cz folder directory create new Tuomas Kuosmanen ././@LongLink0000000000000000000000000000016200000000000011564 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/address-book-new.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/address0000644000175000017500000005472012206477313032740 0ustar mariomario image/svg+xml Addess Book - New Jakub Steiner http://jimmac.musichall.cz address contact book ././@LongLink0000000000000000000000000000015600000000000011567 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/view-refresh.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/view-re0000644000175000017500000004074412206477313032672 0ustar mariomario image/svg+xml Jakub Steiner http://jimmac.musichall.cz View Refresh reload refresh view ././@LongLink0000000000000000000000000000016500000000000011567 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/media-skip-backward.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/media-s0000644000175000017500000010635712206477313032636 0ustar mariomario image/svg+xml Media Skip Backward Lapo Calamandrei Jakub Steiner ././@LongLink0000000000000000000000000000016700000000000011571 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/format-justify-center.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/format-0000644000175000017500000003204012206477313032647 0ustar mariomario image/svg+xml Justify Center 2005-10-29 Andreas Nilsson justify center format ././@LongLink0000000000000000000000000000016100000000000011563 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/system-shutdown.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/system-0000644000175000017500000004125012206477313032706 0ustar mariomario image/svg+xml Jakub Steiner http://jimmac.musichall.cz System Shutdown poweroff shutdown halt system ././@LongLink0000000000000000000000000000015200000000000011563 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/edit-cut.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/edit-cu0000644000175000017500000005501312206477313032641 0ustar mariomario image/svg+xml Edit Cut Garrett Le Sage edit cut clipboard Jakub Steiner ././@LongLink0000000000000000000000000000015700000000000011570 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/document-open.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/documen0000644000175000017500000007412512206477313032746 0ustar mariomario image/svg+xml Folder Icon Accept 2005-01-31 Jakub Steiner http://jimmac.musichall.cz Active state - when files are being dragged to. Novell, Inc. ././@LongLink0000000000000000000000000000015700000000000011570 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/system-search.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/system-0000644000175000017500000003660512206477313032716 0ustar mariomario image/svg+xml Jakub Steiner http://jimmac.musichall.cz ././@LongLink0000000000000000000000000000015600000000000011567 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/bookmark-new.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/bookmar0000644000175000017500000007146212206477313032747 0ustar mariomario image/svg+xml New Bookmark bookmark remember favorite Andreas Nilsson Jakub Steiner create bookmark action ././@LongLink0000000000000000000000000000015100000000000011562 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/go-jump.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/go-jump0000644000175000017500000001766212206477313032675 0ustar mariomario image/svg+xml Jakub Steiner http://jimmac.musichall.cz Go Jump go jump seek arrow pointer ././@LongLink0000000000000000000000000000016500000000000011567 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/media-playback-stop.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/media-p0000644000175000017500000005172212206477313032626 0ustar mariomario image/svg+xml Media Playback Pause Lapo Calamandrei media stop playback video music Jakub Steiner ././@LongLink0000000000000000000000000000015600000000000011567 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/media-record.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/media-r0000644000175000017500000002721012206477313032623 0ustar mariomario image/svg+xml Media Record Lapo Calamandrei media player record music sound video ././@LongLink0000000000000000000000000000015500000000000011566 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/contact-new.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/contact0000644000175000017500000017626112206477313032753 0ustar mariomario image/svg+xml Jakub Steiner http://jimmac.musichall.cz New Contact address contact e-mail person information card ././@LongLink0000000000000000000000000000015600000000000011567 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/mail-forward.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/mail-fo0000644000175000017500000011027112206477313032631 0ustar mariomario image/svg+xml Mail Jakub Steiner Andreas Nilsson mail e-mail MUA ././@LongLink0000000000000000000000000000015400000000000011565 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/window-new.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/window-0000644000175000017500000002660312206477313032676 0ustar mariomario image/svg+xml New Window Corey Woodworth http://jimmac.musichall.cz Jakub Steiner new insert window ././@LongLink0000000000000000000000000000016000000000000011562 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/document-print.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/documen0000644000175000017500000005544512206477313032752 0ustar mariomario image/svg+xml Print Document Jakub Steiner http://jimmac.musichall.cz document lpr print local laser bubblejet inkjet print output cups lpd ././@LongLink0000000000000000000000000000016500000000000011567 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/document-properties.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/documen0000644000175000017500000006152012206477313032741 0ustar mariomario image/svg+xml Document Properties document settings preferences properties tweak Jakub Steiner http://jimmac.musichall.cz ././@LongLink0000000000000000000000000000014700000000000011567 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/go-up.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/go-up.s0000644000175000017500000002003212206477313032570 0ustar mariomario image/svg+xml Jakub Steiner http://jimmac.musichall.cz Go Up go higher up arrow pointer > Andreas Nilsson ././@LongLink0000000000000000000000000000015100000000000011562 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/go-next.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/go-next0000644000175000017500000001734012206477313032671 0ustar mariomario image/svg+xml Jakub Steiner http://jimmac.musichall.cz Go Next go next right arrow pointer > ././@LongLink0000000000000000000000000000016400000000000011566 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/system-lock-screen.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/system-0000644000175000017500000007522512206477313032717 0ustar mariomario image/svg+xml Lock Screen Jakub Steiner video display lock screen password session screensaver http://jimmac.musichall.cz/ ././@LongLink0000000000000000000000000000015300000000000011564 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/edit-copy.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/edit-co0000644000175000017500000003635312206477313032641 0ustar mariomario image/svg+xml Edit Copy 2005-10-15 Andreas Nilsson edit copy Jakub Steiner ././@LongLink0000000000000000000000000000015600000000000011567 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/process-stop.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/process0000644000175000017500000002750212206477313032767 0ustar mariomario image/svg+xml Stop 2005-10-16 Andreas Nilsson stop halt error Jakub Steiner ././@LongLink0000000000000000000000000000015200000000000011563 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/list-add.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/list-ad0000644000175000017500000003473012206477313032647 0ustar mariomario image/svg+xml Add 2006-01-04 Andreas Nilsson http://tango-project.org add plus ././@LongLink0000000000000000000000000000016300000000000011565 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/mail-reply-sender.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/mail-re0000644000175000017500000005702212206477313032637 0ustar mariomario image/svg+xml Mail Reply Garrett LeSage Jakub Steiner, Andreas Nilsson mail e-mail reply sender ././@LongLink0000000000000000000000000000016500000000000011567 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/format-justify-left.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/format-0000644000175000017500000002560012206477313032653 0ustar mariomario image/svg+xml Justify Left 2005-10-29 Andreas Nilsson justify left ././@LongLink0000000000000000000000000000015300000000000011564 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/edit-undo.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/edit-un0000644000175000017500000002202312206477313032647 0ustar mariomario image/svg+xml Jakub Steiner http://jimmac.musichall.cz Edit Undo edit undo revert ././@LongLink0000000000000000000000000000016100000000000011563 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/view-fullscreen.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/view-fu0000644000175000017500000004750712206477313032702 0ustar mariomario image/svg+xml Jakub Steiner http://jimmac.musichall.cz View Fullscreen ././@LongLink0000000000000000000000000000016200000000000011564 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/format-text-bold.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/format-0000644000175000017500000002531112206477313032652 0ustar mariomario image/svg+xml Bold 2006-01-04 Lapo Calamandrei http://tango-project.org text a bold write letter Andreas Nilsson ././@LongLink0000000000000000000000000000016100000000000011563 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/appointment-new.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/appoint0000644000175000017500000004223712206477313032765 0ustar mariomario image/svg+xml Jakub Steiner http://jimmac.musichall.cz New Appointment appointment new meeting rvsp ././@LongLink0000000000000000000000000000016600000000000011570 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/media-playback-start.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/media-p0000644000175000017500000002571612206477313032632 0ustar mariomario image/svg+xml Media Playback Start Lapo Calamandrei play media music video player Jakub Steiner ././@LongLink0000000000000000000000000000015200000000000011563 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/go-first.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/go-firs0000644000175000017500000002121012206477313032645 0ustar mariomario image/svg+xml Jakub Steiner http://jimmac.musichall.cz Go Previous go previous left arrow pointer < Andreas Nilsson ././@LongLink0000000000000000000000000000015500000000000011566 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/go-previous.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/go-prev0000644000175000017500000006742312206477313032676 0ustar mariomario image/svg+xml Jakub Steiner http://jimmac.musichall.cz Go Previous go previous left arrow pointer < ././@LongLink0000000000000000000000000000016600000000000011570 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/format-justify-right.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/format-0000644000175000017500000003210612206477313032652 0ustar mariomario image/svg+xml Justify Right 2005-10-29 Andreas Nilsson justify left format ././@LongLink0000000000000000000000000000016000000000000011562 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/mail-reply-all.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/mail-re0000644000175000017500000013400112206477313032630 0ustar mariomario image/svg+xml Mail Reply All Jakub Steiner Andreas Nilsson, Garrett LeSage mail e-mail reply all ././@LongLink0000000000000000000000000000015700000000000011570 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/document-save.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/documen0000644000175000017500000007230612206477313032745 0ustar mariomario image/svg+xml Save Jakub Steiner hdd hard drive save io store http://jimmac.musichall.cz ././@LongLink0000000000000000000000000000016200000000000011564 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/document-save-as.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/documen0000644000175000017500000007625112206477313032750 0ustar mariomario image/svg+xml Save As Jakub Steiner hdd hard drive save as io store http://jimmac.musichall.cz ././@LongLink0000000000000000000000000000016400000000000011566 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/format-indent-more.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/format-0000644000175000017500000003363412206477313032661 0ustar mariomario image/svg+xml Indent More Jakub Steiner indent more http://jimmac.musichall.cz ././@LongLink0000000000000000000000000000016100000000000011563 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/edit-select-all.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/edit-se0000644000175000017500000003703712206477313032647 0ustar mariomario image/svg+xml Select All Andreas Nilsson select all ././@LongLink0000000000000000000000000000015500000000000011566 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/list-remove.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/list-re0000644000175000017500000003273612206477313032675 0ustar mariomario image/svg+xml Remove 2006-01-04 Andreas Nilsson http://tango-project.org remove delete ././@LongLink0000000000000000000000000000015500000000000011566 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/edit-delete.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/edit-de0000644000175000017500000015321612206477313032626 0ustar mariomario image/svg+xml Delete Jakub Steiner edit delete shredder Novell, Inc. ././@LongLink0000000000000000000000000000015100000000000011562 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/go-home.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/go-home0000644000175000017500000005167512206477313032654 0ustar mariomario image/svg+xmlGo HomeJakub Steinerhttp://jimmac.musichall.czhomereturngodefaultuserdirectoryTuomas Kuosmanen ././@LongLink0000000000000000000000000000016400000000000011566 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/media-skip-forward.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/media-s0000644000175000017500000010564512206477313032635 0ustar mariomario image/svg+xml Media Skip Forward Lapo Calamandrei Jakub Steiner ././@LongLink0000000000000000000000000000016700000000000011571 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/format-text-underline.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/format-0000644000175000017500000003436712206477313032665 0ustar mariomario image/svg+xml Format Text - Underlined Lapo Calamandrei http://tango-project.org text a strikeout strike-out write letter strike-though jakub Steiner ././@LongLink0000000000000000000000000000015000000000000011561 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/go-top.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/go-top.0000644000175000017500000010031212206477313032563 0ustar mariomario image/svg+xml Jakub Steiner http://jimmac.musichall.cz Go Top go highest top arrow pointer > Andreas Nilsson ././@LongLink0000000000000000000000000000016400000000000011566 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/media-seek-forward.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/media-s0000644000175000017500000003460112206477313032626 0ustar mariomario image/svg+xml Media Seek Forward Lapo Calamandrei Jakub Steiner ././@LongLink0000000000000000000000000000016400000000000011566 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/format-indent-less.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/format-0000644000175000017500000003377412206477313032666 0ustar mariomario image/svg+xml Unindent Jakub Steiner indent less unindent Andreas Nilsson ././@LongLink0000000000000000000000000000016500000000000011567 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/media-seek-backward.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/media-s0000644000175000017500000003370612206477313032633 0ustar mariomario image/svg+xml Media Seek Backward Lapo Calamandrei ././@LongLink0000000000000000000000000000016000000000000011562 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/mail-mark-junk.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/mail-ma0000644000175000017500000005436712206477313032637 0ustar mariomario image/svg+xml Jakub Steiner http://jimmac.musichall.cz Mark mail as Junk mail spam junk ././@LongLink0000000000000000000000000000016500000000000011567 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/format-justify-fill.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/format-0000644000175000017500000003202412206477313032651 0ustar mariomario image/svg+xml Justify Center 2005-10-29 Andreas Nilsson justify center format ././@LongLink0000000000000000000000000000016400000000000011566 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/format-text-italic.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/format-0000644000175000017500000002604612206477313032660 0ustar mariomario image/svg+xml Italic 2006-01-04 Lapo Calamandrei http://tango-project.org text a italic cursive write letter ././@LongLink0000000000000000000000000000016300000000000011565 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/edit-find-replace.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/edit-fi0000644000175000017500000013147012206477313032632 0ustar mariomario image/svg+xml Edit Find Replace edit find locate search Garrett LeSage Jakub Steiner, Steven Garrity ././@LongLink0000000000000000000000000000015100000000000011562 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/tab-new.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/tab-new0000644000175000017500000003112612206477313032643 0ustar mariomario image/svg+xml New Tab 2005-10-29 Andreas Nilsson tab new Jakub Steiner ././@LongLink0000000000000000000000000000015100000000000011562 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/go-last.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/go-last0000644000175000017500000002115012206477313032650 0ustar mariomario image/svg+xml Jakub Steiner http://jimmac.musichall.cz Go Next go next right arrow pointer > Andreas Nilsson ././@LongLink0000000000000000000000000000015100000000000011562 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/go-down.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/go-down0000644000175000017500000002021412206477313032654 0ustar mariomario image/svg+xml Jakub Steiner http://jimmac.musichall.cz Go Down go lower down arrow pointer > Andreas Nilsson ././@LongLink0000000000000000000000000000015400000000000011565 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/edit-paste.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/edit-pa0000644000175000017500000005631312206477313032636 0ustar mariomario image/svg+xml Edit Paste 2005-10-10 Andreas Nilsson edit paste Jakub Steiner ././@LongLink0000000000000000000000000000016300000000000011565 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/mail-send-receive.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Actions/mail-se0000644000175000017500000013224512206477313032641 0ustar mariomario image/svg+xml Send and Receive Mail Jakub Steiner Andreas Nilsson, Garrett LeSage mail e-mail send receive shutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Devices/0000755000175000017500000000000012206477313031342 5ustar mariomario././@LongLink0000000000000000000000000000015600000000000011567 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Devices/camera-photo.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Devices/camera-0000644000175000017500000011141212206477313032572 0ustar mariomario image/svg+xml Jakub Steiner http://jimmac.musichall.cz Photo Camera camera photo SLR ././@LongLink0000000000000000000000000000016200000000000011564 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Devices/network-wireless.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Devices/network0000644000175000017500000003522512206477313032765 0ustar mariomario image/svg+xml Jakub Steiner http://jimmac.musichall.cz Wi-Fi network ././@LongLink0000000000000000000000000000015600000000000011567 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Devices/media-floppy.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Devices/media-f0000644000175000017500000003367612206477313032606 0ustar mariomario image/svg+xml Media Floppy Tuomas Kuosmanen http://www.tango-project.org save document store file io floppy media Jakub Steiner ././@LongLink0000000000000000000000000000015200000000000011563 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Devices/computer.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Devices/compute0000644000175000017500000011005112206477313032737 0ustar mariomario image/svg+xml Computer 2005-03-08 Jakub Steiner workstation computer node client http://jimmac.musichall.cz/ ././@LongLink0000000000000000000000000000015100000000000011562 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Devices/battery.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Devices/battery0000644000175000017500000003763012206477313032750 0ustar mariomario image/svg+xml Battery Jakub Steiner http://jimmac.musichall.cz battery apm acpi power management ././@LongLink0000000000000000000000000000016000000000000011562 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Devices/input-keyboard.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Devices/input-k0000644000175000017500000012753612206477313032672 0ustar mariomario image/svg+xml Input - Keyboard Jakub Steiner input keyboard keys peripheral HID http://jimmac.musichall.cz/ ././@LongLink0000000000000000000000000000015500000000000011566 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Devices/input-mouse.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Devices/input-m0000644000175000017500000003366512206477313032673 0ustar mariomario image/svg+xml Input - Mouse Jakub Steiner http://jimmac.musichall.cz mouse input device HID pointer ././@LongLink0000000000000000000000000000017000000000000011563 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Devices/audio-input-microphone.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Devices/audio-i0000644000175000017500000012442312206477313032622 0ustar mariomario image/svg+xml Jakub Steiner http://jimmac.musichall.cz Microphone mic mike microphone input audio record voice ././@LongLink0000000000000000000000000000016000000000000011562 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Devices/drive-harddisk.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Devices/drive-h0000644000175000017500000005657012206477313032640 0ustar mariomario image/svg+xml Drive - Hard Disk Jakub Steiner hdd hard drive fixed media solid http://jimmac.musichall.cz ././@LongLink0000000000000000000000000000015700000000000011570 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Devices/network-wired.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Devices/network0000644000175000017500000005066412206477313032771 0ustar mariomario image/svg+xml Jakub Steiner http://jimmac.musichall.cz Network ././@LongLink0000000000000000000000000000015100000000000011562 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Devices/printer.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Devices/printer0000644000175000017500000005352312206477313032760 0ustar mariomario image/svg+xml Printer Jakub Steiner http://jimmac.musichall.cz printer local laser bubblejet inkjet print output cups lpd ././@LongLink0000000000000000000000000000016700000000000011571 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Devices/drive-removable-media.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Devices/drive-r0000644000175000017500000004475212206477313032651 0ustar mariomario image/svg+xml Drive - Removable Jakub Steiner media removable http://jimmac.musichall.cz ././@LongLink0000000000000000000000000000015700000000000011570 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Devices/drive-optical.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Devices/drive-o0000644000175000017500000005673312206477313032650 0ustar mariomario image/svg+xml Drive - CD-ROM Jakub Steiner cdrom cd-rom optical drive http://jimmac.musichall.cz ././@LongLink0000000000000000000000000000015700000000000011570 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Devices/media-optical.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Devices/media-o0000644000175000017500000007060312206477313032606 0ustar mariomario image/svg+xml Media CD-ROM Jakub Steiner http://jimmac.musichall.cz cdrom media removable cd audio ././@LongLink0000000000000000000000000000015400000000000011565 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Devices/audio-card.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Devices/audio-c0000644000175000017500000006302312206477313032612 0ustar mariomario image/svg+xml Audio Card Audio Card Device http://jimmac.musichall.cz Jakub Steiner sound audio card device ././@LongLink0000000000000000000000000000015600000000000011567 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Devices/input-gaming.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Devices/input-g0000644000175000017500000007155212206477313032662 0ustar mariomario image/svg+xml Input - Gaming Jakub Steiner gaming controller joystick game gaming HID http://jimmac.musichall.cz ././@LongLink0000000000000000000000000000015500000000000011566 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Devices/media-flash.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Devices/media-f0000644000175000017500000006540312206477313032577 0ustar mariomario image/svg+xml Jakub Steiner http://jimmac.musichall.cz Generic Flash Media flash memory removable photo Novell, Inc., Jakub Steiner ././@LongLink0000000000000000000000000000015700000000000011570 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Devices/video-display.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Devices/video-d0000644000175000017500000005701412206477313032623 0ustar mariomario image/svg+xml Video Display Jakub Steiner video display monitor LCD CRT http://jimmac.musichall.cz/ ././@LongLink0000000000000000000000000000015600000000000011567 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Devices/camera-video.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Devices/camera-0000644000175000017500000020550612206477313032602 0ustar mariomario image/svg+xml Camera / Video Jakub Steiner http://jimmac.musichall.cz/ camera camcorder video cam ././@LongLink0000000000000000000000000000016300000000000011565 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Devices/multimedia-player.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Devices/multime0000644000175000017500000013751412206477313032754 0ustar mariomario image/svg+xml Jakub Steiner http://jimmac.musichall.cz http://www.tango-project.org Multimedia PLayer mp3 player shutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Categories/0000755000175000017500000000000012206477313032045 5ustar mariomario././@LongLink0000000000000000000000000000017500000000000011570 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Categories/applications-development.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Categories/appl0000644000175000017500000003633012206477313032731 0ustar mariomario image/svg+xml Henrik Andersen Developer Tools developer dev tool make compile build code hacker Jakub Steiner http://jimmac.musichall.cz ././@LongLink0000000000000000000000000000017500000000000011570 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Categories/applications-accessories.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Categories/appl0000644000175000017500000006552712206477313032743 0ustar mariomario image/svg+xmlGo Homejakub Steinerhttp://jimmac.musichall.czhomereturngodefaultuserdirectory ././@LongLink0000000000000000000000000000017200000000000011565 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Categories/applications-internet.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Categories/appl0000644000175000017500000007550712206477313032742 0ustar mariomario image/svg+xml Internet Category Jakub Steiner Tuomas Kuosmanen http://jimmac.musichall.cz internet tools applications category ././@LongLink0000000000000000000000000000017000000000000011563 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Categories/applications-system.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Categories/appl0000644000175000017500000003744412206477313032740 0ustar mariomario image/svg+xml System Applications Jakub Steiner http://jimmac.musichall.cz/ system applications group category admin root ././@LongLink0000000000000000000000000000017000000000000011563 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Categories/applications-office.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Categories/appl0000644000175000017500000007657712206477313032752 0ustar mariomario image/svg+xml Jakub Steiner http://jimmac.musichall.cz Office Applications office applications category ././@LongLink0000000000000000000000000000016700000000000011571 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Categories/applications-other.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Categories/appl0000644000175000017500000003610012206477313032724 0ustar mariomario image/svg+xml Other applications Jakub Steiner http://jimmac.musichall.cz/ category applications other unspecified ././@LongLink0000000000000000000000000000016700000000000011571 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Categories/applications-games.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Categories/appl0000644000175000017500000003302212206477313032724 0ustar mariomario image/svg+xml Games Andreas Nilsson games Jakub Steiner ././@LongLink0000000000000000000000000000020400000000000011561 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Categories/preferences-desktop-peripherals.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Categories/pref0000644000175000017500000011272412206477313032733 0ustar mariomario image/svg+xml Jakub Steiner http://jimmac.musichall.cz Desktop Peripherals Preferences tablet mouse desktop preferences settings control center peripherals ././@LongLink0000000000000000000000000000017400000000000011567 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Categories/applications-multimedia.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Categories/appl0000644000175000017500000006671612206477313032744 0ustar mariomario image/svg+xml Multimedia Category Jakub Steiner http://jimmac.musichall.cz video multimedia category ././@LongLink0000000000000000000000000000016700000000000011571 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Categories/preferences-system.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Categories/pref0000644000175000017500000004537612206477313032743 0ustar mariomario image/svg+xml Jakub Steiner http://jimmac.musichall.cz Preferences System preferences settings control panel tweaks system ././@LongLink0000000000000000000000000000017200000000000011565 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Categories/applications-graphics.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Categories/appl0000644000175000017500000006414312206477313032734 0ustar mariomario image/svg+xml Graphics Category Jakub Steiner graphics category pixel vector editor draw paint http://tango-project.org ././@LongLink0000000000000000000000000000017000000000000011563 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Categories/preferences-desktop.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Categories/pref0000644000175000017500000007330212206477313032731 0ustar mariomario image/svg+xml Jakub Steiner http://jimmac.musichall.cz Desktop Preferences preferences system category shutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Places/0000755000175000017500000000000012206477313031167 5ustar mariomario././@LongLink0000000000000000000000000000015300000000000011564 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Places/start-here.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Places/start-he0000644000175000017500000004765112206477313032656 0ustar mariomario image/svg+xml Jakub Steiner http://jimmac.musichall.cz Start Here To be replaced by vendor/distribution branding. start applications launchers Garrett LeSage ././@LongLink0000000000000000000000000000015200000000000011563 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Places/user-home.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Places/user-hom0000644000175000017500000006361712206477313032666 0ustar mariomario image/svg+xml Home Folder Icon Jakub Steiner http://jimmac.musichall.cz folder directory home user Garrett LeSage ././@LongLink0000000000000000000000000000015300000000000011564 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Places/user-trash.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Places/user-tra0000644000175000017500000005664612206477313032675 0ustar mariomario image/svg+xml Trash Empty 2003-02-04 Jakub Steiner trash delete deleted files waste recycle bin empty Novell, Inc. Garrett LeSage ././@LongLink0000000000000000000000000000015700000000000011570 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Places/network-server.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Places/network-0000644000175000017500000012160112206477313032661 0ustar mariomario image/svg+xml Server Jakub Steiner http://jimmac.musichall.cz server daemon comupetr lan service provider Garrett LeSage ././@LongLink0000000000000000000000000000016400000000000011566 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Places/folder-saved-search.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Places/folder-s0000644000175000017500000006674412206477313032646 0ustar mariomario image/svg+xml Home Folder Icon Jakub Steiner http://jimmac.musichall.cz folder directory home user Garrett LeSage ././@LongLink0000000000000000000000000000016200000000000011564 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Places/network-workgroup.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Places/network-0000644000175000017500000023377112206477313032675 0ustar mariomario image/svg+xml Workgroup Jakub Steiner http://jimmac.musichall.cz lan workgroup network peer Garrett LeSage ././@LongLink0000000000000000000000000000015500000000000011566 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Places/user-desktop.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Places/user-des0000644000175000017500000005112112206477313032641 0ustar mariomario image/svg+xml Desktop Jakub Steiner http://jimmac.musichall.cz Desktop location. desktop storage files default location Garrett LeSage ././@LongLink0000000000000000000000000000015600000000000011567 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Places/folder-remote.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Places/folder-r0000644000175000017500000007610712206477313032637 0ustar mariomario image/svg+xml Folder Icon Jakub Steiner http://jimmac.musichall.cz folder directory Andreas Nilsson ././@LongLink0000000000000000000000000000014700000000000011567 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Places/folder.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Places/folder.s0000644000175000017500000005452512206477313032641 0ustar mariomario image/svg+xml Folder Icon Jakub Steiner http://jimmac.musichall.cz folder directory ././@LongLink0000000000000000000000000000015000000000000011561 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Places/folder.iconshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Places/folder.i0000644000175000017500000000006712206477313032617 0ustar mariomario[Icon Data] AttachPoints=200,800|800,800|800,80|200,80 shutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Emotes/0000755000175000017500000000000012206477313031214 5ustar mariomario././@LongLink0000000000000000000000000000015200000000000011563 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Emotes/face-kiss.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Emotes/face-kis0000644000175000017500000004166012206477313032630 0ustar mariomario image/svg+xml Face - Kiss emoticon emote smiley kiss :-* :* Jakub Steiner http://jimmac.musichall.cz Lapo Calamandrei ././@LongLink0000000000000000000000000000015300000000000011564 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Emotes/face-smile.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Emotes/face-smi0000644000175000017500000002617212206477313032633 0ustar mariomario image/svg+xml Face - Happy emoticon emote smiley happy :) :-) Jakub Steiner http://jimmac.musichall.cz ././@LongLink0000000000000000000000000000015600000000000011567 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Emotes/face-surprise.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Emotes/face-sur0000644000175000017500000002543512206477313032655 0ustar mariomario image/svg+xml Face - Shocked emoticon emote smiley stare shocked :O Jakub Steiner http://jimmac.musichall.cz ././@LongLink0000000000000000000000000000015100000000000011562 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Emotes/face-sad.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Emotes/face-sad0000644000175000017500000002616712206477313032616 0ustar mariomario image/svg+xml Face - Sad emoticon emote smiley sad :( :-( Jakub Steiner http://jimmac.musichall.cz ././@LongLink0000000000000000000000000000015400000000000011565 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Emotes/face-crying.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Emotes/face-cry0000644000175000017500000004102512206477313032632 0ustar mariomario image/svg+xml Face - Crying emoticon emote smiley crying :~( Jakub Steiner http://jimmac.musichall.cz ././@LongLink0000000000000000000000000000015600000000000011567 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Emotes/face-devilish.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Emotes/face-dev0000644000175000017500000004617712206477313032630 0ustar mariomario image/svg+xml Face - Devil Grin emoticon emote smiley laugh grin >:-D >:D Jakub Steiner http://jimmac.musichall.cz Tuomas Kuosmanen ././@LongLink0000000000000000000000000000015300000000000011564 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Emotes/face-plain.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Emotes/face-pla0000644000175000017500000003014312206477313032610 0ustar mariomario image/svg+xml Face - Plain emoticon emote face plain :| :-| Steven Garrity http://www.tango-project.org Based on face-smile by jimmac ././@LongLink0000000000000000000000000000015400000000000011565 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Emotes/face-monkey.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Emotes/face-mon0000644000175000017500000004450612206477313032635 0ustar mariomario image/svg+xml Ulisse Perusin emote-monkey emoticons monkey 18/05/2006 ././@LongLink0000000000000000000000000000015200000000000011563 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Emotes/face-wink.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Emotes/face-win0000644000175000017500000002660012206477313032634 0ustar mariomario image/svg+xml Face - Wink emoticon emote winkie wink ;) ;-) Jakub Steiner http://jimmac.musichall.cz Corey Woodworth ././@LongLink0000000000000000000000000000015700000000000011570 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Emotes/face-smile-big.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Emotes/face-smi0000644000175000017500000002541012206477313032625 0ustar mariomario image/svg+xml Face - Laughing emoticon emote smiley laughing :-D :D Jakub Steiner http://jimmac.musichall.cz ././@LongLink0000000000000000000000000000015200000000000011563 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Emotes/face-grin.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Emotes/face-gri0000644000175000017500000003240212206477313032615 0ustar mariomario image/svg+xml Face - Laughing emoticon emote smiley laughing :-D :D Jakub Steiner http://jimmac.musichall.cz Tuomas Kuosmanen ././@LongLink0000000000000000000000000000015500000000000011566 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Emotes/face-glasses.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Emotes/face-gla0000644000175000017500000004334012206477313032602 0ustar mariomario image/svg+xml Face - Happy emoticon emote smiley happy :) :-) Jakub Steiner http://jimmac.musichall.cz ././@LongLink0000000000000000000000000000015300000000000011564 Lustar rootrootshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Emotes/face-angel.svgshutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/Tango icon library/Emotes/face-ang0000644000175000017500000003640112206477313032604 0ustar mariomario image/svg+xml Face - Angel emoticon emote smiley angel 0:) 0:-) Jakub Steiner http://jimmac.musichall.cz Corey Woodworth shutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/apply.svg0000644000175000017500000011111712206477313026222 0ustar mariomario image/svg+xml Jakub Steiner http://jimmac.musichall.cz Dialog ok ok sure set apply Andreas Nilsson shutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/tux.svg0000644000175000017500000037670412206477313025734 0ustar mariomario image/svg+xml Tux May 2007 F.Bellaiche <frederic.bellaiche@gmail.com> shutter-0.90.1/share/shutter/resources/icons/drawing_tool/objects/important-red.svg0000644000175000017500000001022612206477313027661 0ustar mariomario shutter-0.90.1/share/shutter/resources/icons/drawing_tool/draw-pointer.png0000644000175000017500000000141612206477313026044 0ustar mariomario‰PNG  IHDRÄ´l;sBIT|dˆtEXtSoftwarewww.inkscape.org›î< IDAT8µÕMH”AðÿÌûéjzèËBM­¬"ŠB*ˆ „ˆ°"‰ÌÖ„‚ˆÖÄC&©ÛîêE :Eavʰ",+(Ô½$Š¡•{©B×ÝØ÷c×wŸ½ &n°¹ < ÌÌ󛇙aD„ÿÑøbƒ^Ÿ»çf[sYÚa•+’úÐçsïI+ 5çj¹ ‰<ž–]i…U5c…³º– ²üØÝæÞ™6˜ˆˆsžã<[âõ¶ìH º®C„•ÕUN“KâSŸ¯u{Z*E†a@ÅÜÓ§ª4Æ…g§tI0c ‚ @†I’òOž¨ sÏ[ÛZ·.會1MÓ IRñ±£A¬ßÝî.ùW˜h"l¼¤üð‘"á…×Û¼1e˜ˆþàœÃ4M¨ªZz`ÿÁïŒ /}¾æ¢ÅòÅd°eYdYˆ¢ø{Y,ƒicÁàŒ6;ä’¬(QSïp(ñxœsèºþEÓ´H8.xÝ¿.öcCœð &S­"#£ï'üþ¡üìì*Û»O,,(š˜ü4¡Õ»î$ËþrÆ¡Pèãý÷"~ÿЈ¡Æ6LÏL‡Á0’—WPÈ«lêlZþ/0uußuü …_u5œo¼ØæŒuŒÂáp¬Z»&÷³jHgR†9°ÛÐbÛêêÞ$ÆôH´{*0µ^Q”¯›7mq€á–T^ø¬<1@`Ùõ×Ú^ ºu»sª¾ÞU Ëž—°DnÒËcŒIöb€@|;Ü“•™é”%yÐÔÍÂx|®À;sb¢Œ1“ˆæX²?φU;»—¯¸.]–eeõ‡‰É®¾Þ¾1æ¼ÐhDDIag»byÞ@t`‘•ÈýÊ0³øØ"JIEND®B`‚shutter-0.90.1/share/shutter/resources/icons/drawing_tool/draw-ellipse.png0000644000175000017500000000167712206477313026032 0ustar mariomario‰PNG  IHDRàw=øbKGDÿÿÿ ½§“tIDATxÚí•Ûke‡ŸïMvödºÝ˜Ö µ-´©±‰ x*h‹ThQ°(B "zQñBPzá•à?à? ^l­Bi za-â¡ÖØM¶¡»Y“ì9»Él&3;3^d6ÙÍÉzç ßÍ;Ãïùæ=üþ¿ µ‹ç­§5¼ çÔÀ™7V¢ )%Ï*QÇ”’½žç–]ÇI¹ ë‡zµðÅô#¿+€³Hm~ã¨:?ê?røåÓÏy‚P$Š‹†¦­—Ŷ-ŠÅcã?‘NNÌþqcd©˜ðo~(7ýHmpÖ  èMè?Ñußá3z4Þ†÷‰ˆ¸ŽmئQX®•¦Ë3·Çk¹»SÀ<0Ì ­f§¶°o Ð=@·¿4]@èl® °ì;gɯwÕÏmk×[‚¾°î‹7{æøÓÝõç_ÿeþçñ¢AaÃT—_IEND®B`‚shutter-0.90.1/share/shutter/resources/icons/drawing_tool/draw-freehand.png0000644000175000017500000000146412206477313026143 0ustar mariomario‰PNG  IHDRÄ´l;sBIT|dˆtEXtSoftwarewww.inkscape.org›î<ÆIDAT8­ÓËKTQðï½sgæ:yÝER ” ‘ÀR |D«ÜE‘J RVD€ ­ÜÔÂUM«íŠp-ÇìA´Hl¢ÒI »£ÍÜÛxçÕ"…Ñ™|dÎâ,~¾¿ß9BüÝZ_¬äž%!6²Ú´– _¾Bß#×G_T·ì ¥lo,Žôž­š·b„;2(ît×¹íMÅ}JÜѤEÊËÊ/]=wC K€X ,>ˆ Sç-Il‘ÿÝ_yèòé®ë*S4 †‡! @ÁuÃMZ¤$¬õÔ=œ¦1À9: ãî‹:~ôGuË[¼ˆv¶6‡J¤q%zAÝ,¥¥¸W–¡Ï‚ÞGÊå_P5è‡9ñÔ6‘1ï#ãpþÄï}"TÔEu˰¶ËËC“1¸ó¼ùd#i0’Ê8Ÿ ‡¢º•^¬Y5ñJèøŒKæ~Ñ/„‰Ú\tU¸£I‹„ÃÅ=-Ç— ¯6’†Kæ,:¾€þ\^ûWxíji©jfrî|¯6& Ìštb¡ý¹BõáÂh#mL¥\š²h’0q0ª[³ –÷ÜÎ4j]áÍ›þ´¿]@éÊhÁÄ~EºxêôñP ÈsbN6W Ó³.MeèäBÒÔJhÜÖ í wo¯¨?¼ ÄËâùƒÇøþÓcF†N&j¢ºe¬†æB’pò@õ^™“,¼ô7¨[÷!eqf¤É"úc-h^â€"uì?Ò0¦Ç0úîzùqFÞ&NDukf­(óóÚ´]¾VV×Úcïã¦èg7£º5¹°|^ñáp–*·ÆÜŠ·2|*ó<Õ'˪,I ç\f>‘ˆ¬p‡ a«œÛš¦eèr8wÆý·ŸZ§ TéÜ ¹²ãxE„s…qÎeð4uÇ.„.Iü¿×o™W0C†Ì¶IEND®B`‚shutter-0.90.1/share/shutter/resources/icons/drawing_tool/draw-line.png0000644000175000017500000000041012206477313025304 0ustar mariomario‰PNG  IHDRàw=øbKGDÿÿÿ ½§“½IDATxÚÕÕ¿‚0Çñï•8±8ø„Í÷!e0(Xp9C@ûç:غ|~½Bî ðª ˜¸eãŒñ05p¤2Æ/@££3Æ[`¼ÌÎ=Ðé{vÀ~ú-B¸ÿü¥Šá©ÁxJ@Ç$á¡ÉxH@þ+ ÿ`‚ï˜á[ó`ÁÏÀ‹¯+mP¶Ü¸éÓ§6,YUSG»œ“ïÍäYÅ]ï*5°…Yoùl‚e3óÀIEND®B`‚shutter-0.90.1/share/shutter/resources/icons/drawing_tool/draw-rectangle.png0000644000175000017500000000061212206477313026325 0ustar mariomario‰PNG  IHDRÚ}\ˆbKGDùC»?IDATxÚµ•1NÃPDßl¢ ‚6gà"œ„‚#@‹è‰–+p‘Ô”–"²D‘’Ø4û‰±ÿwbbV²ü·™ù3^ÏÂ?—çX¿MUÍ^42kG‚ (°Ê€ÑéÙùbH[¦Owà˜gÀàöê‚|Vtši’!’¼2ó3\Þ<L€ø ¶Ï ¦Ï/ql™ù£Ú¹Ý{ï@a›¼^ƒ«ö»—«ñÚ÷o*Û8fÁ™?ñ¾¡à‡©“ ëÆ©¾F Nk€í¬ ŠZ8)ß㶤­i(H´'&vû´¢N‚¾S´ ßÄôRóó/V¥ ŒÞ³Ê« Á—…ˆ½¾2ï>eˆëÏŽ pìÕ~”¾U:ø«‡Ý›<3#g;îƒ%0q]_8ãÎ*,œ&˜úUb…_ßÒÒ92»“{IEND®B`‚shutter-0.90.1/share/shutter/resources/icons/drawing_tool/transform-crop.png0000644000175000017500000000215412206477313026405 0ustar mariomario‰PNG  IHDRÄ´l;bKGDÿÿÿ ½§“ pHYs  šœtIMEÕ 2&ÂÙùIDAT8Ë­”mh[UÇÿçÜ›››&iš¦íÚ¢Ýâ@º±²Ž‚6Ðá7­/æi†Ö$¬?( "Š£R ‚_™ÎM+’¦)N³-Õ½›nVZú¢4«K“Øä†6/÷&¹÷¿¤Úú²†êçËy8¿óãá°ÃÕ×ßKn×§Øùªºxé» IJÿ¸¯¿·9šzvÿ¾ý6’”ÿ3¸¯¿·-šz)à.Bl,Ì’”0í|â9ï¡ÐÔÇPN¥’6%¯4°0%)!JR‚W.ôñîãG2™Ì7PI¥’úôOÓÊèØˆ¶òÎ=N™RZ _¾r[[XYÆ]m…BáRÀ4¤RÉÚÅÅ…¦……yg§ËÝèpز’«P¾6>ÔþÈ_ÀdÀ„$%TI’LW'®5{ô˜œI§u³ÅÂ[ÌVQVdõPk[½ÛãR†‡æËîøƒH&WSªªÚ¿½ÀŽÞwÔÆQι‹Íwï³î¨v{\€/ °(¥ö¹ù945í& üìüLÕ]ν‚ ÕÕ5un+ àå¡ÁaiÛTôø¼{4€¢( „`˜›! »ê VK¥µºº¦Éíqí%„œ^ÞV³ÇçŸz¦;12záFgWcŒ±x<Æff§ÙRø&I Æc]Ú“O?qoÙ$ŸÏ¿úÊköZ¶·?·Ç…ºº]X_O³l&«Ûí¸=.8÷§g?û¾¬Ìú^<ñüé3§Ôt:Í–n.²ÉëרÀçgÙ†yÉ”õõ÷>üo ò#¸‡îbß;ýÂj2Šœœ…ªje«ñUœûò2™,***îÿäÌÀ8¶í'ÔãóÖ‹êÈÛoV“q$¥Òé 2™ *­6BÑÚzH·VZÖx—*ß(²©þŒ[ÏË Å«o¼þ¦9'ç‹Ga6™áÜÝEV‡Y‰èkëk*Ïñ#ËËË¿0”Œ7—¾Ìóü»]®ãÎÚšZʘ0 ›Ëá£Ó§ ‘•[Z>ŸÿUQòc‘[‘÷ÆFÆc¥cÂ_€: €Î—lÓ5ý…ÇÐ&'ô¡àP!'gsL×odsòÀÜìÜ•ëS?J%+ mž­@-í”ôø¼ÍéõÌ´QŠ<ÏOéºîEc_u> €Z­Ñ  ”RÊû¦Õ‚ªªšªª „h”ãr¢Ñ¨QJX¡PÔxõÖJKËï8¿q[ivÔ(9£QТ‘UÕ4Ž£ „0•ç5MUuè<ÏQžç5Aôb±¨#·‰àßzUv1™D"Šâ–ˆ)ŠÂ¢+ñ-{¿m‡ãÛdñIEND®B`‚shutter-0.90.1/share/shutter/resources/icons/drawing_tool/draw-backtext.png0000644000175000017500000000214412206477313026170 0ustar mariomario‰PNG  IHDRÄ´l;sRGB®ÎébKGDÿÿÿ ½§“ pHYs  šœtIMEÛ 2‚Ä'äIDAT8Ë••ßk\EÇ?3÷ÞÝ{77©Ùf»[|ó‹„Å`±¥VŒ¥ ¾´}óÁ-¶ä±ÿ€¢ Pô¥ >‹¥ µy°H R‹ÒÒ†&ÛfK7û{oîÞé;>Äl·í¦Õ/Ã8Ÿ™9sÎ ˜­ô|'„0–e=")¥yÞ¶š¯0`Øb¸–u÷³ãÇ_عsgg̓Rй¹¹p5þ€½½|í­ öï>—Ïç¹téZkâ8FkÍÈÈ“““ö—//Ÿ5æÿÇùôÀ^±XD)õøæÍ›äóyç8´÷qÙ Ú€o„oOMMÉ••”RDQD»ÝF)E¥R!Š"\ו¿Á™^ŒžàmpcÏž=¦^¯Ól6QJ±¸¸ÏÏχJ)”R4 rù|ÿûR¾øŸÁ¶m›™™ñnß¾Í&¨°¼*¥L¹\îÜÀ÷}î3Áµg‚ìÍårÙÁÁAŠÅ"QQ*•Z¯5æL±XT››i­ñ}?ù.?lÛö'ûöíË,//EJ)îܹœH’‹ßÂK•JÅl®+¥Èd2Þ×0ûTp  !MLLÈ¥¥%”R„aH¥R‘Gàâ¼î³T­VQJÇ1®ë"¤ì_„Ÿ¶;pjzzšZ­F½^G)E©TbFá4ÀIcþ¨ÕjëÆ<¬+` ó.¤·[–ul÷îÝÞ­[·:´vÿ~ã”1+ Ô¨ 3ívÛÑZ?û¾\„7X},àµÁÁÁ\6›¥;whí„÷,ð-ð]D7ز,\×Õ_Áùo³WXRþ8;;{Ø÷}yõêU´Ö¤R)¦§§{Vf¡P P(tìõõuš¥ÒF:%ÀªâÑÑQyá”R!‚€……„O€ã8~Äö<²”»JIòkÞ´¾„óãããGWWW©×ë!hµZ”J¥x#J½GŸç…C;vøB|ßw7•‹›1>!Äþ±±±Ìõë×;N­F£ùœÖÐꥰ„¡“$I÷#Úó©!ïÂ9o` ¯µ¦V« µ&Œ¢ÔxK¶^²á嬅aØÝI;ŽùÎÊC †r9¯Z­âºÝ/ C¶ qEBöß4+'p¿Ke qÒ˜kAÆ6Õ×ß4á!ÝI?ßù6¨ôÐ  Â+ V¢Wá ¾®Ð›¬&jkTÛÐjAЄ¨Qâ5H*`Z€dA Üös}.øi²aøñ?o=ÐlÌA ‚õÚmˆ ˜48)H¥ cƒgƒ/ÁúäÆÉm€ç})2Ü=IEND®B`‚shutter-0.90.1/share/shutter/resources/icons/drawing_tool/draw-number.png0000644000175000017500000000102712206477313025652 0ustar mariomario‰PNG  IHDRÄ´l;sBIT|dˆ pHYsrrL’–ÎtEXtSoftwarewww.inkscape.org›î<”IDAT8µÕ½ŠSQÀñß„m´2+l+kg•<€–¦Ûø  v6v‚µ•´KéG•R}€ìRmc¡H Q,\ÇÂs×»ñ$vw`¸œùøÏÜ{Ι™©&ÑÅ5ô‹öŠk†iÑ×™¹¨æ×À1Ä#\ļ@fÅÝ+zŸ±Ÿ™Ïþ‚dæ‘bc$Fè¶ýK±Ý“%gû˜ z€¬V JÎAÞ—€–í.-wSï”Üñ10†å•e}ïð£Øþgç‰a³o]|ĨôOpßk`\Å…%Û¨°º°‡ÃU…¯+À\¯lè!ö:~ŸÑùªó¸‰Æý<=)´%ÓÜóç𯕈ø‰xÙ¬#â~ ›¡·µI+™y¾Ud‚™ùªÛi*lRàÒì£|“S÷1mÀ»ešm"wñ¦m(ŒÝ¬^;x[ô'>µÖ—×ܾ£ ²•™‹ˆØÇÓˆxž™¼Ç‹ÒHóläK­ýˆànfæbíÚ`ÂՇЙŽÍÓôgökª‚ üD?Ó_nÿ»¥hõ(IEND®B`‚shutter-0.90.1/share/shutter/resources/icons/drawing_tool/draw-text.png0000644000175000017500000000201012206477313025337 0ustar mariomario‰PNG  IHDRÄ´l;sBIT|dˆtEXtSoftwarewww.inkscape.org›î<šIDAT8••ÁoUÇ?ß™íì0mhÃR‰à kÄ`ÐÀ‰F=yÐ`¢”Dh þ &&&šxÑ?€¤&r ÈOT)¡Û†=LÙîv»;;Ïyó¼Ìn¶Ð}É73¿—|?ó}óÞÌç;IÒ'’œïû[äyž ‚`aW¯sŽF«×®]{þàÁƒ£9çÆ®_¿žöz½—œsmç­ì•töСC{ggg¹yó&ÖZò<ÇZËáÇ9~üxåöíÛ_lç÷vI{åܹsµf³‰1f‹îß¿Ïììl|$iÛpÛ‚%ÍHzãĉ^£ÑÀC–e Œ1´Z-²,# Cxóÿ$~ÿôéÓ®ÓéÐív1ÆpïÞ½|aa!¦ÞØØ`ÿþý“¾ï_þÏàJ¥rõÔ©Sµ‡Ž–ßh4RcŒ{üøñhqSÅk’<,éõz½>3==M³Ù$Ë2’$ÁZ›_5›M3|˜µ–8Ž àƒg‚+•Êå3gÎDËËËdY†1†ÕÕÕžµökçÜw­VË ç1DQT“ôé®`I{%]8vì˜÷àÁŒ1¤iJ«Õò€œsKëëëcÈóœ0 ñ image/svg+xml Genric Image Jakub Steiner imagepicturesnapshotphoto shutter-0.90.1/share/shutter/resources/icons/drawing_tool/draw-unlocked.png0000644000175000017500000000151312206477313026166 0ustar mariomario‰PNG  IHDRóÿasBIT|dˆ pHYs|4k¡tEXtSoftwarewww.inkscape.org›î< tEXtTitleLockŒ¥·QtEXtAuthorAndreas Nilsson+ïä£IDAT8uÓKHTQÇñß¹çÜ;ÞQ›ÑbÒ4µ‚V”Pö­„ˆŠ¢h_nZ´©ÄUî¢ZÙ"¤MHáÊM‹)iA¨„¦à1a@ó13÷uþçœV†6ú‡³ûžüfŒÁNÓõî-++/kõòÞL&3™N§»^¾xM›¶ð±§ûD循ÎýÕÕ9çlyeÃÃCߦ§fn=Ö±°Ñ‰í>èén>wö|¯‰©Éé¹ß‹ #ñb·þØñ#¢0|àÆFkmÔÔÖ¶%’‰ÄØèØÈÀÀ׫woß»>þkâ~>çyÉd²as»-Pž,?JRb~~þsÛ“öQh{ÜÞúQŽ înnÿ­0øžÕrÄ® Ûáñ“ý)°Ý°üÁúOo>"­†e§{KŸTçSV÷ ÃÌmöÔéû12[›Y2¸|xQ"•Zk©NU¶81 ¶°04ÝI/ÕP±ˆ—6š›wZ=‹ ÷çcaäÃÝÕ„ªCM°…‚Ö®TH²09º×)XAW5“·xIÑÄø«Ìž‚ !ƒ À=eAr^ÎG>gSøÏç´e; 1· –¥Àá#ð$ˆ+i4"eŽÃe<®É‰Á47¤±²:ŽxÙ:ÜbaÔ ¡a”†Å….òÙ%fŹ1æ "±Œ0øƒ » ŠÖ T¥¾È0Á C³¹ËשIjò-Á|ØÌ‡¢$| éCI­¹*²Yß±—‚¢âpÝ‚V*„VŠŠHi(2ð<@‘æ[ÆXé—Xü`))w•”´Â(dR†Œ(€’Ò&cŒÔ2ÔfiÃŒ±cLnÛkdŒqeŒQÿ·ÚÜXk×Ô®IEND®B`‚shutter-0.90.1/share/shutter/resources/icons/drawing_tool/draw-arrow.png0000644000175000017500000000037712206477313025523 0ustar mariomario‰PNG  IHDRàw=øbKGDÿÿÿ ½§“´IDATxÚíÔAjAÐ×££‘H ñ^Ôãd§&äÙg‘@pÆdÜÔ¢HeVã|((º›ÿ«>ŸfĈ HÃß"õ,д/'=ÿb‰WC¤ùëq¢]«Ì+l±ŽóÔ&ozª Ì‘¦™È#ž±ˆMº À[ôv8ÄÀ3Ô¹@¯ð±Kò!öxÁ;>‚§F“Z6¥+“Uà «è?£¾qÂOê!E%2ÿëÿ’t«H1˜ocÄ=â ÝJ4U«ÖIEND®B`‚shutter-0.90.1/share/shutter/resources/icons/drawing_tool/draw-lower.png0000644000175000017500000000072212206477313025513 0ustar mariomario‰PNG  IHDRóÿasBIT|dˆ pHYs × ×B(›xtEXtSoftwarewww.inkscape.org›î<OIDAT8¥“¿JAÆûçÎKR‰ØZû ×o%>CKßÂG±¶´_Ä,Tl¢˜Ã›=ãXÄè&ðƒafv÷[¾ÙÙ1ªÊ"„.«ªÚ‡TUEâÏìBö­9ë•YFÁ_ð“Às]U•Â¥ˆìŠu]“ú$>IK86UUÈNQà(€`B^M. ,Ëbæu0ˆzɹ 7K!\o3Vçy~áUUŒ1«ÀËùå©’¨›@'Óï÷½ˆøã÷‰i>o/ÆØøÌ}Ü7V׬7eflnbç,ÞY>œeä¾U<úfd7NnÀvÀµQÛÛ—æmpíñši¡®ƒ¼g¬oïõ|îGwûÇ;[±i™¯4±™–‘8UB«Èo—þ‰eY3³ðÝÆ…!\ÿÖÆ,ËÎýŸÌÄ9m|ø÷0}¹­ü²Jd;©IEND®B`‚shutter-0.90.1/share/shutter/resources/icons/drawing_tool/draw-censor.png0000644000175000017500000000245112206477313025655 0ustar mariomario‰PNG  IHDRÄ´l;sRGB®ÎébKGDÿÿÿ ½§“ pHYs  šœtIMEÙ 4+¯8¡C©IDAT8˽Õ_lSUÀñïí½½w]×u+[Çþo@Qö Å?¨5, øè &òä“&£ñè«ÆõÁ(‰&‰ab"d nLÊeÿ» ¶®]×®÷OÛ{}à–4f1>OòËÉ9ùå“_~çœøFWÏ6©«g›·°v­–ô.¸†ÛÚä;vxN€ø/ÐR`]Àï^}í 'ü¸sguã–-»·ûEQÖôXVZïížUÕÓ SSFFÌUÐJàù€ßw1j]RÕq0…BÂùƒ·×Ö׿.›æ–iz­l6é²m=ïv׿s¹CQ¾K$“ŸÝìØL> ø}ƒ¡PëuUÆ“©åðàÀ¸paÿþ¶ÚúúJ³Ù½™t:±8?tqiéÓt&sÖÖõ˜bÛM.—«¯ÄëÍ?[[{é«HDïêÙ¶8ðûC¡ÖU—âÉ”¸z{vÆ·nuWuw¿¡ÆÁ|*•’ƒAQª«;yáòåïûúû‡?9íêºêÖ´vlûq¼ÞÛD÷, ü¾L(Ôj:hø8<8p¥[Z:\™ÌS™XìòÂÒÒGÖÂe–õþž¾¾CgAÀî<~ü÷EÃ8)X–LIÉ>E ðû„P¨UQÕñ@<™jÞ* âᎎ=žLæÅôòò©W®¼dÛ~pÅ0ý¡©ùpÂSz´¦¾áÈùôJs¯$¢ Â}×-ËnXߌªŽO¦`Wxp æ˜ Húädµ¦ir<]8HhÛ#7~y:8ò¤â®ÞëvÓÔÛZYA>kt-NÌR#I´47¸þPÇÝñdª h,À»0º·À”4­4YùæVç=M¿†¯Ñ{s”¶x‚?}eÌ•(¸,–ßOdt‚x2åZƒ·‹@W!Ä—¼–µKJ¥Ê£ëCë7·¿ p)£‘4LîžfS‰ÏrŠÆÉ "Ù‘rK©ô›C—.žáÎ7!:° ®‹Åæ×76np Â3Âòr»«{³WÎËY¤×Ö°aÃè( ñ8v™Ÿ$7¾¶LÏܪœŸ›ý‹P°[z¬‡Ló˪`°öáX칩s¿a[Ñòr”T9³BV×ñ®]Ë™Š †d7‚Ðxœ³¿yyà×·Ÿ5lb+w‡Iøæ @1káŽîTòúùãùMòäeÈh(1@T„B¨Šˆ4ƒ§æË±.FÒ™ºt$áæƒ´†Zb@¼÷¤Z‡RymÛõÜ( nõ\QUÝÜ“J^:±¿XmÙ¹. Pz7ö)Ì I•(P3†ÈæžTóµþéå–îàU7 pJ“5ü!>|îØ|9ÖµixBÕ}.f'/„#$ŒÁZË&Uøüȳ“g ž5àÍWn=ýðÞ P·œSÕ©…÷ãC€SÕzˆ"T¿~6½Î¼%)’ŸA$ sÏ3ªn¼˜¸,‡0€ñ<òÆ`_¼ ³²Éh‰ü›ÇáψØ\1;9h# …YÒŸÚƒ{÷ô íPU1†’ݱ¤êž³“gX¡ÿMîß¶Âa¼ºD"1–ó“……Sý!ܸ¥«wꨂçÁ«×–ÞÞÞm¾ïçæFGu5'#"ººp1‰ªêb½ƒFëG[ºÛ“[üJ¹ÜÚÖÞ^1"žsÎÖnYkHµ¨.ÅT—J¥Ò¢fÿÀ}ƒð¥¸¯%-5WL¢YƒJ‹«-µF"‘ŠX»\ _<ïg̹²ïûåx<^ù Ãð&f+l|%IEND®B`‚shutter-0.90.1/share/shutter/resources/icons/drawing_tool/draw-locked.png0000644000175000017500000000151012206477313025620 0ustar mariomario‰PNG  IHDRóÿasBIT|dˆ pHYs|4k¡tEXtSoftwarewww.inkscape.org›î< tEXtTitleLockŒ¥·QtEXtAuthorAndreas Nilsson+ïä£IDAT8m“KkTQ ÇÿçÜÇLÇ™¾Ôj­Z)¶ÓÖ• âFܺô¸q%µèÂ+ApQj‹P„R ¢~×J‹¨ ED,Âh‘©:Zí´ó¸÷Ü“œ¸ðÁ´c „ä$?’¢D2;7“ëÚÑu=›Ížpì¶c\=ª].Ÿ nLŒOVóU#`vnÆïèŸÈKL‚R©T3I,mí­ÙÄ&xñüÅ“woOMŒOÒß¿‘ÖÑÙqyhpøXáC¡¸0??µüyù›î]Ýçóƒû¯:¹¾¶~ Àøäµö°ønñÑØè•[ OSw¦o÷õìÙ=ÚÚšëo¬ÑN„Û<­Q.¯.c“T*Õ/éT~àw4Æÿuðô¾êEçÝ>“Œ Í{}dá^vÌ’ƒ1ä9s<: e‹ùékjßÅ›²´a‰ïŸ^úôc°—ý£ÈÈtµ¡´‚VJ+|/÷à§=‡€ŸakêUiäôÛ:ÈäŽÈ‰ÁCuíù-"”8 ç,~ÛÛ{ˆûâ½xÿæsØ4‚ï·XáBM{Ù´ˆQÄ58ª© ¦ ˆ* »Žz5B­4cÅ^­êt*ÀYÇpœ€É‚‰Aä@VÇ"ÖM€0ôl&ã(LAœS`Ò`˜&Yò„´ç»&@­²¢‚tÆ ¥„ë°öÈ®‚’UP²æÌ„(¬iSM¡Õ”*ù-áÞvG‘öURXÇ ?Q ²Ø2œó¸ P©Da°§·˜u ǰlàØ‚‰~õ:Àä¼ ¥TîñÃ…T¦/GÜR&¶Ú$FYkQ ¶VÈ‘ˆXg“•2^*¥²"RU›ÏùÐðW€°ˆðæÜ_ƒv‚EÇIEND®B`‚shutter-0.90.1/share/shutter/resources/icons/sel_window_active.svg0000644000175000017500000003262412206477313024466 0ustar mariomario image/svg+xml Lapo Calamandrei Create a window window create new shutter-0.90.1/share/shutter/resources/icons/sel_window.svg0000644000175000017500000002265212206477313023133 0ustar mariomario image/svg+xml Jakub Steiner http://jimmac.musichall.cz Windows window manager decoration behavior shutter-0.90.1/share/shutter/resources/icons/lpi-translate.png0000644000175000017500000000107412206477313023520 0ustar mariomario‰PNG  IHDRóÿasBIT|dˆóIDAT8¥“ËkQÆ¿{g&cl•RS:H«©"‚TQºhpᮋdáF*®ÜˆºQ¤ ÿ‚ øh…ní"Õ«E)c©/hAJÛ ©¤f¦™¹¹¶i¦vªàY]ÎýÎï~çƒKr¹ì ¢Ó!!x)MÓˊ˾žžÞ—f~tdž1¦þ¥c*?:2ß Õ¹–a¸>ø5&"_Ç4ÜJÛàBX!ÀÊa|¢ˆê‹lÙÒöýàijã"ªà‚ÿ@ðèý`na ÷³à|]D÷ù'ߥRkàwÖuºò §ºw ïø.´µšx>1‡SÈôv!“²QñXÇ«÷3—†Ç —W¬YÁJ´ãÆ£O¨z ÷vâö…“`Rarº©NÛ+Dgp`Ÿ…£ví­1¸Çìfjð뮿ªmÊ `\b¦\Er[®ÏCCÔåo€FiÉõªÖÎäî¦ë·¨ ¹a¨l9t] ¤Ç7CJ©DX´˜:[M€ÏØŠƒåÑÑ,>|î±bu‰˜NA A[‹E7À@ö‹WøVF|“¡íßn0h”Åœ3hD"nRLJòæ½×ÞÇbéZ™«ò3°óï¦YoøÈÙÁNèêªFi†”P'ü‹ÎÝ3ŵÚ_”ãFÏ´vDIEND®B`‚shutter-0.90.1/share/shutter/resources/icons/sel_window_section.svg0000644000175000017500000002645212206477313024661 0ustar mariomario image/svg+xml shutter-0.90.1/share/shutter/resources/icons/logo-imageshack.png0000644000175000017500000001771512206477313024004 0ustar mariomario‰PNG  IHDRRZÝ/.tEXtSoftwareAdobe ImageReadyqÉe<PLTERRRðððâââ3433*RF ééécccê·ìììîîí½½½àààÖµEEEååå“,؃êêê÷«ä“‰‰‰B9 ÁÁÁÚ™ÕÕÕÿìse æææÙÙÙܧÞÞÞòÐË«ƒƒƒÿé'ÉrEþÂôäþËÿè3üÆ(ÜÜÜ}}}¥4w1öôæÅ‹èÔeÙ·.œœœøÕ²²²ýÙ½¢éÛ‹¥¥¥ý¾†t äÛ¬µµµ¶§-ò´ôëµóØF™ƒfW â¡ñ»ëçÓï½'Ö|íÖWÄlëÓI½xóÛVØ’׌”””þÇäœû²â‹óáwôÒµœ¹ŠÜÔ©äÄóÝdì¢ëÊÔuÆ’ÿüEë¬ÊÊÊ»epppòÑöòØç¥ÎÎθ@£¡,šºµã«ñÍÿÙ4Ì™þÔ«‚ñÒ"ÄYõ飹“þ¹îÒ6SLþÊ­”æÖ|þÕ,ÿÙ%Ê{ÝÙĵZþâŒÿÜ}j æáÁÍ„ÿò6«nóìÇÿÒ3dZðÑ, ­ÍÃòÓ)ìá¢õÀ¹‚óÕ4沫{©©©•zÞ¾¨hŽ| ñÕ>„u®®®®AöÔÖ §[uŒg™c ÿÑ&£—èq]ÿôôÃNzR ò¥õ½äzªtá‚¡KíÁº[óÿÖ—‹2íå´Í²ÿÌ/f ü¼_;ÿÑÿÞ!ëêä]K ßÒˆÝÛÓtFâßÏ·jû×ïÉ)’m ·|ÿÏÝ¿$ÿÕ߯þà*ÌÂF˜VàËtA ÷õî‚mðîâ÷÷ôþÞ7ë¿=O6¸LïÑÓfò¯ÿÙÄbðìØÝÝÝïÛoÿá*+*ƒ"õõõôôôòòòóóóæåÞBW>Ê¡÷ÈÃå×™o*ú¶H<ãÆFí•{t%6GJêÈ1ÿϳŸI`Bïá6ý×=ööö÷÷÷¯ácIDATxÚìœ \WºÀC˜ ’”ƒ Ò&X,!. E ´ˆÊKŒ-Ö„öb­ViE ­àªÕº¾(EÜŠ®]l•¶ÚÚ]ÕfÛšV«®«ÞÚµEE0Ýz/^÷^ïí ¹ßwf&ÄG»ëÕý5ÇG2gf¾3ç?ßëœ9ÝSþÁEàAàAêAêAê)¤¤¤žâAêAêAê)¤÷ÒS3F›2a¤¹“6®ß8iî ¡¿ 錹SÆl\]Á¸”ÕÃNyýt¤sWC½^£Õh4Z­¾k- 3ÁÃô'#}¥‚i%™ÛVnK¹Ä,2/‰Öê™ _y(ýD¤“˜Ö€ÓºEôÊg}&œ ÿíï~N¥µê™1“F?ìõSnÔ3"]æ£üÓÅxë­/÷›_ýÛo2©´=¸ƒ9Sæz¨þx¤ëõeôÔšÆ':R¡¼ÿ·ÿüïùÕo¼ÿFej´ç4€uõ¤ºèœ"ÈSÄüf•@Põ÷ M¹­'Ò)L«nkH~~QFvvv´wWת¾¾U®§Íº´¶2 Ts&üôðÚ×'ÿÿ&ZÕÕ‡¥+Éy ¡¿Tùm¥¸"ÕèveUN[[XXpu”¾>*òp¬4Ö¦±€ªNýÕ? RŽ(ã½B:‰±„Ó9yÓÞyûÊ•øæ•}ýë_ÿ§keäÑeË–ýðh8­ÛÃhÔÿS UQï¤d£70Uß#¤sMuâùœ¢ŒwÞ^0ûª÷ŸÿÜõâ<_ÔÙÏ]l^B‰~]†±jÎú)sOÝÿH@4˜ûÒ—|oÎXÍ4,¡6=}>¿Ò÷mßY¯J}´cvcvFFFooïõ‹oýé™éú² ¤U̘Ñ÷=Ò@G‹>÷LKíÃ}™ˆšðtnqå±GÚæ}±uݬêi¾Ùk×vÌÇÌ*æ·/Ò™Í%eÿ3Ãf<|ê¾F º©b¿‰“ï•/µŸôΠ§N&Íûþ‘c{«+³¦56fdgô½xñbL̾x•¦—”Àh•Y?fÒ°;žVᑊCC¡£â£À˜Äç"°!0&»Ÿ,j’U…º$-*<ØGŽ5ªÐP±{½@,vÕÒЮkBQt’ª_,ÃJ#×^¨ÛØ#O)t&´ê6Ó&ëaX?™ú(((ál]رGþkæûÕEYYT^|äÃsG4¼µlÜÿ¸’žŒöc€ÕSfü(¤ä3…‹ÅjìAº7»èÒI¾®¯ Nôñ×hù .¨²aßlX\ë»ä.¾T0Òª@îH5_ ç;Úë“‹¡½>Ç)MÞNÁâþH«`g×mÚgŒa˜‹õ¦¡ õåØ0߯¯dWæå…‡\ëM?r=¾ð¨ö€åಧž¡¶í))Ók1[]=¬Û~꫃TÍ_f_`°=űá-q¡árˆir—³¾+úæoëî¶Ùº«ØŽò2ùûùDJš\R+»½[ݯ=©XÀV±ÞUîHCáj;o;_zj øSÝÕ , gÏjÌÎΔ“3($5.5¾0.µ°fb\|üÁ˜?…_¥Eæ–ú‘œ«š2f°‡mwŠzfŠ‘'³Ur—>"Q:1*I i2Q–«—ŸAÍô÷ºÜcµFt‘úîîî*<5Pìc»_¦)ø= ÎIqkOi½,Kx<Ò`¼GÆ*Öü»xÁ¾ðúÌ*Mß Ñ[Z™W_ñ²ö;ä ùÒÃ}÷G¤\·¡J· *N =ó¥ÃúL#{ˆ$¼IÈT€õÝü‚"/{ùIÄhìÉB¡L H¼¥I°8ùʺP¹›‘8¼Òž?Qar… ÄUÁ·Ôñë%‘ˆpöo²7í$åìDjì»y só§a £i¡> ºtéü zúùó¹å!Ó:2:ŠŠ‹³²e M[\Ó[S3qbM$mNÓ‰ÂK4ÌØ¡G^^x·ùr ù†H­,Ú>ÿn7Þéd/«ÕŠ¡r<.VÍ ;º{$Ö+è"TZi°ÝÀQQB`›.‹•2(JdâCΡÄsªAùkW‚­=ì¾Ü¡fg¯n ÜÚ>1ôä2È5ØzºYÛC? qøRâdSìwŠô«Iöé%RˆžæMËÈžV^^”ÝÛ[“ZT×, íí§¥ýú™=ᢙzæ—2™8T4&8XL ÙÂíô¾¾!??ì–7vôL,†Ê.öèBÇzPž‰Z'x½HÑ$‡€V"ÖÂùˆ´³Î TŠI‹2™P(EÄJî@/겑´ŒÍy£`²‡ÜdÜGTñµ~pÚ(?môó"JBLÆ%‰J8Ôß ©ý«)ÈÔôMØ´élnþæ¢êÆÆÊüò¼ÒÊöÝíkÇÕ¤¦îï<8£££cðµÁÞzëz¤…Y=‚‹U‘‘oŽU SCÐJÓ $¢Tb¥€?» ‡.Á‡Vð§*Å]}¨GÅ0ðuJŒ“¥ÒNè¢`9ü¢V£7¤¬X¥8Š„? ¶Íù(rÙöü¤pGd¤=ʶވT(ñ)äÖã ïq@•»†ÿ;DŠaŸÑÖSÀ4h×–—s#}¡T‡ÕådMJ¨kSgôvLÜѾ»¸=õz¡®Þ ó$¤Ò(P ()ü/*U'èšZ µˆuJ v*Ä>’ƒá¨¨7È$;Äq/`‡JØ()9RÊ!žB\3 ¾$© m)Ë yi/™Íuªüí9ÊøZ‚†@¬o!‘U¨Õ•„=¹k¦v§H Ó†ZêÓáCOZ—¸¹±$Û·zs~l~XVee{FvGGû;ï Ž¶—¶W¶—ïÞ½{âG-ZfØ+k~ÿ˜Œe꣊PuJÁÉ×&D*$Ôœb¤CdœVK:Oú-uÑö(@ªŠ’bAÜ"½É WC0ÏêW à88…Õ>`ÚeP²–¢vÈ•FÁVÛžŒkµTŒñ@{Šˆ¼9@¡Z‰ýÿ¤èŒO]`ôÑÕ¡CwmŸ¸9²ñkßjßÇ—æçå•–NkÌ訜VÚžÝ1­²´²²(äÝ¢‡Š·Pfަ.<¦ä©FaÿÑL¡0«„R¢CR‚•@> ö¨Yu¤„):S‰ÔS’@YûàÖ`Q±šZ€¾”hºÛdu±àF'2E{Pb !:o'¶î]‰W¤R½Áj)žIœ·ŸÜt˜¨"P"T )˜g*¿a¬wk¤| Ã}ËdÓGÃv½ L«}³îÌãuƒòŠŠŠ€biVÈÎk¥EE!E¥ÅÅ9!û§ÌšVÈ,†óì“”i'é$vI9¥ Ñ ñ b A]¤þè_YÓfuà |)j•»LÕßÈF|èbXB¼¥ŒÃJ´Y · ‰Ë&mˉ\нÐð…Ò*ÄC ¯‹àK1€‚Ü$aaŠPÉEbnõÉwž\RóW*K-u˜N¿4Ì÷Ê•EÏËÉ )ÞY\\œ_¼sgqläôîµýÇDæ%º6¨þRq¢©BâúàRƒ%ÄsɈ¦ AU ýç,é$‰À…0¯ å&é$‰ø~b$GFðϬ¦ª yê¼TJîŒU0ë ¢äl,C|(¯(ã{E•kaœ7ÁÛïÉZ_ä];!Wv*U@U…;*&QÁ·dz¤Ý“ÀޤPO§çæ7^¹räÃEgŠrååç *,±ìŒ-ßy­½æMºö½’×è™I˜8Š•,TbÄ\|… Râí¹ µï ñƒÁà|Az/`“¨`LÉÓ;UõˆKŰ”ŒêèM>•$ƒ0 ƒSi§ÂØ—ÄÆ'¥¸€•€‘(YÊ·'³I[08ˆëŒâÚÃpFÒX3 ƒJUDU«ÄþÉÔ™§I¹-R'N2F™TÁ4ÔSó¶mú 6,{mÜõ¯Ï+Ï)/_šƒ(sàÏNþ—CÕÎâÝóÍ™¢•?<õƒè´…Yÿ° F~±3•B*Çä })BÙ Ç!É\Þ –ØW]ä"6=¡ƒTBß½C#T$˜K…d䘌1Ô7PÁ¦ùp”ÊÍ;ªcÇá¦qúœî¸$©´,Æq®œ„=ROä’ûíu…b~Õ©2v¥`4ÂN-Ü‚©À(?š„ñÅ$p§ô±ü]A gs*3z |xüÕØó¹9åuuu±±±å3§®¼ü[ Ú¾¾nUøSO=x¼ãÔ0Æ•dLÃæ¥\‚=DŒ„œi•ÎG†þ_¦†O&¥Q¤·hmàK!ð(ØÉªd‚Çâ !#Æiº@tl%€FµK—À°ËÕFYl{2¾=b©£:ÙÈ>„Èe3l/™M”J(eóÕtô«È^m»RWý$Åúð¦a‰¹qi `ZZSx`QÌãLÏ…rþÅÆ²hcó¦íß»b=xæ¡8Ý6 3HdGã8ls£' =ɱRâºAŽà½­0¤(À&y“™!›K*0mïòQ«ÕdrÀÈæ¥2¡g¢†dʪ&ÜÑaÊ+“"ª’ˆ4~¼äORlÁö°AÞï0k×^Ÿ˜¤o¤=Ÿ”Ì^ÉtA(ZAŠ*‘B&Nl7Cê ÊâÄò ÓZB=™˜{~Ó¥ M9Å»S¯9slÃáÇM?4 ]º´®xÿC{W¬ØûÎÂe>øìþš©4ìwܦnn|íG‚?Ö·Z]þ®~,_×ìÝB½‡šèé\v#Ðñ17-ÅOx*ˆe¨sr•›§òg'X­Ü´7†ö \N Òsõ*AŸ›`/ŸÊÙfý ìuápÌÖm© Pì")˜†–«¾›—æ¾¼ÏDí:ûí»ƒ =óýÖå¯><þðºÄ'—&†wÐ…+ö>´,æÁ3oö~†˜ïñˆT«•Œ¨¡à'™‡€ÊnײÑM&Ùüüù¾x'yy 0â“Ì3Ê &ô¼)Z ò+ÐÊ»“ï8'ÒƒB ·ë´ÙÒR‡Ž²@ýHÙÈh÷eç9aøJšn‰.k1-ŸWx乘/OœØ°ü½ Ë>\WW´w ]XJzü¹ÅCt" ³þ®,ò­Âìú2¹> Î BÀ(ÀQ•LiÞ_+÷8¢l˜ ŽÊcúj^uþ —L-õ%ç4ú‹õTñÄÔÂë‹ü~øÐP¶l84ýùÒÏžyöÌüø˜>7ñZ•©eþ?¾à”*bM`LB Ú%ÃiÖ ï;¤\Xð"<ÉôñLJ#ÃÖMX•vñŒß+ô­ô‰kƒ!•jX6oßðáC‡ݵ+aSûÞ3ÇÏüïCGb.*œ¸;ä5¤¥£ïΕŠÉÔg2漪 þ6Ç™û ©+Q2¢#™ð¦!Íܘ7þéKÔLò°n £M£Ê¯ î-¼~qÙ¿oß·oߥ Kû6íÞ{üAHGã.ŠŸ88$ϬÓÞ%»Ç'n9MW²í&¾Œ<µË…?Fv’½Éßu;]1àAw$UÀûQ6CïÿÙ¨_Œ˜ÃX¶m«œš›°ªE @ý¼Èꞓ×\?zñó«Û·ïÛ¾}•iøÎù11Ë–YxüHÍàÊüÙ¦6 ŒîZIq$ ]Fñ­½„½Iò£¼ŠÝß b“aÀƒîHª€SRލì»Q#È‹% çW.Ín*Ñ0küü¼þ²g¥å\ˈÿpÑ¢¿A@Ñiáû¾]|K=»bqie~ÙlaæÜÕÅÒ)$Y`U’¢© 4Hh04¥“ÞÃÿéÂ&‚>8Ba:%d52Ý+I‡M5ìbe„,R{+ÖŽ‡6ù¤÷“ª0o‚”#Š@¼PÁè5--2g‡å%RiŒ~ãÇ€ô_×3ZÝŽcEYÓjââŽ, o()k¨5==xѹ£GYÜQ”û…)ÚÂLº7¬@nð7¦Û F¹¡) ‘‚Jù¨ýCá#]íoH*`•ÏØd06 üíu“!]­°+Œép†õ2 d¨„dì•û;Ä4ùËA¶Â]j(wð HY³U~·`#ôj¿‰®o¡ém_ûFnN¤Ó˜)øìðÓº‡úÞ7«²²£··f«î¢¦U¯™ITœŠOõãçWæç.§–Üm%½i1àCu‰QbÀå r©”©I!Q;-iûÃ!9ë;áSŠ–ŽH »ã@ØÉ‹•+8ÃwHµ“u#u˜½ø» £Ñ6gÒ´Ù<;;>;rsØTóéfÜÇÉï½V´íñêÈÊ¢¢¬Òö­"-ÃXZgN6©ÌÈ(°ädfcsdX^^À¬ fS½…+žÄhJ¨ÙÕ•Yaù±çÏ^2µ:›L'7,ß•pöÛºü°Ã'–S@Ý­œô¶Eb’n€Ô®†~+|üú!5ÈrA“½©M‘J|À©C¬ ON*ú…ÏM¢ÝclÁ4l£ _µ*üýèpѾ“ßi¦h IÔcs`—y¾ocdX~Ýù§·SmZíÌpÓìY‰Ë7lØ”pöå];¶ÓÍfÊ={9R!WÁ8B*)0ªÕŠþZ >Uml"‘Hm$¾Ô.ò$W¤¼Ø&8¤R”Zts¤ä©j©Ù´J×V/¢E-™´y¤irsæÈVfÄXÆÒF{'»1,¯núÙ}¦= –6šž·yֺĩ‡ö]J8i2Ñm­ža»¯Æ1wÓ,ˆá¸ÒÌéKqJ¨L€µd2£½@St³V«a*Æ2­ ýÅbßj z†¨õ ú4Sx@äÔ©‘‰[†^ jJ«¢sFwÛ~6LÓÕMMÆô[ Vʤª˜(m£ZÊÎáZüÖ’èòRÞX0ûpQ†ouQþøó@TwT¯£&7Ïšøõç‘ã· ºemÑꙊÑÖnÛχ©Ý`¸Éè‰GŠÏV_e˜Úðú€¦ÁÒ Lg¦™'ƒî½Šã¦ÈŽÈ°¥ulJØn.³4S_|!2‰¾~îýÈuË·l9¼C@7޶’ÉÞŸ Ò›Hɲbé\ªO›¯ŠÒj÷€é·Q-¦ÌHV›!ÚGæ-ÍE¢T‰V_BS¦Uô— k§>±9ñµu³DiZæ‚;wéaÊ#ËpÀ8¦Á¼- yÞ6óUzÉÈZSÛHS@C«^´-#+oi,!ºÇ‚.7œúõ™ESÍ&ÊóuJDoΚJˆî3M>Ç૦+ÿãó/LÛöX´ ¦ÓÍÑtsëœÇ$N5õ %‹ÔÑ™¢š2z¶¡aOm:=ásóç¿ùýéÈÊ¥0d]5t”ÑèÌÌ£é‘ç4°¡m¡¾¬§gê_ø.˜¬{óX>™6agMˆšþÌÚR29m‰Ž¦=óìÂ#…WŽ,îÈ hõm@t#cщtTZ$Z¯Ž«Ðì1½NCtË.tòX¾c&Š<%5-m §_<9ïËøcѾû×®_»¶1Œè(Õ ÑÿŒ±tæ‘ ­Lň—>«Ð—…Óº’Vf”RìAê:Å©é'/´~Cõ=úHtæé"Š¢O. «ÎÎnŒL¿eŸ)ZËT\øî—s˜V-®Í7J¥R?QÖªg^ý W‘úy²Hj*ìÇÌ„>-2/I«®m1SµãõuKÇŸØnª=ÇT¬‘)ekØß9DU/½@ÞÍ›3JèAÚ)gú HÈož !J«±\ÔD×fÒ¦«Ã·›è6ð¿ÀW¾5vã¸q >A¢ªO>1î…#F =H]òOJ ÝW ?ÃG%Ü‹á y ¥oÓQº‘ß@dº@q’7 p…7®sÅÿ?Á7 ÈÛ_Ê#u¨)¸ÓÏÀ@Ÿya܈xò#ð»^ûMY+þüÎØïdìbWîÕ¡Î(¾Hoyº, Oq õg£ž¥àÊKO.÷*ñ–ÌXt—b²ÎÚñn“ãµ.ÜåÉKÝ‘º2âÞ/b_2ŠxiÁ sÆ- Þ’}1TÙÿ…Fòja°gôä‚Ô¡¦ìê!¡Ê•Nîm –h0·dŠ_‚Ï¥’{‡Öc÷.HÙàz'HùW”PBǯ·¸«³ß·éöuEêÎÔÚ߸Y=´ràœo™rÅåu&Qûïr ènÖîšèöb˜§¨Ò~Po°kž7-˜ýº¿>îê5{ÜUÑÃóŽ‘öûƒ-›%ç|sÑn÷°¼¡üŸªÔSõê‚IEND®B`‚shutter-0.90.1/share/shutter/resources/icons/draw.svg0000644000175000017500000005645712206477313021730 0ustar mariomario image/svg+xml Graphics Category Jakub Steiner graphics category pixel vector editor draw paint http://tango-project.org shutter-0.90.1/share/shutter/resources/icons/throbber_16x16.gif0000644000175000017500000000266012206477313023400 0ustar mariomarioGIF89aöÿÿÿúúú’’’ˆˆˆîîîÈÈÈØØØžžžŽŽŽÆÆÆ222RRRìì즦¦”””òòò‚‚‚²²²¤¤¤šššôôôøøø¨¨¨ÎÎÎDDD ```ÞÞÞèèè¼¼¼***666FFFÔÔÔÄÄÄ<<>>HHHÐÐÐÊÊÊZZZ´´´êêêppp¬¬¬¸¸¸ººº^^^\\\bbb†††ààà~~~üüü¢¢¢,,,VVVPPPÌÌÌ888XXXðððÖÖÖœœœâââæææ@@@ªªª$$$ ®®®rrrJJJ444jjjÒÒÒÀÀÀ&&&|||BBBTTT °°°äääLLLööö¶¶¶fffhhhÜÜÜ   """!ÿ NETSCAPE2.0!þCreated with ajaxload.info!ù ,h€‚ƒ "&%ƒ‰ ! (Š‚ — )‚‰‘ #'*Ÿ‚ ”Дй”‘¾$ˆ¡ ÃÅ ÃÑÒ©¾´‰Ö‰ª¬ƒÝ$$ÞÑ%ˆÓÑ!ù ,k€‚ƒ457ƒ‰Š3 /9:=9ƒ+//8; ;0ƒ, 2.6! 5ƒ-)1‰<><2ƒ.0³Š0? ŠÂÃ%$Ä‚$%‚ÆÈÊÎÑÒƒÄÕ‰׉ŠßÉÇ‚áÄ%ËÓÈ!ù ,h€‚ƒƒˆ‰ %*‰‚@A &Eƒ 8>Fˆ¢‰BC4GŠŠD´´ "&%$¹!(¿Á )Áƒ #'“˹­ŠÓ‚ Õ‚•ˆÜ$ÀÖË%¾ÑÑ!ù ,g€‚ƒ„…†‚%%‡ƒƒ$$D NR„…I Q…™…HJOS‹…0¦…457%‹3 /±³‡/¶8«‚.6ª«FPŸ†K L0Œ˜…!¶ 5–ŽL T2‹‰‚MQÞ¿†!ù ,h€‚ƒ„…†‚%%‡ƒƒ$$Œ…†„•‡›‹žŸ‚ˆ‹ %¦‡©    NE…ƒ+VXV¼‚“• "&%U>©F„™!©(GWYB[‡ ©)GZ‹ #'*†!ù ,g€‚ƒ„…†‚%%‡ƒƒ$$Œ…†„•‡›‹žŸ‡%ž$Š¢Ÿ¥ ‹P†] ]ƒF !„DS,ƒ\ Á)457I `ƒC <23Á/^_ „MQ2/Á8«.6†!ù ,g€‚ƒ„…†‚%%‡ƒƒ$$Œ…†„•‡›‹ž "&Šž‚! (ž$Š §)ªŠ #'*¤„+NR¶AOa–„6§‚—™a\Y3§‚Í‚[ZH§» †!ù ,h€‚ƒ„…‚b=J‚%%†‚Fc L$$ƒ„\ O…š‚d>"2†…0?1„457°„3/¶$Ž/8»Ž.6¶…2ǃ%B+]ª…, ¯„¡£‚S_SD–˜‚ÚÌæ;shutter-0.90.1/share/shutter/resources/credits/0000755000175000017500000000000012206477313020553 5ustar mariomarioshutter-0.90.1/share/shutter/resources/credits/dev0000644000175000017500000000071512206477313021257 0ustar mariomarioProject Leader: Mario Kemper Vadim Peretokin Developers: Mario Kemper Patches and Bugfixing: Vadim Rutkovsky Franco Zeoli José Borges Ferreira Plugins: Edwood Ocasio Mario Kemper Martin Rabeneck (cornix) Stephan Tetzel TualatriX shutter-0.90.1/share/shutter/resources/credits/art0000644000175000017500000000037412206477313021270 0ustar mariomarioPascal Grochol Richard Querin Duncan Lock Nicu Buculei Gregor Fröhlich The Tango Desktop Project: http://tango.freedesktop.org The Inkscape Project: http://www.inkscape.org shutter-0.90.1/share/shutter/resources/modules/0000755000175000017500000000000012206477312020565 5ustar mariomarioshutter-0.90.1/share/shutter/resources/modules/Shutter/0000755000175000017500000000000012206477312022223 5ustar mariomarioshutter-0.90.1/share/shutter/resources/modules/Shutter/App/0000755000175000017500000000000012206477313022744 5ustar mariomarioshutter-0.90.1/share/shutter/resources/modules/Shutter/App/Menu.pm0000644000175000017500000010512212206477313024207 0ustar mariomario################################################### # # Copyright (C) 2008-2013 Mario Kemper # # This file is part of Shutter. # # Shutter is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 3 of the License, or # (at your option) any later version. # # Shutter is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License # along with Shutter; if not, write to the Free Software # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA # ################################################### package Shutter::App::Menu; #modules #-------------------------------------- use utf8; use strict; use Gtk2; #Glib use Glib qw/TRUE FALSE/; #-------------------------------------- sub new { my $class = shift; #constructor my $self = { _common => shift }; bless $self, $class; return $self; } sub create_menu { my $self = shift; my $d = $self->{_common}->get_gettext; my $shutter_root = $self->{_common}->get_root; my $accel_group = Gtk2::AccelGroup->new; $self->{_common}->get_mainwindow->add_accel_group($accel_group); #MenuBar $self->{_menubar} = Gtk2::MenuBar->new(); #file $self->{_menuitem_file} = Gtk2::MenuItem->new_with_mnemonic( $d->get('_File') ); $self->{_menuitem_file}->set_submenu( $self->fct_ret_file_menu( $accel_group, $d, $shutter_root ) ); $self->{_menubar}->append( $self->{_menuitem_file} ); #edit $self->{_menuitem_edit} = Gtk2::MenuItem->new_with_mnemonic( $d->get('_Edit') ); $self->{_menuitem_edit}->set_submenu( $self->fct_ret_edit_menu( $accel_group, $d, $shutter_root ) ); $self->{_menubar}->append( $self->{_menuitem_edit} ); #view $self->{_menuitem_view} = Gtk2::MenuItem->new_with_mnemonic( $d->get('_View') ); $self->{_menuitem_view}->set_submenu( $self->fct_ret_view_menu( $accel_group, $d, $shutter_root ) ); $self->{_menubar}->append( $self->{_menuitem_view} ); #actions $self->{_menuitem_actions} = Gtk2::MenuItem->new_with_mnemonic( $d->get('_Screenshot') ); $self->{_menuitem_actions}->set_submenu( $self->fct_ret_actions_menu( $accel_group, $d, $shutter_root ) ); $self->{_menubar}->append( $self->{_menuitem_actions} ); #go-to $self->{_menuitem_session} = Gtk2::MenuItem->new_with_mnemonic( $d->get('_Go') ); $self->{_menuitem_session}->set_submenu( $self->fct_ret_session_menu( $accel_group, $d, $shutter_root ) ); $self->{_menubar}->append( $self->{_menuitem_session} ); #help $self->{_menuitem_help} = Gtk2::MenuItem->new_with_mnemonic( $d->get('_Help') ); $self->{_menuitem_help}->set_submenu( $self->fct_ret_help_menu( $accel_group, $d, $shutter_root ) ); $self->{_menubar}->append( $self->{_menuitem_help} ); #we provide a larger (more actions) menuitem actions as well #this will not be added to any menu entries $self->fct_ret_actions_menu_large( $accel_group, $d, $shutter_root ); return $self->{_menubar}; } sub fct_ret_file_menu { my $self = shift; my $accel_group = shift; my $d = shift; my $shutter_root = shift; #Icontheme my $icontheme = $self->{_common}->get_theme; $self->{_menu_file} = Gtk2::Menu->new(); $self->{_menuitem_new} = Gtk2::ImageMenuItem->new_from_stock('gtk-new'); $self->{_menuitem_new}->set_submenu( $self->fct_ret_new_menu( $accel_group, $d, $shutter_root ) ); $self->{_menu_file}->append( $self->{_menuitem_new} ); $self->{_menu_file}->append( Gtk2::SeparatorMenuItem->new ); $self->{_menuitem_open} = Gtk2::ImageMenuItem->new_with_mnemonic( $d->get('_Open...') ); $self->{_menuitem_open}->set_image( Gtk2::Image->new_from_stock( 'gtk-open', 'menu' ) ); $self->{_menuitem_open}->add_accelerator( 'activate', $accel_group, Gtk2::Accelerator->parse('O'), qw/visible/ ); $self->{_menu_file}->append( $self->{_menuitem_open} ); $self->{_menuitem_recent} = Gtk2::ImageMenuItem->new_with_mnemonic( $d->get('Recent _Files') ); $self->{_menu_file}->append( $self->{_menuitem_recent} ); $self->{_menu_file}->append( Gtk2::SeparatorMenuItem->new ); #~ $self->{_menuitem_save} = Gtk2::ImageMenuItem->new_with_mnemonic( $d->get('_Save') ); #~ $self->{_menuitem_save}->set_image( Gtk2::Image->new_from_stock( 'gtk-save', 'menu' ) ); #~ $self->{_menuitem_save}->set_sensitive(FALSE); #~ $self->{_menuitem_save}->add_accelerator( 'activate', $accel_group, Gtk2::Accelerator->parse('S'), qw/visible/ ); #~ $self->{_menu_file}->append( $self->{_menuitem_save} ); $self->{_menuitem_save_as} = Gtk2::ImageMenuItem->new_with_mnemonic( $d->get('Save _As...') ); $self->{_menuitem_save_as}->set_image( Gtk2::Image->new_from_stock( 'gtk-save-as', 'menu' ) ); $self->{_menuitem_save_as}->set_sensitive(FALSE); $self->{_menuitem_save_as}->add_accelerator( 'activate', $accel_group, Gtk2::Accelerator->parse('S'), qw/visible/ ); $self->{_menu_file}->append( $self->{_menuitem_save_as} ); #~ $self->{_menuitem_export_svg} = Gtk2::ImageMenuItem->new_with_mnemonic( $d->get('Export to SVG...') ); #~ $self->{_menuitem_export_svg}->set_sensitive(FALSE); #~ $self->{_menuitem_export_svg}->add_accelerator( 'activate', $accel_group, Gtk2::Accelerator->parse('G'), qw/visible/ ); #~ $self->{_menu_file}->append( $self->{_menuitem_export_svg} ); $self->{_menuitem_export_pdf} = Gtk2::ImageMenuItem->new_with_mnemonic( $d->get('E_xport to PDF...') ); $self->{_menuitem_export_pdf}->set_sensitive(FALSE); $self->{_menuitem_export_pdf}->add_accelerator( 'activate', $accel_group, Gtk2::Accelerator->parse('P'), qw/visible/ ); $self->{_menu_file}->append( $self->{_menuitem_export_pdf} ); $self->{_menuitem_export_pscript} = Gtk2::ImageMenuItem->new_with_mnemonic( $d->get('Export to Post_Script...') ); $self->{_menuitem_export_pscript}->set_sensitive(FALSE); $self->{_menuitem_export_pscript}->add_accelerator( 'activate', $accel_group, Gtk2::Accelerator->parse('S'), qw/visible/ ); $self->{_menu_file}->append( $self->{_menuitem_export_pscript} ); $self->{_menu_file}->append( Gtk2::SeparatorMenuItem->new ); #~ $self->{_menuitem_pagesetup} = Gtk2::ImageMenuItem->new_from_stock('gtk-page-setup'); #~ $self->{_menu_file}->append( $self->{_menuitem_pagesetup} ); $self->{_menuitem_pagesetup} = Gtk2::ImageMenuItem->new( $d->get('Page Set_up') ); $self->{_menuitem_pagesetup}->set_image( Gtk2::Image->new_from_icon_name( 'document-page-setup', 'menu' ) ); $self->{_menuitem_pagesetup}->set_sensitive(FALSE); $self->{_menu_file}->append( $self->{_menuitem_pagesetup} ); $self->{_menuitem_print} = Gtk2::ImageMenuItem->new_with_mnemonic( $d->get('_Print...') ); $self->{_menuitem_print}->set_image( Gtk2::Image->new_from_stock( 'gtk-print', 'menu' ) ); $self->{_menuitem_print}->add_accelerator( 'activate', $accel_group, Gtk2::Accelerator->parse('P'), qw/visible/ ); $self->{_menuitem_print}->set_sensitive(FALSE); $self->{_menu_file}->append( $self->{_menuitem_print} ); $self->{_menu_file}->append( Gtk2::SeparatorMenuItem->new ); $self->{_menuitem_email} = Gtk2::ImageMenuItem->new($d->get('Send by E_mail...')); $self->{_menuitem_email}->set_image( Gtk2::Image->new_from_icon_name( 'mail-send', 'menu' ) ); $self->{_menuitem_email}->set_sensitive(FALSE); $self->{_menuitem_email}->add_accelerator( 'activate', $accel_group, Gtk2::Accelerator->parse('E'), qw/visible/ ); $self->{_menu_file}->append( $self->{_menuitem_email} ); $self->{_menu_file}->append( Gtk2::SeparatorMenuItem->new ); $self->{_menuitem_close} = Gtk2::ImageMenuItem->new_from_stock('gtk-close'); $self->{_menuitem_close}->set_sensitive(FALSE); $self->{_menuitem_close}->add_accelerator( 'activate', $accel_group, Gtk2::Accelerator->parse('W'), qw/visible/ ); $self->{_menu_file}->append( $self->{_menuitem_close} ); $self->{_menuitem_close_all} = Gtk2::ImageMenuItem->new_with_mnemonic( $d->get('C_lose all') ); $self->{_menuitem_close_all}->set_image( Gtk2::Image->new_from_stock( 'gtk-close', 'menu' ) ); $self->{_menuitem_close_all}->set_sensitive(FALSE); $self->{_menuitem_close_all}->add_accelerator( 'activate', $accel_group, Gtk2::Accelerator->parse('W'), qw/visible/ ); $self->{_menu_file}->append( $self->{_menuitem_close_all} ); $self->{_menu_file}->append( Gtk2::SeparatorMenuItem->new ); $self->{_menuitem_quit} = Gtk2::ImageMenuItem->new_from_stock('gtk-quit'); $self->{_menuitem_quit}->add_accelerator( 'activate', $accel_group, Gtk2::Accelerator->parse('Q'), qw/visible/ ); $self->{_menu_file}->append( $self->{_menuitem_quit} ); return $self->{_menu_file}; } sub fct_ret_edit_menu { my $self = shift; my $accel_group = shift; my $d = shift; my $shutter_root = shift; #Icontheme my $icontheme = $self->{_common}->get_theme; $self->{_menu_edit} = Gtk2::Menu->new(); $self->{_menuitem_undo} = Gtk2::ImageMenuItem->new_from_stock('gtk-undo'); $self->{_menuitem_undo}->add_accelerator( 'activate', $accel_group, Gtk2::Accelerator->parse('Z'), qw/visible/ ); $self->{_menuitem_undo}->set_sensitive(FALSE); $self->{_menu_edit}->append( $self->{_menuitem_undo} ); $self->{_menuitem_redo} = Gtk2::ImageMenuItem->new_from_stock('gtk-redo'); $self->{_menuitem_redo}->add_accelerator( 'activate', $accel_group, Gtk2::Accelerator->parse('Y'), qw/visible/ ); $self->{_menuitem_redo}->set_sensitive(FALSE); $self->{_menu_edit}->append( $self->{_menuitem_redo} ); $self->{_menu_edit}->append( Gtk2::SeparatorMenuItem->new ); $self->{_menuitem_copy} = Gtk2::ImageMenuItem->new_from_stock('gtk-copy'); $self->{_menuitem_copy}->add_accelerator( 'activate', $accel_group, Gtk2::Accelerator->parse('C'), qw/visible/ ); $self->{_menuitem_copy}->set_sensitive(FALSE); $self->{_menu_edit}->append( $self->{_menuitem_copy} ); $self->{_menuitem_copy_filename} = Gtk2::ImageMenuItem->new_from_stock('gtk-copy'); $self->{_menuitem_copy_filename}->get_child->set_text_with_mnemonic( $d->get('Copy _Filename') ); $self->{_menuitem_copy_filename}->add_accelerator( 'activate', $accel_group, Gtk2::Accelerator->parse('C'), qw/visible/ ); $self->{_menuitem_copy_filename}->set_sensitive(FALSE); $self->{_menu_edit}->append( $self->{_menuitem_copy_filename} ); $self->{_menuitem_trash} = Gtk2::ImageMenuItem->new_with_mnemonic( $d->get('Move to _Trash') ); $self->{_menuitem_trash}->add_accelerator( 'activate', $accel_group, Gtk2::Accelerator->parse('Delete'), qw/visible/ ); $self->{_menuitem_trash}->set_image( Gtk2::Image->new_from_icon_name( 'user-trash', 'menu' ) ); $self->{_menuitem_trash}->set_sensitive(FALSE); $self->{_menu_edit}->append( $self->{_menuitem_trash} ); $self->{_menu_edit}->append( Gtk2::SeparatorMenuItem->new ); $self->{_menuitem_select_all} = Gtk2::ImageMenuItem->new_from_stock('gtk-select-all'); $self->{_menuitem_select_all}->add_accelerator( 'activate', $accel_group, Gtk2::Accelerator->parse('A'), qw/visible/ ); $self->{_menu_edit}->append( $self->{_menuitem_select_all} ); $self->{_menu_edit}->append( Gtk2::SeparatorMenuItem->new ); $self->{_menuitem_quicks} = Gtk2::MenuItem->new_with_mnemonic( $d->get('_Quick profile select') ); $self->{_menu_edit}->append( $self->{_menuitem_quicks} ); $self->{_menu_edit}->append( Gtk2::SeparatorMenuItem->new ); $self->{_menuitem_settings} = Gtk2::ImageMenuItem->new_from_stock('gtk-preferences'); $self->{_menuitem_settings}->add_accelerator( 'activate', $accel_group, Gtk2::Gdk->keyval_from_name('P'), qw/mod1-mask/, qw/visible/ ); $self->{_menu_edit}->append( $self->{_menuitem_settings} ); return $self->{_menu_edit}; } sub fct_ret_view_menu { my $self = shift; my $accel_group = shift; my $d = shift; my $shutter_root = shift; #Icontheme my $icontheme = $self->{_common}->get_theme; $self->{_menu_view} = Gtk2::Menu->new(); $self->{_menuitem_btoolbar} = Gtk2::CheckMenuItem->new_with_mnemonic( $d->get('Show Navigation _Toolbar') ); $self->{_menuitem_btoolbar}->set_active(FALSE); $self->{_menu_view}->append( $self->{_menuitem_btoolbar} ); $self->{_menu_view}->append( Gtk2::SeparatorMenuItem->new ); $self->{_menuitem_zoom_in} = Gtk2::ImageMenuItem->new_from_stock('gtk-zoom-in'); $self->{_menuitem_zoom_in}->add_accelerator( 'activate', $accel_group, Gtk2::Accelerator->parse('plus'), qw/visible/ ); $self->{_menuitem_zoom_in}->add_accelerator( 'activate', $accel_group, Gtk2::Accelerator->parse('equal'), qw/visible/ ); $self->{_menuitem_zoom_in}->add_accelerator( 'activate', $accel_group, Gtk2::Accelerator->parse('KP_Add'), qw/visible/ ); $self->{_menuitem_zoom_in}->set_sensitive(FALSE); $self->{_menu_view}->append( $self->{_menuitem_zoom_in} ); $self->{_menuitem_zoom_out} = Gtk2::ImageMenuItem->new_from_stock('gtk-zoom-out'); $self->{_menuitem_zoom_out}->add_accelerator( 'activate', $accel_group, Gtk2::Accelerator->parse('minus'), qw/visible/ ); $self->{_menuitem_zoom_out}->add_accelerator( 'activate', $accel_group, Gtk2::Accelerator->parse('KP_Subtract'), qw/visible/ ); $self->{_menuitem_zoom_out}->set_sensitive(FALSE); $self->{_menu_view}->append( $self->{_menuitem_zoom_out} ); $self->{_menuitem_zoom_100} = Gtk2::ImageMenuItem->new_from_stock('gtk-zoom-100'); $self->{_menuitem_zoom_100}->add_accelerator( 'activate', $accel_group, Gtk2::Accelerator->parse('0'), qw/visible/ ); $self->{_menuitem_zoom_100}->set_sensitive(FALSE); $self->{_menu_view}->append( $self->{_menuitem_zoom_100} ); $self->{_menuitem_zoom_best} = Gtk2::ImageMenuItem->new_from_stock('gtk-zoom-fit'); $self->{_menuitem_zoom_best}->set_sensitive(FALSE); $self->{_menu_view}->append( $self->{_menuitem_zoom_best} ); $self->{_menu_view}->append( Gtk2::SeparatorMenuItem->new ); #create an image item from stock to reuse the translated text $self->{_menuitem_fullscreen_image} = Gtk2::ImageMenuItem->new_from_stock('gtk-fullscreen'); $self->{_menuitem_fullscreen} = Gtk2::CheckMenuItem->new_with_label($self->{_menuitem_fullscreen_image}->get_child->get_text); $self->{_menuitem_fullscreen}->add_accelerator( 'activate', $accel_group, Gtk2::Accelerator->parse('F11'), qw/visible/ ); $self->{_menu_view}->append( $self->{_menuitem_fullscreen} ); return $self->{_menu_view}; } sub fct_ret_session_menu { my $self = shift; my $accel_group = shift; my $d = shift; my $shutter_root = shift; #Icontheme my $icontheme = $self->{_common}->get_theme; $self->{_menu_session} = Gtk2::Menu->new(); $self->{_menuitem_back} = Gtk2::ImageMenuItem->new_from_stock('gtk-go-back'); $self->{_menuitem_back}->add_accelerator( 'activate', $accel_group, Gtk2::Gdk->keyval_from_name('Left'), qw/mod1-mask/, qw/visible/ ); $self->{_menu_session}->append( $self->{_menuitem_back} ); $self->{_menuitem_forward} = Gtk2::ImageMenuItem->new_from_stock('gtk-go-forward'); $self->{_menuitem_forward}->add_accelerator( 'activate', $accel_group, Gtk2::Gdk->keyval_from_name('Right'), qw/mod1-mask/, qw/visible/ ); $self->{_menu_session}->append( $self->{_menuitem_forward} ); $self->{_menu_session}->append( Gtk2::SeparatorMenuItem->new ); $self->{_menuitem_first} = Gtk2::ImageMenuItem->new_from_stock('gtk-goto-first'); $self->{_menuitem_first}->add_accelerator( 'activate', $accel_group, Gtk2::Gdk->keyval_from_name('Home'), qw/mod1-mask/, qw/visible/ ); $self->{_menu_session}->append( $self->{_menuitem_first} ); $self->{_menuitem_last} = Gtk2::ImageMenuItem->new_from_stock('gtk-goto-last'); $self->{_menuitem_last}->add_accelerator( 'activate', $accel_group, Gtk2::Gdk->keyval_from_name('End'), qw/mod1-mask/, qw/visible/ ); $self->{_menu_session}->append( $self->{_menuitem_last} ); return $self->{_menu_session}; } sub fct_ret_help_menu { my $self = shift; my $accel_group = shift; my $d = shift; my $shutter_root = shift; #Icontheme my $icontheme = $self->{_common}->get_theme; $self->{_menu_help} = Gtk2::Menu->new(); $self->{_menuitem_question} = Gtk2::ImageMenuItem->new( $d->get('Get Help Online...') ); if($icontheme->has_icon('lpi-help')){ $self->{_menuitem_question}->set_image( Gtk2::Image->new_from_icon_name( 'lpi-help', 'menu' ) ); }else{ $self->{_menuitem_question}->set_image( Gtk2::Image->new_from_pixbuf( Gtk2::Gdk::Pixbuf->new_from_file_at_size( "$shutter_root/share/shutter/resources/icons/lpi-help.png", Gtk2::IconSize->lookup('menu') ) ) ); } $self->{_menu_help}->append( $self->{_menuitem_question} ); $self->{_menuitem_translate} = Gtk2::ImageMenuItem->new( $d->get('Translate this Application...') ); if($icontheme->has_icon('lpi-translate')){ $self->{_menuitem_translate}->set_image( Gtk2::Image->new_from_icon_name( 'lpi-translate', 'menu' ) ); }else{ $self->{_menuitem_translate}->set_image( Gtk2::Image->new_from_pixbuf( Gtk2::Gdk::Pixbuf->new_from_file_at_size( "$shutter_root/share/shutter/resources/icons/lpi-translate.png", Gtk2::IconSize->lookup('menu') ) ) ); } $self->{_menu_help}->append( $self->{_menuitem_translate} ); $self->{_menuitem_bug} = Gtk2::ImageMenuItem->new( $d->get('Report a Problem') ); if($icontheme->has_icon('lpi-bug')){ $self->{_menuitem_bug}->set_image( Gtk2::Image->new_from_icon_name( 'lpi-bug', 'menu' ) ); }else{ $self->{_menuitem_bug}->set_image( Gtk2::Image->new_from_pixbuf( Gtk2::Gdk::Pixbuf->new_from_file_at_size( "$shutter_root/share/shutter/resources/icons/lpi-bug.png", Gtk2::IconSize->lookup('menu') ) ) ); } $self->{_menu_help}->append( $self->{_menuitem_bug} ); $self->{_menu_help}->append( Gtk2::SeparatorMenuItem->new ); $self->{_menuitem_about} = Gtk2::ImageMenuItem->new_from_stock('gtk-about'); $self->{_menuitem_about}->add_accelerator( 'activate', $accel_group, Gtk2::Gdk->keyval_from_name('I'), qw/control-mask/, qw/visible/ ); $self->{_menu_help}->append( $self->{_menuitem_about} ); return $self->{_menu_help}; } sub fct_ret_new_menu { my $self = shift; my $accel_group = shift; my $d = shift; my $shutter_root = shift; #Icontheme my $icontheme = $self->{_common}->get_theme; $self->{_menu_new} = Gtk2::Menu->new; #redo last capture $self->{_menuitem_redoshot} = Gtk2::ImageMenuItem->new_from_stock('gtk-refresh'); $self->{_menuitem_redoshot}->get_child->set_text_with_mnemonic( $d->get('_Redo last screenshot') ); $self->{_menuitem_redoshot}->add_accelerator( 'activate', $accel_group, Gtk2::Accelerator->parse('F5'), qw/visible/ ); $self->{_menuitem_redoshot}->set_sensitive(FALSE); $self->{_menu_new}->append( $self->{_menuitem_redoshot} ); $self->{_menu_new}->append( Gtk2::SeparatorMenuItem->new ); #selection $self->{_menuitem_selection} = Gtk2::ImageMenuItem->new_with_mnemonic( $d->get('_Selection') ); eval{ my $ccursor_pb = Gtk2::Gdk::Cursor->new('left_ptr')->get_image->scale_simple(Gtk2::IconSize->lookup('menu'), 'bilinear'); $self->{_menuitem_selection}->set_image( Gtk2::Image->new_from_pixbuf($ccursor_pb) ); }; if($@){ if($icontheme->has_icon('applications-accessories')){ $self->{_menuitem_selection}->set_image( Gtk2::Image->new_from_icon_name( 'applications-accessories', 'menu' ) ); }else{ $self->{_menuitem_selection}->set_image( Gtk2::Image->new_from_pixbuf( Gtk2::Gdk::Pixbuf->new_from_file_at_size( "$shutter_root/share/shutter/resources/icons/selection.svg", Gtk2::IconSize->lookup('menu') ) ) ); } } $self->{_menu_new}->append( $self->{_menuitem_selection} ); #~ $self->{_menu_new}->append( Gtk2::SeparatorMenuItem->new ); #full screen $self->{_menuitem_full} = Gtk2::ImageMenuItem->new_with_mnemonic( $d->get('_Desktop') ); if($icontheme->has_icon('user-desktop')){ $self->{_menuitem_full}->set_image( Gtk2::Image->new_from_icon_name( 'user-desktop', 'menu' ) ); }elsif($icontheme->has_icon('desktop')){ $self->{_menuitem_full}->set_image( Gtk2::Image->new_from_icon_name( 'desktop', 'menu' ) ); }else{ $self->{_menuitem_full}->set_image( Gtk2::Image->new_from_pixbuf( Gtk2::Gdk::Pixbuf->new_from_file_at_size( "$shutter_root/share/shutter/resources/icons/desktop.svg", Gtk2::IconSize->lookup('menu') ) ) ); } $self->{_menu_new}->append( $self->{_menuitem_full} ); #~ $self->{_menu_new}->append( Gtk2::SeparatorMenuItem->new ); #awindow $self->{_menuitem_awindow} = Gtk2::ImageMenuItem->new_with_mnemonic( $d->get('_Active Window') ); if($icontheme->has_icon('preferences-system-windows')){ $self->{_menuitem_awindow}->set_image( Gtk2::Image->new_from_icon_name( 'preferences-system-windows', 'menu' ) ); }else{ $self->{_menuitem_awindow}->set_image( Gtk2::Image->new_from_pixbuf( Gtk2::Gdk::Pixbuf->new_from_file_at_size( "$shutter_root/share/shutter/resources/icons/sel_window_active.svg", Gtk2::IconSize->lookup('menu') ) ) ); } $self->{_menu_new}->append( $self->{_menuitem_awindow} ); #window $self->{_menuitem_window} = Gtk2::ImageMenuItem->new_with_mnemonic( $d->get('Select W_indow') ); if($icontheme->has_icon('preferences-system-windows')){ $self->{_menuitem_window}->set_image( Gtk2::Image->new_from_icon_name( 'preferences-system-windows', 'menu' ) ); }else{ $self->{_menuitem_window}->set_image( Gtk2::Image->new_from_pixbuf( Gtk2::Gdk::Pixbuf->new_from_file_at_size( "$shutter_root/share/shutter/resources/icons/sel_window.svg", Gtk2::IconSize->lookup('menu') ) ) ); } $self->{_menu_new}->append( $self->{_menuitem_window} ); #section $self->{_menuitem_section} = Gtk2::ImageMenuItem->new_with_mnemonic( $d->get('Se_ction') ); if($icontheme->has_icon('gdm-xnest')){ $self->{_menuitem_section}->set_image( Gtk2::Image->new_from_icon_name( 'gdm-xnest', 'menu' ) ); }else{ $self->{_menuitem_section}->set_image( Gtk2::Image->new_from_pixbuf( Gtk2::Gdk::Pixbuf->new_from_file_at_size( "$shutter_root/share/shutter/resources/icons/sel_window_section.svg", Gtk2::IconSize->lookup('menu') ) ) ); } $self->{_menu_new}->append( $self->{_menuitem_section} ); #menu $self->{_menuitem_menu} = Gtk2::ImageMenuItem->new_with_mnemonic( $d->get('_Menu') ); if($icontheme->has_icon('alacarte')){ $self->{_menuitem_menu}->set_image( Gtk2::Image->new_from_icon_name( 'alacarte', 'menu' ) ); }else{ $self->{_menuitem_menu}->set_image( Gtk2::Image->new_from_pixbuf( Gtk2::Gdk::Pixbuf->new_from_file_at_size( "$shutter_root/share/shutter/resources/icons/sel_window_menu.svg", Gtk2::IconSize->lookup('menu') ) ) ); } $self->{_menu_new}->append( $self->{_menuitem_menu} ); #tooltip $self->{_menuitem_tooltip} = Gtk2::ImageMenuItem->new_with_mnemonic( $d->get('_Tooltip') ); if($icontheme->has_icon('help-faq')){ $self->{_menuitem_tooltip}->set_image( Gtk2::Image->new_from_icon_name( 'help-faq', 'menu' ) ); }else{ $self->{_menuitem_tooltip}->set_image( Gtk2::Image->new_from_pixbuf( Gtk2::Gdk::Pixbuf->new_from_file_at_size( "$shutter_root/share/shutter/resources/icons/sel_window_tooltip.svg", Gtk2::IconSize->lookup('menu') ) ) ); } $self->{_menu_new}->append( $self->{_menuitem_tooltip} ); #~ $self->{_menu_new}->append( Gtk2::SeparatorMenuItem->new ); #web $self->{_menuitem_web} = Gtk2::ImageMenuItem->new_with_mnemonic( $d->get('_Web') ); if($icontheme->has_icon('web-browser')){ $self->{_menuitem_web}->set_image( Gtk2::Image->new_from_icon_name( 'web-browser', 'menu' ) ); }else{ $self->{_menuitem_web}->set_image( Gtk2::Image->new_from_pixbuf( Gtk2::Gdk::Pixbuf->new_from_file_at_size( "$shutter_root/share/shutter/resources/icons/web_image.svg", Gtk2::IconSize->lookup('menu') ) ) ); } $self->{_menu_new}->append( $self->{_menuitem_web} ); $self->{_menu_new}->append( Gtk2::SeparatorMenuItem->new ); #import from clipboard $self->{_menuitem_iclipboard} = Gtk2::ImageMenuItem->new_from_stock('gtk-paste'); $self->{_menuitem_iclipboard}->get_child->set_text_with_mnemonic( $d->get('Import from clip_board') ); $self->{_menuitem_iclipboard}->add_accelerator( 'activate', $accel_group, Gtk2::Accelerator->parse('V'), qw/visible/ ); $self->{_menu_new}->append( $self->{_menuitem_iclipboard} ); $self->{_menu_new}->show_all; return $self->{_menu_new}; } sub fct_ret_actions_menu{ my $self = shift; my $accel_group = shift; my $d = shift; my $shutter_root = shift; #Icontheme my $icontheme = $self->{_common}->get_theme; $self->{_menu_actions} = Gtk2::Menu->new(); $self->{_menuitem_reopen} = Gtk2::ImageMenuItem->new_with_mnemonic( $d->get('Open wit_h') ); $self->{_menuitem_reopen}->set_image( Gtk2::Image->new_from_stock( 'gtk-open', 'menu' ) ); $self->{_menuitem_reopen}->set_sensitive(FALSE); $self->{_menuitem_reopen}->set_name('item-reopen-list'); $self->{_menu_actions}->append( $self->{_menuitem_reopen} ); $self->{_menuitem_show_in_folder} = Gtk2::ImageMenuItem->new_with_mnemonic( $d->get('Show in _folder') ); $self->{_menuitem_show_in_folder}->set_image( Gtk2::Image->new_from_stock( 'gtk-open', 'menu' ) ); $self->{_menuitem_show_in_folder}->set_sensitive(FALSE); $self->{_menuitem_show_in_folder}->set_name('item-reopen-default'); $self->{_menu_actions}->append( $self->{_menuitem_show_in_folder} ); $self->{_menuitem_rename} = Gtk2::ImageMenuItem->new_with_mnemonic( $d->get('_Rename...') ); $self->{_menuitem_rename}->add_accelerator( 'activate', $accel_group, Gtk2::Accelerator->parse('F2'), qw/visible/ ) if $accel_group; $self->{_menuitem_rename}->set_image( Gtk2::Image->new_from_stock( 'gtk-edit', 'menu' ) ); $self->{_menuitem_rename}->set_sensitive(FALSE); $self->{_menuitem_rename}->set_name('item-rename'); $self->{_menu_actions}->append( $self->{_menuitem_rename} ); $self->{_menu_actions}->append( Gtk2::SeparatorMenuItem->new ); $self->{_menuitem_send} = Gtk2::ImageMenuItem->new($d->get('_Send To...')); $self->{_menuitem_send}->add_accelerator( 'activate', $accel_group, Gtk2::Accelerator->parse('S'), qw/visible/ ); $self->{_menuitem_send}->set_image( Gtk2::Image->new_from_icon_name( 'document-send', 'menu' ) ); $self->{_menuitem_send}->set_sensitive(FALSE); $self->{_menuitem_send}->set_name('item-send'); $self->{_menu_actions}->append( $self->{_menuitem_send} ); $self->{_menuitem_upload} = Gtk2::ImageMenuItem->new_with_mnemonic( $d->get('E_xport...') ); $self->{_menuitem_upload}->add_accelerator( 'activate', $accel_group, Gtk2::Accelerator->parse('U'), qw/visible/ ) if $accel_group; $self->{_menuitem_upload}->set_image( Gtk2::Image->new_from_stock( 'gtk-network', 'menu' ) ); $self->{_menuitem_upload}->set_sensitive(FALSE); $self->{_menuitem_upload}->set_name('item-upload'); $self->{_menu_actions}->append( $self->{_menuitem_upload} ); $self->{_menuitem_links} = Gtk2::ImageMenuItem->new_with_mnemonic( $d->get('Public URLs') ); $self->{_menuitem_links}->set_image( Gtk2::Image->new_from_stock( 'gtk-network', 'menu' ) ); $self->{_menuitem_links}->set_sensitive(FALSE); $self->{_menuitem_links}->set_name('item-links'); $self->{_menu_actions}->append( $self->{_menuitem_links} ); $self->{_menu_actions}->append( Gtk2::SeparatorMenuItem->new ); $self->{_menuitem_draw} = Gtk2::ImageMenuItem->new_with_mnemonic( $d->get('_Edit...') ); $self->{_menuitem_draw}->set_image( Gtk2::Image->new_from_stock( 'gtk-edit', 'menu' ) ); $self->{_menuitem_draw}->add_accelerator( 'activate', $accel_group, Gtk2::Accelerator->parse('E'), qw/visible/ ) if $accel_group; if($icontheme->has_icon('applications-graphics')){ $self->{_menuitem_draw}->set_image( Gtk2::Image->new_from_icon_name( 'applications-graphics', 'menu' ) ); }else{ $self->{_menuitem_draw}->set_image( Gtk2::Image->new_from_pixbuf( Gtk2::Gdk::Pixbuf->new_from_file_at_size( "$shutter_root/share/shutter/resources/icons/draw.svg", Gtk2::IconSize->lookup('menu') ) ) ); } $self->{_menuitem_draw}->set_sensitive(FALSE); $self->{_menuitem_draw}->set_name('item-draw'); $self->{_menu_actions}->append( $self->{_menuitem_draw} ); $self->{_menuitem_plugin} = Gtk2::ImageMenuItem->new_with_mnemonic( $d->get('Run a _plugin...') ); $self->{_menuitem_plugin}->add_accelerator( 'activate', $accel_group, Gtk2::Accelerator->parse('P'), qw/visible/ ) if $accel_group; $self->{_menuitem_plugin}->set_image( Gtk2::Image->new_from_stock( 'gtk-execute', 'menu' ) ); $self->{_menuitem_plugin}->set_sensitive(FALSE); $self->{_menuitem_plugin}->set_name('item-plugin'); $self->{_menu_actions}->append( $self->{_menuitem_plugin} ); $self->{_menu_actions}->append( Gtk2::SeparatorMenuItem->new ); $self->{_menuitem_redoshot_this} = Gtk2::ImageMenuItem->new_with_mnemonic( $d->get('Redo _this screenshot') ); $self->{_menuitem_redoshot_this}->add_accelerator( 'activate', $accel_group, Gtk2::Accelerator->parse('F5'), qw/visible/ ) if $accel_group; $self->{_menuitem_redoshot_this}->set_image( Gtk2::Image->new_from_stock( 'gtk-refresh', 'menu' ) ); $self->{_menuitem_redoshot_this}->set_sensitive(FALSE); $self->{_menuitem_redoshot_this}->set_name('item-redoshot'); $self->{_menu_actions}->append( $self->{_menuitem_redoshot_this} ); $self->{_menu_actions}->show_all; return $self->{_menu_actions}; } sub fct_ret_actions_menu_large{ my $self = shift; my $accel_group = shift; my $d = shift; my $shutter_root = shift; #Icontheme my $icontheme = $self->{_common}->get_theme; $self->{_menu_large_actions} = Gtk2::Menu->new(); $self->{_menuitem_large_reopen} = Gtk2::ImageMenuItem->new_with_mnemonic( $d->get('Open wit_h') ); $self->{_menuitem_large_reopen}->set_image( Gtk2::Image->new_from_stock( 'gtk-open', 'menu' ) ); $self->{_menuitem_large_reopen}->set_sensitive(FALSE); $self->{_menuitem_large_reopen}->set_name('item-large-reopen-list'); $self->{_menu_large_actions}->append( $self->{_menuitem_large_reopen} ); $self->{_menuitem_large_show_in_folder} = Gtk2::ImageMenuItem->new_with_mnemonic( $d->get('Show in _folder') ); $self->{_menuitem_large_show_in_folder}->set_image( Gtk2::Image->new_from_stock( 'gtk-open', 'menu' ) ); $self->{_menuitem_large_show_in_folder}->set_sensitive(FALSE); $self->{_menuitem_large_show_in_folder}->set_name('item-reopen-default'); $self->{_menu_large_actions}->append( $self->{_menuitem_large_show_in_folder} ); $self->{_menuitem_large_rename} = Gtk2::ImageMenuItem->new_with_mnemonic( $d->get('_Rename...') ); $self->{_menuitem_large_rename}->set_image( Gtk2::Image->new_from_stock( 'gtk-edit', 'menu' ) ); $self->{_menuitem_large_rename}->set_sensitive(FALSE); $self->{_menuitem_large_rename}->set_name('item-large-rename'); $self->{_menu_large_actions}->append( $self->{_menuitem_large_rename} ); $self->{_menu_large_actions}->append( Gtk2::SeparatorMenuItem->new ); $self->{_menuitem_large_send} = Gtk2::ImageMenuItem->new($d->get('_Send To...')); $self->{_menuitem_large_send}->set_image( Gtk2::Image->new_from_icon_name( 'document-send', 'menu' ) ); $self->{_menuitem_send}->set_sensitive(FALSE); $self->{_menuitem_send}->set_name('item-large-send'); $self->{_menu_large_actions}->append( $self->{_menuitem_large_send} ); $self->{_menuitem_large_upload} = Gtk2::ImageMenuItem->new_with_mnemonic( $d->get('E_xport...') ); $self->{_menuitem_large_upload}->set_image( Gtk2::Image->new_from_stock( 'gtk-network', 'menu' ) ); $self->{_menuitem_large_upload}->set_sensitive(FALSE); $self->{_menuitem_large_upload}->set_name('item-large-upload'); $self->{_menu_large_actions}->append( $self->{_menuitem_large_upload} ); $self->{_menuitem_large_links} = Gtk2::ImageMenuItem->new_with_mnemonic( $d->get('Public URLs') ); $self->{_menuitem_large_links}->set_image( Gtk2::Image->new_from_stock( 'gtk-network', 'menu' ) ); $self->{_menuitem_large_links}->set_sensitive(FALSE); $self->{_menuitem_large_links}->set_name('item-large-links'); $self->{_menu_large_actions}->append( $self->{_menuitem_large_links} ); $self->{_menu_large_actions}->append( Gtk2::SeparatorMenuItem->new ); $self->{_menuitem_large_copy} = Gtk2::ImageMenuItem->new_from_stock('gtk-copy'); $self->{_menuitem_large_copy}->set_sensitive(FALSE); $self->{_menuitem_large_copy}->set_name('item-large-copy'); $self->{_menu_large_actions}->append( $self->{_menuitem_large_copy} ); $self->{_menuitem_large_copy_filename} = Gtk2::ImageMenuItem->new_from_stock('gtk-copy'); $self->{_menuitem_large_copy_filename}->get_child->set_text_with_mnemonic( $d->get('Copy _Filename') ); $self->{_menuitem_large_copy_filename}->set_sensitive(FALSE); $self->{_menuitem_large_copy_filename}->set_name('item-large-copy-filename'); $self->{_menu_large_actions}->append( $self->{_menuitem_large_copy_filename} ); $self->{_menuitem_large_trash} = Gtk2::ImageMenuItem->new_with_mnemonic( $d->get('Move to _Trash') ); $self->{_menuitem_large_trash}->set_image( Gtk2::Image->new_from_icon_name( 'gnome-stock-trash', 'menu' ) ); $self->{_menuitem_large_trash}->set_sensitive(FALSE); $self->{_menuitem_large_trash}->set_name('item-large-trash'); $self->{_menu_large_actions}->append( $self->{_menuitem_large_trash} ); $self->{_menu_large_actions}->append( Gtk2::SeparatorMenuItem->new ); $self->{_menuitem_large_draw} = Gtk2::ImageMenuItem->new_with_mnemonic( $d->get('_Edit...') ); $self->{_menuitem_large_draw}->set_image( Gtk2::Image->new_from_stock( 'gtk-edit', 'menu' ) ); if($icontheme->has_icon('applications-graphics')){ $self->{_menuitem_large_draw}->set_image( Gtk2::Image->new_from_icon_name( 'applications-graphics', 'menu' ) ); }else{ $self->{_menuitem_large_draw}->set_image( Gtk2::Image->new_from_pixbuf( Gtk2::Gdk::Pixbuf->new_from_file_at_size( "$shutter_root/share/shutter/resources/icons/draw.svg", Gtk2::IconSize->lookup('menu') ) ) ); } $self->{_menuitem_large_draw}->set_sensitive(FALSE); $self->{_menuitem_large_draw}->set_name('item-large-draw'); $self->{_menu_large_actions}->append( $self->{_menuitem_large_draw} ); $self->{_menuitem_large_plugin} = Gtk2::ImageMenuItem->new_with_mnemonic( $d->get('Run a _Plugin...') ); $self->{_menuitem_large_plugin}->set_image( Gtk2::Image->new_from_stock( 'gtk-execute', 'menu' ) ); $self->{_menuitem_large_plugin}->set_sensitive(FALSE); $self->{_menuitem_large_plugin}->set_name('item-large-plugin'); $self->{_menu_large_actions}->append( $self->{_menuitem_large_plugin} ); $self->{_menu_large_actions}->append( Gtk2::SeparatorMenuItem->new ); $self->{_menuitem_large_redoshot_this} = Gtk2::ImageMenuItem->new_with_mnemonic( $d->get('Redo _this screenshot') ); $self->{_menuitem_large_redoshot_this}->set_image( Gtk2::Image->new_from_stock( 'gtk-refresh', 'menu' ) ); $self->{_menuitem_large_redoshot_this}->set_sensitive(FALSE); $self->{_menuitem_large_redoshot_this}->set_name('item-large-redoshot'); $self->{_menu_large_actions}->append( $self->{_menuitem_large_redoshot_this} ); $self->{_menu_large_actions}->show_all; return $self->{_menu_large_actions}; } 1; shutter-0.90.1/share/shutter/resources/modules/Shutter/App/SimpleDialogs.pm0000644000175000017500000002605012206477313026041 0ustar mariomario################################################### # # Copyright (C) 2008-2013 Mario Kemper # # This file is part of Shutter. # # Shutter is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 3 of the License, or # (at your option) any later version. # # Shutter is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License # along with Shutter; if not, write to the Free Software # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA # ################################################### package Shutter::App::SimpleDialogs; #modules #-------------------------------------- use utf8; use strict; use warnings; use Gtk2; #Glib use Glib qw/TRUE FALSE/; #-------------------------------------- ##################public subs################## sub new { my $class = shift; #constructor my $self = { _window => shift, _gdk_window => shift }; bless $self, $class; return $self; } sub dlg_info_message { my $self = shift; my $dlg_info_message = shift; my $dlg_info_header = shift; my $button_text_extra1 = shift; my $button_text_extra2 = shift; my $button_text_extra3 = shift; my $button_widget_extra1 = shift; my $button_widget_extra2 = shift; my $button_widget_extra3 = shift; my $detail_message = shift; my $detail_checkbox = shift; my $content_widget = shift; my $info_dialog = Gtk2::MessageDialog->new( $self->{_window}, [qw/modal destroy-with-parent/], 'info', 'none', undef ); $info_dialog->set_title("Shutter"); $info_dialog->set( 'text' => $dlg_info_header ); $info_dialog->set( 'secondary-text' => $dlg_info_message ); if($content_widget){ $info_dialog->get_content_area()->add($content_widget); } $info_dialog->add_button( $button_text_extra1, 10 ) if $button_text_extra1; $info_dialog->add_button( $button_text_extra2, 20 ) if $button_text_extra2; $info_dialog->add_button( $button_text_extra3, 30 ) if $button_text_extra3; $info_dialog->add_action_widget( $button_widget_extra1, 40 ) if $button_widget_extra1; $info_dialog->add_action_widget( $button_widget_extra2, 50 ) if $button_widget_extra2; $info_dialog->add_action_widget( $button_widget_extra3, 60 ) if $button_widget_extra3; #show a detailed message (use expander to show it) if($detail_message){ my $expander = Gtk2::Expander->new_with_mnemonic ('Show more _details'); my $detail_label = Gtk2::Label->new($detail_message); $detail_label->set_width_chars (50); $detail_label->set_line_wrap (TRUE); $detail_label->set_alignment( 0, 0.5 ); $expander->add($detail_label); my $detail_hbox = Gtk2::HBox->new(); $detail_hbox->pack_start(Gtk2::Label->new, FALSE, FALSE, 12); $detail_hbox->pack_start_defaults($expander); $info_dialog->vbox->add($detail_hbox); } #show a detailed message with checkbox my $dcheck = undef; if($detail_checkbox){ $dcheck = Gtk2::CheckButton->new_with_mnemonic($detail_checkbox); my $detail_hbox = Gtk2::HBox->new(); $detail_hbox->pack_start(Gtk2::Label->new, FALSE, FALSE, 12); $detail_hbox->pack_start_defaults($dcheck); $info_dialog->vbox->add($detail_hbox); } $info_dialog->show_all; if(defined $self->{_gdk_window} && $self->{_gdk_window} =~ /Gtk2::Gdk::Window/){ $info_dialog->window->set_transient_for($self->{_gdk_window}); }else{ $info_dialog->set_transient_for($self->{_window}); } my $info_response = $info_dialog->run; #-1 when response is an event, e.g. delete-event $info_response = -1 if $info_response =~ /event/; $info_dialog->destroy(); return $info_response; } sub dlg_question_message { my $self = shift; my $dlg_question_message = shift; my $dlg_question_header = shift; my $button_text_extra1 = shift; my $button_text_extra2 = shift; my $button_text_extra3 = shift; my $button_widget_extra1 = shift; my $button_widget_extra2 = shift; my $button_widget_extra3 = shift; my $detail_message = shift; my $detail_checkbox = shift; my $question_dialog = Gtk2::MessageDialog->new( $self->{_window}, [qw/modal destroy-with-parent/], 'other', 'none', undef ); $question_dialog->set_title("Shutter"); $question_dialog->set( 'image' => Gtk2::Image->new_from_stock( 'gtk-dialog-question', 'dialog' ) ); $question_dialog->set( 'text' => $dlg_question_header ); $question_dialog->set( 'secondary-text' => $dlg_question_message ); $question_dialog->add_button( $button_text_extra1, 10 ) if $button_text_extra1; $question_dialog->add_button( $button_text_extra2, 20 ) if $button_text_extra2; $question_dialog->add_button( $button_text_extra3, 30 ) if $button_text_extra3; $question_dialog->add_action_widget( $button_widget_extra1, 40 ) if $button_widget_extra1; $question_dialog->add_action_widget( $button_widget_extra2, 50 ) if $button_widget_extra2; $question_dialog->add_action_widget( $button_widget_extra3, 60 ) if $button_widget_extra3; #show a detailed message (use expander to show it) if($detail_message){ my $expander = Gtk2::Expander->new_with_mnemonic ('Show more _details'); my $detail_label = Gtk2::Label->new($detail_message); $detail_label->set_width_chars (50); $detail_label->set_line_wrap (TRUE); $detail_label->set_alignment( 0, 0.5 ); $expander->add($detail_label); my $detail_hbox = Gtk2::HBox->new(); $detail_hbox->pack_start(Gtk2::Label->new, FALSE, FALSE, 12); $detail_hbox->pack_start_defaults($expander); $question_dialog->vbox->add($detail_hbox); } #show a detailed message with checkbox my $dcheck = undef; if($detail_checkbox){ $dcheck = Gtk2::CheckButton->new_with_mnemonic($detail_checkbox); my $detail_hbox = Gtk2::HBox->new(); $detail_hbox->pack_start(Gtk2::Label->new, FALSE, FALSE, 12); $detail_hbox->pack_start_defaults($dcheck); $question_dialog->vbox->add($detail_hbox); } $question_dialog->show_all; if(defined $self->{_gdk_window} && $self->{_gdk_window} =~ /Gtk2::Gdk::Window/){ $question_dialog->window->set_transient_for($self->{_gdk_window}); }else{ $question_dialog->set_transient_for($self->{_window}); } my $question_response = $question_dialog->run; #-1 when response is an event, e.g. delete-event $question_response = -1 if $question_response =~ /event/; $question_dialog->destroy(); if(defined $dcheck){ return ($question_response, $dcheck->get_active); }else{ return $question_response; } } sub dlg_error_message { my $self = shift; my $dlg_error_message = shift; my $dlg_error_header = shift; my $button_text_extra1 = shift; my $button_text_extra2 = shift; my $button_text_extra3 = shift; my $button_widget_extra1 = shift; my $button_widget_extra2 = shift; my $button_widget_extra3 = shift; my $detail_message = shift; my $error_dialog = Gtk2::MessageDialog->new( $self->{_window}, [qw/modal destroy-with-parent/], 'other', 'none', undef ); $error_dialog->set_title("Shutter"); $error_dialog->set( 'image' => Gtk2::Image->new_from_stock( 'gtk-dialog-error', 'dialog' ) ); $error_dialog->set( 'text' => $dlg_error_header ); $error_dialog->set( 'secondary-text' => $dlg_error_message ); $error_dialog->add_button( 'gtk-cancel', 0 ); $error_dialog->add_button( $button_text_extra1, 10 ) if $button_text_extra1; $error_dialog->add_button( $button_text_extra2, 20 ) if $button_text_extra2; $error_dialog->add_button( $button_text_extra3, 30 ) if $button_text_extra3; $error_dialog->add_action_widget( $button_widget_extra1, 40 ) if $button_widget_extra1; $error_dialog->add_action_widget( $button_widget_extra2, 50 ) if $button_widget_extra2; $error_dialog->add_action_widget( $button_widget_extra3, 60 ) if $button_widget_extra3; #show a detailed message (use expander to show it) if($detail_message){ my $expander = Gtk2::Expander->new_with_mnemonic ('Show more _details'); my $detail_label = Gtk2::Label->new($detail_message); $detail_label->set_width_chars (50); $detail_label->set_line_wrap (TRUE); $detail_label->set_alignment( 0, 0.5 ); $expander->add($detail_label); my $detail_hbox = Gtk2::HBox->new(); $detail_hbox->pack_start(Gtk2::Label->new, FALSE, FALSE, 12); $detail_hbox->pack_start_defaults($expander); $error_dialog->vbox->add($detail_hbox); } $error_dialog->show_all; if(defined $self->{_gdk_window} && $self->{_gdk_window} =~ /Gtk2::Gdk::Window/){ $error_dialog->window->set_transient_for($self->{_gdk_window}); }else{ $error_dialog->set_transient_for($self->{_window}); } my $error_response = $error_dialog->run; #-1 when response is an event, e.g. delete-event $error_response = -1 if $error_response =~ /event/; $error_dialog->destroy(); return $error_response; } sub dlg_warning_message { my $self = shift; my $dlg_warning_message = shift; my $dlg_warning_header = shift; my $button_text_extra1 = shift; my $button_text_extra2 = shift; my $button_text_extra3 = shift; my $button_widget_extra1 = shift; my $button_widget_extra2 = shift; my $button_widget_extra3 = shift; my $detail_message = shift; my $warning_dialog = Gtk2::MessageDialog->new( $self->{_window}, [qw/modal destroy-with-parent/], 'other', 'none', undef ); $warning_dialog->set_title("Shutter"); $warning_dialog->set( 'image' => Gtk2::Image->new_from_stock( 'gtk-dialog-warning', 'dialog' ) ); $warning_dialog->set( 'text' => $dlg_warning_header ); $warning_dialog->set( 'secondary-text' => $dlg_warning_message ); $warning_dialog->add_button( 'gtk-cancel', 0 ); $warning_dialog->add_button( $button_text_extra1, 10 ) if $button_text_extra1; $warning_dialog->add_button( $button_text_extra2, 20 ) if $button_text_extra2; $warning_dialog->add_button( $button_text_extra3, 30 ) if $button_text_extra3; $warning_dialog->add_action_widget( $button_widget_extra1, 40 ) if $button_widget_extra1; $warning_dialog->add_action_widget( $button_widget_extra2, 50 ) if $button_widget_extra2; $warning_dialog->add_action_widget( $button_widget_extra3, 60 ) if $button_widget_extra3; #show a detailed message (use expander to show it) if($detail_message){ my $expander = Gtk2::Expander->new_with_mnemonic ('Show more _details'); my $detail_label = Gtk2::Label->new($detail_message); $detail_label->set_width_chars (50); $detail_label->set_line_wrap (TRUE); $detail_label->set_alignment( 0, 0.5 ); $expander->add($detail_label); my $detail_hbox = Gtk2::HBox->new(); $detail_hbox->pack_start(Gtk2::Label->new, FALSE, FALSE, 12); $detail_hbox->pack_start_defaults($expander); $warning_dialog->vbox->add($detail_hbox); } $warning_dialog->show_all; if(defined $self->{_gdk_window} && $self->{_gdk_window} =~ /Gtk2::Gdk::Window/){ $warning_dialog->window->set_transient_for($self->{_gdk_window}); }else{ $warning_dialog->set_transient_for($self->{_window}); } my $warning_response = $warning_dialog->run; #-1 when response is an event, e.g. delete-event $warning_response = -1 if $warning_response =~ /event/; $warning_dialog->destroy(); return $warning_response; } 1; shutter-0.90.1/share/shutter/resources/modules/Shutter/App/Autostart.pm0000644000175000017500000000477612206477313025306 0ustar mariomario################################################### # # Copyright (C) 2008-2013 Mario Kemper # # This file is part of Shutter. # # Shutter is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 3 of the License, or # (at your option) any later version. # # Shutter is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License # along with Shutter; if not, write to the Free Software # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA # ################################################### package Shutter::App::Autostart; use utf8; use strict; use warnings; #Glib use Glib qw/TRUE FALSE/; sub new { my $class = shift; my $self = { }; #read data binmode DATA, ":utf8"; while (my $data = ){ push @{$self->{_data}}, $data; } bless $self, $class; return $self; } sub create_autostart_file { my $self = shift; my $dir = shift; # ~/.config/autostart in most cases my $enabled = shift; my $min = shift; my $nonotification = shift; #copy in order keep original data my @data = @{$self->{_data}}; my $path = $dir."/shutter.desktop"; open FILE, ">:utf8", $path or die $!; foreach my $line (@data){ if($line =~ /Exec=shutter/){ #add options my $options = ''; $options .= " --min_at_startup" if $min; $options .= " --disable_systray" if $nonotification; #remove placeholder $line =~ s//$options/; }elsif($line =~ /X-GNOME-Autostart-enabled=false/){ $line =~ s/false/true/ if $enabled; }elsif($line =~ /Hidden=true/){ $line =~ s/true/false/ if $enabled; } print FILE $line; } close FILE or die $!; return TRUE; } 1; __DATA__ [Desktop Entry] Version=1.0 Name=Shutter Name[de_DE]=Shutter Name[pt_BR]=Shutter GenericName=Screenshot Tool GenericName[de_DE]=Anwendung für Bildschirmfotos GenericName[pt_BR]=Captura de tela Comment=Capture, edit and share screenshots Comment[de_DE]=Bildschirmfotos aufnehmen, bearbeiten und mit Anderen teilen Comment[pt_BR]=Aplicativo avançado para capturar imagens da tela Exec=shutter Icon=shutter Terminal=false Type=Application Categories=Utility;Application; X-GNOME-Autostart-enabled=false Hidden=true shutter-0.90.1/share/shutter/resources/modules/Shutter/App/TrashInfo.pm0000644000175000017500000000406312206477313025202 0ustar mariomario################################################### # # Copyright (C) 2008-2013 Mario Kemper # # This file is part of Shutter. # # Shutter is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 3 of the License, or # (at your option) any later version. # # Shutter is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License # along with Shutter; if not, write to the Free Software # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA # ################################################### package Shutter::App::TrashInfo; use utf8; use strict; use warnings; use Glib qw/TRUE FALSE/; use POSIX qw/ strftime /; use File::Temp qw/ tempfile tempdir /; sub new { my $class = shift; my $self = { }; #read data binmode DATA, ":utf8"; while (my $data = ){ push @{$self->{_data}}, $data; } bless $self, $class; return $self; } sub create_trashinfo_file { my $self = shift; my $filename = shift; #original filename my @data = @{$self->{_data}}; my ( $tmpfh, $tmpfilename ) = tempfile(UNLINK => 1); open FILE, ">:utf8", $tmpfilename or die $!; foreach my $line (@data){ if($line =~ /Path=/){ #remove placeholder $line =~ s//$filename/; }elsif($line =~ /DeletionDate=/){ #The date and time are to be in the YYYY-MM-DDThh:mm:ss format (see RFC 3339). #The time zone should be the user's (or filesystem's) local time. The value type for this key is “stringâ€. my $ddate = strftime "%Y-%m-%dT%H:%M:%S", localtime; #remove placeholder $line =~ s//$ddate/; } print FILE $line; } close FILE or die $!; return $tmpfilename; } 1; __DATA__ [Trash Info] Path= DeletionDate= shutter-0.90.1/share/shutter/resources/modules/Shutter/App/Options.pm0000644000175000017500000000713512206477313024743 0ustar mariomario################################################### # # Copyright (C) 2008-2013 Mario Kemper # # This file is part of Shutter. # # Shutter is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 3 of the License, or # (at your option) any later version. # # Shutter is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License # along with Shutter; if not, write to the Free Software # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA # ################################################### package Shutter::App::Options; use utf8; use strict; use warnings; #Glib use Glib qw/TRUE FALSE/; #Extended processing of command line options use Getopt::Long qw(:config no_ignore_case pass_through); #print a usage message from embedded pod documentation use Pod::Usage; sub new { my $class = shift; my $self = { _sc => shift, _shf => shift }; bless $self, $class; return $self; } sub get_options { my $self = shift; GetOptions ( 's|select:s@' => sub{ my ($select, $sel_ref) = @_; $self->{_sc}->set_start_with("select", $sel_ref); $self->{_sc}->set_min(TRUE); }, 'f|full' => sub{ $self->{_sc}->set_start_with("full"); $self->{_sc}->set_min(TRUE); }, 'w|window:s' => sub{ my ($web, $name) = @_; $self->{_sc}->set_start_with("window", $name); $self->{_sc}->set_min(TRUE); }, 'a|active' => sub{ $self->{_sc}->set_start_with("awindow"); $self->{_sc}->set_min(TRUE); }, 'section' => sub{ $self->{_sc}->set_start_with("section"); $self->{_sc}->set_min(TRUE); }, 'm|menu' => sub{ $self->{_sc}->set_start_with("menu"); $self->{_sc}->set_min(TRUE); }, 't|tooltip' => sub{ $self->{_sc}->set_start_with("tooltip"); $self->{_sc}->set_min(TRUE); }, 'web:s' => sub{ my ($web, $url) = @_; $self->{_sc}->set_start_with("web", $url); }, 'r|redo' => sub{ $self->{_sc}->set_start_with("redoshot"); $self->{_sc}->set_min(TRUE); }, 'p|profile=s' => sub{ my ($p, $profile) = @_; $self->{_sc}->set_profile_to_start_with($profile); }, 'o|output=s' => sub{ my ($o, $output) = @_; $self->{_sc}->set_export_filename($output); }, 'c|include_cursor' => sub{ $self->{_sc}->set_include_cursor(TRUE); }, 'C|remove_cursor' => sub{ $self->{_sc}->set_remove_cursor(TRUE); }, 'd|delay=s' => sub{ my ($d, $delay) = @_; $self->{_sc}->set_delay($delay); }, 'h|help' => sub{ pod2usage(-verbose => 1); }, 'v|version' => sub{ print $self->{_sc}->get_version, " ", $self->{_sc}->get_rev, "\n"; exit; }, 'debug' => sub{ $self->{_sc}->set_debug(TRUE); }, 'clear_cache' => sub{ $self->{_sc}->set_clear_cache(TRUE); }, 'min_at_startup' => sub{ $self->{_sc}->set_min(TRUE); }, 'disable_systray' => sub{ $self->{_sc}->set_disable_systray(TRUE); }, 'e|exit_after_capture' => sub{ $self->{_sc}->set_exit_after_capture(TRUE); }, 'n|no_session' => sub{ $self->{_sc}->set_no_session(TRUE); }, ); #unknown value are passed through in @ARGV - might be filenames my @init_files; if ( @ARGV > 0 ) { foreach my $arg (@ARGV) { if ( $self->{_shf}->file_exists($arg) || $self->{_shf}->uri_exists($arg) ) { #push filename to array, open when GUI is initialized push @init_files, $arg; next; } else { warn "ERROR: unknown command or filename " . $arg . " \n\n"; pod2usage(-verbose => 1); } } } return \@init_files; } 1; shutter-0.90.1/share/shutter/resources/modules/Shutter/App/Directories.pm0000644000175000017500000000353312206477313025562 0ustar mariomario################################################### # # Copyright (C) 2008-2013 Mario Kemper # # This file is part of Shutter. # # Shutter is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 3 of the License, or # (at your option) any later version. # # Shutter is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License # along with Shutter; if not, write to the Free Software # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA # ################################################### package Shutter::App::Directories; use utf8; use strict; use warnings; #Glib use Glib qw/TRUE FALSE/; sub new { my $class = shift; my $self = { }; bless $self, $class; return $self; } sub create_if_not_exists { my $self = shift; my $dir = shift; mkdir($dir) unless (-d $dir && -r $dir); return $dir; } sub get_root_dir { my $self = shift; return $self->create_if_not_exists(Glib::get_user_cache_dir."/shutter"); } sub get_cache_dir { my $self = shift; return $self->create_if_not_exists($self->get_root_dir."/unsaved"); } sub get_temp_dir { my $self = shift; return $self->create_if_not_exists($self->get_root_dir."/temp"); } sub get_autostart_dir { my $self = shift; return $self->create_if_not_exists(Glib::get_user_config_dir."/autostart"); } sub get_home_dir { my $self = shift; return Glib::get_home_dir; } sub get_config_dir { my $self = shift; return Glib::get_user_config_dir; } sub get_settings_dir { #not implemented } 1; shutter-0.90.1/share/shutter/resources/modules/Shutter/App/Toolbar.pm0000644000175000017500000003314312206477313024710 0ustar mariomario################################################### # # Copyright (C) 2008-2013 Mario Kemper # # This file is part of Shutter. # # Shutter is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 3 of the License, or # (at your option) any later version. # # Shutter is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License # along with Shutter; if not, write to the Free Software # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA # ################################################### package Shutter::App::Toolbar; #modules #-------------------------------------- use utf8; use strict; use Gtk2; #Glib use Glib qw/TRUE FALSE/; #-------------------------------------- sub new { my $class = shift; #constructor my $self = { _common => shift }; bless $self, $class; return $self; } sub create_toolbar { my $self = shift; my $d = $self->{_common}->get_gettext; my $window = $self->{_common}->get_mainwindow; my $shutter_root = $self->{_common}->get_root; #Tooltips my $tooltips = $self->{_common}->get_tooltips; #Icontheme my $icontheme = $self->{_common}->get_theme; #button redoshot #-------------------------------------- my $image_redoshot = Gtk2::Image->new_from_stock( 'gtk-refresh', 'large-toolbar' ); $self->{_redoshot} = Gtk2::ToolButton->new( $image_redoshot, $d->get("Redo") ); #~ $self->{_redoshot}->set_is_important (TRUE); $tooltips->set_tip( $self->{_redoshot}, $d->get("Redo last screenshot") ); #-------------------------------------- #button selection #-------------------------------------- my $image_select; eval{ my $ccursor_pb = Gtk2::Gdk::Cursor->new('left_ptr')->get_image->scale_simple(Gtk2::IconSize->lookup('large-toolbar'), 'bilinear'); $image_select = Gtk2::Image->new_from_pixbuf($ccursor_pb); }; if($@){ if($icontheme->has_icon('applications-accessories')){ $image_select = Gtk2::Image->new_from_icon_name( 'applications-accessories', 'large-toolbar' ); }else{ $image_select = Gtk2::Image->new_from_pixbuf( Gtk2::Gdk::Pixbuf->new_from_file_at_size( "$shutter_root/share/shutter/resources/icons/selection.svg", Gtk2::IconSize->lookup('large-toolbar') ) ); } } $self->{_select} = Gtk2::ToolButton->new( $image_select, $d->get("Selection") ); #The GtkToolButton class uses this property to determine whether #to show or hide its label when the toolbar style is GTK_TOOLBAR_BOTH_HORIZ. #The result is that only tool buttons with the #"is_important" property set have labels, an effect known as "priority text" $self->{_select}->set_is_important (TRUE); $tooltips->set_tip( $self->{_select}, $d->get("Draw a rectangular capture area with your mouse\nto select a specified screen area"), '' ); #-------------------------------------- #button full screen #-------------------------------------- my $image_full; if($icontheme->has_icon('user-desktop')){ $image_full = Gtk2::Image->new_from_icon_name( 'user-desktop', 'large-toolbar' ); }elsif($icontheme->has_icon('desktop')){ $image_full = Gtk2::Image->new_from_icon_name( 'desktop', 'large-toolbar' ); }else{ $image_full = Gtk2::Image->new_from_pixbuf( Gtk2::Gdk::Pixbuf->new_from_file_at_size( "$shutter_root/share/shutter/resources/icons/desktop.svg", Gtk2::IconSize->lookup('large-toolbar') ) ); } $self->{_full} = Gtk2::MenuToolButton->new( $image_full, $d->get("Desktop") ); $self->{_full}->set_is_important (TRUE); $tooltips->set_tip( $self->{_full}, $d->get("Take a screenshot of your whole desktop") ); $self->{_full}->set_arrow_tooltip( $tooltips, $d->get("Capture a specific workspace"), '' ); #-------------------------------------- #button active window #-------------------------------------- #~ my $image_awindow; #~ if($icontheme->has_icon('preferences-system-windows')){ #~ $image_awindow = Gtk2::Image->new_from_icon_name( 'preferences-system-windows', 'large-toolbar' ); #~ }else{ #~ $image_awindow = Gtk2::Image->new_from_pixbuf( #~ Gtk2::Gdk::Pixbuf->new_from_file_at_size( #~ "$shutter_root/share/shutter/resources/icons/sel_window_active.svg", #~ Gtk2::IconSize->lookup('large-toolbar') #~ ) #~ ); #~ } #~ $self->{_awindow} = Gtk2::MenuToolButton->new( $image_awindow, $d->get("Window") ); #~ $self->{_awindow}->set_is_important (TRUE); #~ #~ $tooltips->set_tip( $self->{_awindow}, $d->get("Capture active window") ); #~ $self->{_awindow}->set_arrow_tooltip( $tooltips, $d->get("Take a screenshot of a specific window"), '' ); #-------------------------------------- #button window #-------------------------------------- my $image_window; if($icontheme->has_icon('preferences-system-windows')){ $image_window = Gtk2::Image->new_from_icon_name( 'preferences-system-windows', 'large-toolbar' ); }else{ $image_window = Gtk2::Image->new_from_pixbuf( Gtk2::Gdk::Pixbuf->new_from_file_at_size( "$shutter_root/share/shutter/resources/icons/sel_window.svg", Gtk2::IconSize->lookup('large-toolbar') ) ); } $self->{_window} = Gtk2::MenuToolButton->new( $image_window, $d->get("Window") ); $self->{_window}->set_is_important (TRUE); $tooltips->set_tip( $self->{_window}, $d->get("Select a window with your mouse") ); $self->{_window}->set_arrow_tooltip( $tooltips, $d->get("Take a screenshot of a specific window"), '' ); #button section #-------------------------------------- my $image_window_sect; if($icontheme->has_icon('gdm-xnest')){ $image_window_sect = Gtk2::Image->new_from_icon_name( 'gdm-xnest', 'large-toolbar' ); }else{ $image_window_sect = Gtk2::Image->new_from_pixbuf( Gtk2::Gdk::Pixbuf->new_from_file_at_size( "$shutter_root/share/shutter/resources/icons/sel_window_section.svg", Gtk2::IconSize->lookup('large-toolbar') ) ); } $self->{_section} = Gtk2::ToolButton->new( $image_window_sect, $d->get("Section") ); $tooltips->set_tip( $self->{_section}, $d->get( "Captures only a section of the window. You will be able to select any child window by moving the mouse over it" ) ); #-------------------------------------- #button menu #-------------------------------------- my $image_window_menu; if($icontheme->has_icon('alacarte')){ $image_window_menu = Gtk2::Image->new_from_icon_name( 'alacarte', 'large-toolbar' ); }else{ $image_window_menu = Gtk2::Image->new_from_pixbuf( Gtk2::Gdk::Pixbuf->new_from_file_at_size( "$shutter_root/share/shutter/resources/icons/sel_window_menu.svg", Gtk2::IconSize->lookup('large-toolbar') ) ); } $self->{_menu} = Gtk2::ToolButton->new( $image_window_menu, $d->get("Menu") ); $tooltips->set_tip( $self->{_menu}, $d->get( "Select a single menu or cascading menus from any application" ) ); #-------------------------------------- #button tooltip #-------------------------------------- my $image_window_tooltip; if($icontheme->has_icon('help-faq')){ $image_window_tooltip = Gtk2::Image->new_from_icon_name( 'help-faq', 'large-toolbar' ); }else{ $image_window_tooltip = Gtk2::Image->new_from_pixbuf( Gtk2::Gdk::Pixbuf->new_from_file_at_size( "$shutter_root/share/shutter/resources/icons/sel_window_tooltip.svg", Gtk2::IconSize->lookup('large-toolbar') ) ); } $self->{_tooltip} = Gtk2::ToolButton->new( $image_window_tooltip, $d->get("Tooltip") ); $tooltips->set_tip( $self->{_tooltip}, $d->get( "Capture a tooltip" ) ); #-------------------------------------- #button web #-------------------------------------- my $image_web; if($icontheme->has_icon('web-browser')){ $image_web = Gtk2::Image->new_from_icon_name( 'web-browser', 'large-toolbar' ); }else{ $image_web = Gtk2::Image->new_from_pixbuf( Gtk2::Gdk::Pixbuf->new_from_file_at_size( "$shutter_root/share/shutter/resources/icons/web_image.svg", Gtk2::IconSize->lookup('large-toolbar') ) ); } $self->{_web} = Gtk2::MenuToolButton->new( $image_web, $d->get("Web") ); $tooltips->set_tip( $self->{_web}, $d->get("Take a screenshot of a website") ); $self->{_web}->set_arrow_tooltip( $tooltips, $d->get("Set how long Shutter will wait for the screenshot to complete before aborting the process if it's taking too long"), '' ); #-------------------------------------- #expanding separator #-------------------------------------- my $expander_r = Gtk2::SeparatorToolItem->new; $expander_r->set_expand(TRUE); $expander_r->set_draw(FALSE); #button edit #-------------------------------------- my $image_edit; if($icontheme->has_icon('applications-graphics')){ $image_edit = Gtk2::Image->new_from_icon_name( 'applications-graphics', 'large-toolbar' ); }else{ $image_edit = Gtk2::Image->new_from_pixbuf( Gtk2::Gdk::Pixbuf->new_from_file_at_size( "$shutter_root/share/shutter/resources/icons/draw.svg", Gtk2::IconSize->lookup('large-toolbar') ) ); } $self->{_edit} = Gtk2::ToolButton->new( $image_edit, $d->get("Edit") ); $self->{_edit}->set_is_important (TRUE); $tooltips->set_tip( $self->{_edit}, $d->get("Use the built-in editor to highlight important fragments of your screenshot or crop it to a desired size") ); #-------------------------------------- #button upload #-------------------------------------- my $image_upload = Gtk2::Image->new_from_stock( 'gtk-network', 'large-toolbar' ); $self->{_upload} = Gtk2::MenuToolButton->new( $image_upload, $d->get("Export") ); $self->{_upload}->set_is_important (TRUE); $tooltips->set_tip( $self->{_upload}, $d->get("Upload your images to an image hosting service, FTP site or export them to an arbitrary folder") ); $self->{_upload}->set_arrow_tooltip( $tooltips, $d->get("Show links to previous uploads"), '' ); #-------------------------------------- #create the toolbar $self->{_toolbar} = Gtk2::Toolbar->new; $self->{_toolbar}->set_show_arrow(FALSE); $self->{_toolbar}->insert( $self->{_redoshot}, -1 ); $self->{_toolbar}->insert( Gtk2::SeparatorToolItem->new, -1 ); $self->{_toolbar}->insert( $self->{_select}, -1 ); $self->{_toolbar}->insert( $self->{_full}, -1 ); #~ $self->{_toolbar}->insert( Gtk2::SeparatorToolItem->new, -1 ); #~ $self->{_toolbar}->insert( $self->{_aindow}, -1 ); $self->{_toolbar}->insert( $self->{_window}, -1 ); $self->{_toolbar}->insert( $self->{_section}, -1 ); $self->{_toolbar}->insert( $self->{_menu}, -1 ); $self->{_toolbar}->insert( $self->{_tooltip}, -1 ); #~ $self->{_toolbar}->insert( Gtk2::SeparatorToolItem->new, -1 ); $self->{_toolbar}->insert( $self->{_web}, -1 ); #~ $self->{_toolbar}->insert( Gtk2::SeparatorToolItem->new, -1 ); $self->{_toolbar}->insert( $expander_r, -1 ); $self->{_toolbar}->insert( $self->{_edit}, -1 ); $self->{_toolbar}->insert( $self->{_upload}, -1 ); return $self->{_toolbar}; } sub create_btoolbar { my $self = shift; my $d = $self->{_common}->get_gettext; my $window = $self->{_common}->get_mainwindow; my $shutter_root = $self->{_common}->get_root; #Tooltips my $tooltips = $self->{_common}->get_tooltips; #Icontheme my $icontheme = $self->{_common}->get_theme; #expanding separator #-------------------------------------- my $expander_l = Gtk2::SeparatorToolItem->new; $expander_l->set_expand(TRUE); $expander_l->set_draw(FALSE); #-------------------------------------- #button ascending #-------------------------------------- my $image_sorta = Gtk2::Image->new_from_stock( 'gtk-sort-ascending', 'small-toolbar' ); $self->{_sorta} = Gtk2::ToggleToolButton->new(); $self->{_sorta}->set_icon_widget( $image_sorta ); #-------------------------------------- #button back #-------------------------------------- my $image_back = Gtk2::Image->new_from_stock( 'gtk-go-back', 'small-toolbar' ); $self->{_back} = Gtk2::ToolButton->new( $image_back, '' ); #-------------------------------------- #button home #-------------------------------------- my $image_home = Gtk2::Image->new_from_stock( 'gtk-index', 'small-toolbar' ); $self->{_home} = Gtk2::ToolButton->new( $image_home, '' ); #-------------------------------------- #button forward #-------------------------------------- my $image_forw = Gtk2::Image->new_from_stock( 'gtk-go-forward', 'small-toolbar' ); $self->{_forw} = Gtk2::ToolButton->new( $image_forw, '' ); #-------------------------------------- #button sort descending #-------------------------------------- my $image_sortd = Gtk2::Image->new_from_stock( 'gtk-sort-descending', 'small-toolbar' ); $self->{_sortd} = Gtk2::ToggleToolButton->new(); $self->{_sortd}->set_icon_widget( $image_sortd ); #-------------------------------------- #expanding separator #-------------------------------------- my $expander_r = Gtk2::SeparatorToolItem->new; $expander_r->set_expand(TRUE); $expander_r->set_draw(FALSE); #-------------------------------------- #create the toolbar $self->{_btoolbar} = Gtk2::Toolbar->new; $self->{_btoolbar}->set_no_show_all(TRUE); $self->{_btoolbar}->set_show_arrow(FALSE); $self->{_btoolbar}->set_style('icons'); $self->{_btoolbar}->insert( $expander_l, -1 ); $self->{_btoolbar}->insert( $self->{_sorta}, -1 ); $self->{_btoolbar}->insert( $self->{_back}, -1 ); $self->{_btoolbar}->insert( $self->{_home}, -1 ); $self->{_btoolbar}->insert( $self->{_forw}, -1 ); $self->{_btoolbar}->insert( $self->{_sortd}, -1 ); $self->{_btoolbar}->insert( $expander_r, -1 ); return $self->{_btoolbar}; } 1; shutter-0.90.1/share/shutter/resources/modules/Shutter/App/Notification.pm0000644000175000017500000000436712206477313025742 0ustar mariomario################################################### # # Copyright (C) 2008-2013 Mario Kemper # # This file is part of Shutter. # # Shutter is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 3 of the License, or # (at your option) any later version. # # Shutter is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License # along with Shutter; if not, write to the Free Software # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA # ################################################### package Shutter::App::Notification; #modules #-------------------------------------- use utf8; use strict; use warnings; use Net::DBus; #Glib use Glib qw/TRUE FALSE/; #-------------------------------------- sub new { my $class = shift; my $self = { }; #Use notifications object eval{ $self->{_notifications_service} = Net::DBus->session->get_service('org.freedesktop.Notifications'); $self->{_notifications_object} = $self->{_notifications_service}->get_object('/org/freedesktop/Notifications', 'org.freedesktop.Notifications'); }; if($@){ print "Warning: $@", "\n"; } #last nid $self->{_nid} = 0; bless $self, $class; return $self; } sub show { my $self = shift; my $summary = shift; my $body = shift; my $nid = shift || $self->{_nid}; #notification eval{ if(defined $self->{_notifications_object}){ $self->{_nid} = $self->{_notifications_object}->Notify('Shutter', $nid, "gtk-dialog-info", $summary, $body, [], {}, -1); } }; if($@){ print "NotifyWarning: $@", "\n"; } return $self->{_nid}; } sub close { my $self = shift; my $nid = shift || $self->{_nid}; #close notification if($nid){ eval{ if(defined $self->{_notifications_object}){ $self->{_notifications_object}->CloseNotification($nid); } }; if($@){ print "CloseNotificationWarning: $@", "\n"; } return TRUE; } return FALSE; } 1; shutter-0.90.1/share/shutter/resources/modules/Shutter/App/HelperFunctions.pm0000644000175000017500000001143612206477313026417 0ustar mariomario################################################### # # Copyright (C) 2008-2013 Mario Kemper # # This file is part of Shutter. # # Shutter is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 3 of the License, or # (at your option) any later version. # # Shutter is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License # along with Shutter; if not, write to the Free Software # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA # ################################################### package Shutter::App::HelperFunctions; #modules #-------------------------------------- use utf8; use strict; use Gtk2; #Glib use Glib qw/TRUE FALSE/; #-------------------------------------- ##################public subs################## sub new { my $class = shift; #constructor my $self = { _common => shift }; #import shutter dialogs my $current_window = $self->{_common}->get_mainwindow; $self->{_dialogs} = Shutter::App::SimpleDialogs->new( $current_window ); #gettext $self->{_d} = $self->{_common}->get_gettext; bless $self, $class; return $self; } sub xdg_open { my ( $self, $dialog, $link, $user_data ) = @_; system("xdg-open $link"); if($?){ my $response = $self->{_dialogs}->dlg_error_message( sprintf( $self->{_d}->get("Error while executing %s."), "'xdg-open'"), sprintf( $self->{_d}->get("There was an error executing %s."), "'xdg-open'"), undef, undef, undef, undef, undef, undef, sprintf( $self->{_d}->get("Exit Code: %d."), $? >> 8) ); } } sub xdg_open_mail { my ( $self, $dialog, $mail, $user_data ) = @_; system("xdg-email $mail $user_data"); if($?){ my $response = $self->{_dialogs}->dlg_error_message( sprintf( $self->{_d}->get("Error while executing %s."), "'xdg-email'"), sprintf( $self->{_d}->get("There was an error executing %s."), "'xdg-email'"), undef, undef, undef, undef, undef, undef, sprintf( $self->{_d}->get("Exit Code: %d."), $? >> 8) ); } } sub nautilus_sendto { my ( $self, $user_data ) = @_; system("nautilus-sendto $user_data &"); if($?){ my $response = $self->{_dialogs}->dlg_error_message( sprintf( $self->{_d}->get("Error while executing %s."), "'nautilus-sendto'"), sprintf( $self->{_d}->get("There was an error executing %s."), "'nautilus-sendto'"), undef, undef, undef, undef, undef, undef, sprintf( $self->{_d}->get("Exit Code: %d."), $? >> 8) ); } } sub file_exists { my ( $self, $filename ) = @_; return FALSE unless $filename; $filename = $self->switch_home_in_file($filename); return TRUE if ( -f $filename && -r $filename ); return FALSE; } sub folder_exists { my ( $self, $folder ) = @_; return FALSE unless $folder; $folder = $self->switch_home_in_file($folder); return TRUE if ( -d $folder && -r $folder ); return FALSE; } sub uri_exists { my ( $self, $filename ) = @_; return FALSE unless $filename; $filename = $self->switch_home_in_file($filename); my $new_uri = Gnome2::VFS::URI->new($filename); return TRUE if $new_uri->exists; return FALSE; } sub file_executable { my ( $self, $filename ) = @_; return FALSE unless $filename; $filename = $self->switch_home_in_file($filename); return TRUE if ( -x $filename ); return FALSE; } sub switch_home_in_file { my ( $self, $filename ) = @_; $filename =~ s/^~/$ENV{ HOME }/; #switch ~ in path to /home/username return $filename; } sub utf8_decode { my $self = shift; my $string = shift; #see https://bugs.launchpad.net/shutter/+bug/347821 utf8::decode $string; return $string; } sub usage { my $self = shift; print "shutter [options]\n"; print "Available options:\n\n" . "Capture:\n" . "--select (starts Shutter in selection mode)\n" . "--full (starts Shutter and takes a full screen screenshot directly)\n" . "--window (starts Shutter in window selection mode)\n" . "--awindow (capture the active window)\n" . "--section (starts Shutter in section selection mode)\n" . "--menu (starts Shutter in menu selection mode)\n" . "--tooltip (starts Shutter in tooltip selection mode)\n" . "--web (starts Shutter in web capture mode)\n\n" . "Application:\n" . "--min_at_startup (starts Shutter minimized to tray)\n" . "--clear_cache (clears cache, e.g. installed plugins, at startup)\n" . "--debug (prints a lot of debugging information to STDOUT)\n" . "--disable_systray (disable systray icon)\n" . "--version (displays version information)\n" . "--help (displays this help)\n"; return TRUE; } 1; shutter-0.90.1/share/shutter/resources/modules/Shutter/App/ShutterNotification.pm0000644000175000017500000001506412206477313027315 0ustar mariomario################################################### # # Copyright (C) 2008-2013 Mario Kemper # # This file is part of Shutter. # # Shutter is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 3 of the License, or # (at your option) any later version. # # Shutter is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License # along with Shutter; if not, write to the Free Software # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA # ################################################### package Shutter::App::ShutterNotification; #modules #-------------------------------------- use utf8; use strict; use warnings; #Glib use Glib qw/TRUE FALSE/; #Gtk2 and Pango use Gtk2; use Gtk2::Pango; #-------------------------------------- sub new { my $class = shift; my $self = { _sc => shift }; #Use notifications object eval{ #notification window (borderless gtk window) $self->{_notifications_window} = Gtk2::Window->new('popup'); if($self->{_sc}->get_mainwindow->get_screen->is_composited){ $self->{_notifications_window}->set_colormap($self->{_sc}->get_mainwindow->get_screen->get_rgba_colormap); } $self->{_notifications_window}->set_app_paintable(TRUE); $self->{_notifications_window}->set_decorated(FALSE); $self->{_notifications_window}->set_skip_taskbar_hint(TRUE); $self->{_notifications_window}->set_skip_pager_hint(TRUE); $self->{_notifications_window}->set_keep_above(TRUE); $self->{_notifications_window}->set_accept_focus(FALSE); $self->{_notifications_window}->add_events('GDK_ENTER_NOTIFY_MASK'); #shape the window my $pixbuf = Gtk2::Gdk::Pixbuf->new_from_file ($self->{_sc}->get_root . "/share/shutter/resources/icons/notify.svg"); #~ my ($pixmap, $mask) = $pixbuf->render_pixmap_and_mask (1); #~ $self->{_notifications_window}->shape_combine_mask($mask, 0, 0); #add a widget to control size of the window my $fixed = Gtk2::Fixed->new; $fixed->set_size_request(300, 120); $self->{_notifications_window}->add($fixed); $self->{_notifications_window}->signal_connect('expose-event' => sub{ return FALSE unless $self->{_notifications_window}->window; return FALSE unless $self->{_summary}; #current monitor my $mon = $self->{_sc}->get_current_monitor; #initial position unless(defined $self->{_notifications_window}->{'pos'}){ $self->{_notifications_window}->move($mon->x + $mon->width - 315, $mon->y + $mon->height - 140); $self->{_notifications_window}->{'pos'} = 1; } #window size and position my ($w, $h) = $self->{_notifications_window}->get_size; my ($x, $y) = $self->{_notifications_window}->get_position; #obtain current colors and font_desc from the main window my $style = $self->{_sc}->get_mainwindow->get_style; my $sel_bg = Gtk2::Gdk::Color->parse('#131313'); my $sel_tx = Gtk2::Gdk::Color->parse('white'); my $font_fam = $style->font_desc->get_family; my $font_size = $style->font_desc->get_size / Gtk2::Pango->scale; #create cairo context my $cr = Gtk2::Gdk::Cairo::Context->create ($self->{_notifications_window}->window); #pango layout my $layout = Gtk2::Pango::Cairo::create_layout($cr); $layout->set_width( ($w - 30) * Gtk2::Pango->scale ); if ( Gtk2::Pango->CHECK_VERSION( 1, 20, 0 ) ) { $layout->set_height( ($h - 20) * Gtk2::Pango->scale ); }else{ warn "WARNING: \$layout->set_height is not available - outdated Pango version\n"; } if ( Gtk2::Pango->CHECK_VERSION( 1, 6, 0 ) ) { $layout->set_ellipsize ('middle'); }else{ warn "WARNING: \$layout->set_ellipsize is not available - outdated Pango version\n"; } $layout->set_alignment('left'); $layout->set_wrap('word-char'); #set text $layout->set_markup("" . Glib::Markup::escape_text( $self->{_summary} ) . "\n" . Glib::Markup::escape_text( $self->{_body} ) . ""); $cr->set_operator('source'); if($self->{_sc}->get_mainwindow->get_screen->is_composited){ $cr->set_source_rgba( 1.0, 1.0, 1.0, 0 ); Gtk2::Gdk::Cairo::Context::set_source_pixbuf( $cr, $pixbuf, 0, 0 ); $cr->paint; }else{ $cr->set_source_rgb( $sel_bg->red / 257 / 255, $sel_bg->green / 257 / 255, $sel_bg->blue / 257 / 255 ); $cr->paint; } $cr->set_operator('over'); #get layout size my ( $lw, $lh ) = $layout->get_pixel_size; $cr->move_to( ($w - $lw) / 2, ($h - $lh) / 2 ); Gtk2::Pango::Cairo::show_layout( $cr, $layout ); return TRUE; }); $self->{_notifications_window}->signal_connect('enter-notify-event' => sub{ #remove old handler if(defined $self->{_enter_notify_timeout}){ Glib::Source->remove($self->{_enter_notify_timeout}); } #current monitor my $mon = $self->{_sc}->get_current_monitor; if(defined $self->{_notifications_window}->{'pos'} && $self->{_notifications_window}->{'pos'} == 1){ $self->{_notifications_window}->move($mon->x + $mon->width - 315, $mon->y + 40); $self->{_notifications_window}->{'pos'} = 0; }else{ $self->{_notifications_window}->move($mon->x + $mon->width - 315, $mon->y + $mon->height - 140); $self->{_notifications_window}->{'pos'} = 1; } $self->{_enter_notify_timeout} = Glib::Timeout->add (100, sub{ $self->show($self->{_summary}, $self->{_body}); }); return FALSE; }); }; if($@){ print "Warning: $@", "\n"; } #last nid $self->{_nid} = 0; bless $self, $class; return $self; } sub show { my $self = shift; #remove old handler if(defined $self->{_notifications_timeout}){ Glib::Source->remove($self->{_notifications_timeout}); } #set body and summary $self->{_summary} = shift; $self->{_body} = shift; $self->{_notifications_window}->show_all; $self->{_notifications_window}->queue_draw; $self->{_notifications_timeout} = Glib::Timeout->add (3000, sub{ $self->close; }); return 0; } sub close { my $self = shift; my $no_clear = shift; #clear body and summary unless($no_clear){ $self->{_summary} = undef; $self->{_body} = undef; } $self->{_notifications_window}->hide_all; $self->{_notifications_window}->{'pos'} = undef; return 0; } 1; shutter-0.90.1/share/shutter/resources/modules/Shutter/App/Optional/0000755000175000017500000000000012206477313024531 5ustar mariomarioshutter-0.90.1/share/shutter/resources/modules/Shutter/App/Optional/Exif.pm0000644000175000017500000000262212206477313025764 0ustar mariomario################################################### # # Copyright (C) 2008-2013 Mario Kemper # # This file is part of Shutter. # # Shutter is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 3 of the License, or # (at your option) any later version. # # Shutter is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License # along with Shutter; if not, write to the Free Software # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA # ################################################### package Shutter::App::Optional::Exif; #modules #-------------------------------------- use utf8; use strict; use Glib qw/TRUE FALSE/; #-------------------------------------- sub new { my $class = shift; my $self = { }; #libimage-exiftool-perl eval { require Image::ExifTool }; if ($@) { $self->{_exiftool} = FALSE; }else{ $self->{_exiftool} = new Image::ExifTool; } bless $self, $class; return $self; } #getter / setter sub get_exiftool { my $self = shift; return $self->{_exiftool}; } 1; shutter-0.90.1/share/shutter/resources/modules/Shutter/App/AboutDialog.pm0000644000175000017500000000603612206477313025501 0ustar mariomario################################################### # # Copyright (C) 2008-2013 Mario Kemper # # This file is part of Shutter. # # Shutter is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 3 of the License, or # (at your option) any later version. # # Shutter is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License # along with Shutter; if not, write to the Free Software # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA # ################################################### package Shutter::App::AboutDialog; #modules #-------------------------------------- use utf8; use strict; use Gtk2; #Glib use Glib qw/TRUE FALSE/; #-------------------------------------- sub new { my $class = shift; #constructor my $self = { _sc => shift }; bless $self, $class; return $self; } sub show { my $self = shift; my $shf = Shutter::App::HelperFunctions->new( $self->{_sc} ); my $shutter_root = $self->{_sc}->get_root; my $d = $self->{_sc}->get_gettext; #everything is stored in external files, so it is easier to maintain my $all_hint = ""; open( GPL_HINT, "$shutter_root/share/shutter/resources/license/gplv3_hint" ) or die $!; while(my $hint = ){ utf8::decode $hint; $all_hint .= $hint; } close(GPL_HINT); my $all_gpl = ""; open( GPL, "$shutter_root/share/shutter/resources/license/gplv3" ) or die $!; while(my $gpl = ){ utf8::decode $gpl; $all_gpl .= $gpl; } close(GPL); my $all_dev = ""; open( DEVCREDITS, "$shutter_root/share/shutter/resources/credits/dev" ) or die $!; while(my $dev = ){ utf8::decode $dev; $all_dev .= $dev; } close(DEVCREDITS); my $all_art = ""; open( ARTCREDITS, "$shutter_root/share/shutter/resources/credits/art" ) or die $!; while(my $art = ){ utf8::decode $art; $all_art .= $art; } close(ARTCREDITS); my $about = Gtk2::AboutDialog->new; $about->set_logo_icon_name('shutter'); if (Gtk2->CHECK_VERSION( 2, 12, 0 )){ $about->set_program_name($self->{_sc}->get_appname); }else{ $about->set_name($self->{_sc}->get_appname); } $about->set_version($self->{_sc}->get_version); $about->set_url_hook( sub { $shf->xdg_open(@_) } ); #~ $about->set_website_label("Shutter-Website"); $about->set_website("http://shutter-project.org"); $about->set_email_hook( sub { $shf->xdg_open_mail(@_) } ); $about->set_authors( $all_dev ); $about->set_artists( $all_art ); $about->set_translator_credits($d->get("translator-credits")); $about->set_copyright($all_hint); $about->set_license($all_gpl); $about->set_comments($self->{_sc}->get_rev); $about->show_all; $about->signal_connect( 'response' => sub { $about->destroy } ); } 1; shutter-0.90.1/share/shutter/resources/modules/Shutter/App/GlobalSettings.pm0000644000175000017500000000355512206477313026233 0ustar mariomario################################################### # # Copyright (C) 2008-2013 Mario Kemper # # This file is part of Shutter. # # Shutter is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 3 of the License, or # (at your option) any later version. # # Shutter is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License # along with Shutter; if not, write to the Free Software # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA # ################################################### package Shutter::App::GlobalSettings; #modules #-------------------------------------- use utf8; use strict; #Glib use Glib qw/TRUE FALSE/; #-------------------------------------- sub new { my $class = shift; my $self = { }; $self->{_png_quality} = undef; $self->{_jpg_quality} = undef; bless $self, $class; return $self; } #getter / setter sub get_png_quality { my $self = shift; if(defined $self->{_png_quality}){ return $self->{_png_quality}; }else{ return 9; } } sub get_jpg_quality { my $self = shift; if(defined $self->{_jpg_quality}){ return $self->{_jpg_quality}; }else{ return 90; } } sub set_png_quality { my $self = shift; if (@_) { $self->{_png_quality} = shift; } return $self->{_png_quality}; } sub set_jpg_quality { my $self = shift; if (@_) { $self->{_jpg_quality} = shift; } return $self->{_jpg_quality}; } sub clear_quality_settings { my $self = shift; $self->{_jpg_quality} = undef; $self->{_png_quality} = undef; } 1; shutter-0.90.1/share/shutter/resources/modules/Shutter/App/Common.pm0000644000175000017500000002052412206477313024535 0ustar mariomario################################################### # # Copyright (C) 2008-2013 Mario Kemper # # This file is part of Shutter. # # Shutter is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 3 of the License, or # (at your option) any later version. # # Shutter is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License # along with Shutter; if not, write to the Free Software # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA # ################################################### package Shutter::App::Common; #modules #-------------------------------------- use utf8; use strict; use Gtk2; #Gettext and filename parsing use POSIX qw/setlocale/; use Locale::gettext; #Glib use Glib qw/TRUE FALSE/; #File use File::Spec; #-------------------------------------- ##################public subs################## sub new { my $class = shift; #constructor my $self = { _shutter_root => shift, _mainwindow => shift, _appname => shift, _version => shift, _rev => shift, _pid => shift }; #vars $self->{_debug_cparam} = FALSE; $self->{_clear_cache} = FALSE; $self->{_min_cparam} = FALSE; $self->{_disable_systray_cparam} = FALSE; $self->{_exit_after_capture_cparam} = FALSE; $self->{_no_session_cparam} = FALSE; $self->{_start_with} = undef; $self->{_start_with_extra} = undef; $self->{_profile_to_start_with} = undef; $self->{_export_filename} = undef; $self->{_delay} = undef; $self->{_include_cursor} = undef; $self->{_remove_cursor} = undef; #Set LC_NUMERIC to C to prevent decimal commas (or anything else) setlocale(LC_NUMERIC, "C"); setlocale( LC_MESSAGES, "" ); #gettext init $self->{_gettext_object} = Locale::gettext->domain("shutter"); $self->{_gettext_object}->dir( $self->{_shutter_root} . "/share/locale" ); #ENV needed by some plugins $ENV{'SHUTTER_INTL'} = $self->{_shutter_root} . "/share/locale"; #tooltips $self->{_tooltips} = Gtk2::Tooltips->new; #notification object $self->{_notification}; #globalsettings object $self->{_globalsettings}; #icontheme to determine if icons exist or not #in some cases we deliver fallback icons $self->{_icontheme} = Gtk2::IconTheme->get_default; $self->{_icontheme}->append_search_path($self->{_shutter_root} . "/share/icons"); #recently used upload tab $self->{_ruu_tab} = 0; #... and details $self->{_ruu_hosting} = 0; $self->{_ruu_places} = 0; $self->{_ruu_u1} = 0; #recently used save folder $self->{_rusf} = undef; #recently used open folder $self->{_ruof} = undef; bless $self, $class; return $self; } #getter / setter sub get_root { my $self = shift; return $self->{_shutter_root}; } sub get_pid { my $self = shift; return $self->{_pid}; } sub set_pid { my $self = shift; if (@_) { $self->{_pid} = shift; } return $self->{_pid}; } sub get_appname { my $self = shift; return $self->{_appname}; } sub get_version { my $self = shift; return $self->{_version}; } sub get_rev { my $self = shift; return $self->{_rev}; } sub get_gettext { my $self = shift; return $self->{_gettext_object}; } sub set_gettext { my $self = shift; if (@_) { $self->{_gettext_object} = shift; } return $self->{_gettext_object}; } sub get_theme { my $self = shift; return $self->{_icontheme}; } sub get_tooltips { my $self = shift; return $self->{_tooltips}; } sub set_tooltips { my $self = shift; if (@_) { $self->{_tooltips} = shift; } return $self->{_tooltips}; } sub get_notification_object { my $self = shift; return $self->{_notification}; } sub set_notification_object { my $self = shift; if (@_) { $self->{_notification} = shift; } return $self->{_notification}; } sub get_globalsettings_object { my $self = shift; return $self->{_globalsettings}; } sub set_globalsettings_object { my $self = shift; if (@_) { $self->{_globalsettings} = shift; } return $self->{_globalsettings}; } sub get_rusf { my $self = shift; return $self->{_rusf}; } sub set_rusf { my $self = shift; if (@_) { $self->{_rusf} = shift; } return $self->{_rusf}; } sub get_ruof { my $self = shift; return $self->{_ruof}; } sub set_ruof { my $self = shift; if (@_) { $self->{_ruof} = shift; } return $self->{_ruof}; } sub get_ruu_tab { my $self = shift; return $self->{_ruu_tab}; } sub set_ruu_tab { my $self = shift; if (@_) { $self->{_ruu_tab} = shift; } return $self->{_ruu_tab}; } sub get_ruu_hosting { my $self = shift; return $self->{_ruu_hosting}; } sub get_ruu_places { my $self = shift; return $self->{_ruu_places}; } sub get_ruu_u1 { my $self = shift; return $self->{_ruu_u1}; } sub set_ruu_hosting { my $self = shift; if (@_) { $self->{_ruu_hosting} = shift; } return $self->{_ruu_hosting}; } sub set_ruu_places { my $self = shift; if (@_) { $self->{_ruu_places} = shift; } return $self->{_ruu_places}; } sub set_ruu_u1 { my $self = shift; if (@_) { $self->{_ruu_u1} = shift; } return $self->{_ruu_u1}; } sub get_debug { my $self = shift; return $self->{_debug_cparam}; } sub set_debug { my $self = shift; if (@_) { $self->{_debug_cparam} = shift; } return $self->{_debug_cparam}; } sub get_clear_cache { my $self = shift; return $self->{_clear_cache}; } sub set_clear_cache { my $self = shift; if (@_) { $self->{_clear_cache} = shift; } return $self->{_clear_cache}; } sub get_mainwindow { my $self = shift; return $self->{_mainwindow}; } sub set_mainwindow { my $self = shift; if (@_) { $self->{_mainwindow} = shift; } return $self->{_mainwindow}; } sub get_min { my $self = shift; return $self->{_min_cparam}; } sub set_min { my $self = shift; if (@_) { $self->{_min_cparam} = shift; } return $self->{_min_cparam}; } sub get_disable_systray { my $self = shift; return $self->{_disable_systray_cparam}; } sub set_disable_systray { my $self = shift; if (@_) { $self->{_disable_systray_cparam} = shift; } return $self->{_disable_systray_cparam}; } sub get_exit_after_capture { my $self = shift; return $self->{_exit_after_capture_cparam}; } sub set_exit_after_capture { my $self = shift; if (@_) { $self->{_exit_after_capture_cparam} = shift; } return $self->{_exit_after_capture_cparam}; } sub get_no_session { my $self = shift; return $self->{_no_session_cparam}; } sub set_no_session { my $self = shift; if (@_) { $self->{_no_session_cparam} = shift; } return $self->{_no_session_cparam}; } sub get_start_with { my $self = shift; return ($self->{_start_with}, $self->{_start_with_extra}); } sub set_start_with { my $self = shift; if (@_) { $self->{_start_with} = shift; $self->{_start_with_extra} = shift; } return ($self->{_start_with}, $self->{_start_with_extra}); } sub get_profile_to_start_with { my $self = shift; return $self->{_profile_to_start_with}; } sub set_profile_to_start_with { my $self = shift; if (@_) { $self->{_profile_to_start_with} = shift; } return $self->{_profile_to_start_with}; } sub get_export_filename { my $self = shift; return $self->{_export_filename}; } sub set_export_filename { my $self = shift; if (@_) { $self->{_export_filename} = shift; } return $self->{_export_filename}; } sub get_include_cursor { my $self = shift; return $self->{_include_cursor}; } sub set_include_cursor { my $self = shift; if (@_) { $self->{_include_cursor} = shift; } return $self->{_include_cursor}; } sub get_remove_cursor { my $self = shift; return $self->{_remove_cursor}; } sub set_remove_cursor { my $self = shift; if (@_) { $self->{_remove_cursor} = shift; } return $self->{_remove_cursor}; } sub get_delay { my $self = shift; return $self->{_delay}; } sub set_delay { my $self = shift; if (@_) { $self->{_delay} = shift; } return $self->{_delay}; } sub get_current_monitor { my $self = shift; my ( $window_at_pointer, $x, $y, $mask ) = Gtk2::Gdk->get_default_root_window->get_pointer; my $mon = Gtk2::Gdk::Screen->get_default->get_monitor_geometry( Gtk2::Gdk::Screen->get_default->get_monitor_at_point ($x, $y)); return ($mon); } 1; shutter-0.90.1/share/shutter/resources/modules/Shutter/Upload/0000755000175000017500000000000012206477313023450 5ustar mariomarioshutter-0.90.1/share/shutter/resources/modules/Shutter/Upload/UbuntuOne.pm0000644000175000017500000001407412206477313025740 0ustar mariomario################################################### # # Copyright (C) 2008-2013 Mario Kemper # # This file is part of Shutter. # # Shutter is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 3 of the License, or # (at your option) any later version. # # Shutter is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License # along with Shutter; if not, write to the Free Software # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA # ################################################### package Shutter::Upload::UbuntuOne; use utf8; use strict; #DBus message system use Net::DBus::GLib; #Glib use Glib qw/TRUE FALSE/; #-------------------------------------- sub new { my $class = shift; my $self = { _sc => shift, }; bless $self, $class; return $self; } #~ sub DESTROY { #~ my $self = shift; #~ print "$self dying at\n"; #~ } sub connect_to_bus { my $self = shift; eval{ $self->{_bus} = Net::DBus::GLib->session(); $self->{_service} = $self->{_bus}->get_service("com.ubuntuone.SyncDaemon"); }; if($@){ print "Warning: $@", "\n"; return ($@); } return ($self->{_service}); } sub check_api { my $self = shift; return FALSE unless $self->is_connected; my $api = $self->{_service}->get_object("/", "org.freedesktop.DBus.Introspectable"); my $node = $api->Introspect(); if($node =~ /name=\"publicfiles\"/){ return TRUE; } print "Warning: Node 'publicfiles' not found. Your Ubuntu One installation seems to be out of date.", "\n"; return FALSE; } sub get_syncdaemon { my $self = shift; return FALSE unless $self->is_connected; unless(defined $self->{_sd}){ $self->{_sd} = $self->{_service}->get_object("/", "com.ubuntuone.SyncDaemon.SyncDaemon"); } return $self->{_sd}; } sub get_syncdaemon_fs { my $self = shift; return FALSE unless $self->is_connected; unless(defined $self->{_sd_fs}){ $self->{_sd_fs} = $self->{_service}->get_object("/filesystem", "com.ubuntuone.SyncDaemon.FileSystem"); } return $self->{_sd_fs}; } sub get_syncdaemon_events { my $self = shift; return FALSE unless $self->is_connected; unless(defined $self->{_sd_ev}){ $self->{_sd_ev} = $self->{_service}->get_object("/events", "com.ubuntuone.SyncDaemon.Events"); } return $self->{_sd_ev}; } sub get_syncdaemon_folders { my $self = shift; return FALSE unless $self->is_connected; unless(defined $self->{_sd_folders}){ $self->{_sd_folders} = $self->{_service}->get_object("/folders", "com.ubuntuone.SyncDaemon.Folders"); } return $self->{_sd_folders}; } sub get_syncdaemon_config { my $self = shift; return FALSE unless $self->is_connected; #the following does not exist in all versions of U1 my $api = $self->{_service}->get_object("/", "org.freedesktop.DBus.Introspectable"); my $node = $api->Introspect(); if($node =~ /name=\"config\"/){ unless(defined $self->{_sd_config}){ $self->{_sd_config} = $self->{_service}->get_object("/config", "com.ubuntuone.SyncDaemon.Config"); } return $self->{_sd_config}; } print "Warning: Node 'config' not found. Your Ubuntu One installation seems to be out of date. Unable to check for configuration.", "\n"; return FALSE; } sub get_syncdaemon_shares { my $self = shift; return FALSE unless $self->is_connected; unless(defined $self->{_sd_shares}){ $self->{_sd_shares} = $self->{_service}->get_object("/shares", "com.ubuntuone.SyncDaemon.Shares"); } return $self->{_sd_shares}; } sub get_syncdaemon_status { my $self = shift; return FALSE unless $self->is_connected; unless(defined $self->{_sd_status}){ $self->{_sd_status} = $self->{_service}->get_object("/status", "com.ubuntuone.SyncDaemon.Status"); } return $self->{_sd_status}; } sub get_syncdaemon_public { my $self = shift; return FALSE unless $self->is_connected; unless(defined $self->{_sd_public}){ $self->{_sd_public} = $self->{_service}->get_object("/publicfiles", "com.ubuntuone.SyncDaemon.PublicFiles"); } return $self->{_sd_public}; } sub is_connected { my $self = shift; return TRUE if defined $self->{_bus} && defined $self->{_service}; print "Warning: Not connected to bus, you need to call 'connect_to_bus' first", "\n"; return FALSE; } sub is_online { my $self = shift; return FALSE unless $self->is_connected; my ($is_connected, $is_online, $text) = $self->get_current_status; return TRUE if $is_connected && $is_online; print "Warning: Not online, maybe your computer is not connected to a network", "\n"; return FALSE; } sub get_current_status { my $self = shift; my $status_ref = shift; return FALSE unless $self->is_connected; my %status; if(defined $status_ref){ %status = %{$status_ref}; }else{ %status = %{$self->get_syncdaemon_status->current_status}; } #create human readable messages my $d = $self->{_sc}->get_gettext; my $text = $d->get("Disconnected"); if($status{is_connected}){ if($status{name} eq 'QUEUE_MANAGER' && $status{queues} eq 'IDLE'){ $text = $d->get("Synchronization complete"); }else{ $text = $d->get("Synchronization in progress..."); } } return ($status{is_connected}, $status{is_online}, $text); } sub is_synced_folder { my $self = shift; my $folder = shift; return FALSE unless defined $folder; return FALSE unless $self->is_connected; my $sd_fs = $self->get_syncdaemon_fs($folder); my %meta; eval{ %meta = %{$sd_fs->get_metadata($folder)}; print Dumper %meta; }; if($@){ return FALSE; } return $meta{is_dir}; } sub is_notifications_enabled { my $self = shift; return FALSE unless $self->is_connected; my $sd_cf = $self->get_syncdaemon_config; #does not exist in all version of U1 return FALSE unless $sd_cf; my $is_enabled = TRUE; eval{ $is_enabled = $sd_cf->show_all_notifications_enabled; }; if($@){ return FALSE; } return $is_enabled; } 1; shutter-0.90.1/share/shutter/resources/modules/Shutter/Upload/FTP.pm0000644000175000017500000001001712206477313024436 0ustar mariomario################################################### # # Copyright (C) 2008-2013 Mario Kemper # # This file is part of Shutter. # # Shutter is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 3 of the License, or # (at your option) any later version. # # Shutter is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License # along with Shutter; if not, write to the Free Software # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA # ################################################### package Shutter::Upload::FTP; use utf8; use strict; use Net::FTP; use URI; use URI::Split qw(uri_split); #Glib use Glib qw/TRUE FALSE/; #-------------------------------------- sub new { my $class = shift; my $self = { _debug_cparam => shift, _shutter_root => shift, _gettext_object => shift, _main_gtk_window => shift, _mode => shift #active or passive }; #connection settings $self->{_prot} = ""; $self->{_host} = ""; $self->{_port} = ""; $self->{_path} = ""; $self->{_auth} = ""; $self->{_query} = ""; $self->{_frag} = ""; #credentials and filename $self->{_filename} = undef; $self->{_username} = undef; $self->{_password} = undef; bless $self, $class; return $self; } sub login { my ( $self, $uri, $username, $password ) = @_; #uri should start with ftp:// to parse it correctly $uri = "ftp://" . $uri unless ( $uri =~ /^ftp:\/\// ); #split uri my $u = URI->new($uri); ( $self->{_prot}, $self->{_auth}, $self->{_path}, $self->{_query}, $self->{_frage} ) = uri_split($u); #get port and host $self->{_auth} =~ /(.*):?([0-9]?)/; $self->{_host} = $1 || "undefined.host"; $self->{_port} = $2 || 21; #check uri and return if anything is missing unless ( $self->{_host} && $self->{_port} ) { return ( $self->{_gettext_object}->get("Illegal URI."), "<>", undef); } #store parms as object vars $self->{_username} = $username; $self->{_password} = $password; utf8::encode $self->{_host}; utf8::encode $self->{_username} if $self->{_username}; utf8::encode $self->{_password} if $self->{_password}; #CONNECT TO FTP SERVER $self->{_ftp} = Net::FTP->new( $self->{_host}, Passive => $self->{_mode}, Port => $self->{_port}, Timeout => 10 ) or return ( $self->{_gettext_object}->get("Connection error."), $self->{_gettext_object}->get("Please check your connectivity and try again."), $@); #TRY TO LOGIN WITH GIVEN CREDENTIALS $self->{_ftp}->login( $self->{_username}, $self->{_password} ) or return ( sprintf ($self->{_gettext_object}->get("Login with username %s failed."), "'".$self->{_username}."'"), $self->{_gettext_object}->get("Please check your credentials and try again."), $self->{_ftp}->message); #THERE ARE NO ERRORS WHEN ROUTINE RETURNS AT THIS POINT return (FALSE); } sub upload { my ( $self, $upload_filename ) = @_; #store parms as object vars $self->{_filename} = $upload_filename; utf8::encode $self->{_filename}; #CHANGE WORKING DIRECTORY USING CWD COMMAND $self->{_ftp}->cwd( $self->{_path} ) or return ( $self->{_gettext_object}->get("Failed"), $self->{_gettext_object}->get("Cannot change working directory."), $self->{_ftp}->message ); $self->{_ftp}->binary; #UPLOAD FILE $self->{_ftp}->put( $self->{_filename} ) or return ( $self->{_gettext_object}->get("Failed"), $self->{_gettext_object}->get("Command 'put' failed."), $self->{_ftp}->message ); #THERE ARE NO ERRORS WHEN ROUTINE RETURNS AT THIS POINT return (FALSE); } sub quit { my $self = shift; #QUIT CONNECTION $self->{_ftp}->quit; #THERE ARE NO ERRORS WHEN ROUTINE RETURNS AT THIS POINT return (FALSE); } 1; shutter-0.90.1/share/shutter/resources/modules/Shutter/Upload/Shared.pm0000644000175000017500000001055712206477313025224 0ustar mariomario#! /usr/bin/env perl ################################################### # # Copyright (C) 2008, 2009, 2010 Mario Kemper and Shutter Team # # This file is part of Shutter. # # Shutter is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 3 of the License, or # (at your option) any later version. # # Shutter is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License # along with Shutter; if not, write to the Free Software # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA # ################################################### package Shutter::Upload::Shared; use utf8; use strict; use POSIX qw/setlocale/; use Locale::gettext; use Glib qw/TRUE FALSE/; use Data::Dumper; sub new { my $class = shift; my $self = { _host => shift, _debug_cparam => shift, _shutter_root => shift, _gettext_object => shift, _main_gtk_window => shift, _ua => shift }; #received links are stored here $self->{_links} = undef; #credentials and filename $self->{_filename} = undef; $self->{_username} = undef; $self->{_password} = undef; $self->{_notebook} = Gtk2::Notebook->new; $self->{_notebook}->set( homogeneous => 1 ); $self->{_notebook}->set_scrollable(TRUE); bless $self, $class; return $self; } sub create_tab { my $self = shift; my $upload_vbox = Gtk2::VBox->new( FALSE, 0 ); #sizegroup for all labels my $sg = Gtk2::SizeGroup->new('horizontal'); #create entry for each link foreach (keys %{$self->{_links}}){ next if $_ eq 'status'; my $box = $self->create_entry_for_notebook($_, $self->{_links}->{$_}, $sg); $upload_vbox->pack_start($box, FALSE, FALSE, 3); } return $upload_vbox; } sub create_entry_for_notebook { my ($self, $field, $value, $sg) = @_; #Clipboard my $clipboard = Gtk2::Clipboard->get( Gtk2::Gdk->SELECTION_CLIPBOARD ); #Tooltips my $tooltips = Gtk2::Tooltips->new; my $upload_hbox1 = Gtk2::HBox->new(FALSE, 10); my $upload_hbox2 = Gtk2::HBox->new(FALSE, 10); #prepare $field $field =~ s/_/ /ig; $field = ucfirst $field; my $label = Gtk2::Label->new($field); $label->set_alignment( 0, 0.5 ); $sg->add_widget($label); my $entry = Gtk2::Entry->new(); $entry->set_text($value); $entry->signal_connect( 'button-release-event' => sub { my ($widget, $event) = @_; $widget->select_region(0, -1); return FALSE; } ); my $upload_copy = Gtk2::Button->new; $tooltips->set_tip( $upload_copy, $self->{_gettext_object}->get("Copy this code to clipboard") ); $upload_copy->set_image( Gtk2::Image->new_from_stock( 'gtk-copy', 'menu' ) ); $upload_copy->signal_connect( 'clicked' => sub { my ( $widget, $entry ) = @_; $clipboard->set_text( $entry->get_text ); }, $entry ); $upload_hbox1->pack_start($label, FALSE, FALSE, 10); $upload_hbox1->pack_start($entry, TRUE, TRUE, 3); $upload_hbox2->pack_start($upload_hbox1, TRUE, TRUE, 0); $upload_hbox2->pack_start($upload_copy, FALSE, TRUE, 3); return $upload_hbox2; } sub show_all { my $self = shift; #are there any uploaded files? return FALSE if $self->{_notebook}->get_n_pages < 1; my $dlg_header = sprintf($self->{_gettext_object}->get("Upload - %s - %s"), $self->{_host}, $self->{_username}); my $upload_dialog = Gtk2::Dialog->new( $dlg_header, $self->{_main_gtk_window}, [qw/modal destroy-with-parent/], 'gtk-ok' => 'accept' ); $upload_dialog->set_default_response('accept'); $upload_dialog->vbox->add( $self->{_notebook} ); $upload_dialog->show_all; my $upload_response = $upload_dialog->run; if($upload_response eq "accept") { $upload_dialog->destroy(); return TRUE; } else { $upload_dialog->destroy(); return FALSE; } } sub show { my $self = shift; #Tooltips my $tooltips = Gtk2::Tooltips->new; #Create label for each notebook page my $fnlabel = Gtk2::Label->new($self->{_filename}); $fnlabel->set_ellipsize('middle'); $fnlabel->set_width_chars(20); $tooltips->set_tip( $fnlabel, $self->{_filename} ); $self->{_notebook}->append_page( $self->create_tab(), $fnlabel ); return TRUE; } 1; shutter-0.90.1/share/shutter/resources/modules/Shutter/Pixbuf/0000755000175000017500000000000012206477313023461 5ustar mariomarioshutter-0.90.1/share/shutter/resources/modules/Shutter/Pixbuf/Thumbnail.pm0000644000175000017500000000675012206477313025752 0ustar mariomario################################################### # # Copyright (C) 2008-2013 Mario Kemper # # This file is part of Shutter. # # Shutter is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 3 of the License, or # (at your option) any later version. # # Shutter is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License # along with Shutter; if not, write to the Free Software # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA # ################################################### package Shutter::Pixbuf::Thumbnail; #modules #-------------------------------------- use utf8; use strict; use warnings; use Gtk2; #Glib use Glib qw/TRUE FALSE/; #-------------------------------------- ##################public subs################## sub new { my $class = shift; #constructor my $self = { _common => shift }; bless $self, $class; return $self; } #~ sub DESTROY { #~ my $self = shift; #~ print "$self dying at\n"; #~ } sub get_thumbnail { my $self = shift; my $text_uri = shift; my $mime_type = shift; my $mtime = shift; my $rfactor = shift; my $force_new = shift; my $pixbuf; my $factory = Gnome2::ThumbnailFactory->new ('normal'); if($factory->can_thumbnail($text_uri, $mime_type, $mtime)){ unless($factory->has_valid_failed_thumbnail ($text_uri, $mtime)){ #force new thumbnail if($force_new){ print "$text_uri thumbnail creation forced\n" if $self->{_common}->get_debug; $pixbuf = $factory->generate_thumbnail ($text_uri, $mtime); if($pixbuf){ $factory->save_thumbnail ($pixbuf, $text_uri, $mtime); }else{ print "$text_uri thumbnail failed: $@\n" if $self->{_common}->get_debug; $factory->create_failed_thumbnail ($text_uri, $mtime); } #look for existing thumbnail }else{ #thumbnail exists if(my $existing_thumb = $factory->lookup ($text_uri, $mtime)){ print "$text_uri thumbnail already exists\n" if $self->{_common}->get_debug; eval{ $pixbuf = Gtk2::Gdk::Pixbuf->new_from_file ($existing_thumb); }; if($@){ print "$text_uri thumbnail failed: $@\n" if $self->{_common}->get_debug; $factory->create_failed_thumbnail ($text_uri, $mtime); } #generate new thumbnail }else{ print "$text_uri thumbnail created\n" if $self->{_common}->get_debug; $pixbuf = $factory->generate_thumbnail ($text_uri, $mtime); if($pixbuf){ $factory->save_thumbnail ($pixbuf, $text_uri, $mtime); }else{ print "$text_uri thumbnail failed: $@\n" if $self->{_common}->get_debug; $factory->create_failed_thumbnail ($text_uri, $mtime); } } } } } if($pixbuf){ if($rfactor != 1.0){ my $dest_width = $pixbuf->get_width*$rfactor; my $dest_height = $pixbuf->get_height*$rfactor; $dest_width = 1 if $dest_width < 1; $dest_height = 1 if $dest_height < 1; return $pixbuf->scale_simple ($dest_width, $dest_height, 'tiles'); }else{ return $pixbuf; } }else{ my $blank = Gtk2::Gdk::Pixbuf->new ('rgb', TRUE, 8, 5, 5); $blank->fill(0x00000000); return $blank; } } 1; shutter-0.90.1/share/shutter/resources/modules/Shutter/Pixbuf/Save.pm0000644000175000017500000001566212206477313024727 0ustar mariomario################################################### # # Copyright (C) 2008-2013 Mario Kemper # # This file is part of Shutter. # # Shutter is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 3 of the License, or # (at your option) any later version. # # Shutter is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License # along with Shutter; if not, write to the Free Software # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA # ################################################### package Shutter::Pixbuf::Save; #modules #-------------------------------------- use utf8; use strict; use warnings; use Gtk2; #fileparse and tempfile use File::Basename qw/ fileparse dirname basename /; use File::Temp qw/ tempfile tempdir /; #Glib use Glib qw/TRUE FALSE/; #-------------------------------------- sub new { my $class = shift; #constructor my $self = { _common => shift, _window => shift }; #import shutter dialogs my $current_window = $self->{_window} || $self->{_common}->get_mainwindow; $self->{_dialogs} = Shutter::App::SimpleDialogs->new( $current_window ); $self->{_lp} = Shutter::Pixbuf::Load->new( $self->{_common}, $current_window ); bless $self, $class; return $self; } sub save_pixbuf_to_file { my $self = shift; my $pixbuf = shift; my $filename = shift; my $filetype = shift; my $quality = shift; #gettext variable my $d = $self->{_common}->get_gettext; #check if we need to rotate the image or set the exif data accordingly my $option = $self->{_lp}->get_option($pixbuf, 'orientation'); $option = 1 unless defined $option; #FIXME: NOT COVERED BY BINDINGS YET (we use Image::ExifTool instead) #we rotate the pixbuf when saving to any other format than jpeg (jpg) unless ( $filetype eq 'jpeg' || $filetype eq 'jpg') { if($option != 1){ $pixbuf = $self->{_lp}->auto_rotate($pixbuf); } } #we have two main ways of saving file #when possible we try to use all supported formats of the gdk-pixbuf libs #currently this is bmp, jpeg (jpg), png and ico (ico is not useful here) my $imagemagick_result = undef; if ( $filetype eq 'jpeg' || $filetype eq 'jpg' ) { #get quality value from settings if not set if(my $settings = $self->{_common}->get_globalsettings_object){ if(defined $settings->get_jpg_quality){ $quality = $settings->get_jpg_quality; }else{ $quality = 90; } }else{ $quality = 90; } print "Saving file $filename, $filetype, $quality\n" if $self->{_common}->get_debug; eval{ $pixbuf->save( $filename, 'jpeg', quality => $quality ); #FIXME: NOT COVERED BY BINDINGS YET (we use Image::ExifTool instead) #~ $pixbuf->set_option( 'orientation' => $option ); if(my $exif = Shutter::App::Optional::Exif->new()){ #new Image::ExifTool instance my $exiftool = $exif->get_exiftool; if($exiftool){ #Set a new value for a tag $exiftool->SetNewValue('Orientation' => $option, Type => 'ValueConv'); #Write new meta information to a file my $success = $exiftool->WriteInfo($filename); } } }; } elsif ( $filetype eq 'png' ) { #get quality value from settings if not set if(my $settings = $self->{_common}->get_globalsettings_object){ if(defined $settings->get_png_quality){ $quality = $settings->get_png_quality; }else{ $quality = 9; } }else{ $quality = 9; } print "Saving file $filename, $filetype, $quality\n" if $self->{_common}->get_debug; eval{ $pixbuf->save( $filename, $filetype, "tEXt::Software" => "Shutter", compression => $quality ); }; } elsif ( $filetype eq 'bmp' ) { eval{ $pixbuf->save( $filename, $filetype ); }; } elsif ( $filetype eq 'pdf' ) { print "Saving file $filename, $filetype\n" if $self->{_common}->get_debug; #0.8? => 72 / 90 dpi my $surface = Cairo::PdfSurface->create($filename, $pixbuf->get_width * 0.8, $pixbuf->get_height * 0.8); my $cr = Cairo::Context->create($surface); $cr->scale(0.8, 0.8); Gtk2::Gdk::Cairo::Context::set_source_pixbuf( $cr, $pixbuf, 0, 0 ); $cr->paint; $cr->show_page; undef $surface; undef $cr; } elsif ( $filetype eq 'ps' ) { print "Saving file $filename, $filetype\n" if $self->{_common}->get_debug; #0.8? => 72 / 90 dpi my $surface = Cairo::PsSurface->create($filename, $pixbuf->get_width * 0.8, $pixbuf->get_height * 0.8); my $cr = Cairo::Context->create($surface); $cr->scale(0.8, 0.8); Gtk2::Gdk::Cairo::Context::set_source_pixbuf( $cr, $pixbuf, 0, 0 ); $cr->paint; $cr->show_page; undef $surface; undef $cr; } elsif ( $filetype eq 'svg' ) { print "Saving file $filename, $filetype\n" if $self->{_common}->get_debug; #0.8? => 72 / 90 dpi my $surface = Cairo::SvgSurface->create($filename, $pixbuf->get_width * 0.8, $pixbuf->get_height * 0.8); my $cr = Cairo::Context->create($surface); $cr->scale(0.8, 0.8); Gtk2::Gdk::Cairo::Context::set_source_pixbuf( $cr, $pixbuf, 0, 0 ); $cr->paint; $cr->show_page; undef $surface; undef $cr; } else { print "Saving file $filename, $filetype, $quality (using fallback-mode)\n" if $self->{_common}->get_debug; #save pixbuf to tempfile my ( $tmpfh, $tmpfilename ) = tempfile(); $tmpfilename .= '.png'; if($pixbuf){ $pixbuf->save( $tmpfilename, 'png', compression => '9' ); } #and convert filetype with imagemagick $imagemagick_result = $self->use_imagemagick_to_save($tmpfilename, $filename); unlink $tmpfilename; } #handle possible error messages #we use eval to test the pixbuf methods #and error messages provided #by the imagemagick libs if ($@ || $imagemagick_result) { #parse filename my ( $name, $folder, $type ) = fileparse( $filename, qr/\.[^.]*/ ); my $detailed_message = 'Unknown error'; if($@){ $detailed_message = $@->message; }elsif($imagemagick_result){ $detailed_message = $imagemagick_result; } #nice error dialog, more detailed messages are shown with a gtk2 expander my $response = $self->{_dialogs}->dlg_error_message( sprintf( $d->get("Error while saving the image %s."), "'" . $name.$type . "'"), sprintf( $d->get("There was an error saving the image to %s."), "'" . $folder . "'"), undef, undef, undef, undef, undef, undef, $detailed_message ); return FALSE; } return TRUE; } #use imagemagick for all filetypes that are not #supported by the gdk-pixbuf libs #e.g. gif sub use_imagemagick_to_save { my $self = shift; my $file = shift; my $new_file = shift; #escape filename first $file = quotemeta $file; $new_file = quotemeta $new_file; my $result = `convert $file $new_file 2>&1`; return $result; } 1; shutter-0.90.1/share/shutter/resources/modules/Shutter/Pixbuf/Load.pm0000644000175000017500000000725312206477313024705 0ustar mariomario################################################### # # Copyright (C) 2008-2013 Mario Kemper # # This file is part of Shutter. # # Shutter is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 3 of the License, or # (at your option) any later version. # # Shutter is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License # along with Shutter; if not, write to the Free Software # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA # ################################################### package Shutter::Pixbuf::Load; #modules #-------------------------------------- use utf8; use strict; use warnings; use Gtk2; #fileparse and tempfile use File::Basename qw/ fileparse dirname basename /; use File::Temp qw/ tempfile tempdir /; #Glib use Glib qw/TRUE FALSE/; #-------------------------------------- ##################public subs################## sub new { my $class = shift; #constructor my $self = { _common => shift, _window => shift, _no_error_dialog => shift }; bless $self, $class; return $self; } sub load { my $self = shift; my $filename = shift; my $width = shift; my $height = shift; my $sratio = shift; my $rotate = shift; my $pixbuf = undef; eval{ if(defined $width && defined $height && defined $sratio){ $pixbuf = Gtk2::Gdk::Pixbuf->new_from_file_at_scale($filename, $width, $height, $sratio); }elsif(defined $width && defined $height){ $pixbuf = Gtk2::Gdk::Pixbuf->new_from_file_at_size($filename, $width, $height); }else{ $pixbuf = Gtk2::Gdk::Pixbuf->new_from_file($filename); } }; #handle possible error messages if ($@) { unless(defined $self->{_no_error_dialog} && $self->{_no_error_dialog}){ #import shutter dialogs my $current_window = $self->{_window} || $self->{_common}->get_mainwindow; my $sd = Shutter::App::SimpleDialogs->new( $current_window ); #gettext variable my $d = $self->{_common}->get_gettext; #parse filename my ( $name, $folder, $type ) = fileparse( $filename, qr/\.[^.]*/ ); #nice error dialog, more detailed messages are shown with a gtk2 expander my $response = $sd->dlg_error_message( sprintf( $d->get("Error while opening image %s."), "'" . $name.$type . "'"), $d->get("There was an error opening the image."), undef, undef, undef, undef, undef, undef, $@->message ); } } #read exif and rotate accordingly if($rotate && $pixbuf){ $pixbuf = $self->auto_rotate($pixbuf); } return $pixbuf; } sub get_option { my $self = shift; my $pixbuf = shift; my $option = shift; return FALSE unless (defined $pixbuf && defined $option); return $pixbuf->get_option($option); } sub auto_rotate { my $self = shift; my $pixbuf = shift; my %orientation_flags = ( 1 => 'none,-1', 2 => 'none,1', 3 => 'upsidedown,-1', 4 => 'none,0', 5 => 'clockwise,1', 6 => 'clockwise,-1', 7 => 'clockwise,0', 8 => 'counterclockwise,-1', ); my $option = $self->get_option($pixbuf, 'orientation'); if(defined $option && exists $orientation_flags{$option}){ my ($rotate, $flip_horiz) = split ",", $orientation_flags{$option}; #~ print $option, "\n"; if(defined $rotate){ $pixbuf = $pixbuf->rotate_simple($rotate); } if(defined $flip_horiz && $flip_horiz > -1){ $pixbuf = $pixbuf->flip($flip_horiz); } } return $pixbuf; } 1; shutter-0.90.1/share/shutter/resources/modules/Shutter/Pixbuf/Border.pm0000644000175000017500000000405412206477313025237 0ustar mariomario################################################### # # Copyright (C) 2008-2013 Mario Kemper # # This file is part of Shutter. # # Shutter is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 3 of the License, or # (at your option) any later version. # # Shutter is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License # along with Shutter; if not, write to the Free Software # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA # ################################################### package Shutter::Pixbuf::Border; #modules #-------------------------------------- use utf8; use strict; use warnings; use Gtk2; #Glib use Glib qw/TRUE FALSE/; #-------------------------------------- sub new { my $class = shift; #constructor my $self = { _common => shift }; bless $self, $class; return $self; } #~ sub DESTROY { #~ my $self = shift; #~ print "$self dying at\n"; #~ } sub create_border { my $self = shift; my $pixbuf = shift; my $width = shift; my $color = shift; #create new pixbuf my $tmp_pbuf = Gtk2::Gdk::Pixbuf->new ('rgb', TRUE, 8, $pixbuf->get_width+2*$width, $pixbuf->get_height+2*$width); #Create a pixel specification my $pixel = 0; $pixel += ($color->red / 257) << 24; $pixel += ($color->green / 257) << 16; $pixel += ($color->blue / 257) << 8; $pixel += 255; #fill tmp pixbuf $tmp_pbuf->fill($pixel); #copy source pixbuf to new pixbuf eval{ $pixbuf->copy_area (0, 0, $pixbuf->get_width, $pixbuf->get_height, $tmp_pbuf, $width, $width); }; if($@){ print "create border failed: $@\n" if $self->{_common}->get_debug; return $pixbuf; } return $tmp_pbuf; } 1; shutter-0.90.1/share/shutter/resources/modules/Shutter/Draw/0000755000175000017500000000000012206477313023121 5ustar mariomarioshutter-0.90.1/share/shutter/resources/modules/Shutter/Draw/DrawingTool.pm0000644000175000017500000105465212206477313025725 0ustar mariomario################################################### # # Copyright (C) 2008-2013 Mario Kemper # # This file is part of Shutter. # # Shutter is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 3 of the License, or # (at your option) any later version. # # Shutter is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License # along with Shutter; if not, write to the Free Software # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA # ################################################### #perl -x -S perltidy -l=0 -b "%f" package Shutter::Draw::DrawingTool; #modules #-------------------------------------- use utf8; use strict; use warnings; use Gtk2; use Exporter; use Goo::Canvas; use File::Basename qw/ fileparse dirname basename /; use File::Glob qw/ glob /; use File::Temp qw/ tempfile tempdir /; use Data::Dumper; #Sort::Naturally - sort lexically, but sort numeral parts numerically use Sort::Naturally; #load and save settings use XML::Simple; #Glib use Glib qw/TRUE FALSE/; #-------------------------------------- sub new { my $class = shift; my $self = { _sc => shift }; #view, selector, dragger $self->{_view} = Gtk2::ImageView->new; $self->{_selector} = Gtk2::ImageView::Tool::Selector->new( $self->{_view} ); $self->{_dragger} = Gtk2::ImageView::Tool::Dragger->new( $self->{_view} ); $self->{_view}->set_interpolation('tiles'); $self->{_view}->set_tool( $self->{_selector} ); #WORKAROUND #upstream bug #http://trac.bjourne.webfactional.com/ticket/21 #left => zoom in #right => zoom out $self->{_view}->signal_connect( 'scroll-event', sub { my ( $view, $ev ) = @_; if ( $ev->direction eq 'left' ) { $ev->direction('up'); } elsif ( $ev->direction eq 'right' ) { $ev->direction('down'); } return FALSE; } ); #handle zoom events #ignore zoom values greater 10 (see: #654185) $self->{_view}->signal_connect( 'zoom-changed' => sub { if ( $self->{_view}->get_zoom > 10 ) { $self->{_view}->set_zoom(10); } } ); #clipboard $self->{_clipboard} = Gtk2::Clipboard->get( Gtk2::Gdk->SELECTION_CLIPBOARD ); #file $self->{_filename} = undef; $self->{_filetype} = undef; $self->{_mimetype} = undef; $self->{_import_hash} = undef; #custom cursors $self->{_cursors} = undef; #ui $self->{_uimanager} = undef; $self->{_factory} = undef; #canvas $self->{_canvas} = undef; #all items are stored here $self->{_uid} = time; $self->{_items} = undef; $self->{_items_history} = undef; #undo and redo stacks $self->{_undo} = undef; $self->{_redo} = undef; #autoscroll option, disabled by default $self->{_autoscroll} = FALSE; #drawing colors and line width #general - shown in the bottom hbox $self->{_fill_color} = Gtk2::Gdk::Color->parse('#0000ff'); $self->{_fill_color_alpha} = 0.25; $self->{_stroke_color} = Gtk2::Gdk::Color->parse('#ff0000'); $self->{_stroke_color_alpha} = 1; $self->{_line_width} = 3; $self->{_font} = 'Sans Regular 16'; #obtain current colors and font_desc from the main window $self->{_style} = $self->{_sc}->get_mainwindow->get_style; $self->{_style_bg} = $self->{_style}->bg('selected'); $self->{_style_tx} = $self->{_style}->text('selected'); #remember drawing colors, line width and font settings #maybe we have to restore them $self->{_last_fill_color} = Gtk2::Gdk::Color->parse('#0000ff'); $self->{_last_fill_color_alpha} = 0.25; $self->{_last_stroke_color} = Gtk2::Gdk::Color->parse('#ff0000'); $self->{_last_stroke_color_alpha} = 1; $self->{_last_line_width} = 3; $self->{_last_font} = 'Sans Regular 16'; #some status variables $self->{_busy} = undef; $self->{_current_item} = undef; $self->{_current_new_item} = undef; $self->{_current_copy_item} = undef; $self->{_last_mode} = 10; $self->{_current_mode} = 10; $self->{_current_mode_descr} = "select"; $self->{_current_pixbuf} = undef; $self->{_current_pixbuf_filename} = undef; $self->{_cut} = FALSE; $self->{_start_time} = undef; bless $self, $class; return $self; } #~ sub DESTROY { #~ my $self = shift; #~ print "$self dying at\n"; #~ } sub show { my $self = shift; $self->{_filename} = shift; $self->{_filetype} = shift; $self->{_mimetype} = shift; $self->{_name} = shift; $self->{_is_unsaved} = shift; $self->{_import_hash} = shift; #gettext $self->{_d} = $self->{_sc}->get_gettext; #define own icons $self->{_dicons} = $self->{_sc}->get_root . "/share/shutter/resources/icons/drawing_tool"; $self->{_icons} = $self->{_sc}->get_root . "/share/shutter/resources/icons"; #MAIN WINDOW #------------------------------------------------- $self->{_root} = Gtk2::Gdk->get_default_root_window; ( $self->{_root}->{x}, $self->{_root}->{y}, $self->{_root}->{w}, $self->{_root}->{h} ) = $self->{_root}->get_geometry; ( $self->{_root}->{x}, $self->{_root}->{y} ) = $self->{_root}->get_origin; $self->{_drawing_window} = Gtk2::Window->new('toplevel'); if ( defined $self->{_is_unsaved} && $self->{_is_unsaved} ) { $self->{_drawing_window}->set_title( "*" . $self->{_name} . " - Shutter DrawingTool" ); } else { $self->{_drawing_window}->set_title( $self->{_filename} . " - Shutter DrawingTool" ); } $self->{_drawing_window}->set_position('center'); $self->{_drawing_window}->set_modal(1); $self->{_drawing_window}->signal_connect( 'delete_event', sub { return $self->quit(TRUE) } ); #adjust toplevel window size if ( $self->{_root}->{w} > 640 && $self->{_root}->{h} > 480 ) { $self->{_drawing_window}->set_default_size( 640, 480 ); } else { $self->{_drawing_window}->set_default_size( $self->{_root}->{w} - 100, $self->{_root}->{h} - 100 ); } #dialogs, thumbnail generator and pixbuf loader $self->{_dialogs} = Shutter::App::SimpleDialogs->new( $self->{_drawing_window} ); $self->{_thumbs} = Shutter::Pixbuf::Thumbnail->new( $self->{_sc} ); $self->{_lp} = Shutter::Pixbuf::Load->new( $self->{_sc}, $self->{_drawing_window} ); $self->{_lp_ne} = Shutter::Pixbuf::Load->new( $self->{_sc}, $self->{_drawing_window}, TRUE ); #setup cursor-hash # #cursors borrowed from inkscape #http://www.inkscape.org my @cursors = glob( $self->{_dicons} . "/cursor/*" ); foreach my $cursor_path (@cursors) { my ( $cname, $folder, $type ) = fileparse( $cursor_path, qr/\.[^.]*/ ); $self->{_cursors}{$cname} = Gtk2::Gdk::Pixbuf->new_from_file($cursor_path); #see 'man xcursor' for a detailed description #of these values $self->{_cursors}{$cname}{'x_hot'} = $self->{_cursors}{$cname}->get_option('x_hot'); $self->{_cursors}{$cname}{'y_hot'} = $self->{_cursors}{$cname}->get_option('y_hot'); } #setu ui $self->{_uimanager} = $self->setup_uimanager(); #load settings $self->load_settings; #load file $self->{_drawing_pixbuf} = $self->{_lp}->load( $self->{_filename}, undef, undef, undef, TRUE ); unless ( $self->{_drawing_pixbuf} ) { $self->{_drawing_window}->destroy if $self->{_drawing_window}; return FALSE; } #CANVAS #------------------------------------------------- $self->{_canvas} = Goo::Canvas->new(); #enable dnd for it $self->{_canvas}->drag_dest_set( 'all', [ 'copy', 'private', 'default', 'move', 'link', 'ask' ] ); $self->{_canvas}->signal_connect( drag_data_received => sub { $self->import_from_dnd(@_) } ); my $target_list = Gtk2::TargetList->new(); my $atom1 = Gtk2::Gdk::Atom->new('text/uri-list'); $target_list->add( $atom1, 0, 0 ); $self->{_canvas}->drag_dest_set_target_list($target_list); #'redraw-when-scrolled' to reduce the flicker of static items # #this property is not available in older versions #it was added to goocanvas on Mon Nov 17 10:28:07 2008 UTC #http://svn.gnome.org/viewvc/goocanvas?view=revision&revision=28 if ( $self->{_canvas}->find_property('redraw-when-scrolled') ) { $self->{_canvas}->set( 'redraw-when-scrolled' => TRUE ); } #~ my $bg = Gtk2::Gdk::Color->parse('gray'); $self->{_canvas}->set( 'automatic-bounds' => FALSE, 'bounds-from-origin' => FALSE, #~ 'background-color' => sprintf( "#%04x%04x%04x", $bg->red, $bg->green, $bg->blue ), ); #and attach scroll event #to imitate scroll behavior of #Gtk2::ImageView widget Ctrl+Mouse Wheel $self->{_canvas}->signal_connect( 'scroll-event' => sub { my ( $canvas, $ev ) = @_; my $alloc = $self->{_canvas}->allocation; my $scale = $canvas->get_scale; if ( $ev->state >= 'control-mask' && ( $ev->direction eq 'up' || $ev->direction eq 'left' ) ) { $self->zoom_in_cb; $canvas->scroll_to( int( $ev->x - $alloc->width / 2 ) / $scale, int( $ev->y - $alloc->height / 2 ) / $scale ); return TRUE; } elsif ( $ev->state >= 'control-mask' && ( $ev->direction eq 'down' || $ev->direction eq 'right' ) ) { $self->zoom_out_cb; return TRUE; } return FALSE; } ); #create rectangle to resize the background my $bg_color = $self->create_color( Gtk2::Gdk::Color->parse('gray'), 1.0 ); $self->{_canvas_bg_rect} = Goo::Canvas::Rect->new( $self->{_canvas}->get_root_item, 0, 0, $self->{_drawing_pixbuf}->get_width, $self->{_drawing_pixbuf}->get_height, 'fill-pattern' => $bg_color, 'line-dash' => Goo::Canvas::LineDash->new( [ 5, 5 ] ), 'line-width' => 1, 'stroke-color' => 'black', ); #save color $self->{_canvas_bg_rect}{fill_color} = Gtk2::Gdk::Color->parse('gray'); $self->setup_item_signals( $self->{_canvas_bg_rect} ); $self->handle_bg_rects('create'); $self->handle_bg_rects('update'); #~ #create canvas background (:= screenshot) #~ $self->{_canvas_bg} = Goo::Canvas::Image->new( #~ $self->{_canvas}->get_root_item, #~ $self->{_drawing_pixbuf}, #~ 0, 0, #~ ); #~ $self->setup_item_signals( $self->{_canvas_bg} ); #set variables $self->{_current_pixbuf_filename} = $self->{_filename}; $self->{_current_pixbuf} = $self->{_drawing_pixbuf}; #construct an event and create a new image object my $initevent = Gtk2::Gdk::Event->new('motion-notify'); $initevent->set_time( Gtk2->get_current_event_time ); $initevent->window( $self->{_drawing_window}->window ); $initevent->x( int( $self->{_canvas_bg_rect}->get('width') / 2 ) ); $initevent->y( int( $self->{_canvas_bg_rect}->get('height') / 2 ) ); #new item my $nitem = $self->create_image( $initevent, undef, TRUE ); $self->{_canvas_bg} = $self->{_items}{$nitem}{image}; #this item is locked at first $self->{_items}{$nitem}{locked} = FALSE; $self->handle_bg_rects('raise'); #PACKING #------------------------------------------------- $self->{_drawing_vbox} = Gtk2::VBox->new( FALSE, 0 ); $self->{_drawing_inner_vbox} = Gtk2::VBox->new( FALSE, 0 ); $self->{_drawing_inner_vbox_c} = Gtk2::VBox->new( FALSE, 0 ); $self->{_drawing_hbox} = Gtk2::HBox->new( FALSE, 0 ); $self->{_drawing_hbox_c} = Gtk2::HBox->new( FALSE, 0 ); #mark some actions as important $self->{_uimanager}->get_widget("/ToolBar/Close")->set_is_important(TRUE); $self->{_uimanager}->get_widget("/ToolBar/Save")->set_is_important(TRUE); $self->{_uimanager}->get_widget("/ToolBar/Undo")->set_is_important(TRUE); #disable undo/redo actions at startup $self->{_uimanager}->get_widget("/MenuBar/Edit/Undo")->set_sensitive(FALSE); $self->{_uimanager}->get_widget("/MenuBar/Edit/Redo")->set_sensitive(FALSE); $self->{_uimanager}->get_widget("/ToolBar/Undo")->set_sensitive(FALSE); $self->{_uimanager}->get_widget("/ToolBar/Redo")->set_sensitive(FALSE); $self->{_drawing_window}->add( $self->{_drawing_vbox} ); my $menubar = $self->{_uimanager}->get_widget("/MenuBar"); $self->{_drawing_vbox}->pack_start( $menubar, FALSE, FALSE, 0 ); my $toolbar_drawing = $self->{_uimanager}->get_widget("/ToolBarDrawing"); $toolbar_drawing->set_orientation('vertical'); $toolbar_drawing->set_style('icons'); $toolbar_drawing->set_icon_size('menu'); $toolbar_drawing->set_show_arrow(FALSE); $self->{_drawing_hbox}->pack_start( $toolbar_drawing, FALSE, FALSE, 0 ); #DRAWING TOOL CONTAINER #------------------------------------------------- #scrolled window for the canvas $self->{_scrolled_window} = Gtk2::ScrolledWindow->new; $self->{_scrolled_window}->set_policy( 'automatic', 'automatic' ); $self->{_scrolled_window}->add( $self->{_canvas} ); $self->{_hscroll_hid} = $self->{_scrolled_window}->get_hscrollbar->signal_connect( 'value-changed' => sub { $self->adjust_rulers } ); $self->{_vscroll_hid} = $self->{_scrolled_window}->get_vscrollbar->signal_connect( 'value-changed' => sub { $self->adjust_rulers } ); #vruler $self->{_vruler} = Gtk2::VRuler->new; $self->{_vruler}->set_metric('pixels'); $self->{_vruler}->set_range( 0, $self->{_drawing_pixbuf}->get_height, 0, $self->{_drawing_pixbuf}->get_height ); #hruler $self->{_hruler} = Gtk2::HRuler->new; $self->{_hruler}->set_metric('pixels'); $self->{_hruler}->set_range( 0, $self->{_drawing_pixbuf}->get_width, 0, $self->{_drawing_pixbuf}->get_width ); #create a table for placing the ruler and scrolle window $self->{_table} = new Gtk2::Table( 3, 2, FALSE ); #attach scrolled window and rulers to the table $self->{_table}->attach( $self->{_scrolled_window}, 1, 2, 1, 2, [ 'expand', 'fill' ], [ 'expand', 'fill' ], 0, 0 ); $self->{_table}->attach( $self->{_hruler}, 1, 2, 0, 1, [ 'expand', 'shrink', 'fill' ], [], 0, 0 ); $self->{_table}->attach( $self->{_vruler}, 0, 1, 1, 2, [], [ 'fill', 'expand', 'shrink' ], 0, 0 ); $self->{_bhbox} = $self->setup_bottom_hbox; $self->{_drawing_inner_vbox}->pack_start( $self->{_table}, TRUE, TRUE, 0 ); $self->{_drawing_inner_vbox}->pack_start( $self->{_bhbox}, FALSE, TRUE, 0 ); #CROPPING TOOL CONTAINER #------------------------------------------------- #scrolled window for the cropping tool $self->{_scrolled_window_c} = Gtk2::ImageView::ScrollWin->new( $self->{_view} ); ( $self->{_rframe_c}, $self->{_btn_ok_c} ) = $self->setup_right_vbox_c; $self->{_drawing_hbox_c}->pack_start( $self->{_scrolled_window_c}, TRUE, TRUE, 0 ); $self->{_drawing_hbox_c}->pack_start( $self->{_rframe_c}, FALSE, FALSE, 3 ); $self->{_drawing_inner_vbox_c}->pack_start( $self->{_drawing_hbox_c}, TRUE, TRUE, 0 ); #MAIN CONTAINER #------------------------------------------------- #pack both containers to the main hbox $self->{_drawing_hbox}->pack_start( $self->{_drawing_inner_vbox}, TRUE, TRUE, 0 ); $self->{_drawing_hbox}->pack_start( $self->{_drawing_inner_vbox_c}, TRUE, TRUE, 0 ); $self->{_drawing_vbox}->pack_start( $self->{_uimanager}->get_widget("/ToolBar"), FALSE, FALSE, 0 ); $self->{_drawing_vbox}->pack_start( $self->{_drawing_hbox}, TRUE, TRUE, 0 ); #statusbar $self->{_drawing_statusbar} = Gtk2::Statusbar->new; $self->{_drawing_statusbar_image} = Gtk2::Image->new; $self->{_drawing_statusbar}->pack_start( $self->{_drawing_statusbar_image}, FALSE, FALSE, 3 ); $self->{_drawing_statusbar}->reorder_child( $self->{_drawing_statusbar_image}, 0 ); $self->{_drawing_vbox}->pack_start( $self->{_drawing_statusbar}, FALSE, FALSE, 6 ); $self->{_drawing_window}->show_all(); #STARTUP PROCEDURE #------------------------------------------------- $self->{_drawing_window}->window->focus( Gtk2->get_current_event_time ); $self->adjust_rulers; #save start time to show in close dialog $self->{_start_time} = time; #remember drawing colors, line width and font settings #maybe we have to restore them $self->{_last_fill_color} = $self->{_fill_color_w}->get_color; $self->{_last_fill_color_alpha} = $self->{_fill_color_w}->get_alpha / 65535; $self->{_last_stroke_color} = $self->{_stroke_color_w}->get_color; $self->{_last_stroke_color_alpha} = $self->{_stroke_color_w}->get_alpha / 65535; $self->{_last_line_width} = $self->{_line_spin_w}->get_value; $self->{_last_font} = $self->{_font_btn_w}->get_font_name; #init last mode $self->{_last_mode} = 0; #init current tool $self->set_drawing_action( int( $self->{_current_mode} / 10 ) ); #do show these actions because the user would be confused #to see multiple shortcuts to handle zooming #controlequal is used for english keyboard layouts for example $self->{_uimanager}->get_action("/MenuBar/View/ControlEqual")->set_visible(FALSE); $self->{_uimanager}->get_action("/MenuBar/View/ControlKpAdd")->set_visible(FALSE); $self->{_uimanager}->get_action("/MenuBar/View/ControlKpSub")->set_visible(FALSE); #start with everything deactivated $self->deactivate_all; Gtk2->main; return TRUE; } sub setup_bottom_hbox { my $self = shift; #Tooltips my $tooltips = $self->{_sc}->get_tooltips; my $drawing_bottom_hbox = Gtk2::HBox->new( FALSE, 5 ); #fill color my $fill_color_label = Gtk2::Label->new( $self->{_d}->get("Fill color") . ":" ); $self->{_fill_color_w} = Gtk2::ColorButton->new(); $self->{_fill_color_w}->set_color( $self->{_fill_color} ); $self->{_fill_color_w}->set_alpha( int( $self->{_fill_color_alpha} * 65636 ) ); $self->{_fill_color_w}->set_use_alpha(TRUE); $self->{_fill_color_w}->set_title( $self->{_d}->get("Choose fill color") ); $tooltips->set_tip( $fill_color_label, $self->{_d}->get("Adjust fill color and opacity") ); $tooltips->set_tip( $self->{_fill_color_w}, $self->{_d}->get("Adjust fill color and opacity") ); $drawing_bottom_hbox->pack_start( $fill_color_label, FALSE, FALSE, 5 ); $drawing_bottom_hbox->pack_start( $self->{_fill_color_w}, FALSE, FALSE, 5 ); #stroke color my $stroke_color_label = Gtk2::Label->new( $self->{_d}->get("Stroke color") . ":" ); $self->{_stroke_color_w} = Gtk2::ColorButton->new(); $self->{_stroke_color_w}->set_color( $self->{_stroke_color} ); $self->{_stroke_color_w}->set_alpha( int( $self->{_stroke_color_alpha} * 65535 ) ); $self->{_stroke_color_w}->set_use_alpha(TRUE); $self->{_stroke_color_w}->set_title( $self->{_d}->get("Choose stroke color") ); $tooltips->set_tip( $stroke_color_label, $self->{_d}->get("Adjust stroke color and opacity") ); $tooltips->set_tip( $self->{_stroke_color_w}, $self->{_d}->get("Adjust stroke color and opacity") ); $drawing_bottom_hbox->pack_start( $stroke_color_label, FALSE, FALSE, 5 ); $drawing_bottom_hbox->pack_start( $self->{_stroke_color_w}, FALSE, FALSE, 5 ); #line_width my $linew_label = Gtk2::Label->new( $self->{_d}->get("Line width") . ":" ); $self->{_line_spin_w} = Gtk2::SpinButton->new_with_range( 0.5, 20, 0.1 ); $self->{_line_spin_w}->set_value( $self->{_line_width} ); $tooltips->set_tip( $linew_label, $self->{_d}->get("Adjust line width") ); $tooltips->set_tip( $self->{_line_spin_w}, $self->{_d}->get("Adjust line width") ); $drawing_bottom_hbox->pack_start( $linew_label, FALSE, FALSE, 5 ); $drawing_bottom_hbox->pack_start( $self->{_line_spin_w}, FALSE, FALSE, 5 ); #font button my $font_label = Gtk2::Label->new( $self->{_d}->get("Font") . ":" ); $self->{_font_btn_w} = Gtk2::FontButton->new(); $self->{_font_btn_w}->set_font_name( $self->{_font} ); $tooltips->set_tip( $font_label, $self->{_d}->get("Select font family and size") ); $tooltips->set_tip( $self->{_font_btn_w}, $self->{_d}->get("Select font family and size") ); $drawing_bottom_hbox->pack_start( $font_label, FALSE, FALSE, 5 ); $drawing_bottom_hbox->pack_start( $self->{_font_btn_w}, FALSE, FALSE, 5 ); #image button my $image_label = Gtk2::Label->new( $self->{_d}->get("Insert image") . ":" ); my $image_btn = Gtk2::MenuToolButton->new( undef, undef ); Glib::Idle->add( sub { $image_btn->set_menu( $self->import_from_filesystem($image_btn) ); return FALSE; } ); #handle property changes #changes are applied directly to the current item $self->{_line_spin_wh} = $self->{_line_spin_w}->signal_connect( 'value-changed' => sub { $self->{_line_width} = $self->{_line_spin_w}->get_value; if ( $self->{_current_item} ) { #apply all changes directly my $item = $self->{_current_item}; if ( my $child = $self->get_child_item($item) ) { $item = $child; } my $parent = $self->get_parent_item($item); #determine key for item hash my $key = $self->get_item_key( $item, $parent ); $self->apply_properties( $item, $parent, $key, $self->{_fill_color_w}, $self->{_stroke_color_w}, $self->{_line_spin_w}, $self->{_stroke_color_w}, $self->{_font_btn_w} ); } } ); $self->{_stroke_color_wh} = $self->{_stroke_color_w}->signal_connect( 'color-set' => sub { $self->{_stroke_color} = $self->{_stroke_color_w}->get_color; $self->{_stroke_color_alpha} = $self->{_stroke_color_w}->get_alpha / 65535; if ( $self->{_current_item} ) { #apply all changes directly my $item = $self->{_current_item}; if ( my $child = $self->get_child_item($item) ) { $item = $child; } my $parent = $self->get_parent_item($item); #determine key for item hash my $key = $self->get_item_key( $item, $parent ); $self->apply_properties( $item, $parent, $key, $self->{_fill_color_w}, $self->{_stroke_color_w}, $self->{_line_spin_w}, $self->{_stroke_color_w}, $self->{_font_btn_w} ); } } ); $self->{_fill_color_wh} = $self->{_fill_color_w}->signal_connect( 'color-set' => sub { $self->{_fill_color} = $self->{_fill_color_w}->get_color; $self->{_fill_color_alpha} = $self->{_fill_color_w}->get_alpha / 65636; if ( $self->{_current_item} ) { #apply all changes directly my $item = $self->{_current_item}; if ( my $child = $self->get_child_item($item) ) { $item = $child; } my $parent = $self->get_parent_item($item); #determine key for item hash my $key = $self->get_item_key( $item, $parent ); $self->apply_properties( $item, $parent, $key, $self->{_fill_color_w}, $self->{_stroke_color_w}, $self->{_line_spin_w}, $self->{_stroke_color_w}, $self->{_font_btn_w} ); } } ); $self->{_font_btn_wh} = $self->{_font_btn_w}->signal_connect( 'font-set' => sub { my $font_descr = Gtk2::Pango::FontDescription->from_string( $self->{_font_btn_w}->get_font_name ); $self->{_font} = $self->{_font_btn_w}->get_font_name; if ( $self->{_current_item} ) { #apply all changes directly my $item = $self->{_current_item}; if ( my $child = $self->get_child_item($item) ) { $item = $child; } my $parent = $self->get_parent_item($item); #determine key for item hash my $key = $self->get_item_key( $item, $parent ); $self->apply_properties( $item, $parent, $key, $self->{_fill_color_w}, $self->{_stroke_color_w}, $self->{_line_spin_w}, $self->{_stroke_color_w}, $self->{_font_btn_w} ); } } ); $image_btn->signal_connect( 'clicked' => sub { $self->{_canvas}->window->set_cursor( $self->change_cursor_to_current_pixbuf ); } ); $tooltips->set_tip( $image_label, $self->{_d}->get("Insert an arbitrary object or file") ); $tooltips->set_tip( $image_btn, $self->{_d}->get("Insert an arbitrary object or file") ); $drawing_bottom_hbox->pack_start( $image_label, FALSE, FALSE, 5 ); $drawing_bottom_hbox->pack_start( $image_btn, FALSE, FALSE, 5 ); return $drawing_bottom_hbox; } sub setup_right_vbox_c { my $self = shift; #Tooltips my $tooltips = $self->{_sc}->get_tooltips; my $cropping_bottom_vbox = Gtk2::VBox->new( FALSE, 5 ); #get current pixbuf my $pixbuf = $self->{_view}->get_pixbuf || $self->{_drawing_pixbuf}; #X my $xw_label = Gtk2::Label->new( $self->{_d}->get("X") . ":" ); $self->{_x_spin_w} = Gtk2::SpinButton->new_with_range( 0, $pixbuf->get_width, 1 ); $self->{_x_spin_w}->set_value(0); $self->{_x_spin_w_handler} = $self->{_x_spin_w}->signal_connect( 'value-changed' => sub { $self->{_selector}->set_selection( Gtk2::Gdk::Rectangle->new( $self->{_x_spin_w}->get_value, $self->{_y_spin_w}->get_value, $self->{_width_spin_w}->get_value, $self->{_height_spin_w}->get_value ) ); } ); my $xw_hbox = Gtk2::HBox->new( FALSE, 5 ); $xw_hbox->pack_start( $xw_label, FALSE, FALSE, 5 ); $xw_hbox->pack_start( $self->{_x_spin_w}, FALSE, FALSE, 5 ); #y my $yw_label = Gtk2::Label->new( $self->{_d}->get("Y") . ":" ); $self->{_y_spin_w} = Gtk2::SpinButton->new_with_range( 0, $pixbuf->get_height, 1 ); $self->{_y_spin_w}->set_value(0); $self->{_y_spin_w_handler} = $self->{_y_spin_w}->signal_connect( 'value-changed' => sub { $self->{_selector}->set_selection( Gtk2::Gdk::Rectangle->new( $self->{_x_spin_w}->get_value, $self->{_y_spin_w}->get_value, $self->{_width_spin_w}->get_value, $self->{_height_spin_w}->get_value ) ); } ); my $yw_hbox = Gtk2::HBox->new( FALSE, 5 ); $yw_hbox->pack_start( $yw_label, FALSE, FALSE, 5 ); $yw_hbox->pack_start( $self->{_y_spin_w}, FALSE, FALSE, 5 ); #width my $widthw_label = Gtk2::Label->new( $self->{_d}->get("Width") . ":" ); $self->{_width_spin_w} = Gtk2::SpinButton->new_with_range( 0, $pixbuf->get_width, 1 ); $self->{_width_spin_w}->set_value(0); $self->{_width_spin_w_handler} = $self->{_width_spin_w}->signal_connect( 'value-changed' => sub { $self->{_selector}->set_selection( Gtk2::Gdk::Rectangle->new( $self->{_x_spin_w}->get_value, $self->{_y_spin_w}->get_value, $self->{_width_spin_w}->get_value, $self->{_height_spin_w}->get_value ) ); } ); my $ww_hbox = Gtk2::HBox->new( FALSE, 5 ); $ww_hbox->pack_start( $widthw_label, FALSE, FALSE, 5 ); $ww_hbox->pack_start( $self->{_width_spin_w}, FALSE, FALSE, 5 ); #height my $heightw_label = Gtk2::Label->new( $self->{_d}->get("Height") . ":" ); $self->{_height_spin_w} = Gtk2::SpinButton->new_with_range( 0, $pixbuf->get_height, 1 ); $self->{_height_spin_w}->set_value(0); $self->{_height_spin_w_handler} = $self->{_height_spin_w}->signal_connect( 'value-changed' => sub { $self->{_selector}->set_selection( Gtk2::Gdk::Rectangle->new( $self->{_x_spin_w}->get_value, $self->{_y_spin_w}->get_value, $self->{_width_spin_w}->get_value, $self->{_height_spin_w}->get_value ) ); } ); my $hw_hbox = Gtk2::HBox->new( FALSE, 5 ); $hw_hbox->pack_start( $heightw_label, FALSE, FALSE, 5 ); $hw_hbox->pack_start( $self->{_height_spin_w}, FALSE, FALSE, 5 ); #the above values are changed when the selection is changed $self->{_selector_handler} = $self->{_selector}->signal_connect( 'selection-changed' => sub { $self->adjust_crop_values($pixbuf); } ); #cancel button my $crop_c = Gtk2::Button->new_from_stock('gtk-cancel'); $crop_c->signal_connect( 'clicked' => sub { $self->abort_current_mode } ); #crop button my $crop_ok = Gtk2::Button->new_with_mnemonic( $self->{_d}->get("_Crop") ); $crop_ok->set_image( Gtk2::Image->new_from_file( $self->{_dicons} . '/transform-crop.png' ) ); $crop_ok->signal_connect( 'clicked' => sub { my $s = $self->{_selector}->get_selection; my $p = $self->{_view}->get_pixbuf; if ( $s && $p ) { #add to undo stack $self->store_to_xdo_stack( $self->{_canvas_bg}, 'modify', 'undo', $s ); #create new pixbuf #create temp pixbuf because selected area might be bigger than #source pixbuf (screenshot) => canvas area is resizeable my $temp = Gtk2::Gdk::Pixbuf->new( $self->{_drawing_pixbuf}->get_colorspace, TRUE, 8, $p->get_width, $p->get_height ); #whole pixbuf is transparent $temp->fill(0x00000000); #copy source image to temp pixbuf (temp pixbuf's size == $self->{_view}->get_pixbuf) $self->{_drawing_pixbuf}->copy_area( 0, 0, $self->{_drawing_pixbuf}->get_width, $self->{_drawing_pixbuf}->get_height, $temp, 0, 0 ); #and create a new subpixbuf from the temp pixbuf my $new_p = $temp->new_subpixbuf( $s->x, $s->y, $s->width, $s->height ); $self->{_drawing_pixbuf} = $new_p->copy; #update bounds and bg_rects $self->{_canvas_bg_rect}->set( 'width' => $s->width, 'height' => $s->height ); $self->handle_bg_rects('update'); #update canvas and show the new pixbuf $self->{_canvas_bg}->set( 'pixbuf' => $new_p ); #now move all items, #so they are in the right position #~ print $s->x ." - ".$s->y."\n"; $self->move_all( $s->x, $s->y ); #adjust stack order $self->{_canvas_bg}->lower; $self->{_canvas_bg_rect}->lower; $self->handle_bg_rects('raise'); } else { #nothing here right now } #finally reset mode to select tool $self->abort_current_mode; } ); #put buttons in a separated box #all buttons = one size my $sg_butt = Gtk2::SizeGroup->new('vertical'); $sg_butt->add_widget($crop_c); $sg_butt->add_widget($crop_ok); my $cropping_bottom_vbox_b = Gtk2::VBox->new( FALSE, 5 ); $cropping_bottom_vbox_b->pack_start( $crop_c, FALSE, FALSE, 0 ); $cropping_bottom_vbox_b->pack_start( $crop_ok, FALSE, FALSE, 0 ); #final_packing #all labels = one size $xw_label->set_alignment( 0, 0.5 ); $yw_label->set_alignment( 0, 0.5 ); $widthw_label->set_alignment( 0, 0.5 ); $heightw_label->set_alignment( 0, 0.5 ); my $sg_main = Gtk2::SizeGroup->new('horizontal'); $sg_main->add_widget($xw_label); $sg_main->add_widget($yw_label); $sg_main->add_widget($widthw_label); $sg_main->add_widget($heightw_label); $cropping_bottom_vbox->pack_start( $xw_hbox, FALSE, FALSE, 3 ); $cropping_bottom_vbox->pack_start( $yw_hbox, FALSE, FALSE, 3 ); $cropping_bottom_vbox->pack_start( $ww_hbox, FALSE, FALSE, 3 ); $cropping_bottom_vbox->pack_start( $hw_hbox, FALSE, FALSE, 3 ); $cropping_bottom_vbox->pack_start( $cropping_bottom_vbox_b, TRUE, TRUE, 3 ); #nice frame as well my $crop_frame_label = Gtk2::Label->new; $crop_frame_label->set_markup( "" . $self->{_d}->get("Selection") . "" ); my $crop_frame = Gtk2::Frame->new(); $crop_frame->set_border_width(5); $crop_frame->set_label_widget($crop_frame_label); $crop_frame->set_shadow_type('none'); $crop_frame->add($cropping_bottom_vbox); return ( $crop_frame, $crop_ok ); } sub adjust_crop_values { my $self = shift; my $pixbuf = shift; #block 'value-change' handlers for widgets #so we do not apply the changes twice $self->{_x_spin_w}->signal_handler_block( $self->{_x_spin_w_handler} ); $self->{_y_spin_w}->signal_handler_block( $self->{_y_spin_w_handler} ); $self->{_width_spin_w}->signal_handler_block( $self->{_width_spin_w_handler} ); $self->{_height_spin_w}->signal_handler_block( $self->{_height_spin_w_handler} ); my $s = $self->{_selector}->get_selection; if ($s) { $self->{_x_spin_w}->set_value( $s->x ); $self->{_x_spin_w}->set_range( 0, $pixbuf->get_width - $s->width ); $self->{_y_spin_w}->set_value( $s->y ); $self->{_y_spin_w}->set_range( 0, $pixbuf->get_height - $s->height ); $self->{_width_spin_w}->set_value( $s->width ); $self->{_width_spin_w}->set_range( 0, $pixbuf->get_width - $s->x ); $self->{_height_spin_w}->set_value( $s->height ); $self->{_height_spin_w}->set_range( 0, $pixbuf->get_height - $s->y ); } #unblock 'value-change' handlers for widgets $self->{_x_spin_w}->signal_handler_unblock( $self->{_x_spin_w_handler} ); $self->{_y_spin_w}->signal_handler_unblock( $self->{_y_spin_w_handler} ); $self->{_width_spin_w}->signal_handler_unblock( $self->{_width_spin_w_handler} ); $self->{_height_spin_w}->signal_handler_unblock( $self->{_height_spin_w_handler} ); return TRUE; } sub push_tool_help_to_statusbar { my ( $self, $x, $y, $action ) = @_; #init $action if not defined $action = 'none' unless defined $action; #current event coordinates my $status_text = int($x) . " x " . int($y); if ( $self->{_current_mode} == 10 ) { if ( $action eq 'resize' ) { $status_text .= " " . $self->{_d}->get("Click-Drag to scale (try Control to scale uniformly)"); } elsif ( $action eq 'canvas_resize' ) { $status_text .= " " . $self->{_d}->get("Click-Drag to resize the canvas"); } } elsif ( $self->{_current_mode} == 20 || $self->{_current_mode} == 30 ) { $status_text .= " " . $self->{_d}->get("Click to paint (try Control or Shift for a straight line)"); } elsif ( $self->{_current_mode} == 40 ) { $status_text .= " " . $self->{_d}->get("Click-Drag to create a new straight line"); } elsif ( $self->{_current_mode} == 50 ) { $status_text .= " " . $self->{_d}->get("Click-Drag to create a new arrow"); } elsif ( $self->{_current_mode} == 60 ) { $status_text .= " " . $self->{_d}->get("Click-Drag to create a new rectangle"); } elsif ( $self->{_current_mode} == 70 ) { $status_text .= " " . $self->{_d}->get("Click-Drag to create a new ellipse"); } elsif ( $self->{_current_mode} == 80 ) { $status_text .= " " . $self->{_d}->get("Click-Drag to add a new text area"); } elsif ( $self->{_current_mode} == 90 ) { $status_text .= " " . $self->{_d}->get("Click to censor (try Control or Shift for a straight line)"); } elsif ( $self->{_current_mode} == 100 ) { $status_text .= " " . $self->{_d}->get("Click-Drag to create a pixelized region"); } elsif ( $self->{_current_mode} == 110 ) { $status_text .= " " . $self->{_d}->get("Click to add an auto-increment shape"); } elsif ( $self->{_current_mode} == 120 ) { #nothing to do here.... } #update statusbar $self->show_status_message( 1, $status_text ); return TRUE; } sub show_status_message { my $self = shift; my $index = shift; my $status_text = shift; my $status_image = shift; #this is a stock-id #~ #remove old message and timer #~ $self->{_drawing_statusbar}->pop($index); #~ Glib::Source->remove ($self->{_drawing_statusbar}->{statusbar_timer}) if defined $self->{_drawing_statusbar}->{statusbar_timer}; #new message and image if ( defined $status_image ) { $self->{_drawing_statusbar_image}->set_from_stock( $status_image, 'menu' ); } else { $self->{_drawing_statusbar_image}->clear; } $self->{_drawing_statusbar}->push( $index, $status_text ); #~ #...and remove it #~ $self->{_drawing_statusbar}->{statusbar_timer} = Glib::Timeout->add( #~ 3000, #~ sub { #~ $self->{_drawing_statusbar}->pop($index) if defined $self->{_drawing_statusbar}; #~ return FALSE; #~ } #~ ); return TRUE; } sub change_drawing_tool_cb { my $self = shift; my $action = shift; #~ print "change_drawing_tool_cb\n"; eval { $self->{_current_mode} = $action->get_current_value; }; if ($@) { $self->{_current_mode} = $action; } my $cursor = Gtk2::Gdk::Cursor->new('left-ptr'); #tool is switched from "highlighter" OR censor to something else (excluding select tool) if ( $self->{_current_mode} != $self->{_last_mode} && $self->{_current_mode} != 10 && $self->{_current_mode} != 30 && $self->{_current_mode} != 90 && $self->{_current_mode} != 100 && $self->{_current_mode} != 120 ) { $self->restore_drawing_properties; } #show drawing tool widgets if ( $self->{_current_mode} != 120 ) { #show drawing tool widgets $self->{_table}->show_all; $self->{_bhbox}->show_all; $self->{_drawing_inner_vbox}->show_all; #hide cropping tool $self->{_drawing_inner_vbox_c}->hide_all; } #enable controls again $self->{_fill_color_w}->set_sensitive(TRUE); $self->{_stroke_color_w}->set_sensitive(TRUE); $self->{_line_spin_w}->set_sensitive(TRUE); $self->{_font_btn_w}->set_sensitive(TRUE); if ( $self->{_current_mode} == 10 ) { $self->{_current_mode_descr} = "select"; } elsif ( $self->{_current_mode} == 20 ) { $self->{_current_mode_descr} = "freehand"; #disable controls, because they are not useful $self->{_fill_color_w}->set_sensitive(FALSE); $self->{_font_btn_w}->set_sensitive(FALSE); } elsif ( $self->{_current_mode} == 30 ) { $self->{_current_mode_descr} = "highlighter"; $cursor = Gtk2::Gdk::Cursor->new('dotbox'); #disable controls, because they are not useful $self->{_fill_color_w}->set_sensitive(FALSE); $self->{_font_btn_w}->set_sensitive(FALSE); #restore hard-coded highlighter properties $self->restore_fixed_properties( $self->{_current_mode_descr} ); } elsif ( $self->{_current_mode} == 40 ) { $self->{_current_mode_descr} = "line"; #disable controls, because they are not useful $self->{_fill_color_w}->set_sensitive(FALSE); $self->{_font_btn_w}->set_sensitive(FALSE); } elsif ( $self->{_current_mode} == 50 ) { $self->{_current_mode_descr} = "arrow"; #disable controls, because they are not useful $self->{_fill_color_w}->set_sensitive(FALSE); $self->{_font_btn_w}->set_sensitive(FALSE); } elsif ( $self->{_current_mode} == 60 ) { $self->{_current_mode_descr} = "rect"; #disable controls, because they are not useful $self->{_font_btn_w}->set_sensitive(FALSE); } elsif ( $self->{_current_mode} == 70 ) { $self->{_current_mode_descr} = "ellipse"; #disable controls, because they are not useful $self->{_font_btn_w}->set_sensitive(FALSE); } elsif ( $self->{_current_mode} == 80 ) { $self->{_current_mode_descr} = "text"; #disable controls, because they are not useful $self->{_fill_color_w}->set_sensitive(FALSE); $self->{_line_spin_w}->set_sensitive(FALSE); } elsif ( $self->{_current_mode} == 90 ) { $self->{_current_mode_descr} = "censor"; #disable controls, because they are not useful when using the #censor tool $self->{_fill_color_w}->set_sensitive(FALSE); $self->{_stroke_color_w}->set_sensitive(FALSE); $self->{_line_spin_w}->set_sensitive(FALSE); $self->{_font_btn_w}->set_sensitive(FALSE); #restore hard-coded censor properties $self->restore_fixed_properties( $self->{_current_mode_descr} ); } elsif ( $self->{_current_mode} == 100 ) { $self->{_current_mode_descr} = "pixelize"; #disable controls, because they are not useful when using the #pixelize tool $self->{_fill_color_w}->set_sensitive(FALSE); $self->{_stroke_color_w}->set_sensitive(FALSE); $self->{_line_spin_w}->set_sensitive(FALSE); $self->{_font_btn_w}->set_sensitive(FALSE); } elsif ( $self->{_current_mode} == 110 ) { $self->{_current_mode_descr} = "number"; } elsif ( $self->{_current_mode} == 120 ) { $self->{_current_mode_descr} = "crop"; #show cropping tool $self->{_view}->set_pixbuf( $self->save(TRUE) ); $self->{_view}->set_zoom(1); #adjust transp color my $color_string = sprintf( "%02x%02x%02x", $self->{_canvas_bg_rect}{fill_color}->red / 257, $self->{_canvas_bg_rect}{fill_color}->green / 257, $self->{_canvas_bg_rect}{fill_color}->blue / 257 ); $self->{_view}->set_transp( 'color', hex $color_string ); $self->{_view}->show_all; $self->{_drawing_inner_vbox_c}->show_all; #hide drawing tool widgets $self->{_drawing_inner_vbox}->hide_all; #focus crop-ok-button $self->{_btn_ok_c}->grab_focus; } if ( $self->{_canvas} && $self->{_canvas}->window ) { if ( exists $self->{_cursors}{ $self->{_current_mode_descr} } ) { $cursor = Gtk2::Gdk::Cursor->new_from_pixbuf( Gtk2::Gdk::Display->get_default, $self->{_cursors}{ $self->{_current_mode_descr} }, $self->{_cursors}{ $self->{_current_mode_descr} }{'x_hot'}, $self->{_cursors}{ $self->{_current_mode_descr} }{'y_hot'}, ); } $self->{_canvas}->window->set_cursor($cursor); } return TRUE; } sub zoom_in_cb { my $self = shift; if ( $self->{_current_mode_descr} ne "crop" ) { $self->{_canvas}->set_scale( $self->{_canvas}->get_scale + 0.2 ); #~ $self->adjust_rulers; } else { $self->{_view}->zoom_in; } return TRUE; } sub zoom_out_cb { my $self = shift; if ( $self->{_current_mode_descr} ne "crop" ) { my $new_scale = $self->{_canvas}->get_scale - 0.2; if ( $new_scale < 0.2 ) { $self->{_canvas}->set_scale(0.2); } else { $self->{_canvas}->set_scale($new_scale); } #~ $self->adjust_rulers; } else { $self->{_view}->zoom_out; } return TRUE; } sub zoom_normal_cb { my $self = shift; if ( $self->{_current_mode_descr} ne "crop" ) { $self->{_canvas}->set_scale(1); #~ $self->adjust_rulers; } else { $self->{_view}->set_zoom(1); } return TRUE; } sub adjust_rulers { my ( $self, $ev, $item ) = @_; my $s = $self->{_canvas}->get_scale; my ( $hlower, $hupper, $hposition, $hmax_size ) = $self->{_hruler}->get_range; my ( $vlower, $vupper, $vposition, $vmax_size ) = $self->{_vruler}->get_range; if ($ev) { my $copy_event = $ev->copy; #modify event to respect scrollbars and canvas scale $copy_event->x( ( $copy_event->x_root - $hlower ) * $s ); $copy_event->y( ( $copy_event->y_root - $vlower ) * $s ); $self->{_hruler}->signal_emit( 'motion-notify-event', $copy_event ); $self->{_vruler}->signal_emit( 'motion-notify-event', $copy_event ); } else { #modify rulers (e.g. done when scrolling or zooming) if ( $self->{_hruler} && $self->{_hruler} ) { my ( $x, $y, $width, $height, $depth ) = $self->{_canvas}->window->get_geometry; my $ha = $self->{_scrolled_window}->get_hadjustment->value / $s; my $va = $self->{_scrolled_window}->get_vadjustment->value / $s; $self->{_hruler}->set_range( $ha, $ha + $width / $s, 0, $hmax_size ); $self->{_vruler}->set_range( $va, $va + $height / $s, 0, $vmax_size ); } } return TRUE; } sub quit { my ( $self, $show_warning ) = @_; my ( $name, $folder, $type ) = fileparse( $self->{_filename}, qr/\.[^.]*/ ); #save settings to a file in the shutter folder #is there already a .shutter folder? mkdir("$ENV{ 'HOME' }/.shutter") unless ( -d "$ENV{ 'HOME' }/.shutter" ); if ( $show_warning && ( defined $self->{_undo} && scalar( @{ $self->{_undo} } ) > 0 ) ) { #warn the user if there are any unsaved changes my $warn_dialog = Gtk2::MessageDialog->new( $self->{_drawing_window}, [qw/modal destroy-with-parent/], 'other', 'none', undef ); #set question text $warn_dialog->set( 'text' => sprintf( $self->{_d}->get("Save the changes to image %s before closing?"), "'$name$type'" ) ); #set text... $self->update_warning_text($warn_dialog); #...and update it my $id = Glib::Timeout->add( 1000, sub { $self->update_warning_text($warn_dialog); return TRUE; } ); $warn_dialog->set( 'image' => Gtk2::Image->new_from_stock( 'gtk-save', 'dialog' ) ); $warn_dialog->set( 'title' => $self->{_d}->get("Close") . " " . $name . $type ); #don't save button my $dsave_btn = Gtk2::Button->new_with_mnemonic( $self->{_d}->get("Do_n't save") ); $dsave_btn->set_image( Gtk2::Image->new_from_stock( 'gtk-delete', 'button' ) ); #cancel button my $cancel_btn = Gtk2::Button->new_from_stock('gtk-cancel'); $cancel_btn->can_default(TRUE); #save button my $save_btn = Gtk2::Button->new_from_stock('gtk-save'); $warn_dialog->add_action_widget( $dsave_btn, 10 ); $warn_dialog->add_action_widget( $cancel_btn, 20 ); $warn_dialog->add_action_widget( $save_btn, 30 ); $warn_dialog->set_default_response(20); $warn_dialog->vbox->show_all; my $response = $warn_dialog->run; Glib::Source->remove($id); if ( $response == 20 ) { $warn_dialog->destroy; return TRUE; } elsif ( $response == 30 ) { $self->save(); } $self->{_drawing_window}->hide if $self->{_drawing_window}; $warn_dialog->hide; $warn_dialog->destroy; } $self->save_settings; if ( $self->{_selector_handler} ) { $self->{_selector}->signal_handler_disconnect( $self->{_selector_handler} ); } $self->{_drawing_window}->hide if $self->{_drawing_window}; $self->{_drawing_window}->destroy if $self->{_drawing_window}; #remove statusbar timer Glib::Source->remove( $self->{_drawing_statusbar}->{statusbar_timer} ) if defined $self->{_drawing_statusbar}->{statusbar_timer}; #delete hash entries to avoid any #possible circularity # #this would lead to a memory leak foreach ( keys %{$self} ) { delete $self->{$_}; } Gtk2->main_quit(); return FALSE; } sub update_warning_text { my ( $self, $warn_dialog ) = @_; my $minutes = int( ( time - $self->{_start_time} ) / 60 ); $minutes = 1 if $minutes == 0; $warn_dialog->set( 'secondary-text' => sprintf( $self->{_d}->nget( "If you don't save the image, changes from the last minute will be lost", "If you don't save the image, changes from the last %d minutes will be lost", $minutes ), $minutes, ) . "." ); return TRUE; } sub load_settings { my $self = shift; my $shutter_hfunct = Shutter::App::HelperFunctions->new( $self->{_sc} ); #settings file my $settingsfile = "$ENV{ HOME }/.shutter/drawingtool.xml"; my $settings_xml; if ( $shutter_hfunct->file_exists($settingsfile) ) { eval { $settings_xml = XMLin( IO::File->new($settingsfile) ); #restore window state when maximized if ( exists $settings_xml->{'drawing'}->{'state'} && defined $settings_xml->{'drawing'}->{'state'} && $settings_xml->{'drawing'}->{'state'} eq 'maximized' ) { $self->{_drawing_window}->maximize; } #window size and position if ( $settings_xml->{'drawing'}->{'x'} && $settings_xml->{'drawing'}->{'y'} ) { $self->{_drawing_window}->move( $settings_xml->{'drawing'}->{'x'}, $settings_xml->{'drawing'}->{'y'} ); } if ( $settings_xml->{'drawing'}->{'width'} && $settings_xml->{'drawing'}->{'height'} ) { $self->{_drawing_window}->resize( $settings_xml->{'drawing'}->{'width'}, $settings_xml->{'drawing'}->{'height'} ); } #current mode if ( $settings_xml->{'drawing'}->{'mode'} ) { $self->{_current_mode} = $settings_xml->{'drawing'}->{'mode'}; } #autoscroll my $autoscroll_toggle = $self->{_uimanager}->get_widget("/MenuBar/Edit/Autoscroll"); $autoscroll_toggle->set_active( $settings_xml->{'drawing'}->{'autoscroll'} ); #drawing colors $self->{_fill_color} = Gtk2::Gdk::Color->parse( $settings_xml->{'drawing'}->{'fill_color'} ); $self->{_fill_color_alpha} = $settings_xml->{'drawing'}->{'fill_color_alpha'}; $self->{_stroke_color} = Gtk2::Gdk::Color->parse( $settings_xml->{'drawing'}->{'stroke_color'} ); $self->{_stroke_color_alpha} = $settings_xml->{'drawing'}->{'stroke_color_alpha'}; #line_width $self->{_line_width} = $settings_xml->{'drawing'}->{'line_width'}; #font $self->{_font} = $settings_xml->{'drawing'}->{'font'}; }; if ($@) { warn "ERROR: Settings of DrawingTool could not be restored: $@ - ignoring\n"; } } return TRUE; } sub save_settings { my $self = shift; #to avoid saving the properties of the highlighter #this does not make any sense $self->restore_drawing_properties; #settings file my $settingsfile = "$ENV{ HOME }/.shutter/drawingtool.xml"; #hash to store settings my %settings; #window size and position if ( defined $self->{_drawing_window}->window ) { if ( $self->{_drawing_window}->window->get_state eq 'GDK_WINDOW_STATE_MAXIMIZED' ) { $settings{'drawing'}->{'state'} = 'maximized'; } } my ( $w, $h ) = $self->{_drawing_window}->get_size; my ( $x, $y ) = $self->{_drawing_window}->get_position; $settings{'drawing'}->{'x'} = $x; $settings{'drawing'}->{'y'} = $y; $settings{'drawing'}->{'width'} = $w; $settings{'drawing'}->{'height'} = $h; #current action #but don't save the crop tool as last action #as it would be confusing to open the drawing tool #with crop tool enabled if ( $self->{_current_mode_descr} ne "crop" ) { $settings{'drawing'}->{'mode'} = $self->{_current_mode}; } else { $settings{'drawing'}->{'mode'} = 10; } #autoscroll my $autoscroll_toggle = $self->{_uimanager}->get_widget("/MenuBar/Edit/Autoscroll"); $settings{'drawing'}->{'autoscroll'} = $autoscroll_toggle->get_active(); #drawing colors $settings{'drawing'}->{'fill_color'} = sprintf( "#%04x%04x%04x", $self->{_fill_color}->red, $self->{_fill_color}->green, $self->{_fill_color}->blue ); $settings{'drawing'}->{'fill_color_alpha'} = $self->{_fill_color_alpha}; $settings{'drawing'}->{'stroke_color'} = sprintf( "#%04x%04x%04x", $self->{_stroke_color}->red, $self->{_stroke_color}->green, $self->{_stroke_color}->blue ); $settings{'drawing'}->{'stroke_color_alpha'} = $self->{_stroke_color_alpha}; #line_width $settings{'drawing'}->{'line_width'} = $self->{_line_width}; #font $settings{'drawing'}->{'font'} = $self->{_font}; eval { #save to file open( SETTFILE, ">$settingsfile" ) or die $!; print SETTFILE XMLout( \%settings ); close(SETTFILE) or die $!; }; if ($@) { warn "ERROR: Settings of DrawingTool could not be saved: $@ - ignoring\n"; } return TRUE; } sub export_to_file { my $self = shift; my $rfiletype = shift; my $fs = Gtk2::FileChooserDialog->new( $self->{_d}->get("Choose a location to save to"), $self->{_drawing_window}, 'save', 'gtk-cancel' => 'reject', 'gtk-save' => 'accept' ); my $shutter_hfunct = Shutter::App::HelperFunctions->new( $self->{_sc} ); my $shutter_dir = Shutter::App::Directories->new(); #parse filename my ( $short, $folder, $ext ) = fileparse( $self->{_filename}, qr/\.[^.]*/ ); #go to recently used folder if ( defined $self->{_sc}->get_rusf && $shutter_hfunct->folder_exists( $self->{_sc}->get_rusf ) ) { $fs->set_current_folder( $self->{_sc}->get_rusf ); $fs->set_current_name( $short . $ext ); } elsif ( defined $self->{_is_unsaved} && $self->{_is_unsaved} ) { $fs->set_current_folder( $shutter_dir->get_home_dir ); $fs->set_current_name( $short . $ext ); } else { $fs->set_current_folder($folder); $fs->set_current_name( $short . $ext ); } #preview widget my $iprev = Gtk2::Image->new; $fs->set_preview_widget($iprev); $fs->signal_connect( 'selection-changed' => sub { if ( my $pfilename = $fs->get_preview_filename ) { my $pixbuf = $self->{_lp_ne}->load( $pfilename, 200, 200, TRUE, TRUE ); unless ($pixbuf) { $fs->set_preview_widget_active(FALSE); } else { $fs->get_preview_widget->set_from_pixbuf($pixbuf); $fs->set_preview_widget_active(TRUE); } } else { $fs->set_preview_widget_active(FALSE); } } ); #change extension related to the requested filetype if ( defined $rfiletype ) { my ( $short, $folder, $ext ) = fileparse( $self->{_filename}, qr/\.[^.]*/ ); $fs->set_current_name( $short . "." . $rfiletype ); } my $extra_hbox = Gtk2::HBox->new; my $label_save_as_type = Gtk2::Label->new( $self->{_d}->get("Image format") . ":" ); my $combobox_save_as_type = Gtk2::ComboBox->new_text; #add supported formats to combobox my $counter = 0; my $png_counter = undef; #add pdf support if ( defined $rfiletype && $rfiletype eq 'pdf' ) { $combobox_save_as_type->insert_text( $counter, "pdf - Portable Document Format" ); $combobox_save_as_type->set_active(0); #add ps support } elsif ( defined $rfiletype && $rfiletype eq 'ps' ) { $combobox_save_as_type->insert_text( $counter, "ps - PostScript" ); $combobox_save_as_type->set_active(0); #images } else { foreach ( Gtk2::Gdk::Pixbuf->get_formats ) { #we don't want svg here - this is a dedicated action in the DrawingTool next if !defined $rfiletype && $_->{name} =~ /svg/; #we have a requested filetype - nothing else will be offered next if defined $rfiletype && $_->{name} ne $rfiletype; #we want jpg not jpeg if ( $_->{name} eq "jpeg" || $_->{name} eq "jpg" ) { $combobox_save_as_type->insert_text( $counter, "jpg" . " - " . $_->{description} ); } else { $combobox_save_as_type->insert_text( $counter, $_->{name} . " - " . $_->{description} ); } #set active when mime_type is matching #loop because multiple mime types are registered for fome file formats foreach my $mime ( @{ $_->{mime_types} } ) { $combobox_save_as_type->set_active($counter) if $mime eq $self->{'_mimetype'} || defined $rfiletype; #save png_counter as well as fallback $png_counter = $counter if $mime eq 'image/png'; } $counter++; } } #something went wrong here #filetype was not detected automatically #set to png as default unless ( $combobox_save_as_type->get_active_text ) { if ( defined $png_counter ) { $combobox_save_as_type->set_active($png_counter); } } $combobox_save_as_type->signal_connect( 'changed' => sub { my $filename = $fs->get_filename; my $choosen_format = $combobox_save_as_type->get_active_text; $choosen_format =~ s/ \-.*//; #get png or jpeg (jpg) for example #~ print $choosen_format . "\n"; #parse filename my ( $short, $folder, $ext ) = fileparse( $filename, qr/\.[^.]*/ ); $fs->set_current_name( $short . "." . $choosen_format ); } ); #emit the signal once in order to invoke the sub above #~ $combobox_save_as_type->signal_emit('changed'); $extra_hbox->pack_start( $label_save_as_type, FALSE, FALSE, 5 ); $extra_hbox->pack_start( $combobox_save_as_type, FALSE, FALSE, 5 ); my $align_save_as_type = Gtk2::Alignment->new( 1, 0, 0, 0 ); $align_save_as_type->add($extra_hbox); $align_save_as_type->show_all; $fs->set_extra_widget($align_save_as_type); my $fs_resp = $fs->run; if ( $fs_resp eq "accept" ) { my $filename = $fs->get_filename; #parse filename my ( $short, $folder, $ext ) = fileparse( $filename, qr/\.[^.]*/ ); #keep selected folder in mind $self->{_sc}->set_rusf($folder); #handle file format my $choosen_format = $combobox_save_as_type->get_active_text; $choosen_format =~ s/ \-.*//; #get png or jpeg (jpg) for example $filename = $folder . $short . "." . $choosen_format; my $shutter_hfunct = Shutter::App::HelperFunctions->new( $self->{_sc} ); unless ( $shutter_hfunct->file_exists($filename) ) { #save $self->save( FALSE, $filename, $choosen_format ); } else { #ask the user to replace the image #replace button my $replace_btn = Gtk2::Button->new_with_mnemonic( $self->{_d}->get("_Replace") ); $replace_btn->set_image( Gtk2::Image->new_from_stock( 'gtk-save-as', 'button' ) ); my $response = $self->{_dialogs}->dlg_warning_message( sprintf( $self->{_d}->get("The image already exists in %s. Replacing it will overwrite its contents."), "'" . $folder . "'" ), sprintf( $self->{_d}->get("An image named %s already exists. Do you want to replace it?"), "'" . $short . "." . $choosen_format . "'" ), undef, undef, undef, $replace_btn, undef, undef ); if ( $response == 40 ) { #save $self->save( FALSE, $filename, $choosen_format ); } } } $fs->destroy(); } sub export_to_svg { my $self = shift; #here might be some more features in future releases of Shutter #just call the dialog $self->export_to_file('svg'); return TRUE; } sub export_to_ps { my $self = shift; #here might be some more features in future releases of Shutter #just call the dialog $self->export_to_file('ps'); return TRUE; } sub export_to_pdf { my $self = shift; #here might be some more features in future releases of Shutter #just call the dialog $self->export_to_file('pdf'); return TRUE; } sub save { my $self = shift; my $save_to_mem = shift; my $filename = shift || $self->{_filename}; my $filetype = shift || $self->{_filetype}; #make sure not to save the bounding rectangles $self->deactivate_all; #hide line and change background color, e.g. for saving $self->handle_bg_rects('hide'); unless ($save_to_mem) { #image format supports transparency or not #we need to support more formats here I think if ( $filetype eq 'jpeg' || $filetype eq 'jpg' || $filetype eq 'bmp' ) { $self->{_canvas_bg_rect}->set( 'fill-pattern' => $self->create_color( $self->{_canvas_bg_rect}{fill_color}, 1.0 ), 'line-width' => 0, ); } elsif ( $self->{_canvas_bg_rect}{fill_color}->equal( Gtk2::Gdk::Color->parse('gray') ) ) { $self->{_canvas_bg_rect}->set( 'visibility' => 'hidden' ); } else { #ask the user if he wants to save the background color my $bg_dialog = Gtk2::MessageDialog->new( $self->{_drawing_window}, [qw/modal destroy-with-parent/], 'other', 'none', undef ); #set attributes $bg_dialog->set( 'text' => $self->{_d}->get("Do you want to save the changed background color?") ); $bg_dialog->set( 'secondary-text' => $self->{_d}->get("The background is likely to be transparent if you decide to ignore the background color.") ); $bg_dialog->set( 'image' => Gtk2::Image->new_from_stock( 'gtk-save', 'dialog' ) ); $bg_dialog->set( 'title' => $self->{_d}->get("Save Background Color") ); #ignore bg button my $cancel_btn = Gtk2::Button->new_with_mnemonic( $self->{_d}->get("_Ignore Background Color") ); #save bg button my $bg_btn = Gtk2::Button->new_with_mnemonic( $self->{_d}->get("_Save Background Color") ); $bg_btn->can_default(TRUE); $bg_dialog->add_action_widget( $cancel_btn, 10 ); $bg_dialog->add_action_widget( $bg_btn, 20 ); $bg_dialog->set_default_response(20); $bg_dialog->vbox->show_all; my $response = $bg_dialog->run; if ( $response == 10 ) { $self->{_canvas_bg_rect}->set( 'visibility' => 'hidden' ); } elsif ( $response == 20 ) { $self->{_canvas_bg_rect}->set( 'fill-pattern' => $self->create_color( $self->{_canvas_bg_rect}{fill_color}, 1.0 ), 'line-width' => 0, ); } $bg_dialog->destroy; } } else { $self->{_canvas_bg_rect}->set( 'visibility' => 'hidden' ); } if ( $filetype eq 'svg' ) { #0.8? => 72 / 90 dpi my $surface = Cairo::SvgSurface->create( $filename, $self->{_canvas_bg_rect}->get('width') * 0.8, $self->{_canvas_bg_rect}->get('height') * 0.8 ); my $cr = Cairo::Context->create($surface); $cr->scale( 0.8, 0.8 ); $self->{_canvas}->render( $cr, $self->{_canvas_bg_rect}->get_bounds, 1 ); $cr->show_page; } elsif ( $filetype eq 'ps' ) { #0.8? => 72 / 90 dpi my $surface = Cairo::PsSurface->create( $filename, $self->{_canvas_bg_rect}->get('width') * 0.8, $self->{_canvas_bg_rect}->get('height') * 0.8 ); my $cr = Cairo::Context->create($surface); $cr->scale( 0.8, 0.8 ); $self->{_canvas}->render( $cr, $self->{_canvas_bg_rect}->get_bounds, 1 ); $cr->show_page; } elsif ( $filetype eq 'pdf' ) { #0.8? => 72 / 90 dpi my $surface = Cairo::PdfSurface->create( $filename, $self->{_canvas_bg_rect}->get('width') * 0.8, $self->{_canvas_bg_rect}->get('height') * 0.8 ); my $cr = Cairo::Context->create($surface); $cr->scale( 0.8, 0.8 ); $self->{_canvas}->render( $cr, $self->{_canvas_bg_rect}->get_bounds, 1 ); $cr->show_page; } else { my $surface = Cairo::ImageSurface->create( 'argb32', $self->{_canvas_bg_rect}->get('width'), $self->{_canvas_bg_rect}->get('height') ); my $cr = Cairo::Context->create($surface); $self->{_canvas}->render( $cr, $self->{_canvas_bg_rect}->get_bounds, 1 ); my $loader = Gtk2::Gdk::PixbufLoader->new; $surface->write_to_png_stream( sub { my ( $closure, $data ) = @_; $loader->write($data); } ); $loader->close; my $pixbuf = $loader->get_pixbuf; #just return pixbuf if ($save_to_mem) { #update the canvas_rect again $self->{_canvas_bg_rect}->set( 'fill-pattern' => $self->create_color( $self->{_canvas_bg_rect}{fill_color}, 1.0 ), 'line-width' => 1, 'visibility' => 'visible', ); $self->handle_bg_rects('show'); return $pixbuf; } #save pixbuf to file my $pixbuf_save = Shutter::Pixbuf::Save->new( $self->{_sc}, $self->{_drawing_window} ); return $pixbuf_save->save_pixbuf_to_file( $pixbuf, $filename, $filetype ); } } #ITEM SIGNALS sub setup_item_signals { my ( $self, $item ) = @_; $item->signal_connect( 'motion_notify_event', sub { my ( $item, $target, $ev ) = @_; $self->event_item_on_motion_notify( $item, $target, $ev ); } ); $item->signal_connect( 'key_press_event', sub { my ( $item, $target, $ev ) = @_; $self->event_item_on_key_press( $item, $target, $ev ); } ); $item->signal_connect( 'button_press_event', sub { my ( $item, $target, $ev ) = @_; $self->event_item_on_button_press( $item, $target, $ev ); } ); $item->signal_connect( 'button_release_event', sub { my ( $item, $target, $ev ) = @_; $self->event_item_on_button_release( $item, $target, $ev ); } ); return TRUE; } sub setup_item_signals_extra { my ( $self, $item ) = @_; $item->signal_connect( 'enter_notify_event', sub { my ( $item, $target, $ev ) = @_; $self->event_item_on_enter_notify( $item, $target, $ev ); } ); $item->signal_connect( 'leave_notify_event', sub { my ( $item, $target, $ev ) = @_; $self->event_item_on_leave_notify( $item, $target, $ev ); } ); return TRUE; } sub event_item_on_motion_notify { my ( $self, $item, $target, $ev ) = @_; $self->adjust_rulers( $ev, $item ); #autoscroll if enabled #as does not work when using the censor tool -> deactivate it if ( $self->{_current_mode_descr} ne "censor" && $self->{_autoscroll} && ( $ev->state >= 'button1-mask' || $ev->state >= 'button2-mask' ) ) { my ( $x, $y, $width, $height, $depth ) = $self->{_canvas}->window->get_geometry; my $s = $self->{_canvas}->get_scale; my $ha = $self->{_scrolled_window}->get_hadjustment->value; my $va = $self->{_scrolled_window}->get_vadjustment->value; #autoscroll if ( $ev->x > ( $ha / $s + $width / $s - 100 / $s ) && $ev->y > ( $va / $s + $height / $s - 100 / $s ) ) { $self->{_canvas}->scroll_to( $ha / $s + 10 / $s, $va / $s + 10 / $s ); } elsif ( $ev->x > ( $ha / $s + $width / $s - 100 / $s ) ) { $self->{_canvas}->scroll_to( $ha / $s + 10 / $s, $va / $s ); } elsif ( $ev->y > ( $va / $s + $height / $s - 100 / $s ) ) { $self->{_canvas}->scroll_to( $ha / $s, $va / $s + 10 / $s ); } elsif ( $ev->x < ( $ha / $s + 100 / $s ) && $ev->y < ( $va / $s + 100 / $s ) ) { $self->{_canvas}->scroll_to( $ha / $s - 10 / $s, $va / $s - 10 / $s ); } elsif ( $ev->x < ( $ha / $s + 100 / $s ) ) { $self->{_canvas}->scroll_to( $ha / $s - 10 / $s, $va / $s ); } elsif ( $ev->y < ( $va / $s + 100 / $s ) ) { $self->{_canvas}->scroll_to( $ha / $s, $va / $s - 10 / $s ); } } #move if ( $item->{dragging} && ( $ev->state >= 'button1-mask' || $ev->state >= 'button2-mask' ) ) { if ( $item->isa('Goo::Canvas::Rect') ) { my $new_x = $self->{_items}{$item}->get('x') + $ev->x - $item->{drag_x}; my $new_y = $self->{_items}{$item}->get('y') + $ev->y - $item->{drag_y}; $self->{_items}{$item}->set( 'x' => $new_x, 'y' => $new_y, ); $item->{drag_x} = $ev->x; $item->{drag_y} = $ev->y; $self->handle_rects( 'update', $item ); $self->handle_embedded( 'update', $item ); } else { $item->translate( $ev->x - $item->{drag_x}, $ev->y - $item->{drag_y} ); } #add to undo stack if ( $item->{dragging_start} ) { $self->store_to_xdo_stack( $item, 'modify', 'undo' ); $item->{dragging_start} = FALSE; } #freehand line } elsif ( ( $self->{_current_mode_descr} eq "freehand" || $self->{_current_mode_descr} eq "highlighter" || $self->{_current_mode_descr} eq "censor" ) && $ev->state >= 'button1-mask' ) { #mark as active item my $item = undef; if ( $self->{_current_new_item} ) { $item = $self->{_current_new_item}; $self->{_current_new_item} = undef; $self->{_current_item} = $item; #add to undo stack $self->store_to_xdo_stack( $self->{_current_item}, 'create', 'undo' ); } else { $item = $self->{_current_item}; } if ( $ev->state >= 'control-mask' ) { my $last_point = pop @{ $self->{_items}{$item}{'points'} }; $last_point = $ev->y unless $last_point; push @{ $self->{_items}{$item}{'points'} }, $last_point, $ev->x, $last_point; } elsif ( $ev->state >= 'shift-mask' ) { my $last_point_y = pop @{ $self->{_items}{$item}{'points'} }; my $last_point_x = pop @{ $self->{_items}{$item}{'points'} }; $last_point_x = $ev->x unless $last_point_x; $last_point_y = $ev->y unless $last_point_y; push @{ $self->{_items}{$item}{'points'} }, $last_point_x, $last_point_y, $last_point_x, $ev->y; } else { push @{ $self->{_items}{$item}{'points'} }, $ev->x, $ev->y; } $self->{_items}{$item}->set( 'points' => Goo::Canvas::Points->new( $self->{_items}{$item}{'points'} ) ); #new item is already on the canvas with small initial size #drawing is like resizing, so set up for resizing } elsif ( ( $self->{_current_mode_descr} eq "rect" || $self->{_current_mode_descr} eq "line" || $self->{_current_mode_descr} eq "arrow" || $self->{_current_mode_descr} eq "ellipse" || $self->{_current_mode_descr} eq "text" || $self->{_current_mode_descr} eq "image" || $self->{_current_mode_descr} eq "pixelize" || $self->{_current_mode_descr} eq "number" ) && $ev->state >= 'button1-mask' && !$item->{resizing} #if item is not in resize mode already ) { #~ print "start resizing\n"; my $item = $self->{_current_new_item}; return FALSE unless $item; $self->deactivate_all($item); #mark as active item $self->{_current_item} = $item; $self->{_items}{$item}{'bottom-right-corner'}->{res_x} = $ev->x; $self->{_items}{$item}{'bottom-right-corner'}->{res_y} = $ev->y; $self->{_items}{$item}{'bottom-right-corner'}->{resizing} = TRUE; $self->{_canvas}->pointer_grab( $self->{_items}{$item}{'bottom-right-corner'}, [ 'pointer-motion-mask', 'button-release-mask' ], undef, $ev->time ); #add to undo stack $self->store_to_xdo_stack( $item, 'create', 'undo' ); #item is resizing mode already } elsif ( $item->{resizing} && $ev->state >= 'button1-mask' ) { #~ print "resizing\n"; $self->{_current_mode_descr} = "resize"; #canvas resizing shape if ( $self->{_canvas_bg_rect}{'right-side'} == $item ) { my $new_width = $self->{_canvas_bg_rect}->get('width') + ( $ev->x - $item->{res_x} ); unless ( $new_width < 0 ) { $self->{_canvas_bg_rect}->set( 'width' => $new_width, ); $self->handle_bg_rects('update'); } } elsif ( $self->{_canvas_bg_rect}{'bottom-side'} == $item ) { my $new_height = $self->{_canvas_bg_rect}->get('height') + ( $ev->y - $item->{res_y} ); unless ( $new_height < 0 ) { $self->{_canvas_bg_rect}->set( 'height' => $new_height, ); $self->handle_bg_rects('update'); } } elsif ( $self->{_canvas_bg_rect}{'bottom-right-corner'} == $item ) { my $new_width = $self->{_canvas_bg_rect}->get('width') + ( $ev->x - $item->{res_x} ); my $new_height = $self->{_canvas_bg_rect}->get('height') + ( $ev->y - $item->{res_y} ); unless ( $new_width < 0 || $new_height < 0 ) { $self->{_canvas_bg_rect}->set( 'width' => $new_width, 'height' => $new_height, ); $self->handle_bg_rects('update'); } #item resizing shape } else { my $curr_item = $self->{_current_item}; #~ my $cursor = undef; return FALSE unless $curr_item; #calculate aspect ratio (resizing when control is pressed) my $ratio = 1; $ratio = $self->{_items}{$curr_item}->get('width') / $self->{_items}{$curr_item}->get('height') if $self->{_items}{$curr_item}->get('height') != 0; my $new_x = 0; my $new_y = 0; my $new_width = 0; my $new_height = 0; foreach ( keys %{ $self->{_items}{$curr_item} } ) { next unless $_ =~ m/(corner|side)/; #fancy resizing using our little resize boxes if ( $item == $self->{_items}{$curr_item}{$_} ) { #~ $cursor = $_; if ( $_ eq 'bottom-side' ) { $new_x = $self->{_items}{$curr_item}->get('x'); $new_y = $self->{_items}{$curr_item}->get('y'); $new_width = $self->{_items}{$curr_item}->get('width'); $new_height = $self->{_items}{$curr_item}->get('height') + ( $ev->y - $item->{res_y} ); last; } elsif ( $_ eq 'bottom-right-corner' ) { $new_x = $self->{_items}{$curr_item}->get('x'); $new_y = $self->{_items}{$curr_item}->get('y'); if ( $ev->state >= 'control-mask' ) { $new_width = $self->{_items}{$curr_item}->get('width') + ( $ev->y - $item->{res_y} ) * $ratio; $new_height = $self->{_items}{$curr_item}->get('height') + ( $ev->y - $item->{res_y} ); } else { $new_width = $self->{_items}{$curr_item}->get('width') + ( $ev->x - $item->{res_x} ); $new_height = $self->{_items}{$curr_item}->get('height') + ( $ev->y - $item->{res_y} ); } last; } elsif ( $_ eq 'top-left-corner' ) { if ( $ev->state >= 'control-mask' ) { $new_x = $self->{_items}{$curr_item}->get('x') + ( $ev->y - $item->{res_y} ) * $ratio; $new_y = $self->{_items}{$curr_item}->get('y') + ( $ev->y - $item->{res_y} ); $new_width = $self->{_items}{$curr_item}->get('width') + ( $self->{_items}{$curr_item}->get('x') - $new_x ); $new_height = $self->{_items}{$curr_item}->get('height') + ( $self->{_items}{$curr_item}->get('y') - $new_y ); } else { $new_x = $self->{_items}{$curr_item}->get('x') + $ev->x - $item->{res_x}; $new_y = $self->{_items}{$curr_item}->get('y') + $ev->y - $item->{res_y}; $new_width = $self->{_items}{$curr_item}->get('width') + ( $self->{_items}{$curr_item}->get('x') - $new_x ); $new_height = $self->{_items}{$curr_item}->get('height') + ( $self->{_items}{$curr_item}->get('y') - $new_y ); } last; } elsif ( $_ eq 'top-side' ) { $new_x = $self->{_items}{$curr_item}->get('x'); $new_y = $self->{_items}{$curr_item}->get('y') + $ev->y - $item->{res_y}; $new_width = $self->{_items}{$curr_item}->get('width'); $new_height = $self->{_items}{$curr_item}->get('height') + ( $self->{_items}{$curr_item}->get('y') - $new_y ); last; } elsif ( $_ eq 'top-right-corner' ) { $new_x = $self->{_items}{$curr_item}->get('x'); $new_y = $self->{_items}{$curr_item}->get('y') + $ev->y - $item->{res_y}; if ( $ev->state >= 'control-mask' ) { $new_width = $self->{_items}{$curr_item}->get('width') - ( $ev->y - $item->{res_y} ) * $ratio; $new_height = $self->{_items}{$curr_item}->get('height') + ( $self->{_items}{$curr_item}->get('y') - $new_y ); } else { $new_width = $self->{_items}{$curr_item}->get('width') + ( $ev->x - $item->{res_x} ); $new_height = $self->{_items}{$curr_item}->get('height') + ( $self->{_items}{$curr_item}->get('y') - $new_y ); } last; } elsif ( $_ eq 'left-side' ) { $new_x = $self->{_items}{$curr_item}->get('x') + $ev->x - $item->{res_x}; $new_y = $self->{_items}{$curr_item}->get('y'); $new_width = $self->{_items}{$curr_item}->get('width') + ( $self->{_items}{$curr_item}->get('x') - $new_x ); $new_height = $self->{_items}{$curr_item}->get('height'); last; } elsif ( $_ eq 'right-side' ) { $new_x = $self->{_items}{$curr_item}->get('x'); $new_y = $self->{_items}{$curr_item}->get('y'); $new_width = $self->{_items}{$curr_item}->get('width') + ( $ev->x - $item->{res_x} ); $new_height = $self->{_items}{$curr_item}->get('height'); last; } elsif ( $_ eq 'bottom-left-corner' ) { if ( $ev->state >= 'control-mask' ) { $new_x = $self->{_items}{$curr_item}->get('x') - $ev->y + $item->{res_y}; $new_y = $self->{_items}{$curr_item}->get('y'); $new_width = $self->{_items}{$curr_item}->get('width') + ( $self->{_items}{$curr_item}->get('x') - $new_x ); $new_height = $self->{_items}{$curr_item}->get('height') + ( $ev->y - $item->{res_y} ) / $ratio; } else { $new_x = $self->{_items}{$curr_item}->get('x') + $ev->x - $item->{res_x}; $new_y = $self->{_items}{$curr_item}->get('y'); $new_width = $self->{_items}{$curr_item}->get('width') + ( $self->{_items}{$curr_item}->get('x') - $new_x ); $new_height = $self->{_items}{$curr_item}->get('height') + ( $ev->y - $item->{res_y} ); } last; } } } #set cursor #~ $self->{_canvas}->window->set_cursor( Gtk2::Gdk::Cursor->new($cursor) ); #when width or height are too small we switch to opposite rectangle and do the resizing in this way if ( $ev->state >= 'control-mask' && $new_width < 1 && $new_height < 1 ) { $new_x = $self->{_items}{$curr_item}->get('x'); $new_y = $self->{_items}{$curr_item}->get('y'); $new_width = $self->{_items}{$curr_item}->get('width'); $new_height = $self->{_items}{$curr_item}->get('height'); } elsif ( $new_width < 0 || $new_height < 0 ) { $self->{_canvas}->pointer_ungrab( $item, $ev->time ); $self->{_canvas}->keyboard_ungrab( $item, $ev->time ); my $oppo = $self->get_opposite_rect( $item, $curr_item, $new_width, $new_height ); $self->{_items}{$curr_item}{$oppo}->{res_x} = $ev->x; $self->{_items}{$curr_item}{$oppo}->{res_y} = $ev->y; $self->{_items}{$curr_item}{$oppo}->{resizing} = TRUE; #~ #don'change cursor if this item was just started #~ if($self->{_last_item} && $self->{_current_item} && $self->{_last_item} == $self->{_current_item}){ #~ $self->{_canvas}->pointer_grab( $self->{_items}{$curr_item}{$oppo}, [ 'pointer-motion-mask', 'button-release-mask' ], undef, $ev->time ); #~ }else{ #~ $self->{_canvas}->pointer_grab( $self->{_items}{$curr_item}{$oppo}, [ 'pointer-motion-mask', 'button-release-mask' ], Gtk2::Gdk::Cursor->new($oppo), $ev->time ); #~ } $self->{_canvas}->pointer_grab( $self->{_items}{$curr_item}{$oppo}, [ 'pointer-motion-mask', 'button-release-mask' ], undef, $ev->time ); $self->handle_embedded( 'mirror', $curr_item, $new_width, $new_height ); #adjust new values if ( $new_width < 0 ) { $new_x += $new_width; $new_width = abs($new_width); } if ( $new_height < 0 ) { $new_y += $new_height; $new_height = abs($new_height); } } #apply new values... $self->{_items}{$curr_item}->set( 'x' => $new_x, 'y' => $new_y, 'width' => $new_width, 'height' => $new_height, ); #and update rectangles and embedded items $self->handle_rects( 'update', $curr_item ); $self->handle_embedded( 'update', $curr_item ); } $item->{res_x} = $ev->x; $item->{res_y} = $ev->y; } else { if ( $item->isa('Goo::Canvas::Rect') ) { #embedded item? my $parent = $self->get_parent_item($item); $item = $parent if $parent; #shape or canvas background (resizeable rectangle) if ( exists $self->{_items}{$item} or $item == $self->{_canvas_bg_rect} ) { $self->push_tool_help_to_statusbar( int( $ev->x ), int( $ev->y ) ); #canvas resizing shape } elsif ($self->{_canvas_bg_rect}{'right-side'} == $item || $self->{_canvas_bg_rect}{'bottom-side'} == $item || $self->{_canvas_bg_rect}{'bottom-right-corner'} == $item ) { $self->push_tool_help_to_statusbar( int( $ev->x ), int( $ev->y ), 'canvas_resize' ); #resizing shape } else { $self->push_tool_help_to_statusbar( int( $ev->x ), int( $ev->y ), 'resize' ); } } else { $self->push_tool_help_to_statusbar( int( $ev->x ), int( $ev->y ) ); } } return TRUE; } sub get_opposite_rect { my $self = shift; my $rect = shift; my $item = shift; my $width = shift; my $height = shift; foreach ( keys %{ $self->{_items}{$item} } ) { #fancy resizing using our little resize boxes if ( $rect == $self->{_items}{$item}{$_} ) { if ( $_ eq 'top-left-corner' ) { return 'bottom-right-corner' if $width < 0 && $height < 0; return 'top-right-corner' if $width < 0; return 'bottom-left-corner' if $height < 0; } elsif ( $_ eq 'top-side' ) { return 'bottom-side'; } elsif ( $_ eq 'top-right-corner' ) { return 'bottom-left-corner' if $width < 0 && $height < 0; return 'top-left-corner' if $width < 0; return 'bottom-right-corner' if $height < 0; } elsif ( $_ eq 'left-side' ) { return 'right-side'; } elsif ( $_ eq 'right-side' ) { return 'left-side'; } elsif ( $_ eq 'bottom-left-corner' ) { return 'top-right-corner' if $width < 0 && $height < 0; return 'bottom-right-corner' if $width < 0; return 'top-left-corner' if $height < 0; } elsif ( $_ eq 'bottom-side' ) { return 'top-side'; } elsif ( $_ eq 'bottom-right-corner' ) { return 'top-left-corner' if $width < 0 && $height < 0; return 'bottom-left-corner' if $width < 0; return 'top-right-corner' if $height < 0; } } } return FALSE; } sub get_parent_item { my ( $self, $item ) = @_; return FALSE unless $item; my $parent = undef; foreach ( keys %{ $self->{_items} } ) { $parent = $self->{_items}{$_} if exists $self->{_items}{$_}{ellipse} && $self->{_items}{$_}{ellipse} == $item; $parent = $self->{_items}{$_} if exists $self->{_items}{$_}{text} && $self->{_items}{$_}{text} == $item; $parent = $self->{_items}{$_} if exists $self->{_items}{$_}{image} && $self->{_items}{$_}{image} == $item; $parent = $self->{_items}{$_} if exists $self->{_items}{$_}{pixelize} && $self->{_items}{$_}{pixelize} == $item; $parent = $self->{_items}{$_} if exists $self->{_items}{$_}{line} && $self->{_items}{$_}{line} == $item; if ( defined $parent ) { last; } } #~ #debug #~ if($parent){ #~ print "parent: $parent queried for item: $item\n"; #~ }else{ #~ print "no parent found for item: $item\n"; #~ } return $parent; } sub get_highest_auto_digit { my ($self) = @_; my $number = 0; foreach ( keys %{ $self->{_items} } ) { my $item = $self->{_items}{$_}; #numbered shape if ( exists $self->{_items}{$item} && exists $self->{_items}{$item}{type} && $self->{_items}{$item}{type} eq 'number' && $self->{_items}{$item}{text}->get('visibility') ne 'hidden' ) { $number = $self->{_items}{$item}{text}{digit} if $self->{_items}{$item}{text}{digit} > $number; } } return $number; } sub get_pixelated_pixbuf_from_canvas { my ( $self, $item ) = @_; my $bounds = $item->get_bounds; my $sw = $item->get('width'); my $sh = $item->get('height'); #create surface and cairo context my $surface = Cairo::ImageSurface->create( 'argb32', $bounds->x1 + $sw, $bounds->y1 + $sh ); my $cr = Cairo::Context->create($surface); #hide rects and image $self->handle_rects( 'hide', $item ); $self->handle_embedded( 'hide', $item ); #render the content and load it via Gtk2::Gdk::PixbufLoader $self->{_canvas}->render( $cr, $bounds, 1 ); #show rects again $self->handle_rects( 'update', $item ); #~ print "start loader\n"; my $loader = Gtk2::Gdk::PixbufLoader->new; $surface->write_to_png_stream( sub { my ( $closure, $data ) = @_; $loader->write($data); } ); $loader->close; #create vars my ( $pixbuf, $target ) = ( undef, undef ); #error icon my $error = Gtk2::Widget::render_icon( Gtk2::Invisible->new, "gtk-dialog-error", 'menu' ); eval { $pixbuf = $loader->get_pixbuf; #create target pixbuf $target = Gtk2::Gdk::Pixbuf->new( $pixbuf->get_colorspace, TRUE, 8, $sw, $sh ); }; unless ($@) { #maybe rect is only partially on canvas my ( $sx, $sy ) = ( $bounds->x1, $bounds->y1 ); my ( $dx, $dy ) = ( 0, 0 ); if ( $bounds->x1 < 0 ) { $sx = 0; $dx = abs $bounds->x1; $sw += $bounds->x1; } if ( $bounds->y1 < 0 ) { $sy = 0; $dy = abs $bounds->y1; $sh += $bounds->y1; } #valid pixbuf? if ($pixbuf) { #copy area $pixbuf->copy_area( $sx, $sy, $sw, $sh, $target, $dx, $dy ); if ( $target->get_width > 10 && $target->get_height > 10 ) { eval { #pixelate the pixbuf - simply scale it down and scale it up afterwards $target = $target->scale_simple( $target->get_width * 0.1, $target->get_height * 0.1, 'tiles' ); $target = $target->scale_simple( $item->get('width'), $item->get('height'), 'tiles' ); }; unless ($@) { return $target; } } elsif ( $target->get_width > 5 && $target->get_height > 5 ) { eval { #pixelate the pixbuf - simply scale it down and scale it up afterwards $target = $target->scale_simple( $target->get_width * 0.2, $target->get_height * 0.2, 'tiles' ); $target = $target->scale_simple( $item->get('width'), $item->get('height'), 'tiles' ); }; unless ($@) { return $target; } } } } return $error; } sub get_child_item { my ( $self, $item ) = @_; return FALSE unless $item; my $child = undef; #notice (special shapes like numbered ellipse do deliver ellipse here => NOT text!) #therefore the order matters if ( defined $item && exists $self->{_items}{$item} ) { $child = $self->{_items}{$item}{text} if exists $self->{_items}{$item}{text}; $child = $self->{_items}{$item}{ellipse} if exists $self->{_items}{$item}{ellipse}; $child = $self->{_items}{$item}{image} if exists $self->{_items}{$item}{image}; $child = $self->{_items}{$item}{pixelize} if exists $self->{_items}{$item}{pixelize}; $child = $self->{_items}{$item}{line} if exists $self->{_items}{$item}{line}; } #~ #debug #~ if($child){ #~ print "child: $child queried for item: $item\n"; #~ }else{ #~ print "no child found for item: $item\n"; #~ } return $child; } sub abort_current_mode { my ($self) = @_; if ( $self->{_current_item} ) { $self->{_canvas}->pointer_ungrab( $self->{_current_item}, Gtk2->get_current_event_time ); $self->{_canvas}->keyboard_ungrab( $self->{_current_item}, Gtk2->get_current_event_time ); } #~ print "abort_current_mode\n"; $self->set_drawing_action(1); return TRUE; } sub clear_item_from_canvas { my ( $self, $item ) = @_; #~ print "clear_item_from_canvas\n"; $self->{_current_item} = undef; $self->{_current_new_item} = undef; if ($item) { #maybe there is a parent item to delete? my $parent = $self->get_parent_item($item); $item = $parent if $parent; #get child my $child = $self->get_child_item($item); #only delete if not already deleted (hidden) return FALSE if ( $child && $child->get('visibility') eq 'hidden' ); #~ print "1st passed\n"; return FALSE if ( !$child && $item->get('visibility') eq 'hidden' ); #~ print "2nd passed\n"; $self->store_to_xdo_stack( $item, 'delete', 'undo' ); $item->set( 'visibility' => 'hidden' ); $self->handle_rects( 'hide', $item ); $self->handle_embedded( 'hide', $item ); } return TRUE; } sub store_to_xdo_stack { #opt1 is currently only used when cropping the image #it stores the selection my ( $self, $item, $action, $xdo, $opt1, $source ) = @_; return FALSE unless $item; #~ print "xdo - $item\n"; my %do_info = (); #general properties for ellipse, rectangle, image, text if ( $item->isa('Goo::Canvas::Rect') && $item != $self->{_canvas_bg_rect} ) { my $stroke_pattern = $self->create_color( $self->{_items}{$item}{stroke_color}, $self->{_items}{$item}{stroke_color_alpha} ) if exists $self->{_items}{$item}{stroke_color}; my $fill_pattern = $self->create_color( $self->{_items}{$item}{fill_color}, $self->{_items}{$item}{fill_color_alpha} ) if exists $self->{_items}{$item}{fill_color}; my $line_width = $self->{_items}{$item}->get('line-width'); #line my $mirrored_w = undef; my $mirrored_h = undef; my $end_arrow = undef; my $start_arrow = undef; my $arrow_width = undef; my $arrow_length = undef; my $tip_length = undef; #text my $text = undef; #numbered ellipse my $digit = undef; if ( exists $self->{_items}{$item}{ellipse} ) { $line_width = $self->{_items}{$item}{ellipse}->get('line-width'); #numbered ellipse if ( exists $self->{_items}{$item}{text} ) { $text = $self->{_items}{$item}{text}->get('text'); $digit = $self->{_items}{$item}{text}{digit}; } } elsif ( exists $self->{_items}{$item}{text} ) { $text = $self->{_items}{$item}{text}->get('text'); } elsif ( exists $self->{_items}{$item}{image} ) { } elsif ( exists $self->{_items}{$item}{line} ) { #line width $line_width = $self->{_items}{$item}{line}->get('line-width'); #arrow properties $end_arrow = $self->{_items}{$item}{line}->get('end-arrow'); $start_arrow = $self->{_items}{$item}{line}->get('start-arrow'); $arrow_width = $self->{_items}{$item}{line}->get('arrow-width'); $arrow_length = $self->{_items}{$item}{line}->get('arrow-length'); $tip_length = $self->{_items}{$item}{line}->get('arrow-tip-length'); #mirror flag $mirrored_w = $self->{_items}{$item}{mirrored_w}; $mirrored_h = $self->{_items}{$item}{mirrored_h}; } #item props %do_info = ( 'item' => $self->{_items}{$item}, 'action' => $action, 'x' => $self->{_items}{$item}->get('x'), 'y' => $self->{_items}{$item}->get('y'), 'width' => $self->{_items}{$item}->get('width'), 'height' => $self->{_items}{$item}->get('height'), 'stroke_color' => $self->{_items}{$item}{stroke_color}, 'stroke_color_alpha' => $self->{_items}{$item}{stroke_color_alpha}, 'fill_color' => $self->{_items}{$item}{fill_color}, 'fill_color_alpha' => $self->{_items}{$item}{fill_color_alpha}, 'fill-pattern' => $fill_pattern, 'stroke-pattern' => $stroke_pattern, 'line-width' => $line_width, 'mirrored_w' => $mirrored_w, 'mirrored_h' => $mirrored_h, 'end-arrow' => $end_arrow, 'start-arrow' => $start_arrow, 'arrow-length' => $arrow_length, 'arrow-width' => $arrow_width, 'arrow-tip-length' => $tip_length, 'text' => $text, 'digit' => $digit, 'opt1' => $opt1, ); } elsif ( $item->isa('Goo::Canvas::Image') && $item == $self->{_canvas_bg} ) { #canvas_bg_image and bg_rect properties %do_info = ( 'item' => $self->{_canvas_bg}, 'action' => $action, 'drawing_pixbuf' => $self->{_drawing_pixbuf}, 'x' => $self->{_canvas_bg_rect}->get('x'), 'y' => $self->{_canvas_bg_rect}->get('y'), 'width' => $self->{_canvas_bg_rect}->get('width'), 'height' => $self->{_canvas_bg_rect}->get('height'), 'opt1' => $opt1, ); } elsif ( $item->isa('Goo::Canvas::Rect') && $item == $self->{_canvas_bg_rect} ) { #canvas_bg_rect properties %do_info = ( 'item' => $self->{_canvas_bg_rect}, 'action' => $action, 'x' => $self->{_canvas_bg_rect}->get('x'), 'y' => $self->{_canvas_bg_rect}->get('y'), 'width' => $self->{_canvas_bg_rect}->get('width'), 'height' => $self->{_canvas_bg_rect}->get('height'), 'opt1' => $opt1, ); #polyline specific properties to hash } elsif ( $item->isa('Goo::Canvas::Polyline') ) { my $stroke_pattern = $self->create_color( $self->{_items}{$item}{stroke_color}, $self->{_items}{$item}{stroke_color_alpha} ); my $transform = $self->{_items}{$item}->get('transform'); my $line_width = $self->{_items}{$item}->get('line-width'); my $points = $self->{_items}{$item}->get('points'); %do_info = ( 'item' => $self->{_items}{$item}, 'action' => $action, 'points' => $points, 'stroke-pattern' => $stroke_pattern, 'line-width' => $line_width, 'transform' => $transform, 'opt1' => $opt1, ); } #reset redo if ( defined $source && $source eq 'ui' ) { #~ print "no clear\n"; } else { while ( defined $self->{_redo} && scalar @{ $self->{_redo} } > 0 ) { shift @{ $self->{_redo} }; } } if ( $xdo eq 'undo' ) { push @{ $self->{_undo} }, \%do_info; } elsif ( $xdo eq 'redo' ) { push @{ $self->{_redo} }, \%do_info; } #disable undo/redo actions $self->{_uimanager}->get_widget("/MenuBar/Edit/Undo")->set_sensitive( scalar @{ $self->{_undo} } ) if defined $self->{_undo}; $self->{_uimanager}->get_widget("/MenuBar/Edit/Redo")->set_sensitive( scalar @{ $self->{_redo} } ) if defined $self->{_redo}; $self->{_uimanager}->get_widget("/ToolBar/Undo")->set_sensitive( scalar @{ $self->{_undo} } ) if defined $self->{_undo}; $self->{_uimanager}->get_widget("/ToolBar/Redo")->set_sensitive( scalar @{ $self->{_redo} } ) if defined $self->{_redo}; return TRUE; } sub xdo_remove { my $self = shift; my $xdo = shift; my $item = shift; my @indices; my $counter = 0; if ( $xdo eq 'undo' ) { foreach my $do ( @{ $self->{_undo} } ) { push @indices, $counter if $item == $do->{'item'}; $counter++; } #delete from array foreach my $index (@indices) { splice( @{ $self->{_undo} }, $index, 1 ); } } elsif ( $xdo eq 'redo' ) { foreach my $do ( @{ $self->{_redo} } ) { push @indices, $counter if $item == $do->{'item'}; $counter++; } #delete from array foreach my $index (@indices) { splice( @{ $self->{_redo} }, $index, 1 ); } } #disable undo/redo actions $self->{_uimanager}->get_widget("/MenuBar/Edit/Undo")->set_sensitive( scalar @{ $self->{_undo} } ) if defined $self->{_undo}; $self->{_uimanager}->get_widget("/MenuBar/Edit/Redo")->set_sensitive( scalar @{ $self->{_redo} } ) if defined $self->{_redo}; $self->{_uimanager}->get_widget("/ToolBar/Undo")->set_sensitive( scalar @{ $self->{_undo} } ) if defined $self->{_undo}; $self->{_uimanager}->get_widget("/ToolBar/Redo")->set_sensitive( scalar @{ $self->{_redo} } ) if defined $self->{_redo}; return TRUE; } sub xdo { my $self = shift; my $xdo = shift; my $source = shift; my $block_reverse = shift; my $do = undef; if ( $xdo eq 'undo' ) { $do = pop @{ $self->{_undo} }; } elsif ( $xdo eq 'redo' ) { $do = pop @{ $self->{_redo} }; } my $item = $do->{'item'}; my $action = $do->{'action'}; my $opt1 = $do->{'opt1'}; return FALSE unless $item; return FALSE unless $action; if ( $item->isa('Goo::Canvas::Image') && $item == $self->{_canvas_bg} ) { $opt1->x( $do->{'opt1'}->x * -1 ); $opt1->y( $do->{'opt1'}->y * -1 ); } #create reverse action my $reverse_action = 'modify'; if ( $action eq 'raise' ) { $reverse_action = 'lower_xdo'; } elsif ( $action eq 'raise_xdo' ) { $reverse_action = 'lower_xdo'; } elsif ( $action eq 'lower' ) { $reverse_action = 'raise_xdo'; } elsif ( $action eq 'lower_xdo' ) { $reverse_action = 'raise_xdo'; } elsif ( $action eq 'create' ) { $reverse_action = 'delete_xdo'; } elsif ( $action eq 'delete' ) { $reverse_action = 'create_xdo'; } elsif ( $action eq 'create_xdo' ) { $reverse_action = 'delete_xdo'; } elsif ( $action eq 'delete_xdo' ) { $reverse_action = 'create_xdo'; } #undo or redo? unless ($block_reverse) { if ( $xdo eq 'undo' ) { #store to redo stack $self->store_to_xdo_stack( $item, $reverse_action, 'redo', $opt1, $source ); } elsif ( $xdo eq 'redo' ) { #store to undo stack $self->store_to_xdo_stack( $item, $reverse_action, 'undo', $opt1, $source ); } } #finally undo the last event if ( $action eq 'modify' ) { if ( $item->isa('Goo::Canvas::Rect') && $item != $self->{_canvas_bg_rect} ) { $self->{_items}{$item}->set( 'x' => $do->{'x'}, 'y' => $do->{'y'}, 'width' => $do->{'width'}, 'height' => $do->{'height'}, ); if ( exists $self->{_items}{$item}{ellipse} ) { $self->{_items}{$item}{ellipse}->set( 'fill-pattern' => $do->{'fill-pattern'}, 'stroke-pattern' => $do->{'stroke-pattern'}, 'line-width' => $do->{'line-width'}, ); #numbered ellipse if ( exists $self->{_items}{$item}{text} ) { $self->{_items}{$item}{text}->set( 'text' => $do->{'text'}, 'fill-pattern' => $do->{'stroke-pattern'}, ); $self->{_items}{$item}{text}{digit} = $do->{'digit'}; } #restore color and opacity as well $self->{_items}{$item}{fill_color} = $do->{'fill_color'}; $self->{_items}{$item}{fill_color_alpha} = $do->{'fill_color_alpha'}; $self->{_items}{$item}{stroke_color} = $do->{'stroke_color'}; $self->{_items}{$item}{stroke_color_alpha} = $do->{'stroke_color_alpha'}; } elsif ( exists $self->{_items}{$item}{text} ) { $self->{_items}{$item}{text}->set( 'text' => $do->{'text'}, 'fill-pattern' => $do->{'stroke-pattern'}, ); #restore color and opacity as well $self->{_items}{$item}{stroke_color} = $do->{'stroke_color'}; $self->{_items}{$item}{stroke_color_alpha} = $do->{'stroke_color_alpha'}; } elsif ( exists $self->{_items}{$item}{pixelize} ) { $self->{_items}{$item}{pixelize}->set( 'x' => int $self->{_items}{$item}->get('x'), 'y' => int $self->{_items}{$item}->get('y'), 'width' => $self->{_items}{$item}->get('width'), 'height' => $self->{_items}{$item}->get('height'), 'pixbuf' => $self->get_pixelated_pixbuf_from_canvas( $self->{_items}{$item} ), ); } elsif ( exists $self->{_items}{$item}{image} ) { #~ print "xdo image\n"; my $copy = $self->{_lp}->load( $self->{_items}{$item}{orig_pixbuf_filename}, $self->{_items}{$item}->get('width'), $self->{_items}{$item}->get('height'), FALSE, TRUE ); if ($copy) { $self->{_items}{$item}{image}->set( 'x' => int $self->{_items}{$item}->get('x'), 'y' => int $self->{_items}{$item}->get('y'), 'width' => $self->{_items}{$item}->get('width'), 'height' => $self->{_items}{$item}->get('height'), 'pixbuf' => $copy ); } } elsif ( exists $self->{_items}{$item}{line} ) { #save arrow specific properties $self->{_items}{$item}{end_arrow} = $do->{'end-arrow'}; $self->{_items}{$item}{start_arrow} = $do->{'start-arrow'}; $self->{_items}{$item}{arrow_width} = $do->{'arrow-width'}; $self->{_items}{$item}{arrow_length} = $do->{'arrow-length'}; $self->{_items}{$item}{arrow_tip_length} = $do->{'arrow-tip-length'}; $self->{_items}{$item}{line}->set( 'fill-pattern' => $do->{'fill-pattern'}, 'stroke-pattern' => $do->{'stroke-pattern'}, 'line-width' => $do->{'line-width'}, 'end-arrow' => $self->{_items}{$item}{end_arrow}, 'start-arrow' => $self->{_items}{$item}{start_arrow}, 'arrow-length' => $self->{_items}{$item}{arrow_length}, 'arrow-width' => $self->{_items}{$item}{arrow_width}, 'arrow-tip-length' => $self->{_items}{$item}{arrow_tip_length}, ); $self->{_items}{$item}{mirrored_w} = $do->{'mirrored_w'} if exists $do->{'mirrored_w'}; $self->{_items}{$item}{mirrored_h} = $do->{'mirrored_h'} if exists $do->{'mirrored_h'}; #restore color and opacity as well $self->{_items}{$item}{stroke_color} = $do->{'stroke_color'}; $self->{_items}{$item}{stroke_color_alpha} = $do->{'stroke_color_alpha'}; } else { $self->{_items}{$item}->set( 'fill-pattern' => $do->{'fill-pattern'}, 'stroke-pattern' => $do->{'stroke-pattern'}, 'line-width' => $do->{'line-width'}, ); #restore color and opacity as well $self->{_items}{$item}{fill_color} = $do->{'fill_color'}; $self->{_items}{$item}{fill_color_alpha} = $do->{'fill_color_alpha'}; $self->{_items}{$item}{stroke_color} = $do->{'stroke_color'}; $self->{_items}{$item}{stroke_color_alpha} = $do->{'stroke_color_alpha'}; } } elsif ( $item->isa('Goo::Canvas::Image') && $item == $self->{_canvas_bg} ) { #~ print "xdo canvas_bg\n"; my $new_w = $do->{'drawing_pixbuf'}->get_width; my $new_h = $do->{'drawing_pixbuf'}->get_height; #update canvas and show the new pixbuf $self->{_canvas_bg}->set( 'pixbuf' => $do->{'drawing_pixbuf'} ); #save new pixbuf in var $self->{_drawing_pixbuf} = $do->{'drawing_pixbuf'}->copy; #update bounds and bg_rects $self->{_canvas_bg_rect}->set( 'x' => $do->{'x'}, 'y' => $do->{'y'}, 'width' => $do->{'width'}, 'height' => $do->{'height'}, ); #we need to move the shapes $self->move_all( $opt1->x, $opt1->y ); } elsif ( $item->isa('Goo::Canvas::Rect') && $item == $self->{_canvas_bg_rect} ) { #~ print "xdo canvas_bg_rect\n"; $self->{_canvas_bg_rect}->set( 'x' => $do->{'x'}, 'y' => $do->{'y'}, 'width' => $do->{'width'}, 'height' => $do->{'height'}, ); #polyline specific properties } elsif ( $item->isa('Goo::Canvas::Polyline') ) { #if pattern exists #e.g. censor tool does not have a pattern if ( $do->{'stroke-pattern'} ) { $self->{_items}{$item}->set( 'stroke-pattern' => $do->{'stroke-pattern'}, 'line-width' => $do->{'line-width'}, 'points' => $do->{'points'}, 'transform' => $do->{'transform'}, ); $self->{_items}{$item}{stroke_color} = $do->{'stroke_color'}; $self->{_items}{$item}{stroke_color_alpha} = $do->{'stroke_color_alpha'}; } else { $self->{_items}{$item}->set( 'line-width' => $do->{'line-width'}, 'points' => $do->{'points'}, 'transform' => $do->{'transform'}, ); } } #handle resize rectangles and embedded objects if ( $item == $self->{_canvas_bg} ) { $self->handle_bg_rects( 'update', $self->{_canvas_bg_rect} ); } elsif ( $item == $self->{_canvas_bg_rect} ) { $self->handle_bg_rects( 'update', $self->{_canvas_bg_rect} ); } else { $self->handle_rects( 'update', $self->{_items}{$item} ); $self->handle_embedded( 'update', $self->{_items}{$item}, undef, undef, TRUE ); #apply item properties to widgets #line width, fill color, stroke color etc. $self->set_and_save_drawing_properties( $self->{_current_item}, FALSE ); } #adjust stack order $self->{_canvas_bg}->lower; $self->{_canvas_bg_rect}->lower; $self->handle_bg_rects('raise'); } elsif ( $action eq 'raise' || $action eq 'raise_xdo' ) { my $child = $self->get_child_item($item); if ($child) { $self->handle_rects( 'lower', $item ); $child->lower; $item->lower; } else { $self->handle_rects( 'lower', $item ); $item->lower; } $self->{_canvas_bg}->lower; $self->{_canvas_bg_rect}->lower; } elsif ( $action eq 'lower' || $action eq 'lower_xdo' ) { my $child = $self->get_child_item($item); if ($child) { $child->raise; $item->raise; $self->handle_rects( 'raise', $item ); } else { $item->raise; $self->handle_rects( 'raise', $item ); } } elsif ( $action eq 'delete' || $action eq 'delete_xdo' ) { #mark as current $self->{_current_item} = $item; $self->{_current_new_item} = undef; $self->{_items}{$item}->set( 'visibility' => 'visible' ); $self->handle_rects( 'update', $self->{_items}{$item} ); $self->handle_embedded( 'update', $self->{_items}{$item}, undef, undef, TRUE ); } elsif ( $action eq 'create' || $action eq 'create_xdo' ) { $self->{_items}{$item}->set( 'visibility' => 'hidden' ); $self->handle_rects( 'hide', $self->{_items}{$item} ); $self->handle_embedded( 'hide', $self->{_items}{$item} ); } #disable undo/redo actions $self->{_uimanager}->get_widget("/MenuBar/Edit/Undo")->set_sensitive( scalar @{ $self->{_undo} } ) if defined $self->{_undo}; $self->{_uimanager}->get_widget("/MenuBar/Edit/Redo")->set_sensitive( scalar @{ $self->{_redo} } ) if defined $self->{_redo}; $self->{_uimanager}->get_widget("/ToolBar/Undo")->set_sensitive( scalar @{ $self->{_undo} } ) if defined $self->{_undo}; $self->{_uimanager}->get_widget("/ToolBar/Redo")->set_sensitive( scalar @{ $self->{_redo} } ) if defined $self->{_redo}; $self->deactivate_all; return TRUE; } sub set_and_save_drawing_properties { my $self = shift; my $item = shift; my $save_only = shift; return FALSE unless $item; #~ print "set_and_save_drawing_properties1\n"; #determine key for item hash if ( my $child = $self->get_child_item($item) ) { $item = $child; } my $parent = $self->get_parent_item($item); my $key = $self->get_item_key( $item, $parent ); return FALSE unless $key; #~ print "set_and_save_drawing_properties2\n"; #we do not remember the properties for some tools #and don't remember them when just selecting items with the cursor if ( $self->{_items}{$key}{type} ne "highlighter" && $self->{_items}{$key}{type} ne "censor" && $self->{_items}{$key}{type} ne "image" && $self->{_items}{$key}{type} ne "pixelize" && $self->{_current_mode} != 10 ) { #remember drawing colors, line width and font settings #maybe we have to restore them $self->{_last_fill_color} = $self->{_fill_color_w}->get_color; $self->{_last_fill_color_alpha} = $self->{_fill_color_w}->get_alpha / 65535; $self->{_last_stroke_color} = $self->{_stroke_color_w}->get_color; $self->{_last_stroke_color_alpha} = $self->{_stroke_color_w}->get_alpha / 65535; $self->{_last_line_width} = $self->{_line_spin_w}->get_value; $self->{_last_font} = $self->{_font_btn_w}->get_font_name; #remember the last mode as well $self->{_last_mode} = $self->{_current_mode}; } return TRUE if $save_only; #block 'value-change' handlers for widgets #so we do not apply the changes twice $self->{_line_spin_w}->signal_handler_block( $self->{_line_spin_wh} ); $self->{_stroke_color_w}->signal_handler_block( $self->{_stroke_color_wh} ); $self->{_fill_color_w}->signal_handler_block( $self->{_fill_color_wh} ); $self->{_font_btn_w}->signal_handler_block( $self->{_font_btn_wh} ); #~ print "set_and_save_drawing_properties3\n"; if ( $item->isa('Goo::Canvas::Rect') || $item->isa('Goo::Canvas::Ellipse') || $item->isa('Goo::Canvas::Polyline') ) { #line width $self->{_line_spin_w}->set_value( $item->get('line-width') ); #stroke color #some items, e.g. censor tool, do not have a color - skip them if ( $self->{_items}{$key}{stroke_color} ) { #~ print $self->{_items}{$key}{stroke_color}->to_string, "\n"; $self->{_stroke_color_w}->set_color( $self->{_items}{$key}{stroke_color} ); $self->{_stroke_color_w}->set_alpha( int( $self->{_items}{$key}{stroke_color_alpha} * 65535 ) ); } if ( $item->isa('Goo::Canvas::Rect') || $item->isa('Goo::Canvas::Ellipse') ) { #fill color $self->{_fill_color_w}->set_color( $self->{_items}{$key}{fill_color} ); $self->{_fill_color_w}->set_alpha( int( $self->{_items}{$key}{fill_color_alpha} * 65535 ) ); #numbered shapes if ( exists( $self->{_items}{$key}{text} ) ) { #determine font description from string my ( $attr_list, $text_raw, $accel_char ) = Gtk2::Pango->parse_markup( $self->{_items}{$key}{text}->get('text') ); my $font_desc = Gtk2::Pango::FontDescription->from_string( $self->{_font} ); #FIXME, maybe the pango version installed is too old eval { $attr_list->filter( sub { my $attr = shift; $font_desc = $attr->copy->desc if $attr->isa('Gtk2::Pango::AttrFontDesc'); return TRUE; }, ); }; if ($@) { print "\nERROR: Pango Markup could not be parsed:\n$@"; } #apply current font settings to button $self->{_font_btn_w}->set_font_name( $self->{_font} ); } } } elsif ( $item->isa('Goo::Canvas::Text') ) { #determine font description from string my ( $attr_list, $text_raw, $accel_char ) = Gtk2::Pango->parse_markup( $item->get('text') ); my $font_desc = Gtk2::Pango::FontDescription->from_string( $self->{_font} ); #FIXME, maybe the pango version installed is too old eval { $attr_list->filter( sub { my $attr = shift; $font_desc = $attr->copy->desc if $attr->isa('Gtk2::Pango::AttrFontDesc'); return TRUE; }, ); }; if ($@) { print "\nERROR: Pango Markup could not be parsed:\n$@"; } #font color $self->{_stroke_color_w}->set_color( $self->{_items}{$key}{stroke_color} ); $self->{_stroke_color_w}->set_alpha( int( $self->{_items}{$key}{stroke_color_alpha} * 65535 ) ); #apply current font settings to button $self->{_font_btn_w}->set_font_name( $self->{_font} ); } #update global values $self->{_line_width} = $self->{_line_spin_w}->get_value; $self->{_stroke_color} = $self->{_stroke_color_w}->get_color; $self->{_stroke_color_alpha} = $self->{_stroke_color_w}->get_alpha / 65535; $self->{_fill_color} = $self->{_fill_color_w}->get_color; $self->{_fill_color_alpha} = $self->{_fill_color_w}->get_alpha / 65636; my $font_descr = Gtk2::Pango::FontDescription->from_string( $self->{_font_btn_w}->get_font_name ); $self->{_font} = $self->{_font_btn_w}->get_font_name; #unblock 'value-change' handlers for widgets $self->{_line_spin_w}->signal_handler_unblock( $self->{_line_spin_wh} ); $self->{_stroke_color_w}->signal_handler_unblock( $self->{_stroke_color_wh} ); $self->{_fill_color_w}->signal_handler_unblock( $self->{_fill_color_wh} ); $self->{_font_btn_w}->signal_handler_unblock( $self->{_font_btn_wh} ); } sub restore_fixed_properties { my $self = shift; my $mode = shift; #~ print "restore_highlighter_properties\n"; #block 'value-change' handlers for widgets #so we do not apply the changes twice $self->{_line_spin_w}->signal_handler_block( $self->{_line_spin_wh} ); $self->{_stroke_color_w}->signal_handler_block( $self->{_stroke_color_wh} ); $self->{_fill_color_w}->signal_handler_block( $self->{_fill_color_wh} ); $self->{_font_btn_w}->signal_handler_block( $self->{_font_btn_wh} ); if ( $mode eq "highlighter" ) { #highlighter $self->{_fill_color_w}->set_color( Gtk2::Gdk::Color->parse('#00000000ffff') ); $self->{_fill_color_w}->set_alpha( int( 0.234683756771191 * 65535 ) ); $self->{_stroke_color_w}->set_color( Gtk2::Gdk::Color->parse('#ffffffff0000') ); $self->{_stroke_color_w}->set_alpha( int( 0.499992370489052 * 65535 ) ); $self->{_line_spin_w}->set_value(18); } elsif ( $mode eq "censor" ) { #censor $self->{_line_spin_w}->set_value(14); } #update global values $self->{_line_width} = $self->{_line_spin_w}->get_value; $self->{_stroke_color} = $self->{_stroke_color_w}->get_color; $self->{_stroke_color_alpha} = $self->{_stroke_color_w}->get_alpha / 65535; $self->{_fill_color} = $self->{_fill_color_w}->get_color; $self->{_fill_color_alpha} = $self->{_fill_color_w}->get_alpha / 65636; #unblock 'value-change' handlers for widgets $self->{_line_spin_w}->signal_handler_unblock( $self->{_line_spin_wh} ); $self->{_stroke_color_w}->signal_handler_unblock( $self->{_stroke_color_wh} ); $self->{_fill_color_w}->signal_handler_unblock( $self->{_fill_color_wh} ); $self->{_font_btn_w}->signal_handler_unblock( $self->{_font_btn_wh} ); } sub restore_drawing_properties { my $self = shift; #saved properties available? return FALSE unless defined $self->{_last_fill_color}; #anything done until now? return FALSE unless defined $self->{_last_mode}; #~ print "restore_drawing_properties\n"; #block 'value-change' handlers for widgets #so we do not apply the changes twice $self->{_line_spin_w}->signal_handler_block( $self->{_line_spin_wh} ); $self->{_stroke_color_w}->signal_handler_block( $self->{_stroke_color_wh} ); $self->{_fill_color_w}->signal_handler_block( $self->{_fill_color_wh} ); $self->{_font_btn_w}->signal_handler_block( $self->{_font_btn_wh} ); #restore them $self->{_fill_color_w}->set_color( $self->{_last_fill_color} ); $self->{_fill_color_w}->set_alpha( int( $self->{_last_fill_color_alpha} * 65535 ) ); $self->{_stroke_color_w}->set_color( $self->{_last_stroke_color} ); $self->{_stroke_color_w}->set_alpha( int( $self->{_last_stroke_color_alpha} * 65535 ) ); $self->{_line_spin_w}->set_value( $self->{_last_line_width} ); $self->{_font_btn_w}->set_font_name( $self->{_last_font} ); #update global values $self->{_line_width} = $self->{_line_spin_w}->get_value; $self->{_stroke_color} = $self->{_stroke_color_w}->get_color; $self->{_stroke_color_alpha} = $self->{_stroke_color_w}->get_alpha / 65535; $self->{_fill_color} = $self->{_fill_color_w}->get_color; $self->{_fill_color_alpha} = $self->{_fill_color_w}->get_alpha / 65636; my $font_descr = Gtk2::Pango::FontDescription->from_string( $self->{_font_btn_w}->get_font_name ); $self->{_font} = $self->{_font_btn_w}->get_font_name; #unblock 'value-change' handlers for widgets $self->{_line_spin_w}->signal_handler_unblock( $self->{_line_spin_wh} ); $self->{_stroke_color_w}->signal_handler_unblock( $self->{_stroke_color_wh} ); $self->{_fill_color_w}->signal_handler_unblock( $self->{_fill_color_wh} ); $self->{_font_btn_w}->signal_handler_unblock( $self->{_font_btn_wh} ); } sub event_item_on_key_press { my ( $self, $item, $target, $ev ) = @_; if ( $self->{_current_item} ) { #current item my $curr_item = $self->{_current_item}; if ( exists $self->{_items}{$curr_item} ) { #construct an motion-notify event my $mevent = Gtk2::Gdk::Event->new('motion-notify'); $mevent->set_state('button2-mask'); $mevent->set_time( Gtk2->get_current_event_time ); $mevent->window( $self->{_drawing_window}->window ); #get current x, y values my $old_x = $self->{_items}{$curr_item}->get('x'); my $old_y = $self->{_items}{$curr_item}->get('y'); #set item flags $curr_item->{drag_x} = $old_x; $curr_item->{drag_y} = $old_y; $curr_item->{dragging} = TRUE; $curr_item->{dragging_start} = TRUE; #move with arrow keys if ( $ev->keyval == Gtk2::Gdk->keyval_from_name('Up') ) { #~ print $ev->keyval," $old_x,$old_y-up\n"; $mevent->x($old_x); $mevent->y( $old_y - 1 ); } elsif ( $ev->keyval == Gtk2::Gdk->keyval_from_name('Down') ) { #~ print $ev->keyval," $old_x,$old_y-down\n"; $mevent->x($old_x); $mevent->y( $old_y + 1 ); } elsif ( $ev->keyval == Gtk2::Gdk->keyval_from_name('Left') ) { #~ print $ev->keyval," $old_x,$old_y-left\n"; $mevent->x( $old_x - 1 ); $mevent->y($old_y); } elsif ( $ev->keyval == Gtk2::Gdk->keyval_from_name('Right') ) { #~ print $ev->keyval," $old_x,$old_y-right\n"; $mevent->x( $old_x + 1 ); $mevent->y($old_y); } else { return FALSE; } #finally call motion-notify handler $self->event_item_on_motion_notify( $curr_item, $target, $mevent ); } } return TRUE; } sub event_item_on_button_press { my ( $self, $item, $target, $ev, $select ) = @_; #~ print "button-press\n"; #canvas is busy now... $self->{_busy} = TRUE; my $cursor = Gtk2::Gdk::Cursor->new('left-ptr'); #activate item #if it is not activated yet # => single click if ( $ev->type eq 'button-press' && ( $self->{_current_mode_descr} eq "select" || $select || $ev->button == 2 || $ev->button == 3 ) ) { #embedded item? my $parent = $self->get_parent_item($item); $item = $parent if $parent; #real shape if ( exists $self->{_items}{$item} ) { unless ( defined $self->{_current_item} && $item == $self->{_current_item} ) { unless ( $self->{_current_mode_descr} eq "number" || $self->{_current_mode_descr} eq "text" ) { unless ( $self->{_items}{$item}{locked} ) { #deactivate last item my $last_item = $self->{_current_item}; if ( defined $last_item ) { #~ print "deactivated item: $last_item\n"; $self->{_canvas}->pointer_ungrab( $last_item, $ev->time ); $self->{_canvas}->keyboard_ungrab( $last_item, $ev->time ); $self->handle_rects( 'hide', $last_item ); } #mark as active item $self->{_current_item} = $item; $self->{_current_new_item} = undef; $self->handle_rects( 'update', $self->{_current_item} ); #apply item properties to widgets #line width, fill color, stroke color etc. $self->set_and_save_drawing_properties( $self->{_current_item}, FALSE ); #~ print "activated item: $item\n"; } else { $self->deactivate_all; #~ print "deactivate because $item is locked\n"; } } else { $self->deactivate_all( $self->{_current_item} ); #~ print "deactivate because $item is text or number\n"; } } else { #~ print "no activate because $item is already current item\n"; } #no item selected, deactivate all items } elsif ( $item == $self->{_canvas_bg_rect} ) { $self->deactivate_all; #~ print "deactivate because $item is background rectangle\n"; } else { #~ print "no activate because $item does not exist\n"; } } else { #~ print "no activate action\n"; } #left mouse click to drag, resize, create or delelte items if ( $ev->type eq 'button-press' && ( $ev->button == 1 || $ev->button == 2 ) ) { #MOVE if ( $self->{_current_mode_descr} eq "select" || $ev->button == 2 ) { #don't_move the bounding rectangle or the bg_image return TRUE if $item == $self->{_canvas_bg_rect}; #don't move locked item return TRUE if ( exists $self->{_items}{$item} && $self->{_items}{$item}{locked} ); if ( $item->isa('Goo::Canvas::Rect') ) { #real shape => move if ( exists $self->{_items}{$item} ) { $item->{drag_x} = $ev->x; $item->{drag_y} = $ev->y; $item->{dragging} = TRUE; $item->{dragging_start} = TRUE; $cursor = Gtk2::Gdk::Cursor->new('fleur'); #resizing shape => resize } else { $item->{res_x} = $ev->x; $item->{res_y} = $ev->y; $item->{resizing} = TRUE; $cursor = undef; #resizing the canvas_bg_rect if ( $self->{_canvas_bg_rect}{'right-side'} == $item || $self->{_canvas_bg_rect}{'bottom-side'} == $item || $self->{_canvas_bg_rect}{'bottom-right-corner'} == $item ) { #add to undo stack $self->store_to_xdo_stack( $self->{_canvas_bg_rect}, 'modify', 'undo' ); #other resizing rectangles } else { #add to undo stack $self->store_to_xdo_stack( $self->{_current_item}, 'modify', 'undo' ); } #restore style pattern my $pattern = $self->create_color( $self->{_style_bg}, 1 ); $item->set( 'fill-pattern' => $pattern ); } #no rectangle, e.g. polyline } else { #no rect, just move it ... $item->{drag_x} = $ev->x; $item->{drag_y} = $ev->y; $item->{dragging} = TRUE; $item->{dragging_start} = TRUE; #add to undo stack #~ $self->store_to_xdo_stack($self->{_current_item} , 'modify', 'undo'); $cursor = undef; } #~ print "grab keyboard and pointer focus for $item\n"; #grab keyboard and pointer focus $self->{_canvas}->pointer_grab( $item, [ 'pointer-motion-mask', 'button-release-mask' ], $cursor, $ev->time ); $self->{_canvas}->grab_focus($item); #current mode not equal 'select' and no polyline } elsif ( $ev->button == 1 ) { #resizing shape => resize (no real shape) #no polyline modes if ( $item->isa('Goo::Canvas::Rect') && !exists $self->{_items}{$item} && $item != $self->{_canvas_bg_rect} && $self->{_current_mode_descr} ne "freehand" && $self->{_current_mode_descr} ne "highlighter" && $self->{_current_mode_descr} ne "censor" ) { $item->{res_x} = $ev->x; $item->{res_y} = $ev->y; $item->{resizing} = TRUE; $cursor = undef; #resizing the canvas_bg_rect if ( $self->{_canvas_bg_rect}{'right-side'} == $item || $self->{_canvas_bg_rect}{'bottom-side'} == $item || $self->{_canvas_bg_rect}{'bottom-right-corner'} == $item ) { #add to undo stack $self->store_to_xdo_stack( $self->{_canvas_bg_rect}, 'modify', 'undo' ); #other resizing rectangles } else { #add to undo stack $self->store_to_xdo_stack( $self->{_current_item}, 'modify', 'undo' ); } #restore style pattern my $pattern = $self->create_color( $self->{_style_bg}, 1 ); $item->set( 'fill-pattern' => $pattern ); #~ print "grab keyboard and pointer focus for $item\n"; #grab keyboard and pointer focus $self->{_canvas}->pointer_grab( $item, [ 'pointer-motion-mask', 'button-release-mask' ], $cursor, $ev->time ); $self->{_canvas}->grab_focus($item); #create new item } else { #freehand if ( $self->{_current_mode_descr} eq "freehand" ) { $self->deactivate_all; $self->create_polyline( $ev, undef, FALSE ); #highlighter } elsif ( $self->{_current_mode_descr} eq "highlighter" ) { $self->deactivate_all; $self->create_polyline( $ev, undef, TRUE ); #Line } elsif ( $self->{_current_mode_descr} eq "line" ) { $self->create_line( $ev, undef ); #Arrow } elsif ( $self->{_current_mode_descr} eq "arrow" ) { $self->create_line( $ev, undef, TRUE, FALSE ); #Censor } elsif ( $self->{_current_mode_descr} eq "censor" ) { $self->deactivate_all; $self->create_censor( $ev, undef ); #Number } elsif ( $self->{_current_mode_descr} eq "number" ) { $self->create_ellipse( $ev, undef, TRUE ); #RECTANGLES } elsif ( $self->{_current_mode_descr} eq "rect" ) { $self->create_rectangle( $ev, undef ); #ELLIPSE } elsif ( $self->{_current_mode_descr} eq "ellipse" ) { $self->create_ellipse( $ev, undef ); #TEXT } elsif ( $self->{_current_mode_descr} eq "text" ) { $self->create_text( $ev, undef ); #IMAGE } elsif ( $self->{_current_mode_descr} eq "image" ) { $self->create_image( $ev, undef ); #PIXELIZE } elsif ( $self->{_current_mode_descr} eq "pixelize" ) { $self->create_pixel_image( $ev, undef ); } #grab keyboard focus if ( my $nitem = $self->{_current_new_item} ) { #~ print "grab keyboard focus for new item $nitem\n"; $self->{_canvas}->grab_focus($nitem); } } } #right click => show context menu, double-click => show properties directly } elsif ( $ev->type eq '2button-press' || $ev->button == 3 ) { $self->{_canvas}->pointer_ungrab( $item, $ev->time ); $self->{_canvas}->keyboard_ungrab( $item, $ev->time ); #determine key for item hash if ( my $child = $self->get_child_item($item) ) { $item = $child; } my $parent = $self->get_parent_item($item); my $key = $self->get_item_key( $item, $parent ); #real shape if ( defined $key && exists $self->{_items}{$key} ) { if ( $ev->type eq '2button-press' && $ev->button == 1 && $self->{_current_mode_descr} ne "text" && $self->{_current_mode_descr} ne "number" && $self->{_current_mode_descr} ne "freehand" && $self->{_current_mode_descr} ne "highlighter" && $self->{_current_mode_descr} ne "censor" ) { #some items do not have properties, e.g. images or censor return FALSE if $item->isa('Goo::Canvas::Image') || !exists( $self->{_items}{$key}{stroke_color} ); #~ print $item, $parent, $key, "\n"; $self->show_item_properties( $item, $parent, $key ); } elsif ( $ev->type eq 'button-press' && $ev->button == 3 ) { my $item_menu = $self->ret_item_menu( $item, $parent, $key ); $item_menu->popup( undef, # parent menu shell undef, # parent menu item undef, # menu pos func undef, # data $ev->button, $ev->time ); } } else { #background rectangle if ( $item == $self->{_canvas_bg_rect} ) { my $bg_menu = $self->ret_background_menu($item); $bg_menu->popup( undef, # parent menu shell undef, # parent menu item undef, # menu pos func undef, # data $ev->button, $ev->time ); } } #canvas idle now $self->{_busy} = FALSE; } return TRUE; } sub ret_background_menu { my $self = shift; my $item = shift; my $menu_bg = Gtk2::Menu->new; #properties my $prop_item = Gtk2::ImageMenuItem->new( $self->{_d}->get("Change Background Color...") ); $prop_item->set_image( Gtk2::Image->new_from_stock( 'gtk-select-color', 'menu' ) ); $prop_item->signal_connect( 'activate' => sub { my $color_dialog = Gtk2::ColorSelectionDialog->new( $self->{_d}->get("Choose fill color") ); #remove help button $color_dialog->help_button->destroy; #add reset button my $reset_btn = Gtk2::Button->new_with_mnemonic( $self->{_d}->get("_Reset to Default") ); $color_dialog->add_action_widget( $reset_btn, 'reject' ); my $col_sel = $color_dialog->colorsel; $col_sel->set_current_color( $self->{_canvas_bg_rect}{fill_color} ); $col_sel->set_current_alpha(65535); $color_dialog->show_all; #run dialog my $response = 'reject'; while ( $response eq 'reject' ) { $response = $color_dialog->run; if ( $response eq 'ok' ) { #apply new color my $new_fill_pattern = $self->create_color( $col_sel->get_current_color, 1.0 ); $self->{_canvas_bg_rect}->set( 'fill-pattern' => $new_fill_pattern ); $self->{_canvas_bg_rect}{fill_color} = $col_sel->get_current_color; last; } elsif ( $response eq 'reject' ) { $col_sel->set_current_color( Gtk2::Gdk::Color->parse('gray') ); $col_sel->set_current_alpha(65535); } else { last; } } $color_dialog->destroy; } ); $menu_bg->append($prop_item); $menu_bg->show_all; return $menu_bg; } sub ret_item_menu { my $self = shift; my $item = shift; my $parent = shift; my $key = shift; #~ print "ret_item_menu\n"; my $menu_item = Gtk2::Menu->new; #raise my $raise_item = Gtk2::ImageMenuItem->new( $self->{_d}->get("Raise") ); $raise_item->set_image( Gtk2::Image->new_from_pixbuf( Gtk2::Gdk::Pixbuf->new_from_file_at_size( $self->{_dicons} . '/draw-raise.png', Gtk2::IconSize->lookup('menu') ) ) ); $raise_item->signal_connect( 'activate' => sub { if ($parent) { #add to undo stack $self->store_to_xdo_stack( $parent, 'raise', 'undo' ); $parent->raise; $item->raise; $self->handle_rects( 'raise', $parent ); } else { #add to undo stack $self->store_to_xdo_stack( $item, 'raise', 'undo' ); $item->raise; $self->handle_rects( 'raise', $item ); } } ); $menu_item->append($raise_item); #lower my $lower_item = Gtk2::ImageMenuItem->new( $self->{_d}->get("Lower") ); $lower_item->set_image( Gtk2::Image->new_from_pixbuf( Gtk2::Gdk::Pixbuf->new_from_file_at_size( $self->{_dicons} . '/draw-lower.png', Gtk2::IconSize->lookup('menu') ) ) ); $lower_item->signal_connect( 'activate' => sub { if ($parent) { #add to undo stack $self->store_to_xdo_stack( $parent, 'lower', 'undo' ); $self->handle_rects( 'lower', $parent ); $item->lower; $parent->lower; } else { #add to undo stack $self->store_to_xdo_stack( $item, 'lower', 'undo' ); $self->handle_rects( 'lower', $item ); $item->lower; } $self->{_canvas_bg}->lower; $self->{_canvas_bg_rect}->lower; } ); $menu_item->append($lower_item); $menu_item->append( Gtk2::SeparatorMenuItem->new ); #copy item my $copy_item = Gtk2::ImageMenuItem->new_from_stock('gtk-copy'); $copy_item->signal_connect( 'activate' => sub { #clear clipboard $self->{_clipboard}->set_text(""); $self->{_cut} = FALSE; $self->{_current_copy_item} = $self->{_current_item}; } ); $menu_item->append($copy_item); #cut item my $cut_item = Gtk2::ImageMenuItem->new_from_stock('gtk-cut'); $cut_item->signal_connect( 'activate' => sub { #clear clipboard $self->{_clipboard}->set_text(""); $self->{_cut} = TRUE; $self->{_current_copy_item} = $self->{_current_item}; $self->clear_item_from_canvas( $self->{_current_copy_item} ); } ); $menu_item->append($cut_item); #paste item my $paste_item = Gtk2::ImageMenuItem->new_from_stock('gtk-paste'); $paste_item->signal_connect( 'activate' => sub { $self->paste_item( $self->{_current_copy_item}, $self->{_cut} ); $self->{_cut} = FALSE; } ); $menu_item->append($paste_item); #delete item my $remove_item = Gtk2::ImageMenuItem->new_from_stock('gtk-delete'); $remove_item->signal_connect( 'activate' => sub { $self->clear_item_from_canvas($item); } ); $menu_item->append($remove_item); $menu_item->append( Gtk2::SeparatorMenuItem->new ); #add lock/unlock entry if item == background image if ( $item == $self->{_canvas_bg} ) { my $lock_item = undef; if ( exists $self->{_items}{$key} && $self->{_items}{$key}{locked} == TRUE ) { $lock_item = Gtk2::ImageMenuItem->new_with_label( $self->{_d}->get("Unlock") ); $lock_item->set_image( Gtk2::Image->new_from_pixbuf( Gtk2::Gdk::Pixbuf->new_from_file_at_size( $self->{_dicons} . '/draw-unlocked.png', Gtk2::IconSize->lookup('menu') ) ) ); } elsif ( exists $self->{_items}{$key} && $self->{_items}{$key}{locked} == FALSE ) { $lock_item = Gtk2::ImageMenuItem->new_with_label( $self->{_d}->get("Lock") ); $lock_item->set_image( Gtk2::Image->new_from_pixbuf( Gtk2::Gdk::Pixbuf->new_from_file_at_size( $self->{_dicons} . '/draw-locked.png', Gtk2::IconSize->lookup('menu') ) ) ); } #handler $lock_item->signal_connect( 'activate' => sub { if ( exists $self->{_items}{$key} && $self->{_items}{$key}{locked} == FALSE ) { $self->{_items}{$key}{locked} = TRUE; $self->deactivate_all; } elsif ( exists $self->{_items}{$key} && $self->{_items}{$key}{locked} == TRUE ) { $self->{_items}{$key}{locked} = FALSE; } } ); $menu_item->append($lock_item); $menu_item->append( Gtk2::SeparatorMenuItem->new ); } #properties my $prop_item = Gtk2::ImageMenuItem->new( $self->{_d}->get("Edit Preferences...") ); $prop_item->set_image( Gtk2::Image->new_from_stock( 'gtk-properties', 'menu' ) ); #some items do not have properties, e.g. images or censor $prop_item->set_sensitive(FALSE) if $item->isa('Goo::Canvas::Image') || !exists( $self->{_items}{$key}{stroke_color} ); $prop_item->signal_connect( 'activate' => sub { $self->show_item_properties( $item, $parent, $key ); } ); $menu_item->append($prop_item); $menu_item->show_all; return $menu_item; } sub get_item_key { my ( $self, $item, $parent ) = @_; if ( exists $self->{_items}{$item} ) { return $item; } else { return $parent; } } sub show_item_properties { my ( $self, $item, $parent, $key ) = @_; #~ print "show_item_properties\n"; #create dialog my $prop_dialog = Gtk2::Dialog->new( $self->{_d}->get("Preferences"), $self->{_drawing_window}, [qw/modal destroy-with-parent/], 'gtk-cancel' => 'cancel', 'gtk-ok' => 'ok' ); $prop_dialog->set_default_response('ok'); #RECT OR ELLIPSE OR POLYLINE my $line_spin = undef; my $fill_color = undef; my $stroke_color = undef; #NUMBERED ELLIPSE my $number_spin = undef; #ARROW my $end_arrow = undef; my $start_arrow = undef; my $arrow_spin = undef; my $arrowl_spin = undef; my $arrowt_spin = undef; #TEXT my $font_btn; my $text; my $textview; my $font_color; #RECT OR ELLIPSE OR NUMBER OR POLYLINE #GENERAL SETTINGS if ( $item->isa('Goo::Canvas::Rect') || $item->isa('Goo::Canvas::Ellipse') || $item->isa('Goo::Canvas::Polyline') || ( $item->isa('Goo::Canvas::Text') && defined $self->{_items}{$key}{ellipse} ) ) { my $general_vbox = Gtk2::VBox->new( FALSE, 5 ); my $label_general = Gtk2::Label->new; $label_general->set_markup( "" . $self->{_d}->get("Main") . "" ); my $frame_general = Gtk2::Frame->new(); $frame_general->set_label_widget($label_general); $frame_general->set_shadow_type('none'); $frame_general->set_border_width(5); $prop_dialog->vbox->add($frame_general); #line_width my $line_hbox = Gtk2::HBox->new( FALSE, 5 ); $line_hbox->set_border_width(5); my $linew_label = Gtk2::Label->new( $self->{_d}->get("Line width") . ":" ); $line_spin = Gtk2::SpinButton->new_with_range( 0.5, 20, 0.1 ); $line_spin->set_value( $item->get('line-width') ); $line_hbox->pack_start( $linew_label, FALSE, TRUE, 12 ); $line_hbox->pack_start( $line_spin, TRUE, TRUE, 0 ); $general_vbox->pack_start( $line_hbox, FALSE, FALSE, 0 ); if ( $item->isa('Goo::Canvas::Rect') || $item->isa('Goo::Canvas::Ellipse') ) { #fill color my $fill_color_hbox = Gtk2::HBox->new( FALSE, 5 ); $fill_color_hbox->set_border_width(5); my $fill_color_label = Gtk2::Label->new( $self->{_d}->get("Fill color") . ":" ); $fill_color = Gtk2::ColorButton->new(); $fill_color->set_color( $self->{_items}{$key}{fill_color} ); $fill_color->set_alpha( int( $self->{_items}{$key}{fill_color_alpha} * 65535 ) ); $fill_color->set_use_alpha(TRUE); $fill_color->set_title( $self->{_d}->get("Choose fill color") ); $fill_color_hbox->pack_start( $fill_color_label, FALSE, TRUE, 12 ); $fill_color_hbox->pack_start( $fill_color, TRUE, TRUE, 0 ); $general_vbox->pack_start( $fill_color_hbox, FALSE, FALSE, 0 ); } #some items, e.g. censor tool, do not have a color - skip them if ( $self->{_items}{$key}{stroke_color} ) { #stroke color my $stroke_color_hbox = Gtk2::HBox->new( FALSE, 5 ); $stroke_color_hbox->set_border_width(5); my $stroke_color_label = Gtk2::Label->new( $self->{_d}->get("Stroke color") . ":" ); $stroke_color = Gtk2::ColorButton->new(); $stroke_color->set_color( $self->{_items}{$key}{stroke_color} ); $stroke_color->set_alpha( int( $self->{_items}{$key}{stroke_color_alpha} * 65535 ) ); $stroke_color->set_use_alpha(TRUE); $stroke_color->set_title( $self->{_d}->get("Choose stroke color") ); $stroke_color_hbox->pack_start( $stroke_color_label, FALSE, TRUE, 12 ); $stroke_color_hbox->pack_start( $stroke_color, TRUE, TRUE, 0 ); $general_vbox->pack_start( $stroke_color_hbox, FALSE, FALSE, 0 ); } $frame_general->add($general_vbox); #special shapes like numbered ellipse if ( defined $self->{_items}{$key}{text} ) { my $numbered_vbox = Gtk2::VBox->new( FALSE, 5 ); my $label_numbered = Gtk2::Label->new; $label_numbered->set_markup( "" . $self->{_d}->get("Numbering") . "" ); my $frame_numbered = Gtk2::Frame->new(); $frame_numbered->set_label_widget($label_numbered); $frame_numbered->set_shadow_type('none'); $frame_numbered->set_border_width(5); $prop_dialog->vbox->add($frame_numbered); #current digit my $number_hbox = Gtk2::HBox->new( FALSE, 5 ); $number_hbox->set_border_width(5); my $numberw_label = Gtk2::Label->new( $self->{_d}->get("Current value") . ":" ); $number_spin = Gtk2::SpinButton->new_with_range( 0, 999, 1 ); $number_spin->set_value( $self->{_items}{$key}{text}{digit} ); $number_hbox->pack_start( $numberw_label, FALSE, TRUE, 12 ); $number_hbox->pack_start( $number_spin, TRUE, TRUE, 0 ); $numbered_vbox->pack_start( $number_hbox, FALSE, FALSE, 0 ); #font button my $font_hbox = Gtk2::HBox->new( FALSE, 5 ); $font_hbox->set_border_width(5); my $font_label = Gtk2::Label->new( $self->{_d}->get("Font") . ":" ); $font_btn = Gtk2::FontButton->new(); #determine font description from string my ( $attr_list, $text_raw, $accel_char ) = Gtk2::Pango->parse_markup( $self->{_items}{$key}{text}->get('text') ); my $font_desc = Gtk2::Pango::FontDescription->from_string( $self->{_font} ); #FIXME, maybe the pango version installed is too old eval { $attr_list->filter( sub { my $attr = shift; $font_desc = $attr->copy->desc if $attr->isa('Gtk2::Pango::AttrFontDesc'); return TRUE; }, ); }; if ($@) { print "\nERROR: Pango Markup could not be parsed:\n$@"; } #apply current font settings to button $font_btn->set_font_name( $self->{_font} ); $font_hbox->pack_start( $font_label, FALSE, TRUE, 12 ); $font_hbox->pack_start( $font_btn, TRUE, TRUE, 0 ); $numbered_vbox->pack_start( $font_hbox, FALSE, FALSE, 0 ); $frame_numbered->add($numbered_vbox); } } #ARROW item if ( $item->isa('Goo::Canvas::Polyline') && defined $self->{_items}{$key}{end_arrow} && defined $self->{_items}{$key}{start_arrow} ) { my $arrow_vbox = Gtk2::VBox->new( FALSE, 5 ); my $label_arrow = Gtk2::Label->new; $label_arrow->set_markup( "" . $self->{_d}->get("Arrow") . "" ); my $frame_arrow = Gtk2::Frame->new(); $frame_arrow->set_label_widget($label_arrow); $frame_arrow->set_shadow_type('none'); $frame_arrow->set_border_width(5); $prop_dialog->vbox->add($frame_arrow); #arrow_width my $arrow_hbox = Gtk2::HBox->new( FALSE, 5 ); $arrow_hbox->set_border_width(5); my $arroww_label = Gtk2::Label->new( $self->{_d}->get("Width") . ":" ); $arrow_spin = Gtk2::SpinButton->new_with_range( 0.5, 10, 0.1 ); $arrow_spin->set_value( $item->get('arrow-width') ); $arrow_hbox->pack_start( $arroww_label, FALSE, TRUE, 12 ); $arrow_hbox->pack_start( $arrow_spin, TRUE, TRUE, 0 ); $arrow_vbox->pack_start( $arrow_hbox, FALSE, FALSE, 0 ); #arrow_length my $arrowl_hbox = Gtk2::HBox->new( FALSE, 5 ); $arrowl_hbox->set_border_width(5); my $arrowl_label = Gtk2::Label->new( $self->{_d}->get("Length") . ":" ); $arrowl_spin = Gtk2::SpinButton->new_with_range( 0.5, 10, 0.1 ); $arrowl_spin->set_value( $item->get('arrow-length') ); $arrowl_hbox->pack_start( $arrowl_label, FALSE, TRUE, 12 ); $arrowl_hbox->pack_start( $arrowl_spin, TRUE, TRUE, 0 ); $arrow_vbox->pack_start( $arrowl_hbox, FALSE, FALSE, 0 ); #arrow_tip_length my $arrowt_hbox = Gtk2::HBox->new( FALSE, 5 ); $arrowt_hbox->set_border_width(5); my $arrowt_label = Gtk2::Label->new( $self->{_d}->get("Tip length") . ":" ); $arrowt_spin = Gtk2::SpinButton->new_with_range( 0.5, 10, 0.1 ); $arrowt_spin->set_value( $item->get('arrow-tip-length') ); $arrowt_hbox->pack_start( $arrowt_label, FALSE, TRUE, 12 ); $arrowt_hbox->pack_start( $arrowt_spin, TRUE, TRUE, 0 ); $arrow_vbox->pack_start( $arrowt_hbox, FALSE, FALSE, 0 ); #checkboxes for start and end arrows $end_arrow = Gtk2::CheckButton->new( $self->{_d}->get("Display an arrow at the end of the line") ); $end_arrow->set_active( $self->{_items}{$key}{end_arrow} ); $start_arrow = Gtk2::CheckButton->new( $self->{_d}->get("Display an arrow at the start of the line") ); $start_arrow->set_active( $self->{_items}{$key}{start_arrow} ); my $end_arrow_hbox = Gtk2::HBox->new( FALSE, 5 ); $end_arrow_hbox->set_border_width(5); my $start_arrow_hbox = Gtk2::HBox->new( FALSE, 5 ); $start_arrow_hbox->set_border_width(5); $end_arrow_hbox->pack_start( $end_arrow, FALSE, TRUE, 12 ); $start_arrow_hbox->pack_start( $start_arrow, FALSE, TRUE, 12 ); $arrow_vbox->pack_start( $start_arrow_hbox, FALSE, FALSE, 0 ); $arrow_vbox->pack_start( $end_arrow_hbox, FALSE, FALSE, 0 ); #final packing $frame_arrow->add($arrow_vbox); #simple TEXT item (no numbered ellipse) } elsif ( $item->isa('Goo::Canvas::Text') && !defined $self->{_items}{$key}{ellipse} ) { my $text_vbox = Gtk2::VBox->new( FALSE, 5 ); my $label_text = Gtk2::Label->new; $label_text->set_markup( "" . $self->{_d}->get("Text") . "" ); my $frame_text = Gtk2::Frame->new(); $frame_text->set_label_widget($label_text); $frame_text->set_shadow_type('none'); $frame_text->set_border_width(5); $prop_dialog->vbox->add($frame_text); #font button my $font_hbox = Gtk2::HBox->new( FALSE, 5 ); $font_hbox->set_border_width(5); my $font_label = Gtk2::Label->new( $self->{_d}->get("Font") . ":" ); $font_btn = Gtk2::FontButton->new(); #determine font description from string my ( $attr_list, $text_raw, $accel_char ) = Gtk2::Pango->parse_markup( $item->get('text') ); my $font_desc = Gtk2::Pango::FontDescription->from_string( $self->{_font} ); #FIXME, maybe the pango version installed is too old eval { $attr_list->filter( sub { my $attr = shift; $font_desc = $attr->copy->desc if $attr->isa('Gtk2::Pango::AttrFontDesc'); return TRUE; }, ); }; if ($@) { print "\nERROR: Pango Markup could not be parsed:\n$@"; } $font_hbox->pack_start( $font_label, FALSE, TRUE, 12 ); $font_hbox->pack_start( $font_btn, TRUE, TRUE, 0 ); $text_vbox->pack_start( $font_hbox, FALSE, FALSE, 0 ); #font color my $font_color_hbox = Gtk2::HBox->new( FALSE, 5 ); $font_color_hbox->set_border_width(5); my $font_color_label = Gtk2::Label->new( $self->{_d}->get("Font color") . ":" ); $font_color = Gtk2::ColorButton->new(); $font_color->set_use_alpha(TRUE); $font_color->set_alpha( int( $self->{_items}{$key}{stroke_color_alpha} * 65535 ) ); $font_color->set_color( $self->{_items}{$key}{stroke_color} ); $font_color->set_title( $self->{_d}->get("Choose font color") ); $font_color_hbox->pack_start( $font_color_label, FALSE, TRUE, 12 ); $font_color_hbox->pack_start( $font_color, TRUE, TRUE, 0 ); $text_vbox->pack_start( $font_color_hbox, FALSE, FALSE, 0 ); #initial buffer my $text = Gtk2::TextBuffer->new; $text->set_text($text_raw); #textview my $textview_hbox = Gtk2::HBox->new( FALSE, 5 ); $textview_hbox->set_border_width(5); $textview = Gtk2::TextView->new_with_buffer($text); $textview->can_focus(TRUE); $textview->set_size_request( 150, 200 ); $textview_hbox->pack_start_defaults($textview); $text_vbox->pack_start_defaults($textview_hbox); #use font checkbox my $use_font = Gtk2::CheckButton->new_with_label( $self->{_d}->get("Use selected font") ); $use_font->set_active(FALSE); $text_vbox->pack_start_defaults($use_font); #use font color checkbox my $use_font_color = Gtk2::CheckButton->new_with_label( $self->{_d}->get("Use selected font color") ); $use_font_color->set_active(FALSE); $text_vbox->pack_start_defaults($use_font_color); #apply changes directly $use_font->signal_connect( 'toggled' => sub { $self->modify_text_in_properties( $font_btn, $textview, $font_color, $item, $use_font, $use_font_color ); } ); $use_font_color->signal_connect( 'toggled' => sub { $self->modify_text_in_properties( $font_btn, $textview, $font_color, $item, $use_font, $use_font_color ); } ); $font_btn->signal_connect( 'font-set' => sub { $self->modify_text_in_properties( $font_btn, $textview, $font_color, $item, $use_font, $use_font_color ); } ); $font_color->signal_connect( 'color-set' => sub { $self->modify_text_in_properties( $font_btn, $textview, $font_color, $item, $use_font, $use_font_color ); } ); #apply current font settings to button $font_btn->set_font_name( $self->{_font} ); #FIXME >> why do we have to invoke this manually?? $font_btn->signal_emit('font-set'); $frame_text->add($text_vbox); } #instant changes my $store_count = 0; if ( defined $line_spin ) { $line_spin->signal_connect( 'value-changed' => sub { $self->apply_properties( $item, $parent, $key, $fill_color, $stroke_color, $line_spin, $font_color, $font_btn, $textview, $end_arrow, $start_arrow, $arrow_spin, $arrowl_spin, $arrowt_spin, $number_spin, $store_count ); $store_count++; } ); } if ( defined $fill_color ) { $fill_color->signal_connect( 'color-set' => sub { $self->apply_properties( $item, $parent, $key, $fill_color, $stroke_color, $line_spin, $font_color, $font_btn, $textview, $end_arrow, $start_arrow, $arrow_spin, $arrowl_spin, $arrowt_spin, $number_spin, $store_count ); $store_count++; } ); } if ( defined $stroke_color ) { $stroke_color->signal_connect( 'color-set' => sub { $self->apply_properties( $item, $parent, $key, $fill_color, $stroke_color, $line_spin, $font_color, $font_btn, $textview, $end_arrow, $start_arrow, $arrow_spin, $arrowl_spin, $arrowt_spin, $number_spin, $store_count ); $store_count++; } ); } if ( defined $number_spin ) { $number_spin->signal_connect( 'value-changed' => sub { $self->apply_properties( $item, $parent, $key, $fill_color, $stroke_color, $line_spin, $font_color, $font_btn, $textview, $end_arrow, $start_arrow, $arrow_spin, $arrowl_spin, $arrowt_spin, $number_spin, $store_count ); $store_count++; } ); } if ( defined $end_arrow ) { $end_arrow->signal_connect( 'toggled' => sub { $self->apply_properties( $item, $parent, $key, $fill_color, $stroke_color, $line_spin, $font_color, $font_btn, $textview, $end_arrow, $start_arrow, $arrow_spin, $arrowl_spin, $arrowt_spin, $number_spin, $store_count ); $store_count++; } ); } if ( defined $start_arrow ) { $start_arrow->signal_connect( 'toggled' => sub { $self->apply_properties( $item, $parent, $key, $fill_color, $stroke_color, $line_spin, $font_color, $font_btn, $textview, $end_arrow, $start_arrow, $arrow_spin, $arrowl_spin, $arrowt_spin, $number_spin, $store_count ); $store_count++; } ); } if ( defined $arrow_spin ) { $arrow_spin->signal_connect( 'value-changed' => sub { $self->apply_properties( $item, $parent, $key, $fill_color, $stroke_color, $line_spin, $font_color, $font_btn, $textview, $end_arrow, $start_arrow, $arrow_spin, $arrowl_spin, $arrowt_spin, $number_spin, $store_count ); $store_count++; } ); } if ( defined $arrowl_spin ) { $arrowl_spin->signal_connect( 'value-changed' => sub { $self->apply_properties( $item, $parent, $key, $fill_color, $stroke_color, $line_spin, $font_color, $font_btn, $textview, $end_arrow, $start_arrow, $arrow_spin, $arrowl_spin, $arrowt_spin, $number_spin, $store_count ); $store_count++; } ); } if ( defined $arrowt_spin ) { $arrowt_spin->signal_connect( 'value-changed' => sub { $self->apply_properties( $item, $parent, $key, $fill_color, $stroke_color, $line_spin, $font_color, $font_btn, $textview, $end_arrow, $start_arrow, $arrow_spin, $arrowl_spin, $arrowt_spin, $number_spin, $store_count ); $store_count++; } ); } if ( defined $font_btn ) { $font_btn->signal_connect( 'font-set' => sub { $self->apply_properties( $item, $parent, $key, $fill_color, $stroke_color, $line_spin, $font_color, $font_btn, $textview, $end_arrow, $start_arrow, $arrow_spin, $arrowl_spin, $arrowt_spin, $number_spin, $store_count ); $store_count++; } ); } if ( defined $font_color ) { $font_color->signal_connect( 'color-set' => sub { $self->apply_properties( $item, $parent, $key, $fill_color, $stroke_color, $line_spin, $font_color, $font_btn, $textview, $end_arrow, $start_arrow, $arrow_spin, $arrowl_spin, $arrowt_spin, $number_spin, $store_count ); $store_count++; } ); } if ( defined $textview ) { $textview->signal_connect( 'key-release-event' => sub { $self->apply_properties( $item, $parent, $key, $fill_color, $stroke_color, $line_spin, $font_color, $font_btn, $textview, $end_arrow, $start_arrow, $arrow_spin, $arrowl_spin, $arrowt_spin, $number_spin, $store_count ); $store_count++; } ); } #layout adjustments my $sg_prop = Gtk2::SizeGroup->new('horizontal'); foreach ( $prop_dialog->get_children->get_children ) { if ( $_->can('get_children') ) { foreach ( $_->get_children ) { if ( $_->can('get_children') ) { foreach ( $_->get_children ) { if ( $_->can('get_children') ) { foreach ( $_->get_children ) { if ( $_ =~ /Gtk2::Label/ ) { #~ print $_->get_text, "\n"; $_->set_alignment( 0, 0.5 ); $sg_prop->add_widget($_); } } } } } } } } #run dialog $prop_dialog->show_all; #textview grab focus to be able to edit #immediately if ( defined $textview ) { $textview->grab_focus; } my $prop_dialog_res = $prop_dialog->run; if ( $prop_dialog_res eq 'ok' ) { $self->apply_properties( $item, $parent, $key, $fill_color, $stroke_color, $line_spin, $font_color, $font_btn, $textview, $end_arrow, $start_arrow, $arrow_spin, $arrowl_spin, $arrowt_spin, $number_spin, $store_count ); #apply item properties to widgets #line width, fill color, stroke color etc. $self->set_and_save_drawing_properties( $self->{_current_item}, FALSE ); #FIXME - we need to save the changed values in this case $self->set_and_save_drawing_properties( $self->{_current_item}, TRUE ); $prop_dialog->destroy; return TRUE; } else { if ($store_count) { $self->xdo( 'undo', undef, TRUE ); } $prop_dialog->destroy; return FALSE; } } sub apply_properties { my ( $self, #item related infos $item, $parent, $key, #general properties $fill_color, $stroke_color, $line_spin, #only text $font_color, $font_btn, $textview, #only arrow $end_arrow, $start_arrow, $arrow_spin, $arrowl_spin, $arrowt_spin, #only numbered shapes $number_spin, #DO NOT STORE THE CHANGES (UNDO/REDO) $dont_store ) = @_; #~ print "apply_properties\n"; #remember drawing colors, line width and font settings #maybe we have to restore them if ( $self->{_items}{$key}{type} ne "highlighter" && $self->{_items}{$key}{type} ne "censor" ) { $self->{_last_fill_color} = $self->{_fill_color_w}->get_color; $self->{_last_fill_color_alpha} = $self->{_fill_color_w}->get_alpha / 65535; $self->{_last_stroke_color} = $self->{_stroke_color_w}->get_color; $self->{_last_stroke_color_alpha} = $self->{_stroke_color_w}->get_alpha / 65535; $self->{_last_line_width} = $self->{_line_spin_w}->get_value; $self->{_last_font} = $self->{_font_btn_w}->get_font_name; #remember the last mode as well $self->{_last_mode} = $self->{_current_mode}; } #add to undo stack unless ($dont_store) { $self->store_to_xdo_stack( $self->{_current_item}, 'modify', 'undo' ); } #apply rect or ellipse options if ( $item->isa('Goo::Canvas::Rect') || $item->isa('Goo::Canvas::Ellipse') ) { my $fill_pattern = $self->create_color( $fill_color->get_color, $fill_color->get_alpha / 65535 ); my $stroke_pattern = $self->create_color( $stroke_color->get_color, $stroke_color->get_alpha / 65535 ); $item->set( 'line-width' => $line_spin->get_value, 'fill-pattern' => $fill_pattern, 'stroke-pattern' => $stroke_pattern ); #special shapes like numbered ellipse (digit changed) if ( defined $self->{_items}{$key}{text} ) { #determine new or current digit my $digit = undef; if ( defined $number_spin ) { $digit = $number_spin->get_value; } else { $digit = $self->{_items}{$key}{text}{digit}; } my $fill_pattern = undef; if ( defined $font_color ) { $fill_pattern = $self->create_color( $font_color->get_color, $font_color->get_alpha / 65535 ); } elsif ( defined $stroke_color ) { $fill_pattern = $self->create_color( $stroke_color->get_color, $stroke_color->get_alpha / 65535 ); } my $font_descr = Gtk2::Pango::FontDescription->from_string( $font_btn->get_font_name ); $self->{_items}{$key}{text}->set( 'text' => "" . $digit . "", 'fill-pattern' => $fill_pattern, ); #adjust parent rectangle my $tb = $self->{_items}{$key}{text}->get_bounds; #keep ratio = 1 my $qs = abs( $tb->x1 - $tb->x2 ); $qs = abs( $tb->y1 - $tb->y2 ) if abs( $tb->y1 - $tb->y2 ) > abs( $tb->x1 - $tb->x2 ); #add line width of parent ellipse $qs += $self->{_items}{$key}{ellipse}->get('line-width') + 5; $parent->set( 'width' => $qs, 'height' => $qs, ); #save digit in hash as well (only item properties dialog) if ( defined $number_spin ) { $self->{_items}{$key}{text}{digit} = $digit; } $self->handle_rects( 'update', $parent ); $self->handle_embedded( 'update', $parent ); } #save color and opacity as well $self->{_items}{$key}{fill_color} = $fill_color->get_color; $self->{_items}{$key}{fill_color_alpha} = $fill_color->get_alpha / 65535; $self->{_items}{$key}{stroke_color} = $stroke_color->get_color; $self->{_items}{$key}{stroke_color_alpha} = $stroke_color->get_alpha / 65535; } #apply polyline options (arrow) if ( $item->isa('Goo::Canvas::Polyline') && defined $self->{_items}{$key}{end_arrow} && defined $self->{_items}{$key}{start_arrow} ) { my $stroke_pattern = $self->create_color( $stroke_color->get_color, $stroke_color->get_alpha / 65535 ); #these values are only available in the item menu if ( defined $arrowl_spin && defined $arrow_spin && defined $arrowt_spin && defined $end_arrow && defined $start_arrow ) { $item->set( 'line-width' => $line_spin->get_value, 'stroke-pattern' => $stroke_pattern, 'end-arrow' => $end_arrow->get_active, 'start-arrow' => $start_arrow->get_active, 'arrow-length' => $arrowl_spin->get_value, 'arrow-width' => $arrow_spin->get_value, 'arrow-tip-length' => $arrowt_spin->get_value, ); } else { $item->set( 'line-width' => $line_spin->get_value, 'stroke-pattern' => $stroke_pattern, 'end-arrow' => $self->{_items}{$key}{line}->get('end-arrow'), 'start-arrow' => $self->{_items}{$key}{line}->get('start-arrow'), ); } #save color and opacity as well $self->{_items}{$key}{stroke_color} = $stroke_color->get_color; $self->{_items}{$key}{stroke_color_alpha} = $stroke_color->get_alpha / 65535; #save arrow specific properties $self->{_items}{$key}{end_arrow} = $self->{_items}{$key}{line}->get('end-arrow'); $self->{_items}{$key}{start_arrow} = $self->{_items}{$key}{line}->get('start-arrow'); $self->{_items}{$key}{arrow_width} = $self->{_items}{$key}{line}->get('arrow-width'); $self->{_items}{$key}{arrow_length} = $self->{_items}{$key}{line}->get('arrow-length'); $self->{_items}{$key}{arrow_tip_length} = $self->{_items}{$key}{line}->get('arrow-tip-length'); #apply polyline options (freehand, highlighter) } elsif ( $item->isa('Goo::Canvas::Polyline') && defined $self->{_items}{$key}{stroke_color} ) { my $stroke_pattern = $self->create_color( $stroke_color->get_color, $stroke_color->get_alpha / 65535 ); $item->set( 'line-width' => $line_spin->get_value, 'stroke-pattern' => $stroke_pattern, ); #save color and opacity as well $self->{_items}{$key}{stroke_color} = $stroke_color->get_color; $self->{_items}{$key}{stroke_color_alpha} = $stroke_color->get_alpha / 65535; } #apply text options if ( $item->isa('Goo::Canvas::Text') ) { my $font_descr = Gtk2::Pango::FontDescription->from_string( $font_btn->get_font_name ); my $fill_pattern = $self->create_color( $font_color->get_color, $font_color->get_alpha / 65535 ); my $new_text = undef; if ($textview) { $new_text = $textview->get_buffer->get_text( $textview->get_buffer->get_start_iter, $textview->get_buffer->get_end_iter, FALSE ) || " "; } else { #determine font description and text from string my ( $attr_list, $text_raw, $accel_char ) = Gtk2::Pango->parse_markup( $item->get('text') ); $new_text = $text_raw; } $item->set( 'text' => "" . Glib::Markup::escape_text($new_text) . "", 'width' => -1, 'use-markup' => TRUE, 'fill-pattern' => $fill_pattern ); #adjust parent rectangle my $tb = $item->get_bounds; $parent->set( 'width' => abs( $tb->x1 - $tb->x2 ), 'height' => abs( $tb->y1 - $tb->y2 ), ); $self->handle_rects( 'update', $parent ); $self->handle_embedded( 'update', $parent ); #save color and opacity as well $self->{_items}{$key}{stroke_color} = $font_color->get_color; $self->{_items}{$key}{stroke_color_alpha} = $font_color->get_alpha / 65535; } } sub modify_text_in_properties { my $self = shift; my $font_btn = shift; my $textview = shift; my $font_color = shift; my $item = shift; my $use_font = shift; my $use_font_color = shift; my $font_descr = Gtk2::Pango::FontDescription->from_string( $font_btn->get_font_name ); my $texttag = Gtk2::TextTag->new; if ( $use_font->get_active && $use_font_color->get_active ) { $texttag->set( 'font-desc' => $font_descr, 'foreground-gdk' => $font_color->get_color ); } elsif ( $use_font->get_active ) { $texttag->set( 'font-desc' => $font_descr ); } elsif ( $use_font_color->get_active ) { $texttag->set( 'foreground-gdk' => $font_color->get_color ); } my $texttagtable = Gtk2::TextTagTable->new; $texttagtable->add($texttag); my $text = Gtk2::TextBuffer->new($texttagtable); $text->signal_connect( 'changed' => sub { $text->apply_tag( $texttag, $text->get_start_iter, $text->get_end_iter ); } ); $text->set_text( $textview->get_buffer->get_text( $textview->get_buffer->get_start_iter, $textview->get_buffer->get_end_iter, FALSE ) ); $text->apply_tag( $texttag, $text->get_start_iter, $text->get_end_iter ); $textview->set_buffer($text); return TRUE; } sub move_all { my ( $self, $x, $y ) = @_; foreach ( keys %{ $self->{_items} } ) { my $item = $self->{_items}{$_}; #embedded item? my $parent = $self->get_parent_item($item); $item = $parent if $parent; #real shape if ( exists $self->{_items}{$item} ) { if ( $item->isa('Goo::Canvas::Rect') ) { $item->set( 'x' => $item->get('x') - $x, 'y' => $item->get('y') - $y, ); my $child = $self->get_child_item($item); $child = $item unless $child; #it item is hidden, keep the status if ( $child->get('visibility') eq 'hidden' ) { $self->handle_rects( 'hide', $item ); $self->handle_embedded( 'hide', $item ); } else { $self->handle_rects( 'update', $item ); #pixelizer is treated differently if ( $child && $child->isa('Goo::Canvas::Image') ) { my $parent = $self->get_parent_item($child); if ( exists $self->{_items}{$parent}{pixelize} ) { Glib::Idle->add( sub { $self->{_items}{$parent}{pixelize}->set( 'x' => int $self->{_items}{$parent}->get('x'), 'y' => int $self->{_items}{$parent}->get('y'), 'width' => $self->{_items}{$parent}->get('width'), 'height' => $self->{_items}{$parent}->get('height'), 'pixbuf' => $self->get_pixelated_pixbuf_from_canvas( $self->{_items}{$parent} ), ); $self->handle_embedded( 'update', $parent, undef, undef, TRUE ); #deactivate all after move $self->deactivate_all; return FALSE; } ); } else { $self->handle_embedded( 'update', $item ); } } else { $self->handle_embedded( 'update', $item ); } } #freehand line for example } else { $item->translate( -$x, -$y ); } } } #deactivate all after move $self->deactivate_all; return TRUE; } sub deactivate_all { my $self = shift; my $exclude = shift || 0; #~ print "deactivate_all\n"; foreach ( keys %{ $self->{_items} } ) { my $item = $self->{_items}{$_}; next if $item == $exclude; #embedded item? my $parent = $self->get_parent_item($item); $item = $parent if $parent; #real shape if ( exists $self->{_items}{$item} ) { $self->handle_rects( 'hide', $item ); } } $self->{_current_item} = undef; $self->{_current_new_item} = undef; return TRUE; } sub handle_embedded { my ( $self, $action, $item, $new_width, $new_height, $force_show ) = @_; return FALSE unless ( $item && exists $self->{_items}{$item} ); if ( $action eq 'update' ) { my $visibility = 'visible'; #embedded ellipse if ( exists $self->{_items}{$item}{ellipse} ) { $self->{_items}{$item}{ellipse}->set( 'center-x' => $self->{_items}{$item}->get('x') + $self->{_items}{$item}->get('width') / 2, 'center-y' => $self->{_items}{$item}->get('y') + $self->{_items}{$item}->get('height') / 2, ); $self->{_items}{$item}{ellipse}->set( 'radius-x' => $self->{_items}{$item}->get('x') + $self->{_items}{$item}->get('width') - $self->{_items}{$item}{ellipse}->get('center-x'), 'radius-y' => $item->get('y') + $self->{_items}{$item}->get('height') - $self->{_items}{$item}{ellipse}->get('center-y'), 'visibility' => $visibility, ); #numbered ellipse if ( exists $self->{_items}{$item}{text} ) { $self->{_items}{$item}{text}->set( 'x' => $self->{_items}{$item}{ellipse}->get('center-x'), 'y' => $self->{_items}{$item}{ellipse}->get('center-y'), 'visibility' => $visibility, ); } } elsif ( exists $self->{_items}{$item}{text} ) { $self->{_items}{$item}{text}->set( 'x' => $self->{_items}{$item}->get('x'), 'y' => $self->{_items}{$item}->get('y'), 'width' => $self->{_items}{$item}->get('width'), 'visibility' => $visibility, ); } elsif ( exists $self->{_items}{$item}{line} ) { #handle possible arrows properly #arrow is always and end-arrow if ( $self->{_items}{$item}{mirrored_w} < 0 && $self->{_items}{$item}{mirrored_h} < 0 ) { $self->{_items}{$item}{line}->set( 'points' => Goo::Canvas::Points->new( [ $self->{_items}{$item}->get('x') + $self->{_items}{$item}->get('width'), $self->{_items}{$item}->get('y') + $self->{_items}{$item}->get('height'), $self->{_items}{$item}->get('x'), $self->{_items}{$item}->get('y') ] ), 'visibility' => $visibility ); } elsif ( $self->{_items}{$item}{mirrored_w} < 0 ) { $self->{_items}{$item}{line}->set( 'points' => Goo::Canvas::Points->new( [ $self->{_items}{$item}->get('x') + $self->{_items}{$item}->get('width'), $self->{_items}{$item}->get('y'), $self->{_items}{$item}->get('x'), $self->{_items}{$item}->get('y') + $self->{_items}{$item}->get('height') ] ), 'visibility' => $visibility ); } elsif ( $self->{_items}{$item}{mirrored_h} < 0 ) { $self->{_items}{$item}{line}->set( 'points' => Goo::Canvas::Points->new( [ $self->{_items}{$item}->get('x'), $self->{_items}{$item}->get('y') + $self->{_items}{$item}->get('height'), $self->{_items}{$item}->get('x') + $self->{_items}{$item}->get('width'), $self->{_items}{$item}->get('y') ] ), 'visibility' => $visibility ); } else { $self->{_items}{$item}{line}->set( 'points' => Goo::Canvas::Points->new( [ $self->{_items}{$item}->get('x'), $self->{_items}{$item}->get('y'), $self->{_items}{$item}->get('x') + $self->{_items}{$item}->get('width'), $self->{_items}{$item}->get('y') + $self->{_items}{$item}->get('height') ] ), 'visibility' => $visibility ); } } elsif ( exists $self->{_items}{$item}{pixelize} ) { if ($force_show) { $self->{_items}{$item}{pixelize}->set( 'visibility' => $visibility, ); } else { $self->{_items}{$item}{pixelize}->set( 'visibility' => 'hidden', ); } } elsif ( exists $self->{_items}{$item}{image} ) { if ( $self->{_items}{$item}->get('width') == $self->{_items}{$item}{image}->get('width') && $self->{_items}{$item}->get('height') == $self->{_items}{$item}{image}->get('height') ) { $self->{_items}{$item}{image}->set( 'x' => int $self->{_items}{$item}->get('x'), 'y' => int $self->{_items}{$item}->get('y'), 'visibility' => $visibility, ); } else { #be careful when resizing images #don't do anything when width or height are too small if ( $self->{_items}{$item}->get('width') > 5 && $self->{_items}{$item}->get('height') > 5 ) { $self->{_items}{$item}{image}->set( 'x' => int $self->{_items}{$item}->get('x'), 'y' => int $self->{_items}{$item}->get('y'), 'width' => $self->{_items}{$item}->get('width'), 'height' => $self->{_items}{$item}->get('height'), 'pixbuf' => $self->{_items}{$item}{orig_pixbuf}->scale_simple( $self->{_items}{$item}->get('width'), $self->{_items}{$item}->get('height'), 'nearest' ), 'visibility' => $visibility, ); } else { $self->{_items}{$item}{image}->set( 'x' => int $self->{_items}{$item}->get('x'), 'y' => int $self->{_items}{$item}->get('y'), 'width' => $self->{_items}{$item}->get('width'), 'height' => $self->{_items}{$item}->get('height'), 'visibility' => $visibility, ); } } } } elsif ( $action eq 'delete' ) { #ellipse if ( exists $self->{_items}{$item}{ellipse} ) { if ( my $nint = $self->{_canvas}->get_root_item->find_child( $self->{_items}{$item}{ellipse} ) ) { $self->{_canvas}->get_root_item->remove_child($nint); } } #text if ( exists $self->{_items}{$item}{text} ) { if ( my $nint = $self->{_canvas}->get_root_item->find_child( $self->{_items}{$item}{text} ) ) { $self->{_canvas}->get_root_item->remove_child($nint); } } #pixelize if ( exists $self->{_items}{$item}{pixelize} ) { if ( my $nint = $self->{_canvas}->get_root_item->find_child( $self->{_items}{$item}{pixelize} ) ) { $self->{_canvas}->get_root_item->remove_child($nint); } } #image if ( exists $self->{_items}{$item}{image} ) { if ( my $nint = $self->{_canvas}->get_root_item->find_child( $self->{_items}{$item}{image} ) ) { $self->{_canvas}->get_root_item->remove_child($nint); } } #line if ( exists $self->{_items}{$item}{line} ) { if ( my $nint = $self->{_canvas}->get_root_item->find_child( $self->{_items}{$item}{line} ) ) { $self->{_canvas}->get_root_item->remove_child($nint); } } } elsif ( $action eq 'hide' ) { my $visibility = 'hidden'; #ellipse => hide rectangle as well if ( exists $self->{_items}{$item}{ellipse} ) { $self->{_items}{$item}{ellipse}->set( 'visibility' => $visibility ); } #text => hide rectangle as well if ( exists $self->{_items}{$item}{text} ) { $self->{_items}{$item}{text}->set( 'visibility' => $visibility ); } #pixelize => hide rectangle as well if ( exists $self->{_items}{$item}{pixelize} ) { $self->{_items}{$item}{pixelize}->set( 'visibility' => $visibility ); } #image => hide rectangle as well if ( exists $self->{_items}{$item}{image} ) { $self->{_items}{$item}{image}->set( 'visibility' => $visibility ); } #line => hide rectangle as well if ( exists $self->{_items}{$item}{line} ) { $self->{_items}{$item}{line}->set( 'visibility' => $visibility ); } } elsif ( $action eq 'mirror' ) { if ( exists $self->{_items}{$item}{line} ) { #width if ( $new_width < 0 && $self->{_items}{$item}{mirrored_w} >= 0 ) { $self->{_items}{$item}{mirrored_w} = $new_width; } elsif ( $new_width < 0 && $self->{_items}{$item}{mirrored_w} < 0 ) { $self->{_items}{$item}{mirrored_w} = 0; } #height if ( $new_height < 0 && $self->{_items}{$item}{mirrored_h} >= 0 ) { $self->{_items}{$item}{mirrored_h} = $new_height; } elsif ( $new_height < 0 && $self->{_items}{$item}{mirrored_h} < 0 ) { $self->{_items}{$item}{mirrored_h} = 0; } } } return TRUE; } sub handle_bg_rects { my ( $self, $action ) = @_; my $x = $self->{_canvas_bg_rect}->get('x'); my $y = $self->{_canvas_bg_rect}->get('y'); my $width = $self->{_canvas_bg_rect}->get('width'); my $height = $self->{_canvas_bg_rect}->get('height'); my $middle_h = $x + $width / 2; my $middle_v = $y + $height / 2; my $bottom = $y + $height; my $top = $y; my $left = $x; my $right = $x + $width; if ( $action eq 'create' ) { my $pattern = $self->create_color( $self->{_style_bg}, 1 ); $self->{_canvas_bg_rect}{'bottom-side'} = Goo::Canvas::Rect->new( $self->{_canvas}->get_root_item, $middle_h, $bottom, 8, 8, 'fill-pattern' => $pattern, 'line-width' => 1, ); $self->{_canvas_bg_rect}{'bottom-right-corner'} = Goo::Canvas::Rect->new( $self->{_canvas}->get_root_item, $right, $bottom, 8, 8, 'fill-pattern' => $pattern, 'line-width' => 1, ); $self->{_canvas_bg_rect}{'right-side'} = Goo::Canvas::Rect->new( $self->{_canvas}->get_root_item, $right, $middle_v, 8, 8, 'fill-pattern' => $pattern, 'line-width' => 1, ); $self->setup_item_signals( $self->{_canvas_bg_rect}{'bottom-side'} ); $self->setup_item_signals( $self->{_canvas_bg_rect}{'bottom-right-corner'} ); $self->setup_item_signals( $self->{_canvas_bg_rect}{'right-side'} ); $self->setup_item_signals_extra( $self->{_canvas_bg_rect}{'bottom-side'} ); $self->setup_item_signals_extra( $self->{_canvas_bg_rect}{'bottom-right-corner'} ); $self->setup_item_signals_extra( $self->{_canvas_bg_rect}{'right-side'} ); } elsif ( $action eq 'hide' || $action eq 'show' ) { my $visibility = undef; if ( $action eq 'hide' ) { $visibility = 'hidden'; } elsif ( $action eq 'show' ) { $visibility = 'visible'; } foreach ( keys %{ $self->{_canvas_bg_rect} } ) { if ( $self->{_canvas_bg_rect}{$_}->can('set') ) { $self->{_canvas_bg_rect}{$_}->set( 'visibility' => $visibility, ); } } #end determine rect } elsif ( $action eq 'update' ) { #update the canvas bounds as well $self->{_canvas}->set_bounds( 0, 0, $self->{_canvas_bg_rect}->get('width'), $self->{_canvas_bg_rect}->get('height') ); $self->{_canvas_bg_rect}{'bottom-side'}->set( 'x' => $middle_h - 8, 'y' => $bottom - 8, ); $self->{_canvas_bg_rect}{'bottom-right-corner'}->set( 'x' => $right - 8, 'y' => $bottom - 8, ); $self->{_canvas_bg_rect}{'right-side'}->set( 'x' => $right - 8, 'y' => $middle_v - 8, ); $self->handle_bg_rects('raise'); } elsif ( $action eq 'raise' ) { $self->{_canvas_bg_rect}{'bottom-side'}->raise; $self->{_canvas_bg_rect}{'bottom-right-corner'}->raise; $self->{_canvas_bg_rect}{'right-side'}->raise; } } sub handle_rects { my ( $self, $action, $item ) = @_; #~ print "entering handle_rects1\n"; return FALSE unless $item; return FALSE unless exists $self->{_items}{$item}; #~ print "entering handle_rects2\n"; #get root item my $root = $self->{_canvas}->get_root_item; if ( $self->{_items}{$item}->isa('Goo::Canvas::Rect') ) { my $x = $self->{_items}{$item}->get('x'); my $y = $self->{_items}{$item}->get('y'); my $width = $self->{_items}{$item}->get('width'); my $height = $self->{_items}{$item}->get('height'); my $middle_h = $x + $width / 2; my $middle_v = $y + $height / 2; my $bottom = $y + $height; my $top = $y; my $left = $x; my $right = $x + $width; if ( $action eq 'create' ) { my $pattern = $self->create_color( $self->{_style_bg}, 1 ); $self->{_items}{$item}{'top-side'} = Goo::Canvas::Rect->new( $root, $middle_h, $top, 8, 8, 'fill-pattern' => $pattern, 'visibility' => 'hidden', 'line-width' => 0.5, ); $self->{_items}{$item}{'top-left-corner'} = Goo::Canvas::Rect->new( $root, $left, $top, 8, 8, 'fill-pattern' => $pattern, 'visibility' => 'hidden', 'line-width' => 0.5, 'radius-x' => 8, 'radius-y' => 8, ); $self->{_items}{$item}{'top-right-corner'} = Goo::Canvas::Rect->new( $root, $right, $top, 8, 8, 'fill-pattern' => $pattern, 'visibility' => 'hidden', 'line-width' => 0.5, 'radius-x' => 8, 'radius-y' => 8, ); $self->{_items}{$item}{'bottom-side'} = Goo::Canvas::Rect->new( $root, $middle_h, $bottom, 8, 8, 'fill-pattern' => $pattern, 'visibility' => 'hidden', 'line-width' => 0.5, ); $self->{_items}{$item}{'bottom-left-corner'} = Goo::Canvas::Rect->new( $root, $left, $bottom, 8, 8, 'fill-pattern' => $pattern, 'visibility' => 'hidden', 'line-width' => 0.5, 'radius-x' => 8, 'radius-y' => 8, ); $self->{_items}{$item}{'bottom-right-corner'} = Goo::Canvas::Rect->new( $root, $right, $bottom, 8, 8, 'fill-pattern' => $pattern, 'visibility' => 'hidden', 'line-width' => 0.5, 'radius-x' => 8, 'radius-y' => 8, ); $self->{_items}{$item}{'left-side'} = Goo::Canvas::Rect->new( $root, $left - 8, $middle_v, 8, 8, 'fill-pattern' => $pattern, 'visibility' => 'hidden', 'line-width' => 0.5, ); $self->{_items}{$item}{'right-side'} = Goo::Canvas::Rect->new( $root, $right, $middle_v, 8, 8, 'fill-pattern' => $pattern, 'visibility' => 'hidden', 'line-width' => 0.5, ); $self->setup_item_signals( $self->{_items}{$item}{'top-side'} ); $self->setup_item_signals( $self->{_items}{$item}{'top-left-corner'} ); $self->setup_item_signals( $self->{_items}{$item}{'top-right-corner'} ); $self->setup_item_signals( $self->{_items}{$item}{'bottom-side'} ); $self->setup_item_signals( $self->{_items}{$item}{'bottom-left-corner'} ); $self->setup_item_signals( $self->{_items}{$item}{'bottom-right-corner'} ); $self->setup_item_signals( $self->{_items}{$item}{'left-side'} ); $self->setup_item_signals( $self->{_items}{$item}{'right-side'} ); $self->setup_item_signals_extra( $self->{_items}{$item}{'top-side'} ); $self->setup_item_signals_extra( $self->{_items}{$item}{'top-left-corner'} ); $self->setup_item_signals_extra( $self->{_items}{$item}{'top-right-corner'} ); $self->setup_item_signals_extra( $self->{_items}{$item}{'bottom-side'} ); $self->setup_item_signals_extra( $self->{_items}{$item}{'bottom-left-corner'} ); $self->setup_item_signals_extra( $self->{_items}{$item}{'bottom-right-corner'} ); $self->setup_item_signals_extra( $self->{_items}{$item}{'left-side'} ); $self->setup_item_signals_extra( $self->{_items}{$item}{'right-side'} ); } elsif ( $action eq 'delete' ) { if ( my $nint = $self->{_canvas}->get_root_item->find_child( $self->{_items}{$item}{'top-side'} ) ) { $self->{_canvas}->get_root_item->remove_child($nint); } if ( my $nint = $self->{_canvas}->get_root_item->find_child( $self->{_items}{$item}{'top-left-corner'} ) ) { $self->{_canvas}->get_root_item->remove_child($nint); } if ( my $nint = $self->{_canvas}->get_root_item->find_child( $self->{_items}{$item}{'top-right-corner'} ) ) { $self->{_canvas}->get_root_item->remove_child($nint); } if ( my $nint = $self->{_canvas}->get_root_item->find_child( $self->{_items}{$item}{'bottom-side'} ) ) { $self->{_canvas}->get_root_item->remove_child($nint); } if ( my $nint = $self->{_canvas}->get_root_item->find_child( $self->{_items}{$item}{'bottom-left-corner'} ) ) { $self->{_canvas}->get_root_item->remove_child($nint); } if ( my $nint = $self->{_canvas}->get_root_item->find_child( $self->{_items}{$item}{'bottom-right-corner'} ) ) { $self->{_canvas}->get_root_item->remove_child($nint); } if ( my $nint = $self->{_canvas}->get_root_item->find_child( $self->{_items}{$item}{'left-side'} ) ) { $self->{_canvas}->get_root_item->remove_child($nint); } if ( my $nint = $self->{_canvas}->get_root_item->find_child( $self->{_items}{$item}{'right-side'} ) ) { $self->{_canvas}->get_root_item->remove_child($nint); } } elsif ( $action eq 'update' || $action eq 'hide' ) { my $visibility = 'visible'; $visibility = 'hidden' if $action eq 'hide'; my $lw = $item->get('line-width'); #ellipse => hide rectangle as well if ( exists $self->{_items}{$item}{ellipse} ) { $self->{_items}{$item}->set( 'visibility' => $visibility ); } #text => hide rectangle as well if ( exists $self->{_items}{$item}{text} ) { $self->{_items}{$item}->set( 'visibility' => $visibility ); } #pixelize => hide rectangle as well if ( exists $self->{_items}{$item}{pixelize} ) { $self->{_items}{$item}->set( 'visibility' => $visibility ); } #image => hide rectangle as well if ( exists $self->{_items}{$item}{image} ) { $self->{_items}{$item}->set( 'visibility' => $visibility ); } #line => hide rectangle as well if ( exists $self->{_items}{$item}{line} ) { $self->{_items}{$item}->set( 'visibility' => $visibility ); } #just to make sure the update routines are not #called in wrong order #we test the first value, if this is ok #we believe all other resize rects are ok as well return FALSE unless defined $self->{_items}{$item}{'top-side'}; $self->{_items}{$item}{'top-side'}->set( 'x' => $middle_h - 4, 'y' => $top - 8, 'visibility' => $visibility, ); $self->{_items}{$item}{'top-left-corner'}->set( 'x' => $left - 8, 'y' => $top - 8, 'visibility' => $visibility, ); $self->{_items}{$item}{'top-right-corner'}->set( 'x' => $right, 'y' => $top - 8, 'visibility' => $visibility, ); $self->{_items}{$item}{'bottom-side'}->set( 'x' => $middle_h - 4, 'y' => $bottom, 'visibility' => $visibility, ); $self->{_items}{$item}{'bottom-left-corner'}->set( 'x' => $left - 8, 'y' => $bottom, 'visibility' => $visibility, ); $self->{_items}{$item}{'bottom-right-corner'}->set( 'x' => $right, 'y' => $bottom, 'visibility' => $visibility, ); $self->{_items}{$item}{'left-side'}->set( 'x' => $left - 8, 'y' => $middle_v - 4, 'visibility' => $visibility, ); $self->{_items}{$item}{'right-side'}->set( 'x' => $right, 'y' => $middle_v - 4, 'visibility' => $visibility, ); #~ $self->handle_bg_rects('raise'); } elsif ( $action eq 'raise' ) { $self->{_items}{$item}{'top-side'}->raise; $self->{_items}{$item}{'top-left-corner'}->raise; $self->{_items}{$item}{'top-right-corner'}->raise; $self->{_items}{$item}{'bottom-side'}->raise; $self->{_items}{$item}{'bottom-left-corner'}->raise; $self->{_items}{$item}{'bottom-right-corner'}->raise; $self->{_items}{$item}{'left-side'}->raise; $self->{_items}{$item}{'right-side'}->raise; } elsif ( $action eq 'lower' ) { $self->{_items}{$item}{'top-side'}->lower; $self->{_items}{$item}{'top-left-corner'}->lower; $self->{_items}{$item}{'top-right-corner'}->lower; $self->{_items}{$item}{'bottom-side'}->lower; $self->{_items}{$item}{'bottom-left-corner'}->lower; $self->{_items}{$item}{'bottom-right-corner'}->lower; $self->{_items}{$item}{'left-side'}->lower; $self->{_items}{$item}{'right-side'}->lower; } } return TRUE; } sub event_item_on_button_release { my ( $self, $item, $target, $ev ) = @_; $self->{_canvas}->pointer_ungrab( $item, $ev->time ); $self->{_canvas}->keyboard_ungrab( $item, $ev->time ); #canvas is idle now... $self->{_busy} = FALSE; #we handle some minimum sizes here if the new items are too small #maybe the user just wanted to place an rect or an object on the canvas #and clicked on it without describing an rectangular area my $nitem = $self->{_current_new_item}; if ($nitem) { #apply item properties to widgets #line width, fill color, stroke color etc. $self->set_and_save_drawing_properties( $nitem, FALSE ); #flag if item has to be deleted directly my $deleted = FALSE; #set minimum sizes if ( $nitem->isa('Goo::Canvas::Rect') ) { #real shape if ( exists $self->{_items}{$nitem} ) { #images if ( exists $self->{_items}{$nitem}{image} ) { $self->{_items}{$nitem}->set( 'x' => $ev->x - int( $self->{_items}{$nitem}{orig_pixbuf}->get_width / 2 ), 'y' => $ev->y - int( $self->{_items}{$nitem}{orig_pixbuf}->get_height / 2 ), 'width' => $self->{_items}{$nitem}{orig_pixbuf}->get_width, 'height' => $self->{_items}{$nitem}{orig_pixbuf}->get_height, ); #texts } elsif ( exists $self->{_items}{$nitem}{text} ) { if ( $self->{_items}{$nitem}{type} eq 'text' ) { #clear text $self->{_items}{$nitem}{text}->set( 'text' => "" ); #adjust parent rectangle my $tb = $self->{_items}{$nitem}{text}->get_bounds; $nitem->set( 'x' => $ev->x, 'y' => $ev->y - int( abs( $tb->y1 - $tb->y2 ) / 2 ), 'width' => abs( $tb->x1 - $tb->x2 ), 'height' => abs( $tb->y1 - $tb->y2 ), ); #show property dialog directly Glib::Idle->add( sub { unless ( $self->show_item_properties( $self->{_items}{$nitem}{text}, $nitem, $nitem ) ) { if ( my $nint = $self->{_canvas}->get_root_item->find_child($nitem) ) { #delete canvas objects $self->{_canvas}->get_root_item->remove_child($nint); $self->handle_rects( 'delete', $nitem ); $self->handle_embedded( 'delete', $nitem ); #delete from hash delete $self->{_items}{$nitem}; #delete all xdo emtries for this object $self->xdo_remove( 'undo', $nitem ); $self->xdo_remove( 'redo', $nitem ); $self->deactivate_all; } } return FALSE; } ); } elsif ( $self->{_items}{$nitem}{type} eq 'number' ) { $self->{_items}{$nitem}->set( 'x' => $ev->x - int( $self->{_items}{$nitem}->get('width') / 2 ), 'y' => $ev->y - int( $self->{_items}{$nitem}->get('height') / 2 ), 'width' => $self->{_items}{$nitem}->get('width'), 'height' => $self->{_items}{$nitem}->get('height'), ); } #all other objects } else { #delete if ( my $nint = $self->{_canvas}->get_root_item->find_child($nitem) ) { #delete from canvas $self->{_canvas}->get_root_item->remove_child($nint); #mark as deleted $deleted = TRUE; #~ print "item $nitem marked as deleted at ",$ev->x,", ",$ev->y,"\n"; } } #~ print "new item created: $item\n"; } } if ($deleted) { #delete child objects and resizing rectangles $self->handle_rects( 'delete', $nitem ); $self->handle_embedded( 'delete', $nitem ); #delete from hash delete $self->{_items}{$nitem}; #~ print "item $nitem deleted at ",$ev->x,", ",$ev->y,"\n"; #deactivate all $self->deactivate_all; if ( my $oitem = $self->{_canvas}->get_item_at( $ev->x_root, $ev->y_root, TRUE ) ) { #~ print "item $oitem found at ",$ev->x,", ",$ev->y,"\n"; #turn into a button-press-event my $initevent = Gtk2::Gdk::Event->new('button-press'); $initevent->set_time( Gtk2->get_current_event_time ); $initevent->window( $self->{_drawing_window}->window ); $initevent->x( $ev->x ); $initevent->y( $ev->y ); $self->event_item_on_button_press( $oitem, undef, $initevent, TRUE ); $self->event_item_on_button_release( $oitem, undef, $initevent ); return FALSE; } } else { $self->deactivate_all($nitem); #mark as active item $self->{_current_item} = $nitem; $self->handle_rects( 'update', $nitem ); $self->handle_embedded( 'update', $nitem ); #add to undo stack $self->store_to_xdo_stack( $nitem, 'create', 'undo' ); } #no new item #existing item selected } else { #cleanup #it may happen that items are created #but resize mode is not activated immediately #those items would not be visible on the canvas #we delete them here my $citem = $self->{_current_item}; if ( $citem && $citem->isa('Goo::Canvas::Rect') ) { if ( exists $self->{_items}{$citem} ) { if ( $self->{_items}{$citem}->get('visibility') eq 'hidden' ) { if ( my $nint = $self->{_canvas}->get_root_item->find_child($citem) ) { $self->xdo( 'undo', undef, TRUE ); #delete from canvas $self->{_canvas}->get_root_item->remove_child($nint); #delete child objects and resizing rectangles $self->handle_rects( 'delete', $citem ); $self->handle_embedded( 'delete', $citem ); #delete from hash delete $self->{_items}{$citem}; } } } } #apply item properties to widgets #line width, fill color, stroke color etc. $self->set_and_save_drawing_properties( $citem, FALSE ); } #uncheck previous active item $self->{_current_new_item} = undef; #unset action flags $item->{dragging} = FALSE if exists $item->{dragging}; $item->{dragging_start} = FALSE if exists $item->{dragging_start}; $item->{resizing} = FALSE if exists $item->{resizing}; #because of performance reason we load the current image new from file when #the current action is over => button-release #when resizing or moving the image we just scale the current image with low quality settings #see handle_embedded my $child = $self->get_child_item( $self->{_current_item} ); if ( $child && $child->isa('Goo::Canvas::Image') ) { my $parent = $self->get_parent_item($child); if ( exists $self->{_items}{$parent}{pixelize} ) { $self->{_items}{$parent}{pixelize}->set( 'x' => int $self->{_items}{$parent}->get('x'), 'y' => int $self->{_items}{$parent}->get('y'), 'width' => $self->{_items}{$parent}->get('width'), 'height' => $self->{_items}{$parent}->get('height'), 'pixbuf' => $self->get_pixelated_pixbuf_from_canvas( $self->{_items}{$parent} ), ); $self->handle_embedded( 'update', $parent, undef, undef, TRUE ); } else { my $copy = $self->{_lp}->load( $self->{_items}{$parent}{orig_pixbuf_filename}, $self->{_items}{$parent}->get('width'), $self->{_items}{$parent}->get('height'), FALSE, TRUE ); if ($copy) { $self->{_items}{$parent}{image}->set( 'x' => int $self->{_items}{$parent}->get('x'), 'y' => int $self->{_items}{$parent}->get('y'), 'width' => $self->{_items}{$parent}->get('width'), 'height' => $self->{_items}{$parent}->get('height'), 'pixbuf' => $copy, ); $self->handle_embedded( 'update', $parent, undef, undef, TRUE ); } else { #Try to load it with default width and height (Bug #975247) $self->{_items}{$parent}->set( 'x' => $ev->x - int( $self->{_items}{$parent}{orig_pixbuf}->get_width / 2 ), 'y' => $ev->y - int( $self->{_items}{$parent}{orig_pixbuf}->get_height / 2 ), 'width' => $self->{_items}{$parent}{orig_pixbuf}->get_width, 'height' => $self->{_items}{$parent}{orig_pixbuf}->get_height, ); #mark as active item $self->{_current_item} = $parent; $self->handle_rects( 'update', $parent ); $self->handle_embedded( 'update', $parent, undef, undef, TRUE ); #~ $self->abort_current_mode; } } } $self->set_drawing_action( int( $self->{_current_mode} / 10 ) ); return TRUE; } sub event_item_on_enter_notify { my ( $self, $item, $target, $ev ) = @_; return TRUE if $self->{_busy}; if ( ( $item->isa('Goo::Canvas::Rect') || $item->isa('Goo::Canvas::Ellipse') || $item->isa('Goo::Canvas::Text') || $item->isa('Goo::Canvas::Image') || $item->isa('Goo::Canvas::Polyline') ) && ( $self->{_current_mode_descr} ne "freehand" && $self->{_current_mode_descr} ne "highlighter" && $self->{_current_mode_descr} ne "censor" ) ) { #embedded item? my $parent = $self->get_parent_item($item); $item = $parent if $parent; #real shape if ( exists $self->{_items}{$item} ) { #nothing here yet #canvas resizing shape } elsif ($self->{_canvas_bg_rect}{'right-side'} == $item || $self->{_canvas_bg_rect}{'bottom-side'} == $item || $self->{_canvas_bg_rect}{'bottom-right-corner'} == $item ) { my $pattern = $self->create_color( 'red', 1 ); $item->set( 'fill-pattern' => $pattern ); #resizing shape } else { my $pattern = $self->create_color( 'red', 1 ); $item->set( 'fill-pattern' => $pattern ); } } return TRUE; } sub event_item_on_leave_notify { my ( $self, $item, $target, $ev ) = @_; return TRUE if $self->{_busy}; if ( ( $item->isa('Goo::Canvas::Rect') || $item->isa('Goo::Canvas::Ellipse') || $item->isa('Goo::Canvas::Text') || $item->isa('Goo::Canvas::Image') || $item->isa('Goo::Canvas::Polyline') ) && ( $self->{_current_mode_descr} ne "freehand" && $self->{_current_mode_descr} ne "highlighter" && $self->{_current_mode_descr} ne "censor" ) ) { #embedded item? my $parent = $self->get_parent_item($item); $item = $parent if $parent; #real shape if ( exists $self->{_items}{$item} ) { #nothing here yet #canvas resizing shape } elsif ($self->{_canvas_bg_rect}{'right-side'} == $item || $self->{_canvas_bg_rect}{'bottom-side'} == $item || $self->{_canvas_bg_rect}{'bottom-right-corner'} == $item ) { my $pattern = $self->create_color( $self->{_style_bg}, 1 ); $item->set( 'fill-pattern' => $pattern ); #resizing shape } else { my $pattern = $self->create_color( $self->{_style_bg}, 1 ); $item->set( 'fill-pattern' => $pattern ); } } return TRUE; } sub create_stipple { my $self = shift; our @stipples; my ( $color_name, $stipple_data ) = @_; my $color = Gtk2::Gdk::Color->parse($color_name); $stipple_data->[2] = $stipple_data->[14] = $color->red >> 8; $stipple_data->[1] = $stipple_data->[13] = $color->green >> 8; $stipple_data->[0] = $stipple_data->[12] = $color->blue >> 8; my $stipple_str = join( '', map { chr } @$stipple_data ); push @stipples, \$stipple_str; # make $stipple_str refcnt increase my $surface = Cairo::ImageSurface->create_for_data( $stipple_str, 'argb32', 2, 2, 8 ); my $pattern = Cairo::SurfacePattern->create($surface); $pattern->set_extend('repeat'); return Goo::Cairo::Pattern->new($pattern); } sub create_alpha { my $self = shift; my $pattern = Cairo::SolidPattern->create_rgba( 0, 0, 0, 0 ); return Goo::Cairo::Pattern->new($pattern); } sub create_color { my $self = shift; my $color_name = shift; my $alpha = shift; return FALSE unless defined $color_name; return FALSE unless defined $alpha; my $color; #if it is a color, we do not need to parse it unless ( $color_name->isa('Gtk2::Gdk::Color') ) { $color = Gtk2::Gdk::Color->parse($color_name); } else { $color = $color_name; } my $pattern = Cairo::SolidPattern->create_rgba( $color->red / 257 / 255, $color->green / 257 / 255, $color->blue / 257 / 255, $alpha ); return Goo::Cairo::Pattern->new($pattern); } #ui related stuff sub setup_uimanager { my $self = shift; $self->{_factory} = Gtk2::IconFactory->new(); $self->{_factory}->add( 'shutter-ellipse', Gtk2::IconSet->new_from_pixbuf( Gtk2::Gdk::Pixbuf->new_from_file( $self->{_dicons} . '/draw-ellipse.png' ) ) ); $self->{_factory}->add( 'shutter-eraser', Gtk2::IconSet->new_from_pixbuf( Gtk2::Gdk::Pixbuf->new_from_file( $self->{_dicons} . '/draw-eraser.png' ) ) ); $self->{_factory}->add( 'shutter-freehand', Gtk2::IconSet->new_from_pixbuf( Gtk2::Gdk::Pixbuf->new_from_file( $self->{_dicons} . '/draw-freehand.png' ) ) ); $self->{_factory}->add( 'shutter-highlighter', Gtk2::IconSet->new_from_pixbuf( Gtk2::Gdk::Pixbuf->new_from_file( $self->{_dicons} . '/draw-highlighter.png' ) ) ); $self->{_factory}->add( 'shutter-pointer', Gtk2::IconSet->new_from_pixbuf( Gtk2::Gdk::Pixbuf->new_from_file( $self->{_dicons} . '/draw-pointer.png' ) ) ); $self->{_factory}->add( 'shutter-rectangle', Gtk2::IconSet->new_from_pixbuf( Gtk2::Gdk::Pixbuf->new_from_file( $self->{_dicons} . '/draw-rectangle.png' ) ) ); $self->{_factory}->add( 'shutter-line', Gtk2::IconSet->new_from_pixbuf( Gtk2::Gdk::Pixbuf->new_from_file( $self->{_dicons} . '/draw-line.png' ) ) ); $self->{_factory}->add( 'shutter-arrow', Gtk2::IconSet->new_from_pixbuf( Gtk2::Gdk::Pixbuf->new_from_file( $self->{_dicons} . '/draw-arrow.png' ) ) ); $self->{_factory}->add( 'shutter-text', Gtk2::IconSet->new_from_pixbuf( Gtk2::Gdk::Pixbuf->new_from_file( $self->{_dicons} . '/draw-text.png' ) ) ); $self->{_factory}->add( 'shutter-censor', Gtk2::IconSet->new_from_pixbuf( Gtk2::Gdk::Pixbuf->new_from_file( $self->{_dicons} . '/draw-censor.png' ) ) ); $self->{_factory}->add( 'shutter-pixelize', Gtk2::IconSet->new_from_pixbuf( Gtk2::Gdk::Pixbuf->new_from_file( $self->{_dicons} . '/draw-pixelize.png' ) ) ); $self->{_factory}->add( 'shutter-number', Gtk2::IconSet->new_from_pixbuf( Gtk2::Gdk::Pixbuf->new_from_file( $self->{_dicons} . '/draw-number.png' ) ) ); $self->{_factory}->add( 'shutter-crop', Gtk2::IconSet->new_from_pixbuf( Gtk2::Gdk::Pixbuf->new_from_file( $self->{_dicons} . '/transform-crop.png' ) ) ); #~ $self->{_factory}->add( 'shutter-mime-pdf', Gtk2::IconSet->new_from_pixbuf( Gtk2::Gdk::Pixbuf->new_from_file($self->{_dicons}.'/mime-pdf.svg') ) ); #~ $self->{_factory}->add( 'shutter-mime-svg', Gtk2::IconSet->new_from_pixbuf( Gtk2::Gdk::Pixbuf->new_from_file($self->{_dicons}.'/mime-svg.svg') ) ); $self->{_factory}->add_default(); my @main_actions = ( [ "File", undef, $self->{_d}->get("_File") ], [ "Edit", undef, $self->{_d}->get("_Edit") ], [ "Tools", undef, $self->{_d}->get("_Tools") ], [ "View", undef, $self->{_d}->get("_View") ], [ "Undo", 'gtk-undo', undef, "Z", $self->{_d}->get("Undo last action"), sub { $self->abort_current_mode; $self->xdo( 'undo', 'ui' ); } ], [ "Redo", 'gtk-redo', undef, "Y", $self->{_d}->get("Do again the last undone action"), sub { $self->abort_current_mode; $self->xdo( 'redo', 'ui' ); } ], [ "Copy", 'gtk-copy', undef, "C", $self->{_d}->get("Copy selection to clipboard"), sub { #clear clipboard $self->{_clipboard}->set_text(""); $self->{_cut} = FALSE; $self->{_current_copy_item} = $self->{_current_item}; } ], [ "Cut", 'gtk-cut', undef, "X", $self->{_d}->get("Cut selection to clipboard"), sub { #clear clipboard $self->{_clipboard}->set_text(""); $self->{_cut} = TRUE; $self->{_current_copy_item} = $self->{_current_item}; $self->clear_item_from_canvas( $self->{_current_copy_item} ); } ], [ "Paste", 'gtk-paste', undef, "V", $self->{_d}->get("Paste objects from clipboard"), sub { $self->paste_item( $self->{_current_copy_item}, $self->{_cut} ); $self->{_cut} = FALSE; } ], [ "Delete", 'gtk-delete', undef, "Delete", $self->{_d}->get("Delete current object"), sub { $self->clear_item_from_canvas( $self->{_current_item} ); } ], [ "Clear", 'gtk-clear', undef, "Delete", $self->{_d}->get("Clear canvas"), sub { #store items to delete in temporary hash #sort them uid my %time_hash; foreach ( keys %{ $self->{_items} } ) { next if ( exists $self->{_items}{$_}{image} && $self->{_items}{$_}{image} == $self->{_canvas_bg} ); $time_hash{ $self->{_items}{$_}{uid} } = $self->{_items}{$_}; } #delete items foreach ( sort keys %time_hash ) { $self->clear_item_from_canvas( $time_hash{$_} ); } } ], [ "Stop", 'gtk-stop', undef, "Escape", $self->{_d}->get("Abort current mode"), sub { $self->abort_current_mode; } ], [ "Close", 'gtk-close', undef, "Q", $self->{_d}->get("Close this window"), sub { $self->quit(TRUE); } ], [ "Save", 'gtk-save', undef, "S", $self->{_d}->get("Save image"), sub { $self->save(), $self->quit(FALSE); } ], [ "ExportTo", 'gtk-save-as', $self->{_d}->get("Export to _File..."), "E", $self->{_d}->get("Export to File..."), sub { $self->export_to_file(); } ], [ "ExportToSvg", undef, $self->{_d}->get("_Export to SVG..."), "V", $self->{_d}->get("Export to SVG..."), sub { $self->export_to_svg(); } ], [ "ExportToPdf", undef, $self->{_d}->get("E_xport to PDF..."), "P", $self->{_d}->get("Export to PDF..."), sub { $self->export_to_pdf(); } ], [ "ExportToPS", undef, $self->{_d}->get("Export to Post_Script..."), "S", $self->{_d}->get("Export to PostScript..."), sub { $self->export_to_ps(); } ], [ "ZoomIn", 'gtk-zoom-in', undef, "plus", undef, sub { $self->zoom_in_cb($self); } ], [ "ControlEqual", 'gtk-zoom-in', undef, "equal", undef, sub { $self->zoom_in_cb($self); } ], [ "ControlKpAdd", 'gtk-zoom-in', undef, "KP_Add", undef, sub { $self->zoom_in_cb($self); } ], [ "ZoomOut", 'gtk-zoom-out', undef, "minus", undef, sub { $self->zoom_out_cb($self); } ], [ "ControlKpSub", 'gtk-zoom-out', undef, "KP_Subtract", undef, sub { $self->zoom_out_cb($self); } ], [ "ZoomNormal", 'gtk-zoom-100', undef, "0", undef, sub { $self->zoom_normal_cb($self); } ], ); my @toggle_actions = ( [ "Autoscroll", undef, $self->{_d}->get("Automatic scrolling"), undef, undef, sub { my $widget = shift; if ( $widget->get_active ) { $self->{_autoscroll} = TRUE; } else { $self->{_autoscroll} = FALSE; } #'redraw-when-scrolled' to reduce the flicker of static items # #this property is not available in older versions #it was added to goocanvas on Mon Nov 17 10:28:07 2008 UTC #http://svn.gnome.org/viewvc/goocanvas?view=revision&revision=28 if ( $self->{_canvas} && $self->{_canvas}->find_property('redraw-when-scrolled') ) { $self->{_canvas}->set( 'redraw-when-scrolled' => !$self->{_autoscroll} ); } } ], [ "Fullscreen", 'gtk-fullscreen', undef, "F11", undef, sub { my $action = shift; if ( $action->get_active ) { $self->{_drawing_window}->fullscreen; } else { $self->{_drawing_window}->unfullscreen; } } ] ); my @drawing_actions = ( [ "Select", 'shutter-pointer', $self->{_d}->get("Select"), "0", $self->{_d}->get("Select item to move or resize it"), 10 ], [ "Freehand", 'shutter-freehand', $self->{_d}->get("Freehand"), "1", $self->{_d}->get("Draw a freehand line"), 20 ], [ "Highlighter", 'shutter-highlighter', $self->{_d}->get("Highlighter"), "2", $self->{_d}->get("Highlighter"), 30 ], [ "Line", 'shutter-line', $self->{_d}->get("Line"), "3", $self->{_d}->get("Draw a straight line"), 40 ], [ "Arrow", 'shutter-arrow', $self->{_d}->get("Arrow"), "4", $self->{_d}->get("Draw an arrow"), 50 ], [ "Rect", 'shutter-rectangle', $self->{_d}->get("Rectangle"), "5", $self->{_d}->get("Draw a rectangle"), 60 ], [ "Ellipse", 'shutter-ellipse', $self->{_d}->get("Ellipse"), "6", $self->{_d}->get("Draw a ellipse"), 70 ], [ "Text", 'shutter-text', $self->{_d}->get("Text"), "7", $self->{_d}->get("Add some text to the screenshot"), 80 ], [ "Censor", 'shutter-censor', $self->{_d}->get("Censor"), "8", $self->{_d}->get("Censor portions of your screenshot to hide private data"), 90 ], [ "Pixelize", 'shutter-pixelize', $self->{_d}->get("Pixelize"), "8", $self->{_d}->get("Pixelize selected areas of your screenshot to hide private data"), 100 ], [ "Number", 'shutter-number', $self->{_d}->get("Number"), "9", $self->{_d}->get("Add an auto-increment shape to the screenshot"), 110 ], [ "Crop", 'shutter-crop', $self->{_d}->get("Crop"), "c", $self->{_d}->get("Crop your screenshot"), 120 ] ); my $uimanager = Gtk2::UIManager->new(); #keyboard accel_group my $accelgroup = $uimanager->get_accel_group; $self->{_drawing_window}->add_accel_group($accelgroup); # Setup the main group. my $main_group = Gtk2::ActionGroup->new("main"); $main_group->add_actions( \@main_actions ); #setup the menu toggle group my $toggle_group = Gtk2::ActionGroup->new("toggle"); $toggle_group->add_toggle_actions( \@toggle_actions ); # Setup the drawing group. my $drawing_group = Gtk2::ActionGroup->new("drawing"); $drawing_group->add_radio_actions( \@drawing_actions, 10, sub { my $action = shift; $self->change_drawing_tool_cb($action); } ); $uimanager->insert_action_group( $main_group, 0 ); $uimanager->insert_action_group( $toggle_group, 0 ); $uimanager->insert_action_group( $drawing_group, 0 ); my $ui_info = " "; eval { $uimanager->add_ui_from_string($ui_info) }; if ($@) { die "Unable to create menus: $@\n"; } return $uimanager; } sub import_from_dnd { my ( $self, $widget, $context, $x, $y, $selection, $info, $time ) = @_; my $type = $selection->target->name; my $data = $selection->data; return unless $type eq 'text/uri-list'; my @files = grep defined($_), split /[\r\n]+/, $data; my @valid_files; foreach (@files) { my $mime_type = Gnome2::VFS->get_mime_type_for_name($_); if ( $mime_type && $self->check_valid_mime_type($mime_type) ) { push @valid_files, $_; } } #open all valid files if (@valid_files) { #backup current pixbuf and filename my $old_current = $self->{_current_pixbuf}; my $old_filename = $self->{_current_pixbuf_filename}; foreach (@valid_files) { #transform uri to path my $new_uri = Gnome2::VFS::URI->new( $self->utf8_decode( Gnome2::VFS->unescape_string($_) ) ); my $new_file = $self->utf8_decode( Gnome2::VFS->unescape_string( $new_uri->get_path ) ); $self->{_current_pixbuf} = $self->{_lp}->load( $new_file, undef, undef, undef, TRUE ); if ( $self->{_current_pixbuf} ) { $self->{_current_pixbuf_filename} = $new_file; #construct an event and create a new image object my $initevent = Gtk2::Gdk::Event->new('motion-notify'); $initevent->set_time( Gtk2->get_current_event_time ); $initevent->window( $self->{_drawing_window}->window ); $initevent->x($x); $initevent->y($y); #new item my $nitem = $self->create_image( $initevent, undef, TRUE ); #add to undo stack $self->store_to_xdo_stack( $nitem, 'create', 'undo' ); } else { $self->abort_current_mode; } } #restore saved values $self->{_current_pixbuf} = $old_current; $self->{_current_pixbuf_filename} = $old_filename; #uncheck previous active item $self->{_current_new_item} = undef; } else { $context->finish( 0, 0, $time ); return FALSE; } $context->finish( 1, 0, $time ); return TRUE; } sub utf8_decode { my $self = shift; my $string = shift; #see https://bugs.launchpad.net/shutter/+bug/347821 utf8::decode $string; return $string; } sub check_valid_mime_type { my $self = shift; my $mime_type = shift; foreach ( Gtk2::Gdk::Pixbuf->get_formats ) { foreach ( @{ $_->{mime_types} } ) { return TRUE if $_ eq $mime_type; last; } } return FALSE; } sub import_from_filesystem { my $self = shift; my $button = shift; #used when called recursively my $parent = shift; my $directory = shift; my $menu_objects = Gtk2::Menu->new; my $dobjects = $directory || $self->{_sc}->get_root . "/share/shutter/resources/icons/drawing_tool/objects"; #first directory flag (see description above) my $fd = TRUE; my $ff = FALSE; my @objects = glob("$dobjects/*"); foreach my $name ( sort { -d $a <=> -d $b } @objects ) { #parse filename my ( $short, $folder, $type ) = fileparse( $name, qr/\.[^.]*/ ); #if current object is a directory we call the current sub #recursively if ( -d $name ) { #objects from each directory are sorted (files first) #we display a separator when the first directory is listed if ( $fd && $ff ) { $menu_objects->append( Gtk2::SeparatorMenuItem->new ); $fd = FALSE; } #objects from directory $name my $subdir_item = Gtk2::ImageMenuItem->new_with_label($short); $subdir_item->set( 'always_show_image' => TRUE ) if Gtk2->CHECK_VERSION( 2, 16, 0 ); $subdir_item->set_image( Gtk2::Image->new_from_stock( 'gtk-directory', 'menu' ) ); #add empty menu first my $menu_empty = Gtk2::Menu->new; my $empty_item = Gtk2::MenuItem->new_with_label( $self->{_d}->get("No icon was found") ); $empty_item->set_sensitive(FALSE); $menu_empty->append($empty_item); $subdir_item->set_submenu($menu_empty); #and populate later (performance) $subdir_item->{'nid'} = $subdir_item->signal_connect( 'activate' => sub { $subdir_item->set_image( Gtk2::Image->new_from_file( $self->{_icons} . "/throbber_16x16.gif" ) ); my $submenu = $self->import_from_filesystem( $button, $subdir_item, $dobjects . "/$short" ); if ( $submenu->get_children ) { $subdir_item->set_submenu($submenu); } else { $subdir_item->set_image( Gtk2::Image->new_from_stock( 'gtk-directory', 'menu' ) ); } return TRUE; } ); #diconnect handler when this event occurs $subdir_item->signal_connect( 'leave-notify-event' => sub { if ( $subdir_item->signal_handler_is_connected( $subdir_item->{'nid'} ) ) { $subdir_item->signal_handler_disconnect( $subdir_item->{'nid'} ); } } ); $menu_objects->append($subdir_item); next; } #there is at least one single file #set the flag $ff = TRUE; #init item with filename first my $new_item = Gtk2::ImageMenuItem->new_with_label($short); $new_item->set( 'always_show_image' => TRUE ) if Gtk2->CHECK_VERSION( 2, 16, 0 ); $menu_objects->append($new_item); #sfsdc $new_item->{'name'} = $name; } #do not do that when called recursively #top level call unless ($directory) { $menu_objects->append( Gtk2::SeparatorMenuItem->new ); #objects from icontheme if ( Gtk2->CHECK_VERSION( 2, 12, 0 ) ) { my $icontheme = Gtk2::IconTheme->get_default; my $utheme_item = Gtk2::ImageMenuItem->new_with_label( $self->{_d}->get("Import from current theme...") ); $utheme_item->set( 'always_show_image' => TRUE ) if Gtk2->CHECK_VERSION( 2, 16, 0 ); if ( $icontheme->has_icon('preferences-desktop-theme') ) { $utheme_item->set_image( Gtk2::Image->new_from_icon_name( 'preferences-desktop-theme', 'menu' ) ); } $utheme_item->set_submenu( $self->import_from_utheme( $icontheme, $button ) ); $menu_objects->append($utheme_item); $menu_objects->append( Gtk2::SeparatorMenuItem->new ); } #objects from session my $session_menu_item = Gtk2::ImageMenuItem->new_with_label( $self->{_d}->get("Import from session...") ); $session_menu_item->set( 'always_show_image' => TRUE ) if Gtk2->CHECK_VERSION( 2, 16, 0 ); $session_menu_item->set_image( Gtk2::Image->new_from_stock( 'gtk-index', 'menu' ) ); $session_menu_item->set_submenu( $self->import_from_session($button) ); #gen thumbnails in an idle callback $self->gen_thumbnail_on_idle( 'gtk-index', $session_menu_item, $button, TRUE, $session_menu_item->get_submenu->get_children ); $menu_objects->append($session_menu_item); #objects from filesystem my $filesystem_menu_item = Gtk2::ImageMenuItem->new_with_label( $self->{_d}->get("Import from filesystem...") ); $filesystem_menu_item->set( 'always_show_image' => TRUE ) if Gtk2->CHECK_VERSION( 2, 16, 0 ); $filesystem_menu_item->set_image( Gtk2::Image->new_from_stock( 'gtk-open', 'menu' ) ); $filesystem_menu_item->signal_connect( 'activate' => sub { my $fs = Gtk2::FileChooserDialog->new( $self->{_d}->get("Choose file to open"), $self->{_drawing_window}, 'open', 'gtk-cancel' => 'reject', 'gtk-open' => 'accept' ); $fs->set_select_multiple(FALSE); #preview widget my $iprev = Gtk2::Image->new; $fs->set_preview_widget($iprev); $fs->signal_connect( 'selection-changed' => sub { if ( my $pfilename = $fs->get_preview_filename ) { my $pixbuf = $self->{_lp_ne}->load( $pfilename, 200, 200, TRUE, TRUE ); unless ($pixbuf) { $fs->set_preview_widget_active(FALSE); } else { $fs->get_preview_widget->set_from_pixbuf($pixbuf); $fs->set_preview_widget_active(TRUE); } } else { $fs->set_preview_widget_active(FALSE); } } ); my $filter_all = Gtk2::FileFilter->new; $filter_all->set_name( $self->{_d}->get("All compatible image formats") ); $fs->add_filter($filter_all); foreach ( Gtk2::Gdk::Pixbuf->get_formats ) { my $filter = Gtk2::FileFilter->new; $filter->set_name( $_->{name} . " - " . $_->{description} ); foreach ( @{ $_->{extensions} } ) { $filter->add_pattern( "*." . uc $_ ); $filter_all->add_pattern( "*." . uc $_ ); $filter->add_pattern( "*." . $_ ); $filter_all->add_pattern( "*." . $_ ); } $fs->add_filter($filter); } if ( $ENV{'HOME'} ) { $fs->set_current_folder( $ENV{'HOME'} ); } my $fs_resp = $fs->run; my $new_file; if ( $fs_resp eq "accept" ) { $new_file = $fs->get_filenames; $self->{_current_pixbuf} = $self->{_lp}->load( $new_file, undef, undef, undef, TRUE ); if ( $self->{_current_pixbuf} ) { $self->{_current_pixbuf_filename} = $new_file; $button->set_icon_widget( Gtk2::Image->new_from_pixbuf( Gtk2::Gdk::Pixbuf->new_from_file_at_size( $self->{_dicons} . '/draw-image.svg', Gtk2::IconSize->lookup('menu') ) ) ); $button->show_all; $self->{_canvas}->window->set_cursor( $self->change_cursor_to_current_pixbuf ); } else { $self->abort_current_mode; } $fs->destroy(); } else { $fs->destroy(); } } ); $menu_objects->append($filesystem_menu_item); } $button->show_all; $menu_objects->show_all; #generate thumbnails in an idle callback $self->gen_thumbnail_on_idle( 'gtk-directory', $parent, $button, FALSE, $menu_objects->get_children ); return $menu_objects; } sub import_from_utheme { my $self = shift; my $icontheme = shift; my $button = shift; my $menu_ctxt = Gtk2::Menu->new; foreach my $context ( sort $icontheme->list_contexts ) { #objects from current theme (contexts) my $utheme_ctxt = Gtk2::ImageMenuItem->new_with_label($context); $utheme_ctxt->set( 'always_show_image' => TRUE ) if Gtk2->CHECK_VERSION( 2, 16, 0 ); $utheme_ctxt->set_image( Gtk2::Image->new_from_stock( 'gtk-directory', 'menu' ) ); #add empty menu first my $menu_empty = Gtk2::Menu->new; my $empty_item = Gtk2::MenuItem->new_with_label( $self->{_d}->get("No icon was found") ); $empty_item->set_sensitive(FALSE); $menu_empty->append($empty_item); $utheme_ctxt->set_submenu($menu_empty); #and populate later (performance) my @menu_items; $utheme_ctxt->{'nid'} = $utheme_ctxt->signal_connect( 'activate' => sub { $utheme_ctxt->set_image( Gtk2::Image->new_from_file( $self->{_icons} . "/throbber_16x16.gif" ) ); my $context_submenu = $self->import_from_utheme_ctxt( $icontheme, $context, $button ); if ( $context_submenu->get_children ) { $utheme_ctxt->set_submenu($context_submenu); #gen thumbnails in an idle callback $self->gen_thumbnail_on_idle( 'gtk-directory', $utheme_ctxt, $button, TRUE, $utheme_ctxt->get_submenu->get_children ); } else { $utheme_ctxt->set_image( Gtk2::Image->new_from_stock( 'gtk-directory', 'menu' ) ); } return TRUE; } ); #disconnect handler when this event occurs $utheme_ctxt->signal_connect( 'leave-notify-event' => sub { if ( $utheme_ctxt->signal_handler_is_connected( $utheme_ctxt->{'nid'} ) ) { $utheme_ctxt->signal_handler_disconnect( $utheme_ctxt->{'nid'} ); } } ); $menu_ctxt->append($utheme_ctxt); } $menu_ctxt->show_all; return $menu_ctxt; } sub import_from_utheme_ctxt { my $self = shift; my $icontheme = shift; my $context = shift; my $button = shift; my $menu_ctxt_items = Gtk2::Menu->new; my $size = Gtk2::IconSize->lookup('dialog'); foreach my $icon ( sort $icontheme->list_icons($context) ) { #objects from current theme (icons for specific contexts) my $utheme_ctxt_item = Gtk2::ImageMenuItem->new_with_label($icon); $utheme_ctxt_item->set( 'always_show_image' => TRUE ) if Gtk2->CHECK_VERSION( 2, 16, 0 ); my $iconinfo = $icontheme->lookup_icon( $icon, $size, 'generic-fallback' ); #save filename and generate thumbnail later #idle callback $utheme_ctxt_item->{'name'} = $iconinfo->get_filename; $menu_ctxt_items->append($utheme_ctxt_item); } $menu_ctxt_items->show_all; return $menu_ctxt_items; } sub import_from_session { my $self = shift; my $button = shift; my $menu_session_objects = Gtk2::Menu->new; my %import_hash = %{ $self->{_import_hash} }; foreach my $key ( Sort::Naturally::nsort( keys %import_hash ) ) { next unless exists $import_hash{$key}->{'short'}; next unless defined $import_hash{$key}->{'short'}; #init item with filename my $screen_menu_item = Gtk2::ImageMenuItem->new_with_label( $import_hash{$key}->{'short'} ); $screen_menu_item->set( 'always_show_image' => TRUE ) if Gtk2->CHECK_VERSION( 2, 16, 0 ); #set sensitive == FALSE if image eq current file $screen_menu_item->set_sensitive(FALSE) if $import_hash{$key}->{'long'} eq $self->{_filename}; #save filename and attributes $screen_menu_item->{'name'} = $import_hash{$key}->{'long'}; $screen_menu_item->{'mime_type'} = $import_hash{$key}->{'mime_type'}; $screen_menu_item->{'mtime'} = $import_hash{$key}->{'mtime'}; $screen_menu_item->{'uri'} = $import_hash{$key}->{'uri'}; $screen_menu_item->{'no_thumbnail'} = $import_hash{$key}->{'no_thumbnail'}; $menu_session_objects->append($screen_menu_item); } $menu_session_objects->show_all; return $menu_session_objects; } sub gen_thumbnail_on_idle { my $self = shift; my $stock = shift; my $parent = shift; my $button = shift; my $no_init = shift; my @menu_items = @_; #generate thumbnails in an idle callback my $next_item = 0; Glib::Idle->add( sub { #get next item my $child = $menu_items[$next_item]; #no valid item - stop the idle handler unless ($child) { $parent->set_image( Gtk2::Image->new_from_stock( $stock, 'menu' ) ) if $parent; return FALSE; } my $name = $child->{'name'}; #no valid item - stop the idle handler unless ($name) { $parent->set_image( Gtk2::Image->new_from_stock( $stock, 'menu' ) ) if $parent; return FALSE; } #increment counter $next_item++; #create thumbnail my $small_image; eval { #if uri exists we generate a thumbnail #with Shutter::Pixbuf::Thumbnail if ( exists $child->{'uri'} ) { my $thumb; unless ( $child->{'no_thumbnail'} ) { $thumb = $self->{_thumbs}->get_thumbnail( $child->{'uri'}->to_string, $child->{'mime_type'}, $child->{'mtime'}, 0.2 ); } else { $thumb = Gtk2::Gdk::Pixbuf->new( 'rgb', TRUE, 8, 5, 5 ); $thumb->fill(0x00000000); } $small_image = Gtk2::Image->new_from_pixbuf($thumb); } else { my $pixbuf = $self->{_lp_ne}->load( $name, undef, undef, undef, TRUE ); #16x16 is minimum size if ( $pixbuf->get_width >= 16 && $pixbuf->get_height >= 16 ) { $small_image = Gtk2::Image->new_from_pixbuf( $pixbuf->scale_down_pixbuf( Gtk2::IconSize->lookup('menu') ) ); } } }; unless ($@) { if ($small_image) { $child->set_image($small_image); #init when toplevel unless ($no_init) { unless ( $button->get_icon_widget ) { $button->set_icon_widget( Gtk2::Image->new_from_pixbuf( $small_image->get_pixbuf ) ); $self->{_current_pixbuf_filename} = $name; $button->show_all; } } $child->signal_connect( 'activate' => sub { $self->{_current_pixbuf_filename} = $name; $button->set_icon_widget( Gtk2::Image->new_from_pixbuf( $small_image->get_pixbuf ) ); $button->show_all; $self->{_canvas}->window->set_cursor( $self->change_cursor_to_current_pixbuf ); } ); } else { $child->destroy; } } else { $child->destroy; } return TRUE; } ); #end idle callback } sub set_drawing_action { my $self = shift; my $index = shift; #~ print "set_drawing_action\n"; my $item_index = 0; my $toolbar = $self->{_uimanager}->get_widget("/ToolBarDrawing"); for ( my $i = 0 ; $i < $toolbar->get_n_items ; $i++ ) { my $item = $toolbar->get_nth_item($i); #skip separators #we only want to activate tools next if $item->isa('Gtk2::SeparatorToolItem'); #add 1 to item index $item_index++; if ( $item_index == $index ) { if ( $item->get_active ) { $self->change_drawing_tool_cb( $item_index * 10 ); } else { $item->set_active(TRUE); } last; } } } sub change_cursor_to_current_pixbuf { my $self = shift; #~ print "change_cursor_to_current_pixbuf\n"; $self->{_current_mode_descr} = "image"; my $cursor = undef; #load file $self->{_current_pixbuf} = $self->{_lp}->load( $self->{_current_pixbuf_filename}, undef, undef, undef, TRUE ); unless ( $self->{_current_pixbuf} ) { $cursor = Gtk2::Gdk::Cursor->new_from_pixbuf( Gtk2::Gdk::Display->get_default, Gtk2::Gdk::Pixbuf->new_from_file( $self->{_dicons} . '/draw-image.svg' ), Gtk2::IconSize->lookup('menu') ); } #very big images usually don't work as a cursor (no error though??) my $pb_w = $self->{_current_pixbuf}->get_width; my $pb_h = $self->{_current_pixbuf}->get_height; if ( $pb_w < 800 && $pb_h < 800 ) { eval { #maximum cursor size my ( $cw, $ch ) = Gtk2::Gdk::Display->get_default->get_maximal_cursor_size; #images smaller than max cursor size? # => don't scale to a bigger size if ( $cw > $pb_w || $ch > $pb_w ) { $cursor = Gtk2::Gdk::Cursor->new_from_pixbuf( Gtk2::Gdk::Display->get_default, $self->{_current_pixbuf}, int( $pb_w / 2 ), int( $pb_h / 2 ) ); } else { my $cpixbuf = $self->{_lp}->load( $self->{_current_pixbuf_filename}, $cw, $ch, TRUE, TRUE ); $cursor = Gtk2::Gdk::Cursor->new_from_pixbuf( Gtk2::Gdk::Display->get_default, $cpixbuf, int( $cpixbuf->get_width / 2 ), int( $cpixbuf->get_height / 2 ) ); } }; if ($@) { my $response = $self->{_dialogs}->dlg_error_message( sprintf( $self->{_d}->get("Error while opening image %s."), "'" . $self->{_current_pixbuf_filename} . "'" ), $self->{_d}->get("There was an error opening the image."), undef, undef, undef, undef, undef, undef, $@ ); $self->abort_current_mode; } } else { $cursor = Gtk2::Gdk::Cursor->new_from_pixbuf( Gtk2::Gdk::Display->get_default, Gtk2::Gdk::Pixbuf->new_from_file( $self->{_dicons} . '/draw-image.svg' ), Gtk2::IconSize->lookup('menu') ); } return $cursor; } sub paste_item { my $self = shift; my $item = shift; #cut instead of copy my $delete_after = shift; #import from system's clipboard if ( my $image = $self->{_clipboard}->wait_for_image ) { #backup current pixbuf and filename my $old_current = $self->{_current_pixbuf}; my $old_filename = $self->{_current_pixbuf_filename}; #create tempfile my ( $tmpfh, $tmpfilename ) = tempfile( UNLINK => 1 ); #save pixbuf to tempfile and integrate it my $pixbuf_save = Shutter::Pixbuf::Save->new( $self->{_sc}, $self->{_drawing_window} ); if ( $pixbuf_save->save_pixbuf_to_file( $image, $tmpfilename, 'png' ) ) { #set pixbuf vars $self->{_current_pixbuf} = $image; $self->{_current_pixbuf_filename} = $tmpfilename; #construct an event and create a new image object my $initevent = Gtk2::Gdk::Event->new('motion-notify'); $initevent->set_time( Gtk2->get_current_event_time ); $initevent->window( $self->{_drawing_window}->window ); #calculate coordinates $initevent->x( int( $self->{_canvas_bg_rect}->get('width') / 2 ) ); $initevent->y( int( $self->{_canvas_bg_rect}->get('height') / 2 ) ); #new item my $nitem = $self->create_image( $initevent, undef, TRUE ); #add to undo stack $self->store_to_xdo_stack( $nitem, 'create', 'undo' ); #restore saved values $self->{_current_pixbuf} = $old_current; $self->{_current_pixbuf_filename} = $old_filename; #uncheck $self->{_current_new_item} = undef; $self->{_current_item} = undef; $self->{_current_copy_item} = undef; } #import from DrawingTool's clipboard } elsif ( defined $item ) { my $child = $self->get_child_item($item); my $new_item = undef; if ( $item->isa('Goo::Canvas::Rect') && !$child ) { #~ print "Creating Rectangle...\n"; $new_item = $self->create_rectangle( undef, $item ); } elsif ( $item->isa('Goo::Canvas::Polyline') && !$child ) { #~ print "Creating Polyline...\n"; $new_item = $self->create_polyline( undef, $item ); } elsif ( $child->isa('Goo::Canvas::Polyline') && exists $self->{_items}{$item}{stroke_color} ) { #~ print "Creating Line...\n"; $new_item = $self->create_line( undef, $item ); } elsif ( $child->isa('Goo::Canvas::Polyline') ) { #~ print "Creating Censor...\n"; $new_item = $self->create_censor( undef, $item ); } elsif ( $child->isa('Goo::Canvas::Ellipse') ) { #~ print "Creating Ellipse...\n"; $new_item = $self->create_ellipse( undef, $item ); } elsif ( $child->isa('Goo::Canvas::Text') ) { #~ print "Creating Text...\n"; $new_item = $self->create_text( undef, $item ); } elsif ( $child->isa('Goo::Canvas::Image') && exists $self->{_items}{$item}{pixelize} ) { #~ print "Creating Pixelize...\n"; $new_item = $self->create_pixel_image( undef, $item ); } elsif ( $child->isa('Goo::Canvas::Image') ) { #~ print "Creating Image...\n"; $new_item = $self->create_image( undef, $item ); } #cut instead of copy if ($delete_after) { $self->clear_item_from_canvas($item); $self->{_current_item} = undef; $self->{_current_copy_item} = undef; } #add to undo stack $self->store_to_xdo_stack( $new_item, 'create', 'undo' ); } return TRUE; } sub create_polyline { my $self = shift; my $ev = shift; my $copy_item = shift; #this is a highlighter? #we need different default values in this case my $highlighter = shift; my @points = (); my $stroke_pattern = $self->create_color( $self->{_stroke_color}, $self->{_stroke_color_alpha} ); my $transform; my $line_width = $self->{_line_width}; #use event coordinates if ($ev) { @points = ( $ev->x, $ev->y, $ev->x, $ev->y ); #use source item coordinates } elsif ($copy_item) { foreach ( @{ $self->{_items}{$copy_item}{points} } ) { push @points, $_ + 20; } $stroke_pattern = $self->create_color( $self->{_items}{$copy_item}{stroke_color}, $self->{_items}{$copy_item}{stroke_color_alpha} ); $transform = $self->{_items}{$copy_item}->get('transform'); $line_width = $self->{_items}{$copy_item}->get('line_width'); } my $item = undef; if ($highlighter) { $item = Goo::Canvas::Polyline->new_line( $self->{_canvas}->get_root_item, $points[0], $points[1], $points[2], $points[3], 'stroke-pattern' => $self->create_color( Gtk2::Gdk::Color->parse('#FFFF00'), 0.5 ), 'line-width' => 18, 'fill-rule' => 'CAIRO_FILL_RULE_EVEN_ODD', 'line-cap' => 'CAIRO_LINE_CAP_SQUARE', 'line-join' => 'CAIRO_LINE_JOIN_BEVEL', ); } else { $item = Goo::Canvas::Polyline->new_line( $self->{_canvas}->get_root_item, $points[0], $points[1], $points[2], $points[3], 'stroke-pattern' => $stroke_pattern, 'line-width' => $line_width, 'line-cap' => 'CAIRO_LINE_CAP_ROUND', 'line-join' => 'CAIRO_LINE_JOIN_ROUND', ); } $self->{_current_new_item} = $item unless ($copy_item); $self->{_items}{$item} = $item; #need at least 2 points push @{ $self->{_items}{$item}{'points'} }, @points; $self->{_items}{$item}->set( points => Goo::Canvas::Points->new( $self->{_items}{$item}{'points'} ) ); $self->{_items}{$item}->set( transform => $transform ) if $transform; if ($highlighter) { #set type flag $self->{_items}{$item}{type} = 'highlighter'; $self->{_items}{$item}{uid} = $self->{_uid}++; $self->{_items}{$item}{stroke_color} = Gtk2::Gdk::Color->parse('#FFFF00'); $self->{_items}{$item}{stroke_color_alpha} = 0.5; } else { #set type flag $self->{_items}{$item}{type} = 'freehand'; $self->{_items}{$item}{uid} = $self->{_uid}++; $self->{_items}{$item}{stroke_color} = $self->{_stroke_color}; $self->{_items}{$item}{stroke_color_alpha} = $self->{_stroke_color_alpha}; } $self->setup_item_signals( $self->{_items}{$item} ); $self->setup_item_signals_extra( $self->{_items}{$item} ); return $item; } sub create_censor { my $self = shift; my $ev = shift; my $copy_item = shift; my @points = (); my $transform; #use event coordinates if ($ev) { @points = ( $ev->x, $ev->y, $ev->x, $ev->y ); #use source item coordinates } elsif ($copy_item) { foreach ( @{ $self->{_items}{$copy_item}{points} } ) { push @points, $_ + 20; } $transform = $self->{_items}{$copy_item}->get('transform'); } my @stipple_data = ( 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255 ); my $stroke_pattern = $self->create_stipple( 'black', \@stipple_data ); my $item = Goo::Canvas::Polyline->new_line( $self->{_canvas}->get_root_item, $points[0], $points[1], $points[2], $points[3], 'stroke-pattern' => $stroke_pattern, 'line-width' => 14, 'line-cap' => 'CAIRO_LINE_CAP_ROUND', 'line-join' => 'CAIRO_LINE_JOIN_ROUND', ); $self->{_current_new_item} = $item unless ($copy_item); $self->{_items}{$item} = $item; #set type flag $self->{_items}{$item}{type} = 'censor'; $self->{_items}{$item}{uid} = $self->{_uid}++; #need at least 2 points push @{ $self->{_items}{$item}{'points'} }, @points; $self->{_items}{$item}->set( points => Goo::Canvas::Points->new( $self->{_items}{$item}{'points'} ) ); $self->{_items}{$item}->set( transform => $transform ) if $transform; $self->setup_item_signals( $self->{_items}{$item} ); $self->setup_item_signals_extra( $self->{_items}{$item} ); return $item; } sub create_pixel_image { my $self = shift; my $ev = shift; my $copy_item = shift; my @dimensions = ( 0, 0, 0, 0 ); #use event coordinates and selected color if ($ev) { @dimensions = ( $ev->x, $ev->y, 0, 0 ); #use source item coordinates and item color } elsif ($copy_item) { @dimensions = ( $copy_item->get('x') + 20, $copy_item->get('y') + 20, $copy_item->get('width'), $copy_item->get('height') ); } my $pattern = $self->create_alpha; my $item = Goo::Canvas::Rect->new( $self->{_canvas}->get_root_item, @dimensions, 'fill-pattern' => $pattern, 'line-dash' => Goo::Canvas::LineDash->new( [ 5, 5 ] ), 'line-width' => 1, 'stroke-color' => 'gray', ); $self->{_current_new_item} = $item unless ($copy_item); $self->{_items}{$item} = $item; #blank pixbuf my $blank = Gtk2::Gdk::Pixbuf->new( 'rgb', TRUE, 8, 2, 2 ); #whole pixbuf is transparent $blank->fill(0x00000000); $self->{_items}{$item}{pixelize} = Goo::Canvas::Image->new( $self->{_canvas}->get_root_item, $blank, $item->get('x'), $item->get('y'), 'width' => 2, 'height' => 2, ); #set type flag $self->{_items}{$item}{type} = 'pixelize'; $self->{_items}{$item}{uid} = $self->{_uid}++; #create rectangles $self->handle_rects( 'create', $item ); if ($copy_item) { $self->{_items}{$item}{pixelize}->set( 'x' => int $self->{_items}{$item}->get('x'), 'y' => int $self->{_items}{$item}->get('y'), 'width' => $self->{_items}{$item}->get('width'), 'height' => $self->{_items}{$item}->get('height'), 'pixbuf' => $self->get_pixelated_pixbuf_from_canvas( $self->{_items}{$item} ), ); $self->handle_embedded( 'update', $item, undef, undef, TRUE ); } $self->setup_item_signals( $self->{_items}{$item}{pixelize} ); $self->setup_item_signals_extra( $self->{_items}{$item}{pixelize} ); $self->setup_item_signals( $self->{_items}{$item} ); $self->setup_item_signals_extra( $self->{_items}{$item} ); return $item; } sub create_image { my $self = shift; my $ev = shift; my $copy_item = shift; my $force_orig_size_init = shift; my @dimensions = ( 0, 0, 0, 0 ); #use event coordinates if ($ev) { #we create the new image item #and use the original image size #dnd for example if ($force_orig_size_init) { @dimensions = ( $ev->x - int( $self->{_current_pixbuf}->get_width / 2 ), $ev->y - int( $self->{_current_pixbuf}->get_height / 2 ), $self->{_current_pixbuf}->get_width, $self->{_current_pixbuf}->get_height ); } else { @dimensions = ( $ev->x, $ev->y, 0, 0 ); } #use source item coordinates } elsif ($copy_item) { @dimensions = ( $copy_item->get('x') + 20, $copy_item->get('y') + 20, $self->{_items}{$copy_item}->get('width'), $self->{_items}{$copy_item}->get('height') ); } my $pattern = $self->create_alpha; my $item = Goo::Canvas::Rect->new( $self->{_canvas}->get_root_item, @dimensions, 'fill-pattern' => $pattern, 'line-dash' => Goo::Canvas::LineDash->new( [ 5, 5 ] ), 'line-width' => 1, 'stroke-color' => 'gray', ); $self->{_current_new_item} = $item unless ($copy_item); $self->{_items}{$item} = $item; if ($ev) { $self->{_items}{$item}{orig_pixbuf} = $self->{_current_pixbuf}->copy; $self->{_items}{$item}{orig_pixbuf_filename} = $self->{_current_pixbuf_filename}; } elsif ($copy_item) { $self->{_items}{$item}{orig_pixbuf} = $self->{_items}{$copy_item}{orig_pixbuf}->copy; $self->{_items}{$item}{orig_pixbuf_filename} = $self->{_items}{$copy_item}{orig_pixbuf_filename}; } $self->{_items}{$item}{image} = Goo::Canvas::Image->new( $self->{_canvas}->get_root_item, $self->{_items}{$item}{orig_pixbuf}, $item->get('x'), $item->get('y'), 'width' => 2, 'height' => 2, ); #set type flag $self->{_items}{$item}{type} = 'image'; $self->{_items}{$item}{uid} = $self->{_uid}++; #create rectangles $self->handle_rects( 'create', $item ); #show image directly when copy or dnd if ( $copy_item || $force_orig_size_init ) { $self->handle_embedded( 'update', $item ); } $self->setup_item_signals( $self->{_items}{$item}{image} ); $self->setup_item_signals_extra( $self->{_items}{$item}{image} ); $self->setup_item_signals( $self->{_items}{$item} ); $self->setup_item_signals_extra( $self->{_items}{$item} ); if ($copy_item) { my $copy = $self->{_lp}->load( $self->{_items}{$item}{orig_pixbuf_filename}, $self->{_items}{$item}->get('width'), $self->{_items}{$item}->get('height'), FALSE, TRUE ); $self->{_items}{$item}{image}->set( 'x' => int $self->{_items}{$item}->get('x'), 'y' => int $self->{_items}{$item}->get('y'), 'pixbuf' => $copy ); $self->handle_rects( 'hide', $item ); } return $item; } sub create_text { my $self = shift; my $ev = shift; my $copy_item = shift; my @dimensions = ( 0, 0, 0, 0 ); my $stroke_pattern = $self->create_color( $self->{_stroke_color}, $self->{_stroke_color_alpha} ); my $text = $self->{_d}->get('New text...'); my $line_width = $self->{_line_width}; #use event coordinates and selected color if ($ev) { @dimensions = ( $ev->x, $ev->y, 0, 0 ); #use source item coordinates and item color } elsif ($copy_item) { @dimensions = ( $copy_item->get('x') + 20, $copy_item->get('y') + 20, $copy_item->get('width'), $copy_item->get('height') ); $stroke_pattern = $self->create_color( $self->{_items}{$copy_item}{stroke_color}, $self->{_items}{$copy_item}{stroke_color_alpha} ); $text = $self->{_items}{$copy_item}{text}->get('text'); $line_width = $self->{_items}{$copy_item}{text}->get('line-width'); } my $pattern = $self->create_alpha; my $item = Goo::Canvas::Rect->new( $self->{_canvas}->get_root_item, @dimensions, 'fill-pattern' => $pattern, 'line-dash' => Goo::Canvas::LineDash->new( [ 5, 5 ] ), 'line-width' => 1, 'stroke-color' => 'gray', ); $self->{_current_new_item} = $item unless ($copy_item); $self->{_items}{$item} = $item; $self->{_items}{$item}{text} = Goo::Canvas::Text->new( $self->{_canvas}->get_root_item, "" . $text . "", $item->get('x'), $item->get('y'), -1, 'nw', 'use-markup' => TRUE, 'fill-pattern' => $stroke_pattern, 'line-width' => $line_width, ); #adjust parent rectangle my $tb = $self->{_items}{$item}{text}->get_bounds; my $w = abs( $tb->x1 - $tb->x2 ); my $h = abs( $tb->y1 - $tb->y2 ); if ($copy_item) { $self->{_items}{$item}->set( 'x' => $self->{_items}{$item}->get('x') + 20, 'y' => $self->{_items}{$item}->get('y') + 20, 'width' => $w, 'height' => $h, 'visibility' => 'hidden', ); } else { $self->{_items}{$item}->set( 'x' => $ev->x - $w, 'y' => $ev->y - $h, 'width' => $w, 'height' => $h, 'visibility' => 'hidden', ); } #update text $self->handle_embedded( 'hide', $item ); #set type flag $self->{_items}{$item}{type} = 'text'; $self->{_items}{$item}{uid} = $self->{_uid}++; $self->{_items}{$item}{stroke_color} = $self->{_stroke_color}; $self->{_items}{$item}{stroke_color_alpha} = $self->{_stroke_color_alpha}; #create rectangles $self->handle_rects( 'create', $item ); if ($copy_item) { $self->handle_embedded( 'update', $item ); $self->handle_rects( 'hide', $item ); } $self->setup_item_signals( $self->{_items}{$item}{text} ); $self->setup_item_signals_extra( $self->{_items}{$item}{text} ); $self->setup_item_signals( $self->{_items}{$item} ); $self->setup_item_signals_extra( $self->{_items}{$item} ); return $item; } sub create_line { my $self = shift; my $ev = shift; my $copy_item = shift; my $end_arrow = shift; my $start_arrow = shift; my @dimensions = ( 0, 0, 0, 0 ); my $stroke_pattern = $self->create_color( $self->{_stroke_color}, $self->{_stroke_color_alpha} ); my $line_width = $self->{_line_width}; my $mirrored_w = 0; my $mirrored_h = 0; #default values my $arrow_width = 4; my $arrow_length = 5; my $arrow_tip_length = 4; #use event coordinates and selected color if ($ev) { @dimensions = ( $ev->x, $ev->y, 0, 0 ); #use source item coordinates and item color } elsif ($copy_item) { @dimensions = ( $copy_item->get('x') + 20, $copy_item->get('y') + 20, $copy_item->get('width'), $copy_item->get('height') ); $stroke_pattern = $self->create_color( $self->{_items}{$copy_item}{stroke_color}, $self->{_items}{$copy_item}{stroke_color_alpha} ); $line_width = $self->{_items}{$copy_item}{line}->get('line-width'); $mirrored_w = $self->{_items}{$copy_item}{mirrored_w}; $mirrored_h = $self->{_items}{$copy_item}{mirrored_h}; #arrow specific properties $end_arrow = $self->{_items}{$copy_item}{end_arrow}; $start_arrow = $self->{_items}{$copy_item}{start_arrow}; $arrow_width = $self->{_items}{$copy_item}{arrow_width}; $arrow_length = $self->{_items}{$copy_item}{arrow_length}; $arrow_tip_length = $self->{_items}{$copy_item}{arrow_tip_length}; } my $pattern = $self->create_alpha; my $item = Goo::Canvas::Rect->new( $self->{_canvas}->get_root_item, @dimensions, 'fill-pattern' => $pattern, 'line-dash' => Goo::Canvas::LineDash->new( [ 5, 5 ] ), 'line-width' => 1, 'stroke-color' => 'gray', ); $self->{_current_new_item} = $item unless ($copy_item); $self->{_items}{$item} = $item; $self->{_items}{$item}{line} = Goo::Canvas::Polyline->new_line( $self->{_canvas}->get_root_item, $item->get('x'), $item->get('y'), $item->get('x') + $item->get('width'), $item->get('y') + $item->get('height'), 'stroke-pattern' => $stroke_pattern, 'line-width' => $line_width, 'line-cap' => 'CAIRO_LINE_CAP_ROUND', 'line-join' => 'CAIRO_LINE_JOIN_ROUND', 'end-arrow' => $end_arrow, 'start-arrow' => $start_arrow, 'arrow-length' => $arrow_length, 'arrow-width' => $arrow_width, 'arrow-tip-length' => $arrow_tip_length, 'visibility' => 'hidden', ); if ( defined $end_arrow || defined $start_arrow ) { #save arrow specific properties $self->{_items}{$item}{end_arrow} = $self->{_items}{$item}{line}->get('end-arrow'); $self->{_items}{$item}{start_arrow} = $self->{_items}{$item}{line}->get('start-arrow'); $self->{_items}{$item}{arrow_width} = $self->{_items}{$item}{line}->get('arrow-width'); $self->{_items}{$item}{arrow_length} = $self->{_items}{$item}{line}->get('arrow-length'); $self->{_items}{$item}{arrow_tip_length} = $self->{_items}{$item}{line}->get('arrow-tip-length'); } #set type flag $self->{_items}{$item}{type} = 'line'; $self->{_items}{$item}{uid} = $self->{_uid}++; $self->{_items}{$item}{mirrored_w} = $mirrored_w; $self->{_items}{$item}{mirrored_h} = $mirrored_h; $self->{_items}{$item}{stroke_color} = $self->{_stroke_color}; $self->{_items}{$item}{stroke_color_alpha} = $self->{_stroke_color_alpha}; #create rectangles $self->handle_rects( 'create', $item ); if ($copy_item) { $self->handle_embedded( 'update', $item ); $self->handle_rects( 'hide', $item ); } $self->setup_item_signals( $self->{_items}{$item}{line} ); $self->setup_item_signals_extra( $self->{_items}{$item}{line} ); $self->setup_item_signals( $self->{_items}{$item} ); $self->setup_item_signals_extra( $self->{_items}{$item} ); return $item; } sub create_ellipse { my $self = shift; my $ev = shift; my $copy_item = shift; my $numbered = shift; my @dimensions = ( 0, 0, 0, 0 ); my $stroke_pattern = $self->create_color( $self->{_stroke_color}, $self->{_stroke_color_alpha} ); my $fill_pattern = $self->create_color( $self->{_fill_color}, $self->{_fill_color_alpha} ); my $line_width = $self->{_line_width}; #use event coordinates and selected color if ($ev) { @dimensions = ( $ev->x, $ev->y, 0, 0 ); #use source item coordinates and item color } elsif ($copy_item) { @dimensions = ( $copy_item->get('x') + 20, $copy_item->get('y') + 20, $copy_item->get('width'), $copy_item->get('height') ); $stroke_pattern = $self->create_color( $self->{_items}{$copy_item}{stroke_color}, $self->{_items}{$copy_item}{stroke_color_alpha} ); $fill_pattern = $self->create_color( $self->{_items}{$copy_item}{fill_color}, $self->{_items}{$copy_item}{fill_color_alpha} ); $line_width = $self->{_items}{$copy_item}{ellipse}->get('line-width'); $numbered = TRUE if exists $self->{_items}{$copy_item}{text}; } my $pattern = $self->create_alpha; my $item = Goo::Canvas::Rect->new( $self->{_canvas}->get_root_item, @dimensions, 'fill-pattern' => $pattern, 'line-dash' => Goo::Canvas::LineDash->new( [ 5, 5 ] ), 'line-width' => 1, 'stroke-color' => 'gray', ); $self->{_current_new_item} = $item unless ($copy_item); $self->{_items}{$item} = $item; $self->{_items}{$item}{ellipse} = Goo::Canvas::Ellipse->new( $self->{_canvas}->get_root_item, $item->get('x'), $item->get('y'), $item->get('width'), $item->get('height'), 'fill-pattern' => $fill_pattern, 'stroke-pattern' => $stroke_pattern, 'line-width' => $line_width, ); #numbered ellipse if ($numbered) { my $number = $self->get_highest_auto_digit(); $number++; $self->{_items}{$item}{text} = Goo::Canvas::Text->new( $self->{_canvas}->get_root_item, "" . $number . "", $self->{_items}{$item}{ellipse}->get('center-x'), $self->{_items}{$item}{ellipse}->get('center-y'), -1, 'GTK_ANCHOR_CENTER', 'use-markup' => TRUE, 'fill-pattern' => $stroke_pattern, 'line-width' => $line_width, ); #save used number $self->{_items}{$item}{text}{digit} = $number; #set type flag $self->{_items}{$item}{type} = 'number'; $self->{_items}{$item}{uid} = $self->{_uid}++; #adjust parent rectangle if numbered ellipse my $tb = $self->{_items}{$item}{text}->get_bounds; #keep ratio = 1 my $qs = abs( $tb->x1 - $tb->x2 ); $qs = abs( $tb->y1 - $tb->y2 ) if abs( $tb->y1 - $tb->y2 ) > abs( $tb->x1 - $tb->x2 ); #add line width of parent ellipse $qs += $self->{_items}{$item}{ellipse}->get('line-width') + 5; if ($copy_item) { $self->{_items}{$item}->set( 'x' => $self->{_items}{$item}->get('x') + 20, 'y' => $self->{_items}{$item}->get('y') + 20, 'width' => $qs, 'height' => $qs, 'visibility' => 'hidden', ); } else { $self->{_items}{$item}->set( 'x' => $self->{_items}{$item}->get('x') - $qs, 'y' => $self->{_items}{$item}->get('y') - $qs, 'width' => $qs, 'height' => $qs, 'visibility' => 'hidden', ); } $self->handle_embedded( 'hide', $item ); } else { #set type flag $self->{_items}{$item}{type} = 'ellipse'; $self->{_items}{$item}{uid} = $self->{_uid}++; } #save color and opacity as well $self->{_items}{$item}{fill_color} = $self->{_fill_color}; $self->{_items}{$item}{fill_color_alpha} = $self->{_fill_color_alpha}; $self->{_items}{$item}{stroke_color} = $self->{_stroke_color}; $self->{_items}{$item}{stroke_color_alpha} = $self->{_stroke_color_alpha}; #create rectangles $self->handle_rects( 'create', $item ); if ($copy_item) { $self->handle_embedded( 'update', $item ); $self->handle_rects( 'hide', $item ); } if ($numbered) { $self->setup_item_signals( $self->{_items}{$item}{text} ); $self->setup_item_signals_extra( $self->{_items}{$item}{text} ); } $self->setup_item_signals( $self->{_items}{$item}{ellipse} ); $self->setup_item_signals_extra( $self->{_items}{$item}{ellipse} ); $self->setup_item_signals( $self->{_items}{$item} ); $self->setup_item_signals_extra( $self->{_items}{$item} ); return $item; } sub create_rectangle { my $self = shift; my $ev = shift; my $copy_item = shift; my @dimensions = ( 0, 0, 0, 0 ); my $stroke_pattern = $self->create_color( $self->{_stroke_color}, $self->{_stroke_color_alpha} ); my $fill_pattern = $self->create_color( $self->{_fill_color}, $self->{_fill_color_alpha} ); my $line_width = $self->{_line_width}; #use event coordinates and selected color if ($ev) { @dimensions = ( $ev->x, $ev->y, 0, 0 ); #use source item coordinates and item color } elsif ($copy_item) { @dimensions = ( $copy_item->get('x') + 20, $copy_item->get('y') + 20, $copy_item->get('width'), $copy_item->get('height') ); $stroke_pattern = $self->create_color( $self->{_items}{$copy_item}{stroke_color}, $self->{_items}{$copy_item}{stroke_color_alpha} ); $fill_pattern = $self->create_color( $self->{_items}{$copy_item}{fill_color}, $self->{_items}{$copy_item}{fill_color_alpha} ); $line_width = $self->{_items}{$copy_item}->get('line-width'); } my $item = Goo::Canvas::Rect->new( $self->{_canvas}->get_root_item, @dimensions, 'fill-pattern' => $fill_pattern, 'stroke-pattern' => $stroke_pattern, 'line-width' => $line_width, ); $self->{_current_new_item} = $item unless ($copy_item); $self->{_items}{$item} = $item; #set type flag $self->{_items}{$item}{type} = 'rectangle'; $self->{_items}{$item}{uid} = $self->{_uid}++; $self->{_items}{$item}{fill_color} = $self->{_fill_color}; $self->{_items}{$item}{fill_color_alpha} = $self->{_fill_color_alpha}; $self->{_items}{$item}{stroke_color} = $self->{_stroke_color}; $self->{_items}{$item}{stroke_color_alpha} = $self->{_stroke_color_alpha}; #create rectangles $self->handle_rects( 'create', $item ); $self->setup_item_signals( $self->{_items}{$item} ); $self->setup_item_signals_extra( $self->{_items}{$item} ); return $item; } 1; shutter-0.90.1/share/shutter/resources/modules/Shutter/Geometry/0000755000175000017500000000000012206477313024017 5ustar mariomarioshutter-0.90.1/share/shutter/resources/modules/Shutter/Geometry/Region.pm0000644000175000017500000000413412206477313025602 0ustar mariomario################################################### # # Copyright (C) 2008-2013 Mario Kemper # # This file is part of Shutter. # # Shutter is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 3 of the License, or # (at your option) any later version. # # Shutter is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License # along with Shutter; if not, write to the Free Software # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA # ################################################### package Shutter::Geometry::Region; #modules #-------------------------------------- use utf8; use strict; use warnings; use Gtk2; #Glib use Glib qw/TRUE FALSE/; sub new { my $class = shift; #constructor my $self = { }; bless $self, $class; return $self; } sub get_clipbox { my $self = shift; my $region = shift; #store clipbox here my $clip = undef; #calculate clipbox foreach my $rect ($region->get_rectangles){ #~ print $rect->x, " - ", $rect->y, " - ", $rect->width, " - ", $rect->height, "\n"; unless(defined $clip){ $clip = Gtk2::Gdk::Rectangle->new($rect->x, $rect->y, $rect->width, $rect->height); }else{ if($rect->x < $clip->x){ $clip->width($clip->width+$clip->x); $clip->x($rect->x); } if($rect->y < $clip->y){ $clip->height($clip->height+$clip->y); $clip->y($rect->y); } if($rect->x + $rect->width > $clip->x + $clip->width){ $clip->width($rect->x + $rect->width - $clip->x); } if($rect->y + $rect->height > $clip->y + $clip->height){ $clip->height($rect->y + $rect->height - $clip->y); } } } #return clip or empty rectangle if(defined $clip){ return $clip; }else{ return Gtk2::Gdk::Rectangle->new(0,0,0,0); } } 1; shutter-0.90.1/share/shutter/resources/modules/Shutter/Screenshot/0000755000175000017500000000000012206477313024341 5ustar mariomarioshutter-0.90.1/share/shutter/resources/modules/Shutter/Screenshot/SelectorAdvanced.pm0000644000175000017500000012072312206477313030112 0ustar mariomario################################################### # # Copyright (C) 2008-2013 Mario Kemper # # This file is part of Shutter. # # Shutter is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 3 of the License, or # (at your option) any later version. # # Shutter is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License # along with Shutter; if not, write to the Free Software # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA # ################################################### #perl -x -S perltidy -l=0 -b "%f" package Shutter::Screenshot::SelectorAdvanced; #modules #-------------------------------------- use utf8; use strict; use warnings; use Gtk2::ImageView; use Gnome2::Canvas; use Shutter::Screenshot::Main; use Shutter::Screenshot::History; use Data::Dumper; our @ISA = qw(Shutter::Screenshot::Main); #Glib use Glib qw/TRUE FALSE/; #-------------------------------------- sub new { my $class = shift; #call constructor of super class (shutter_common, include_cursor, delay, notify_timeout) my $self = $class->SUPER::new( shift, shift, shift, shift ); $self->{_zoom_active} = shift; $self->{_hide_time} = shift; #a short timeout to give the server a chance to redraw the area that was obscured $self->{_show_help} = shift; #hide help text? #initial selection size $self->{_init_x} = shift; $self->{_init_y} = shift; $self->{_init_w} = shift; $self->{_init_h} = shift; #view, selector, dragger $self->{_view} = Gtk2::ImageView->new; $self->{_selector} = Gtk2::ImageView::Tool::Selector->new( $self->{_view} ); $self->{_dragger} = Gtk2::ImageView::Tool::Dragger->new( $self->{_view} ); $self->{_view}->set_interpolation('tiles'); $self->{_view}->set_tool( $self->{_selector} ); #WORKAROUND #upstream bug #http://trac.bjourne.webfactional.com/ticket/21 #left => zoom in #right => zoom out $self->{_view}->signal_connect( 'scroll-event', sub { my ( $view, $ev ) = @_; if ( $ev->direction eq 'left' ) { $ev->direction('up'); } elsif ( $ev->direction eq 'right' ) { $ev->direction('down'); } return FALSE; } ); bless $self, $class; return $self; } #~ sub DESTROY { #~ my $self = shift; #~ print "$self dying at\n"; #~ } sub select_advanced { my $self = shift; #return value my $output = 5; my $d = $self->{_sc}->get_gettext; #create pixbuf (root window) my $clean_pixbuf = Gtk2::Gdk::Pixbuf->get_from_drawable( $self->{_root}, undef, 0, 0, 0, 0, $self->{_root}->{w}, $self->{_root}->{h} ); $self->{_view}->set_pixbuf($clean_pixbuf); #show help text (do not show help text if predefined selection area is enabled)? if ( $self->{_init_w} < 1 || $self->{_init_h} < 1 ) { if ( $self->{_show_help} ) { Glib::Idle->add( sub { #we display the tip only on the current monitor #if we would use the root window we would display the next #right in the middle of both screens, this is pretty ugly my $mon1 = $self->get_current_monitor; print "Using monitor: " . $mon1->x . " - " . $mon1->y . " - " . $mon1->width . " - " . $mon1->height . "\n" if $self->{_sc}->get_debug; #obtain current colors and font_desc from the main window my $style = $self->{_sc}->get_mainwindow->get_style; my $sel_bg = Gtk2::Gdk::Color->parse('#131313'); my $sel_tx = $style->text('selected'); my $font_fam = $style->font_desc->get_family; my $font_size = $style->font_desc->get_size / Gtk2::Pango->scale; #create cairo context und layout my $surface = Cairo::ImageSurface->create( 'argb32', $self->{_root}->{w}, $self->{_root}->{h} ); my $cr = Cairo::Context->create($surface); #set_source_pixbuf Gtk2::Gdk::Cairo::Context::set_source_pixbuf( $cr, $clean_pixbuf, 0, 0 ); $cr->paint; my $layout = Gtk2::Pango::Cairo::create_layout($cr); $layout->set_width( int( $mon1->width / 2 ) * Gtk2::Pango->scale ); $layout->set_alignment('left'); $layout->set_wrap('word'); #determine font-size my $size1 = int( $font_size * 2.0 ); my $size2 = int( $font_size * 1.5 ); my $size3 = int( $font_size * 1.0 ); my $text1 = $d->get("Draw a rectangular area using the mouse."); my $text2 = $d->get("To take a screenshot, press the Enter key. Press Esc to quit."); my $text3 = $d->get("shift/right-click → selection dialog on/off") . "\n" . $d->get("ctrl + scrollwheel → zoom in/out") . "\n" . $d->get("space → zoom window on/off") . "\n" . $d->get("cursor keys → move cursor") . "\n" . $d->get("cursor keys + alt → move selection") . "\n" . $d->get("cursor keys + ctrl → resize selection"); #use this one for white font-color $layout->set_markup("$text1\n$text2\n\n$text3"); #draw the rectangle $cr->set_source_rgba( $sel_bg->red / 257 / 255, $sel_bg->green / 257 / 255, $sel_bg->blue / 257 / 255, 0.85 ); my ( $lw, $lh ) = $layout->get_pixel_size; my $w = $lw + $size1 * 2; my $h = $lh + $size1 * 2; my $x = int( ( $mon1->width - $w ) / 2 ) + $mon1->x; my $y = int( ( $mon1->height - $h ) / 2 ) + $mon1->y; my $r = 20; $cr->move_to( $x + $r, $y ); $cr->line_to( $x + $w - $r, $y ); $cr->curve_to( $x + $w, $y, $x + $w, $y, $x + $w, $y + $r ); $cr->line_to( $x + $w, $y + $h - $r ); $cr->curve_to( $x + $w, $y + $h, $x + $w, $y + $h, $x + $w - $r, $y + $h ); $cr->line_to( $x + $r, $y + $h ); $cr->curve_to( $x, $y + $h, $x, $y + $h, $x, $y + $h - $r ); $cr->line_to( $x, $y + $r ); $cr->curve_to( $x, $y, $x, $y, $x + $r, $y ); $cr->fill; $cr->move_to( $x + $size1, $y + $size1 ); #draw the pango layout Gtk2::Pango::Cairo::show_layout( $cr, $layout ); #write surface to pixbuf my $loader = Gtk2::Gdk::PixbufLoader->new; $surface->write_to_png_stream( sub { my ( $closure, $data ) = @_; $loader->write($data); } ); $loader->close; #set pixbuf $self->{_view}->set_pixbuf( $loader->get_pixbuf ); return FALSE; } ); } } #define zoom window $self->{_zoom_window} = Gtk2::Window->new('popup'); $self->{_zoom_window}->set_decorated(FALSE); $self->{_zoom_window}->set_skip_taskbar_hint(TRUE); $self->{_zoom_window}->set_skip_pager_hint(TRUE); $self->{_zoom_window}->set_keep_above(TRUE); $self->{_zoom_window}->set_accept_focus(FALSE); #pack canvas to a scrolled window my $scwin = Gtk2::ScrolledWindow->new(); $scwin->set_policy( 'never', 'never' ); #define and setup the canvas my $canvas = Gnome2::Canvas->new(); $canvas->set_size_request( 105, 105 ); $canvas->modify_bg( 'normal', Gtk2::Gdk::Color->new( 65535, 65535, 65535 ) ); $canvas->set_pixels_per_unit(5); my $canvas_root = $canvas->root(); $scwin->add($canvas); my $xlabel = Gtk2::Label->new("X: "); my $ylabel = Gtk2::Label->new("Y: "); my $rlabel = Gtk2::Label->new("0 x 0"); $ylabel->set_max_width_chars(10); $xlabel->set_max_width_chars(10); $rlabel->set_max_width_chars(10); my $zoom_vbox = Gtk2::VBox->new; $zoom_vbox->pack_start_defaults($scwin); $zoom_vbox->pack_start_defaults($xlabel); $zoom_vbox->pack_start_defaults($ylabel); $zoom_vbox->pack_start_defaults($rlabel); #do some packing $self->{_zoom_window}->add($zoom_vbox); $self->{_zoom_window}->move( $self->{_root}->{x}, $self->{_root}->{y} ); #define shutter cursor (frame) my $shutter_cursor_pixbuf_frame = Gtk2::Gdk::Pixbuf->new_from_file( $self->{_sc}->get_root . "/share/shutter/resources/icons/shutter_cursor_frame.png" ); #create root... my $root_item = Gnome2::Canvas::Item->new( $canvas_root, "Gnome2::Canvas::Pixbuf", x => 0, y => 0, pixbuf => $clean_pixbuf ); #...and cursor icon my $cursor_item = Gnome2::Canvas::Item->new( $canvas_root, "Gnome2::Canvas::Pixbuf", x => 0, y => 0, pixbuf => $shutter_cursor_pixbuf_frame, ); #starting point my ( $window_at_pointer, $xinit, $yinit, $mask ) = $self->{_root}->get_pointer; #move cursor on the canvas... $cursor_item->set( x => $xinit - 10, y => $yinit - 10, ); #scroll region $canvas->set_scroll_region( $xinit - 9, $yinit - 9, $xinit + 10, $yinit + 10 ); #window to manipulate the selection $self->{_prop_window} = $self->select_dialog(); $self->{_prop_active} = FALSE; #window that contains the imageview widget $self->{_select_window} = Gtk2::Window->new('popup'); $self->{_select_window}->set_type_hint('splashscreen'); $self->{_select_window}->set_has_frame(FALSE); $self->{_select_window}->can_focus(TRUE); $self->{_select_window}->set_accept_focus(TRUE); $self->{_select_window}->set_modal(TRUE); $self->{_select_window}->set_decorated(FALSE); $self->{_select_window}->set_skip_taskbar_hint(TRUE); $self->{_select_window}->set_skip_pager_hint(TRUE); $self->{_select_window}->set_keep_above(TRUE); $self->{_select_window}->add( $self->{_view} ); $self->{_select_window}->set_default_size( $self->{_root}->{w}, $self->{_root}->{h} ); $self->{_select_window}->resize( $self->{_root}->{w}, $self->{_root}->{h} ); $self->{_select_window}->move( $self->{_root}->{x}, $self->{_root}->{y} ); $self->{_select_window}->show_all; $self->{_select_window}->present; #init state flags if ( $self->{_show_help} ) { $self->{_selector_init} = TRUE; } else { $self->{_selector_init} = FALSE; } $self->{_selector_init_zoom} = 0; #hide help text when selector is invoked $self->{_selector_handler} = $self->{_selector}->signal_connect( 'selection-changed' => sub { #hide initial text if ( $self->{_selector_init} ) { $self->{_view}->set_pixbuf( $clean_pixbuf, FALSE ); $self->{_selector_init} = FALSE; $self->{_selector_init_zoom}++; } #update prop dialog values $self->adjust_prop_values(); } ); #handle zoom events #ignore zoom values smaller 1 $self->{_view_zoom_handler} = $self->{_view}->signal_connect( 'zoom-changed' => sub { if ( $self->{_view}->get_zoom < 1 ) { $self->{_view}->set_zoom(1); } elsif ( $self->{_view}->get_zoom > 10 ) { $self->{_view}->set_zoom(10); } elsif ( $self->{_view}->get_zoom > 1 ) { if ( $self->{_zoom_active} ) { $self->{_zoom_window}->hide_all; } } else { if ( $self->{_zoom_active} ) { $self->{_zoom_window}->show_all; $self->zoom_check_pos(); } } #hide help text when zoomed if ( $self->{_selector_init_zoom} == 1 ) { $self->{_view}->set_pixbuf( $clean_pixbuf, FALSE ); $self->{_selector_init} = FALSE; } else { $self->{_selector_init_zoom}++; } } ); #set initial size Glib::Idle->add( sub { if ( $self->{_init_w} && $self->{_init_h} ) { $self->{_selector}->set_selection( Gtk2::Gdk::Rectangle->new( $self->{_init_x}, $self->{_init_y}, $self->{_init_w}, $self->{_init_h} ) ); } return FALSE; } ); #event-handling #we simulate a 2button-press here $self->{_view_button_handler} = $self->{_view}->signal_connect( 'button-press-event' => sub { my ( $view, $event ) = @_; return FALSE unless defined $event; my $s = $self->{_selector}->get_selection; if ( $event->button == 1 ) { unless ( defined $self->{_dclick} ) { $self->{_dclick} = $event->time; return FALSE; } else { if ( $event->time - $self->{_dclick} <= 500 ) { $self->{_select_window}->hide; $self->{_zoom_window}->hide; $self->{_prop_window}->hide; #A short timeout to give the server a chance to #redraw the area Glib::Timeout->add( $self->{_hide_time}, sub { Gtk2->main_quit; return FALSE; } ); Gtk2->main(); $output = $self->take_screenshot( $s, $clean_pixbuf ); $self->quit; } else { $self->{_dclick} = $event->time; return FALSE; } } } } ); #event-handling #all other events $self->{_view_event_handler} = $self->{_view}->signal_connect( 'event' => sub { my ( $window, $event ) = @_; return FALSE unless defined $event; my $s = $self->{_selector}->get_selection; #~ print $event->type, "\n"; #handle button-release event if ( $event->type eq 'button-release' ) { if ( $event->button == 3 ) { if ( $self->{_prop_active} ) { Gtk2::Gdk->keyboard_ungrab( Gtk2->get_current_event_time ); $self->{_prop_window}->hide_all; $self->{_prop_active} = FALSE; Gtk2::Gdk->keyboard_grab( $self->{_select_window}->window, 0, Gtk2->get_current_event_time ); } else { Gtk2::Gdk->keyboard_ungrab( Gtk2->get_current_event_time ); my ( $window_at_pointer, $x, $y, $mask ) = $self->{_root}->get_pointer; $self->{_prop_window}->move( $x, $y ); $self->{_prop_window}->show_all; $self->{_prop_active} = TRUE; Gtk2::Gdk->keyboard_grab( $self->{_prop_window}->window, 0, Gtk2->get_current_event_time ); } } #handle motion-notify } elsif ( $event->type eq 'motion-notify' ) { #update zoom window if ( $self->{_zoom_active} && $self->{_view}->get_zoom == 1 ) { my $s = $self->{_selector}->get_selection; my $v = $self->{_view}->get_viewport; my ( $window_at_pointer, $x, $y, $mask ) = $self->{_root}->get_pointer; #event coordinates my $ev_x = int( $v->x / $self->{_view}->get_zoom + $x / $self->{_view}->get_zoom ); my $ev_y = int( $v->y / $self->{_view}->get_zoom + $y / $self->{_view}->get_zoom ); #sync cursor with selection my $cursor = $self->{_selector}->cursor_at_point( $x, $y ); if ( defined $s ) { my $sx = $s->x; my $sy = $s->y; my $sw = $s->width; my $sh = $s->height; if ( $cursor->type eq 'bottom-right-corner' ) { $ev_x = $sx + $sw - 1; $ev_y = $sy + $sh - 1; } elsif ( $cursor->type eq 'right-side' ) { $ev_x = $sx + $sw - 1; } elsif ( $cursor->type eq 'top-right-corner' ) { $ev_x = $sx + $sw - 1; $ev_y = $sy; } elsif ( $cursor->type eq 'top-side' ) { $ev_y = $sy; } elsif ( $cursor->type eq 'top-left-corner' ) { $ev_x = $sx; $ev_y = $sy; } elsif ( $cursor->type eq 'left-side' ) { $ev_x = $sx; } elsif ( $cursor->type eq 'bottom-left-corner' ) { $ev_x = $sx; $ev_y = $sy + $sh - 1; } elsif ( $cursor->type eq 'bottom-side' ) { $ev_y = $sy + $sh - 1; } } #update label in zoom_window $xlabel->set_text( "X: " . ( $ev_x + 1 ) ); $ylabel->set_text( "Y: " . ( $ev_y + 1 ) ); #check pos and geometry of the zoom window and move it if needed $self->zoom_check_pos(); #move cursor on the canvas... $cursor_item->set( x => $ev_x - 10, y => $ev_y - 10, ); #update scroll region #this is significantly faster than #scroll_to $canvas->set_scroll_region( $ev_x - 9, $ev_y - 9, $ev_x + 10, $ev_y + 10 ); #update zoom_window text if ( defined $s ) { $rlabel->set_text( $s->width . " x " . $s->height ); } else { $rlabel->set_text("0 x 0"); } } #zoom active #handle key-press } elsif ( $event->type eq 'key-press' ) { #where is the pointer currently? my ( $window_at_pointer, $x, $y, $mask ) = $self->{_root}->get_pointer; #toggle zoom window if ( $event->keyval == Gtk2::Gdk->keyval_from_name('space') ) { if ( $self->{_zoom_active} ) { $self->{_zoom_window}->hide_all; $self->{_zoom_active} = FALSE; } elsif ( $self->{_view}->get_zoom == 1 ) { $self->zoom_check_pos(); $self->{_zoom_active} = TRUE; } #toggle prop dialog } elsif ( $event->keyval == Gtk2::Gdk->keyval_from_name('Shift_L') || $event->keyval == Gtk2::Gdk->keyval_from_name('Shift_R') ) { if ( $self->{_prop_active} ) { Gtk2::Gdk->keyboard_ungrab( Gtk2->get_current_event_time ); $self->{_prop_window}->hide_all; $self->{_prop_active} = FALSE; Gtk2::Gdk->keyboard_grab( $self->{_select_window}->window, 0, Gtk2->get_current_event_time ); } else { Gtk2::Gdk->keyboard_ungrab( Gtk2->get_current_event_time ); my ( $window_at_pointer, $x, $y, $mask ) = $self->{_root}->get_pointer; $self->{_prop_window}->move( $x, $y ); $self->{_prop_window}->show_all; $self->{_prop_active} = TRUE; Gtk2::Gdk->keyboard_grab( $self->{_prop_window}->window, 0, Gtk2->get_current_event_time ); } #abort screenshot } elsif ( $event->keyval == Gtk2::Gdk->keyval_from_name('Escape') ) { $self->quit; #move / resize selector } elsif ( $event->keyval == Gtk2::Gdk->keyval_from_name('Up') ) { if ( $event->state >= 'control-mask' && $s ) { $s->height( $s->height - 1 ); $self->{_selector}->set_selection($s); $self->{_gdk_display}->warp_pointer( $self->{_gdk_screen}, $s->width + $s->x, $s->height + $s->y ); } elsif ( $event->state >= 'mod1-mask' && $s ) { $s->y( $s->y - 1 ); $self->{_selector}->set_selection($s); $self->{_gdk_display}->warp_pointer( $self->{_gdk_screen}, $s->x, $s->y ); } else { $self->{_gdk_display}->warp_pointer( $self->{_gdk_screen}, $x, $y - 1 ); } } elsif ( $event->keyval == Gtk2::Gdk->keyval_from_name('Down') ) { if ( $event->state >= 'control-mask' && $s ) { $s->height( $s->height + 1 ); $self->{_selector}->set_selection($s); $self->{_gdk_display}->warp_pointer( $self->{_gdk_screen}, $s->width + $s->x, $s->height + $s->y ); } elsif ( $event->state >= 'control-mask' ) { $self->{_selector}->set_selection( Gtk2::Gdk::Rectangle->new( $x, $y, 1, 2 ) ); $self->{_gdk_display}->warp_pointer( $self->{_gdk_screen}, $x + 1, $y + 2 ); } elsif ( $event->state >= 'mod1-mask' && $s ) { $s->y( $s->y + 1 ); $self->{_selector}->set_selection($s); $self->{_gdk_display}->warp_pointer( $self->{_gdk_screen}, $s->x, $s->y ); } else { $self->{_gdk_display}->warp_pointer( $self->{_gdk_screen}, $x, $y + 1 ); } } elsif ( $event->keyval == Gtk2::Gdk->keyval_from_name('Left') ) { if ( $event->state >= 'control-mask' && $s ) { $s->width( $s->width - 1 ); $self->{_selector}->set_selection($s); $self->{_gdk_display}->warp_pointer( $self->{_gdk_screen}, $s->width + $s->x, $s->height + $s->y ); } elsif ( $event->state >= 'mod1-mask' && $s ) { $s->x( $s->x - 1 ); $self->{_selector}->set_selection($s); $self->{_gdk_display}->warp_pointer( $self->{_gdk_screen}, $s->x, $s->y ); } else { $self->{_gdk_display}->warp_pointer( $self->{_gdk_screen}, $x - 1, $y ); } } elsif ( $event->keyval == Gtk2::Gdk->keyval_from_name('Right') ) { if ( $event->state >= 'control-mask' && $s ) { $s->width( $s->width + 1 ); $self->{_selector}->set_selection($s); $self->{_gdk_display}->warp_pointer( $self->{_gdk_screen}, $s->width + $s->x, $s->height + $s->y ); } elsif ( $event->state >= 'control-mask' ) { $self->{_selector}->set_selection( Gtk2::Gdk::Rectangle->new( $x, $y, 2, 1 ) ); $self->{_gdk_display}->warp_pointer( $self->{_gdk_screen}, $x + 2, $y + 1 ); } elsif ( $event->state >= 'mod1-mask' && $s ) { $s->x( $s->x + 1 ); $self->{_selector}->set_selection($s); $self->{_gdk_display}->warp_pointer( $self->{_gdk_screen}, $s->x, $s->y ); } else { $self->{_gdk_display}->warp_pointer( $self->{_gdk_screen}, $x + 1, $y ); } #zoom in } elsif ($event->keyval == Gtk2::Gdk->keyval_from_name('KP_Add') || $event->keyval == Gtk2::Gdk->keyval_from_name('plus') || $event->keyval == Gtk2::Gdk->keyval_from_name('equal') ) { if ( $event->state >= 'control-mask' ) { $self->{_view}->zoom_in; } #zoom out } elsif ($event->keyval == Gtk2::Gdk->keyval_from_name('KP_Subtract') || $event->keyval == Gtk2::Gdk->keyval_from_name('minus') ) { if ( $event->state >= 'control-mask' ) { $self->{_view}->zoom_out; } #zoom normal } elsif ( $event->keyval == Gtk2::Gdk->keyval_from_name('0') ) { if ( $event->state >= 'control-mask' ) { $self->{_view}->set_zoom(1); } #take screenshot } elsif ( $event->keyval == Gtk2::Gdk->keyval_from_name('Return') || $event->keyval == Gtk2::Gdk->keyval_from_name('KP_Enter') ) { $self->{_select_window}->hide; $self->{_zoom_window}->hide; $self->{_prop_window}->hide; #A short timeout to give the server a chance to #redraw the area Glib::Timeout->add( $self->{_hide_time}, sub { Gtk2->main_quit; return FALSE; } ); Gtk2->main(); $output = $self->take_screenshot( $s, $clean_pixbuf ); $self->quit; } } } ); my $status = Gtk2::Gdk->keyboard_grab( $self->{_select_window}->window, 0, Gtk2->get_current_event_time ); #~ if($status eq 'success'){ if ( $self->{_zoom_active} ) { $self->{_zoom_window}->show_all; $self->{_zoom_window}->window->set_override_redirect(TRUE); $self->zoom_check_pos(); $self->{_zoom_window}->window->raise; } Gtk2->main(); #~ }else{ #~ $output = 1; #~ $self->clean; #~ } return $output; } sub zoom_check_pos { my $self = shift; my $s = $self->{_selector}->get_selection; my $v = $self->{_view}->get_viewport; return FALSE unless defined $v; my ( $window_at_pointer, $x, $y, $mask ) = $self->{_root}->get_pointer; #event coordinates my $ev_x = int( $v->x / $self->{_view}->get_zoom + $x / $self->{_view}->get_zoom ); my $ev_y = int( $v->y / $self->{_view}->get_zoom + $y / $self->{_view}->get_zoom ); my ( $zw, $zh ) = $self->{_zoom_window}->get_size; my ( $zx, $zy ) = $self->{_zoom_window}->get_position; my $sregion = undef; if ( defined $s ) { $sregion = Gtk2::Gdk::Region->rectangle( Gtk2::Gdk::Rectangle->new( $s->x - 50, $s->y - 50, $s->width + 50, $s->height + 50 ) ); } else { $sregion = Gtk2::Gdk::Region->rectangle( Gtk2::Gdk::Rectangle->new( $ev_x - 50, $ev_y - 50, 50, 50 ) ); } my $otype = $sregion->rect_in( Gtk2::Gdk::Rectangle->new( $zx - 50, $zy - 50, $zw + 50, $zh + 50 ) ); if ( $otype eq 'in' || $otype eq 'part' || !$self->{_zoom_window}->visible ) { my $moved = FALSE; #possible positions if we need to move the zoom window my @pos = ( Gtk2::Gdk::Rectangle->new( $self->{_root}->{x}, $self->{_root}->{y}, 0, 0 ), Gtk2::Gdk::Rectangle->new( 0, $self->{_root}->{h} - $zh, 0, 0 ), Gtk2::Gdk::Rectangle->new( $self->{_root}->{w} - $zw, $self->{_root}->{y}, 0, 0 ), Gtk2::Gdk::Rectangle->new( $self->{_root}->{w} - $zw, $self->{_root}->{h} - $zh, 0, 0 ) ); foreach (@pos) { my $otypet = $sregion->rect_in( Gtk2::Gdk::Rectangle->new( $_->x - 50, $_->y - 50, $zw + 50, $zh + 50 ) ); if ( $otypet eq 'out' ) { $self->{_zoom_window}->move( $_->x, $_->y ); $self->{_zoom_window}->show_all; $moved = TRUE; last; } } #if window could not be moved without covering the selection area unless ($moved) { $moved = FALSE; $self->{_zoom_window}->hide_all; } } } sub adjust_prop_values { my $self = shift; #block 'value-change' handlers for widgets #so we do not apply the changes twice $self->{_x_spin_w}->signal_handler_block( $self->{_x_spin_w_handler} ); $self->{_y_spin_w}->signal_handler_block( $self->{_y_spin_w_handler} ); $self->{_width_spin_w}->signal_handler_block( $self->{_width_spin_w_handler} ); $self->{_height_spin_w}->signal_handler_block( $self->{_height_spin_w_handler} ); my $s = $self->{_selector}->get_selection; if ($s) { $self->{_x_spin_w}->set_value( $s->x ); $self->{_x_spin_w}->set_range( 0, $self->{_root}->{w} - $s->width ); $self->{_y_spin_w}->set_value( $s->y ); $self->{_y_spin_w}->set_range( 0, $self->{_root}->{h} - $s->height ); $self->{_width_spin_w}->set_value( $s->width ); $self->{_width_spin_w}->set_range( 0, $self->{_root}->{w} - $s->x ); $self->{_height_spin_w}->set_value( $s->height ); $self->{_height_spin_w}->set_range( 0, $self->{_root}->{h} - $s->y ); } #unblock 'value-change' handlers for widgets $self->{_x_spin_w}->signal_handler_unblock( $self->{_x_spin_w_handler} ); $self->{_y_spin_w}->signal_handler_unblock( $self->{_y_spin_w_handler} ); $self->{_width_spin_w}->signal_handler_unblock( $self->{_width_spin_w_handler} ); $self->{_height_spin_w}->signal_handler_unblock( $self->{_height_spin_w_handler} ); return TRUE; } sub select_dialog { my $self = shift; my $d = $self->{_sc}->get_gettext; #current selection my $s = $self->{_selector}->get_selection; my $sx = 0; my $sy = 0; my $sw = 0; my $sh = 0; if ( defined $s ) { $sx = $s->x; $sy = $s->y; $sw = $s->width; $sh = $s->height; } #X my $xw_label = Gtk2::Label->new( $d->get("X") . ":" ); $self->{_x_spin_w} = Gtk2::SpinButton->new_with_range( 0, $self->{_root}->{w}, 1 ); $self->{_x_spin_w}->set_value($sx); $self->{_x_spin_w_handler} = $self->{_x_spin_w}->signal_connect( 'value-changed' => sub { $self->{_selector}->set_selection( Gtk2::Gdk::Rectangle->new( $self->{_x_spin_w}->get_value, $self->{_y_spin_w}->get_value, $self->{_width_spin_w}->get_value, $self->{_height_spin_w}->get_value ) ); } ); my $xw_hbox = Gtk2::HBox->new( FALSE, 5 ); $xw_hbox->pack_start( $xw_label, FALSE, FALSE, 5 ); $xw_hbox->pack_start( $self->{_x_spin_w}, FALSE, FALSE, 5 ); #y my $yw_label = Gtk2::Label->new( $d->get("Y") . ":" ); $self->{_y_spin_w} = Gtk2::SpinButton->new_with_range( 0, $self->{_root}->{h}, 1 ); $self->{_y_spin_w}->set_value($sy); $self->{_y_spin_w_handler} = $self->{_y_spin_w}->signal_connect( 'value-changed' => sub { $self->{_selector}->set_selection( Gtk2::Gdk::Rectangle->new( $self->{_x_spin_w}->get_value, $self->{_y_spin_w}->get_value, $self->{_width_spin_w}->get_value, $self->{_height_spin_w}->get_value ) ); } ); my $yw_hbox = Gtk2::HBox->new( FALSE, 5 ); $yw_hbox->pack_start( $yw_label, FALSE, FALSE, 5 ); $yw_hbox->pack_start( $self->{_y_spin_w}, FALSE, FALSE, 5 ); #width my $widthw_label = Gtk2::Label->new( $d->get("Width") . ":" ); $self->{_width_spin_w} = Gtk2::SpinButton->new_with_range( 0, $self->{_root}->{w}, 1 ); $self->{_width_spin_w}->set_value($sw); $self->{_width_spin_w_handler} = $self->{_width_spin_w}->signal_connect( 'value-changed' => sub { $self->{_selector}->set_selection( Gtk2::Gdk::Rectangle->new( $self->{_x_spin_w}->get_value, $self->{_y_spin_w}->get_value, $self->{_width_spin_w}->get_value, $self->{_height_spin_w}->get_value ) ); } ); my $ww_hbox = Gtk2::HBox->new( FALSE, 5 ); $ww_hbox->pack_start( $widthw_label, FALSE, FALSE, 5 ); $ww_hbox->pack_start( $self->{_width_spin_w}, FALSE, FALSE, 5 ); #height my $heightw_label = Gtk2::Label->new( $d->get("Height") . ":" ); $self->{_height_spin_w} = Gtk2::SpinButton->new_with_range( 0, $self->{_root}->{h}, 1 ); $self->{_height_spin_w}->set_value($sh); $self->{_height_spin_w_handler} = $self->{_height_spin_w}->signal_connect( 'value-changed' => sub { $self->{_selector}->set_selection( Gtk2::Gdk::Rectangle->new( $self->{_x_spin_w}->get_value, $self->{_y_spin_w}->get_value, $self->{_width_spin_w}->get_value, $self->{_height_spin_w}->get_value ) ); } ); my $hw_hbox = Gtk2::HBox->new( FALSE, 5 ); $hw_hbox->pack_start( $heightw_label, FALSE, FALSE, 5 ); $hw_hbox->pack_start( $self->{_height_spin_w}, FALSE, FALSE, 5 ); my $prop_dialog = Gtk2::Window->new('toplevel'); $prop_dialog->set_modal(TRUE); $prop_dialog->set_decorated(FALSE); $prop_dialog->set_skip_taskbar_hint(TRUE); $prop_dialog->set_skip_pager_hint(TRUE); $prop_dialog->set_keep_above(TRUE); $prop_dialog->set_accept_focus(TRUE); $prop_dialog->set_resizable(FALSE); $prop_dialog->signal_connect( 'key-press-event' => sub { my $window = shift; my $event = shift; #toggle zoom window if ( $event->keyval == Gtk2::Gdk->keyval_from_name('Space') ) { if ( $self->{_zoom_active} ) { $self->{_zoom_window}->hide_all; $self->{_zoom_active} = FALSE; } elsif ( $self->{_view}->get_zoom == 1 ) { $self->zoom_check_pos(); $self->{_zoom_active} = TRUE; } #toggle prop dialog } elsif ( $event->keyval == Gtk2::Gdk->keyval_from_name('Shift_L') || $event->keyval == Gtk2::Gdk->keyval_from_name('Shift_R') ) { if ( $self->{_prop_active} ) { Gtk2::Gdk->keyboard_ungrab( Gtk2->get_current_event_time ); $self->{_prop_window}->hide_all; $self->{_prop_active} = FALSE; Gtk2::Gdk->keyboard_grab( $self->{_select_window}->window, 0, Gtk2->get_current_event_time ); } else { Gtk2::Gdk->keyboard_ungrab( Gtk2->get_current_event_time ); my ( $window_at_pointer, $x, $y, $mask ) = $self->{_root}->get_pointer; $self->{_prop_window}->move( $x, $y ); $self->{_prop_window}->show_all; $self->{_prop_active} = TRUE; Gtk2::Gdk->keyboard_grab( $self->{_prop_window}->window, 0, Gtk2->get_current_event_time ); } #abort screenshot } elsif ( $event->keyval == Gtk2::Gdk->keyval_from_name('Escape') ) { $self->quit; } } ); my $hide_btn = Gtk2::Button->new_with_mnemonic( $d->get("_Hide") ); $hide_btn->set_image( Gtk2::Image->new_from_stock( 'gtk-close', 'button' ) ); $hide_btn->can_default(TRUE); $hide_btn->signal_connect( 'clicked' => sub { Gtk2::Gdk->keyboard_ungrab( Gtk2->get_current_event_time ); $prop_dialog->hide_all; $self->{_prop_active} = FALSE; Gtk2::Gdk->keyboard_grab( $self->{_select_window}->window, 0, Gtk2->get_current_event_time ); } ); #final_packing #all labels = one size $xw_label->set_alignment( 0, 0.5 ); $yw_label->set_alignment( 0, 0.5 ); $widthw_label->set_alignment( 0, 0.5 ); $heightw_label->set_alignment( 0, 0.5 ); my $sg_main = Gtk2::SizeGroup->new('horizontal'); $sg_main->add_widget($xw_label); $sg_main->add_widget($yw_label); $sg_main->add_widget($widthw_label); $sg_main->add_widget($heightw_label); my $vbox = Gtk2::VBox->new( FALSE, 5 ); $vbox->pack_start( $xw_hbox, FALSE, FALSE, 3 ); $vbox->pack_start( $yw_hbox, FALSE, FALSE, 3 ); $vbox->pack_start( $ww_hbox, FALSE, FALSE, 3 ); $vbox->pack_start( $hw_hbox, FALSE, FALSE, 3 ); $vbox->pack_start( $hide_btn, FALSE, FALSE, 3 ); #nice frame as well my $frame_label = Gtk2::Label->new; $frame_label->set_markup( "" . $d->get("Selection") . "" ); my $frame = Gtk2::Frame->new(); $frame->set_border_width(5); $frame->set_label_widget($frame_label); $frame->set_shadow_type('none'); $frame->add($vbox); $prop_dialog->add($frame); $prop_dialog->realize; $prop_dialog->set_transient_for( $self->{_select_window} ); $prop_dialog->window->set_override_redirect(TRUE); return $prop_dialog; } sub take_screenshot { my $self = shift; my $s = shift; my $clean_pixbuf = shift; my $d = $self->{_sc}->get_gettext; my $output; #no delay? then we take a subsection of the pixbuf in memory if ( $s && $clean_pixbuf && $self->{_delay} == 0 ) { $output = $clean_pixbuf->new_subpixbuf( $s->x, $s->y, $s->width, $s->height ); #include cursor if ( $self->{_include_cursor} ) { $output = $self->include_cursor( $s->x, $s->y, $s->width, $s->height, $self->{_root}, $output ); } #if there is a delay != 0 set, we have to wait and get a new pixbuf from the root window } elsif ( $s && $self->{_delay} != 0 ) { ($output) = $self->get_pixbuf_from_drawable( $self->{_root}, $s->x, $s->y, $s->width, $s->height ); #section not valid } else { $output = 0; } #we don't have a useful string for wildcards (e.g. $name) if ( $output =~ /Gtk2/ ) { $self->{_action_name} = $d->get("Selection"); } #set history object if ($s) { $self->{_history} = Shutter::Screenshot::History->new( $self->{_sc}, $self->{_root}, $s->x, $s->y, $s->width, $s->height ); } return $output; } sub redo_capture { my $self = shift; my $output = 3; if ( defined $self->{_history} ) { ($output) = $self->get_pixbuf_from_drawable( $self->{_history}->get_last_capture ); } return $output; } sub get_history { my $self = shift; return $self->{_history}; } sub get_error_text { my $self = shift; return $self->{_error_text}; } sub get_action_name { my $self = shift; return $self->{_action_name}; } sub quit { my $self = shift; $self->ungrab_pointer_and_keyboard( FALSE, FALSE, TRUE ); $self->clean; } sub clean { my $self = shift; $self->{_selector}->signal_handler_disconnect( $self->{_selector_handler} ); $self->{_view}->signal_handler_disconnect( $self->{_view_zoom_handler} ); $self->{_view}->signal_handler_disconnect( $self->{_view_button_handler} ); $self->{_view}->signal_handler_disconnect( $self->{_view_event_handler} ); $self->{_select_window}->destroy; $self->{_zoom_window}->destroy; $self->{_prop_window}->destroy; } 1; shutter-0.90.1/share/shutter/resources/modules/Shutter/Screenshot/SelectorAuto.pm0000644000175000017500000000474512206477313027322 0ustar mariomario################################################### # # Copyright (C) 2008-2013 Mario Kemper # # This file is part of Shutter. # # Shutter is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 3 of the License, or # (at your option) any later version. # # Shutter is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License # along with Shutter; if not, write to the Free Software # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA # ################################################### package Shutter::Screenshot::SelectorAuto; #modules #-------------------------------------- use utf8; use strict; use warnings; use Shutter::Screenshot::Main; use Shutter::Screenshot::History; use Data::Dumper; our @ISA = qw(Shutter::Screenshot::Main); #Glib use Glib qw/TRUE FALSE/; #-------------------------------------- sub new { my $class = shift; #call constructor of super class (shutter_common, include_cursor, delay, notify_timeout) my $self = $class->SUPER::new( shift, shift, shift, shift ); bless $self, $class; return $self; } sub select_auto { my $self = shift; my $x = shift; my $y = shift; my $width = shift; my $height = shift; my $d = $self->{_sc}->get_gettext; my $output; if ($x && $y && $width && $height) { ($output) = $self->get_pixbuf_from_drawable( $self->{_root}, $x, $y, $width, $height ); #section not valid } else { $output = 0; } #we don't have a useful string for wildcards (e.g. $name) if($output =~ /Gtk2/){ $self->{_action_name} = $d->get("Selection"); } #set history object if($output){ $self->{_history} = Shutter::Screenshot::History->new($self->{_sc}, $self->{_root}, $x, $y, $width, $height); } return $output; } sub redo_capture { my $self = shift; my $output = 3; if(defined $self->{_history}){ ($output) = $self->get_pixbuf_from_drawable($self->{_history}->get_last_capture); } return $output; } sub get_history { my $self = shift; return $self->{_history}; } sub get_error_text { my $self = shift; return $self->{_error_text}; } sub get_action_name { my $self = shift; return $self->{_action_name}; } 1; shutter-0.90.1/share/shutter/resources/modules/Shutter/Screenshot/Window.pm0000644000175000017500000011605412206477313026155 0ustar mariomario################################################### # # Copyright (C) 2008-2013 Mario Kemper # # This file is part of Shutter. # # Shutter is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 3 of the License, or # (at your option) any later version. # # Shutter is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License # along with Shutter; if not, write to the Free Software # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA # ################################################### package Shutter::Screenshot::Window; #modules #-------------------------------------- use utf8; use strict; use warnings; #File operations use IO::File(); use Shutter::Screenshot::Main; use Shutter::Screenshot::History; use Data::Dumper; our @ISA = qw(Shutter::Screenshot::Main); #Glib use Gtk2; use Glib qw/TRUE FALSE/; #-------------------------------------- sub new { my $class = shift; #call constructor of super class (shutter_common, include_cursor, delay, notify_timeout) my $self = $class->SUPER::new( shift, shift, shift, shift ); #get params $self->{_include_border} = shift; $self->{_windowresize} = shift; $self->{_windowresize_w} = shift; $self->{_windowresize_h} = shift; $self->{_hide_time} = shift; #a short timeout to give the server a chance to redraw the area that was obscured $self->{_mode} = shift; $self->{_auto_shape} = shift; #shape the window without XShape support $self->{_is_hidden} = shift; $self->{_show_visible} = shift; #show user-visible windows only when selecting a window $self->{_ignore_type} = shift; #Ignore possibly wrong type hints #X11 protocol and XSHAPE ext require X11::Protocol; $self->{_x11} = X11::Protocol->new( $ENV{ 'DISPLAY' } ); $self->{_x11}{ext_shape} = $self->{_x11}->init_extension('SHAPE'); #main window $self->{_main_gtk_window} = $self->{_sc}->get_mainwindow; #only used when selecting a window if(defined $self->{_mode} && $self->{_mode} =~ m/(window|section)/ig){ #check if compositing is available my $compos = $self->{_main_gtk_window}->get_screen->is_composited; #higlighter (borderless gtk window) $self->{_highlighter} = Gtk2::Window->new('popup'); if($compos){ $self->{_highlighter}->set_colormap($self->{_main_gtk_window}->get_screen->get_rgba_colormap); } $self->{_highlighter}->set_app_paintable(TRUE); $self->{_highlighter}->set_decorated(FALSE); $self->{_highlighter}->set_skip_taskbar_hint(TRUE); $self->{_highlighter}->set_skip_pager_hint(TRUE); $self->{_highlighter}->set_keep_above(TRUE); $self->{_highlighter}->set_accept_focus(FALSE); #obtain current colors and font_desc from the main window my $style = $self->{_main_gtk_window}->get_style; my $sel_bg = $style->bg('selected'); my $sel_tx = $style->text('selected'); my $font_fam = $style->font_desc->get_family; my $font_size = $style->font_desc->get_size / Gtk2::Pango->scale; #get current monitor my $mon = $self->get_current_monitor; $self->{_highlighter_expose} = $self->{_highlighter}->signal_connect('expose-event' => sub{ return FALSE unless $self->{_highlighter}->window; #Place window and resize it $self->{_highlighter}->window->move_resize($self->{_c}{'cw'}{'x'}-3, $self->{_c}{'cw'}{'y'}-3 ,$self->{_c}{'cw'}{'width'}+6, $self->{_c}{'cw'}{'height'}+6); print $self->{_c}{'cw'}{'window'}->get_name, "\n" if $self->{_sc}->get_debug; my $text = Glib::Markup::escape_text ($self->{_c}{'cw'}{'window'}->get_name); utf8::decode $text; my $sec_text = "\n".$self->{_c}{'cw'}{'width'} . "x" . $self->{_c}{'cw'}{'height'}; #window size and position my ($w, $h) = $self->{_highlighter}->get_size; my ($x, $y) = $self->{_highlighter}->get_position; #app icon my $icon = $self->{_c}{'cw'}{'window'}->get_icon; #create cairo context my $cr = Gtk2::Gdk::Cairo::Context->create ($self->{_highlighter}->window); #pango layout my $layout = Gtk2::Pango::Cairo::create_layout($cr); $layout->set_width( ($w - $icon->get_width - $font_size * 3) * Gtk2::Pango->scale ); $layout->set_alignment('left'); $layout->set_wrap('char'); #warning if there are no subwindows #when we are in section mode and #a toplevel window was already selected if($self->{_c}{'ws'}){ my $xwindow = $self->{_c}{'ws'}->XWINDOW; if (scalar @{$self->{_c}{'cw'}{$xwindow}} <= 1){ #error icon $icon = Gtk2::Widget::render_icon (Gtk2::Invisible->new, "gtk-dialog-error", 'dialog'); #error message my $d = $self->{_sc}->get_gettext; $text = $d->get("No subwindow detected"); $sec_text = "\n".$d->get("Maybe this window is using client-side windows (or similar).\nShutter is not yet able to query the tree information of such windows."); #wrap nicely $layout->set_wrap('word-char'); } } #set text $layout->set_markup("$text$sec_text"); #get layout size my ( $lw, $lh ) = $layout->get_pixel_size; #adjust values $lw += $icon->get_width; $lh = $icon->get_height if $icon->get_height > $lh; #calculate values for rounded/shaped rectangle my $wi = $lw + $font_size * 3; my $hi = $lh + $font_size * 2; my $xi = int( ($w - $wi) / 2 ); my $yi = int( ($h - $hi) / 2 ); my $ri = 20; #two different ways - compositing or not if($compos){ #fill window $cr->set_operator('source'); $cr->set_source_rgba( $sel_bg->red / 257 / 255, $sel_bg->green / 257 / 255, $sel_bg->blue / 257 / 255, 0.3 ); $cr->paint; #Parent window with text and icon if($self->{_c}{'cw'}{'is_parent'}){ $cr->set_operator('over'); #create small frame (window outlines) $cr->set_source_rgba( $sel_bg->red / 257 / 255, $sel_bg->green / 257 / 255, $sel_bg->blue / 257 / 255, 0.75 ); $cr->set_line_width(6); $cr->rectangle (0, 0, $w, $h); $cr->stroke; if($lw <= $w && $lh <= $h){ #rounded rectangle to display the window name $cr->move_to( $xi + $ri, $yi ); $cr->line_to( $xi + $wi - $ri, $yi ); $cr->curve_to( $xi + $wi, $yi, $xi + $wi, $yi, $xi + $wi, $yi + $ri ); $cr->line_to( $xi + $wi, $yi + $hi - $ri ); $cr->curve_to( $xi + $wi, $yi + $hi, $xi + $wi, $yi + $hi, $xi + $wi - $ri, $yi + $hi ); $cr->line_to( $xi + $ri, $yi + $hi ); $cr->curve_to( $xi, $yi + $hi, $xi, $yi + $hi, $xi, $yi + $hi - $ri ); $cr->line_to( $xi, $yi + $ri ); $cr->curve_to( $xi, $yi, $xi, $yi, $xi + $ri, $yi ); $cr->fill; #app icon Gtk2::Gdk::Cairo::Context::set_source_pixbuf( $cr, $icon, $xi + $font_size, $yi + $font_size ); $cr->paint; #draw the pango layout $cr->move_to( $xi + $font_size*2 + $icon->get_width, $yi + $font_size ); Gtk2::Pango::Cairo::show_layout( $cr, $layout ); } }else{ #create small frame $cr->set_source_rgba( $sel_bg->red / 257 / 255, $sel_bg->green / 257 / 255, $sel_bg->blue / 257 / 255, 0.75 ); $cr->set_line_width(6); $cr->rectangle (0, 0, $w, $h); $cr->stroke; } #no compositing }else{ #fill window $cr->set_operator('over'); $cr->set_source_rgb( $sel_bg->red / 257 / 255, $sel_bg->green / 257 / 255, $sel_bg->blue / 257 / 255 ); $cr->paint; #Parent window with text and icon if($self->{_c}{'cw'}{'is_parent'}){ if($lw <= $w && $lh <= $h){ #app icon Gtk2::Gdk::Cairo::Context::set_source_pixbuf( $cr, $icon, $xi + $font_size, $yi + $font_size ); $cr->paint; #draw the pango layout $cr->move_to( $xi + $font_size*2 + $icon->get_width, $yi + $font_size ); Gtk2::Pango::Cairo::show_layout( $cr, $layout ); } } my $rectangle1 = Gtk2::Gdk::Rectangle->new (0, 0, $w, $h); my $rectangle2 = Gtk2::Gdk::Rectangle->new (3, 3, $w-6, $h-6); my $rectangle3 = Gtk2::Gdk::Rectangle->new ($xi, $yi, $wi, $hi); my $shape_region1 = Gtk2::Gdk::Region->rectangle ($rectangle1); my $shape_region2 = Gtk2::Gdk::Region->rectangle ($rectangle2); my $shape_region3 = Gtk2::Gdk::Region->rectangle ($rectangle3); #Parent window with text and icon if($self->{_c}{'cw'}{'is_parent'}){ if($lw <= $w && $lh <= $h){ $shape_region2->subtract($shape_region3); } } $shape_region1->subtract($shape_region2); $self->{_highlighter}->window->shape_combine_region ($shape_region1, 0, 0); } return TRUE; }); } bless $self, $class; return $self; } #~ sub DESTROY { #~ my $self = shift; #~ print "$self dying at\n"; #~ } #~ sub find_wm_window { my $self = shift; my $xid = shift; do { my ( $qroot, $qparent, @qkids ) = $self->{_x11}->QueryTree($xid); return undef unless ( $qroot || $qparent ); return $xid if ( $qroot == $qparent ); $xid = $qparent; } while (TRUE); } sub get_shape { my $self = shift; my $xid = shift; my $orig = shift; my $l_cropped = shift; my $r_cropped = shift; my $t_cropped = shift; my $b_cropped = shift; print "$l_cropped, $r_cropped, $t_cropped, $b_cropped cropped\n" if $self->{_sc}->get_debug; print "Calculating window shape\n" if $self->{_sc}->get_debug; #check if extenstion is available and use it my ($ordering, @r) = (undef, undef); if($self->{_x11}{ext_shape}){ ($ordering, @r) = $self->{_x11}->ShapeGetRectangles($self->find_wm_window($xid), 'Bounding'); } my $manually_shaped = FALSE; #create shape manually when option is set and the shape was not detected automatically if (scalar @r <= 1 && defined $self->{_auto_shape} && $self->{_auto_shape}){ my $shf = Shutter::App::HelperFunctions->new( $self->{_sc} ); my $shape_path = undef; $shape_path = $self->{_sc}->get_root . "/share/shutter/resources/conf/shape.conf" if $shf->file_exists($self->{_sc}->get_root . "/share/shutter/resources/conf/shape.conf"); $shape_path = "$ENV{'HOME'}/.shutter/shape.conf" if $shf->file_exists("$ENV{'HOME'}/.shutter/shape.conf"); if(defined $shape_path && $shape_path){ my @fregion; my $fh = new IO::File; if ($fh->open("< $shape_path")) { while( my $line = <$fh> ){ #skip on comments next if $line =~ /^#/; chomp($line); push @fregion, $line; } $fh->close; }else{ print "Unable to open file $shape_path" if $self->{_sc}->get_debug; return $orig; } print "Window shape not detected - using $shape_path\n" if $self->{_sc}->get_debug; #remove current entry pop @r; my $width = $orig->get_width; my $height = $orig->get_height; foreach my $line(@fregion){ $line =~ s/width/$width/; $line =~ s/height/$height/; $line =~ s/(\d+)-(\d+)/$1-$2/eg; my @temp = split(' ', $line); push @r, \@temp; } $manually_shaped = TRUE; }else{ print "Unable to locate shape.conf\n" if $self->{_sc}->get_debug; } #do nothing if there are no #shape rectangles (or only one) }elsif(scalar @r <= 1){ return $orig; } #create a region from the bounding rectangles my $bregion = Gtk2::Gdk::Region->new; foreach my $r (@r){ my @rect = @{$r}; next unless defined $rect[0]; next unless defined $rect[1]; next unless defined $rect[2]; next unless defined $rect[3]; unless($manually_shaped){ #adjust rectangle if window is only partially visible if($l_cropped){ $rect[2] -= $l_cropped - $rect[0]; $rect[0] = 0; } if($t_cropped){ $rect[3] -= $t_cropped - $rect[1]; $rect[1] = 0; } } print "Current $rect[0],$rect[1],$rect[2],$rect[3]\n" if $self->{_sc}->get_debug; $bregion->union_with_rect(Gtk2::Gdk::Rectangle->new ($rect[0],$rect[1],$rect[2],$rect[3])); } if(defined $orig){ #create target pixbuf with dimensions if selected/current window my $target = Gtk2::Gdk::Pixbuf->new ($orig->get_colorspace, TRUE, 8, $orig->get_width, $orig->get_height); #whole pixbuf is transparent $target->fill(0x00000000); #copy all rectangles of bounding region to the target pixbuf foreach my $r($bregion->get_rectangles){ print $r->x." ".$r->y." ".$r->width." ".$r->height."\n" if $self->{_sc}->get_debug; next if($r->x > $orig->get_width); next if($r->y > $orig->get_height); $r->width($orig->get_width - $r->x) if($r->x+$r->width > $orig->get_width); $r->height($orig->get_height - $r->y) if($r->y+$r->height > $orig->get_height); if($r->x >= 0 && $r->x + $r->width <= $orig->get_width && $r->y >= 0 && $r->y + $r->height <= $orig->get_height){ $orig->copy_area ($r->x, $r->y, $r->width, $r->height, $target, $r->x, $r->y); }else{ warn "WARNING: There was an error while calculating the window shape\n"; return $orig; } } return $target; }else{ return $bregion; } } sub get_window_size { my ( $self, $wnck_window, $gdk_window, $border, $no_resize ) = @_; #windowresize is active if($self->{_mode} eq "window" || $self->{_mode} eq "tray_window" || $self->{_mode} eq "awindow" || $self->{_mode} eq "tray_awindow"){ unless($no_resize){ if(defined $self->{_windowresize} && $self->{_windowresize}) { #windows can usually not be resized when maximized if($wnck_window->is_maximized){ $wnck_window->unmaximize; } $self->quit_eventh_only; Glib::Timeout->add ($self->{_hide_time}, sub{ Gtk2->main_quit; return FALSE; }); Gtk2->main(); my ($xc, $yc, $wc, $hc) = $self->get_window_size($wnck_window, $gdk_window, $border, TRUE); if(defined $self->{_windowresize_w} && $self->{_windowresize} > 0){ $wc = $self->{_windowresize_w}; } if(defined $self->{_windowresize_h} && $self->{_windowresize_h} > 0){ $hc = $self->{_windowresize_h}; } if($border){ $wnck_window->set_geometry ('current', [qw/width height/], $xc, $yc, $wc, $hc); }else{ $gdk_window->resize ($wc, $hc); } Glib::Timeout->add ($self->{_hide_time}, sub{ Gtk2->main_quit; return FALSE; }); Gtk2->main(); } } } #calculate size of the window my ( $xp, $yp, $wp, $hp ) = (0, 0, 0, 0); if ($border) { ( $xp, $yp, $wp, $hp ) = $wnck_window->get_geometry; } else { ( $xp, $yp, $wp, $hp ) = $gdk_window->get_geometry; ( $xp, $yp ) = $gdk_window->get_origin; } return ( $xp, $yp, $wp, $hp ); } sub update_highlighter { my $self = shift; if(defined $self->{_c}{'cw'}{'gdk_window'} && defined $self->{_c}{'cw'}{'window'}){ #and show highlighter window at current cursor position $self->{_highlighter}->show_all; $self->{_highlighter}->queue_draw; Gtk2::Gdk->keyboard_grab( $self->{_highlighter}->window, 0, Gtk2->get_current_event_time ); #save last window objects $self->{_c}{'lw'}{'window'} = $self->{_c}{'cw'}{'window'}; $self->{_c}{'lw'}{'gdk_window'} = $self->{_c}{'cw'}{'gdk_window'}; } } sub find_current_parent_window { my $self = shift; my $event = shift; my $active_workspace = shift; #get all toplevel windows my @wnck_windows = $self->{_wnck_screen}->get_windows_stacked; #show user-visible windows only when selecting a window if(defined $self->{_show_visible} && $self->{_show_visible}){ @wnck_windows = reverse @wnck_windows; } foreach my $cwdow (@wnck_windows) { my $drawable = Gtk2::Gdk::Window->foreign_new( $cwdow->get_xid ); if(defined $drawable){ #do not detect shutter window when it is hidden if ( $self->{_main_gtk_window}->window && $self->{_is_hidden} ) { next if ( $cwdow->get_xid == $self->{_main_gtk_window}->window->get_xid ); } my ( $xp, $yp, $wp, $hp ) = $self->get_window_size( $cwdow, $drawable, $self->{_include_border}, TRUE ); my $wr = Gtk2::Gdk::Region->rectangle( Gtk2::Gdk::Rectangle->new( $xp, $yp, $wp, $hp ) ); if ($cwdow->is_visible_on_workspace($active_workspace) && $wr->point_in( $event->x, $event->y ) && $wp * $hp <= $self->{_min_size}) { $self->{_c}{'cw'}{'window'} = $cwdow; $self->{_c}{'cw'}{'gdk_window'} = $drawable; $self->{_c}{'cw'}{'x'} = $xp; $self->{_c}{'cw'}{'y'} = $yp; $self->{_c}{'cw'}{'width'} = $wp; $self->{_c}{'cw'}{'height'} = $hp; $self->{_c}{'cw'}{'is_parent'} = TRUE; $self->{_min_size} = $wp * $hp; #show user-visible windows only when selecting a window if(defined $self->{_show_visible} && $self->{_show_visible}){ last; } } #size and geometry check } #not defined gdk::window } #end if toplevel window loop return TRUE; } sub find_current_child_window { my ( $self, $event, $xwindow, $xparent, $depth, $limit, $type_hint ) = @_; #reparenting depth and recursion limit $depth = 0 unless defined $depth; $limit = 0 unless defined $limit; if ($depth > $limit){ return TRUE; } my ( $qroot, $qparent, @qkids ); unless(defined $self->{_c}{'cw'}{$xwindow} && scalar @{$self->{_c}{'cw'}{$xwindow}}){ #query all child windows of xwindow ( $qroot, $qparent, @qkids ) = $self->{_x11}->QueryTree($xwindow); #and save them, so we don't have to query them again @{$self->{_c}{'cw'}{$xwindow}} = @qkids; }else{ #we can use the cached children information @qkids = @{$self->{_c}{'cw'}{$xwindow}}; } foreach my $kid (reverse @qkids) { my $gdk_window = Gtk2::Gdk::Window->foreign_new($kid); if ( defined $gdk_window ) { #window needs to be viewable and visible next unless $gdk_window->is_visible; next unless $gdk_window->is_viewable; #check type_hint if(defined $type_hint){ my $curr_type_hint = $gdk_window->get_type_hint; next unless $curr_type_hint =~ /$type_hint/; } #~ print $curr_type_hint, " - passed \n"; #min size my ( $xp, $yp, $wp, $hp, $depthp ) = $gdk_window->get_geometry; ( $xp, $yp ) = $gdk_window->get_origin; next if ( $wp * $hp < 4 ); my $sr = Gtk2::Gdk::Region->rectangle( Gtk2::Gdk::Rectangle->new( $xp, $yp, $wp, $hp ) ); if ( $sr->point_in( $event->x, $event->y ) && $wp * $hp <= $self->{_min_size} ) { $self->{_c}{'cw'}{'gdk_window'} = $gdk_window; $self->{_c}{'cw'}{'x'} = $xp; $self->{_c}{'cw'}{'y'} = $yp; $self->{_c}{'cw'}{'width'} = $wp; $self->{_c}{'cw'}{'height'} = $hp; $self->{_c}{'cw'}{'is_parent'} = FALSE; $self->{_min_size} = $wp * $hp; #~ print $self->{_c}{'cw'}{'x'}, " - ", #~ $self->{_c}{'cw'}{'y'}, " - ", #~ $self->{_c}{'cw'}{'width'}, " - ", #~ $self->{_c}{'cw'}{'height'}, " \n " if $self->{_sc}->get_debug; #check next depth unless($gdk_window->XWINDOW == $xwindow){ $self->find_current_child_window( $event, $gdk_window->XWINDOW, $xparent, $depth++, $limit, $type_hint ); }else{ last; } #~ last; } } } return TRUE; } sub find_active_window { my $self = shift; my $gdk_window = $self->{_gdk_screen}->get_active_window; if ( defined $gdk_window ) { my $wnck_window = Gnome2::Wnck::Window->get( $gdk_window->get_xid ); if ( defined $wnck_window ) { return ($wnck_window, $gdk_window); } } return FALSE; } sub find_region_for_window_type { my ( $self, $xwindow, $type_hint) = @_; #XQueryTree - query window tree information my ( $qroot, $qparent, @qkids ) = $self->{_x11}->QueryTree($xwindow); foreach my $kid (reverse @qkids) { my $gdk_window = Gtk2::Gdk::Window->foreign_new($kid); if ( defined $gdk_window ) { #check type_hint my $curr_type_hint = $gdk_window->get_type_hint; if(defined $type_hint){ next unless $curr_type_hint =~ /$type_hint/; } #XGetWindowAttributes, XGetGeometry, XWindowAttributes - get current #window attribute or geometry and current window attributes structure my @atts = $self->{_x11}->GetWindowAttributes($kid); return unless @atts; #window needs to be viewable return FALSE unless $atts[19] eq 'Viewable'; #min size my ( $xp, $yp, $wp, $hp, $depthp ) = $gdk_window->get_geometry; ( $xp, $yp ) = $gdk_window->get_origin; #~ print $xp, " - ", $yp, " - ", $wp, " - ", $hp, "\n"; #create region my $sr = Gtk2::Gdk::Region->rectangle( Gtk2::Gdk::Rectangle->new( $xp, $yp, $wp, $hp ) ); #init region unless(defined $self->{_c}{'cw'}{'window_region'}){ $self->{_c}{'cw'}{'window_region'} = Gtk2::Gdk::Region->new; $self->{_c}{'cw'}{'window_region'}->union($sr); }else{ $self->{_c}{'cw'}{'window_region'}->union($sr); } #store clipbox geometry #~ my $cbox = $self->{_c}{'cw'}{'window_region'}->get_clipbox; my $cbox = $self->get_clipbox($self->{_c}{'cw'}{'window_region'}); $self->{_c}{'cw'}{'gdk_window'} = $gdk_window; $self->{_c}{'cw'}{'x'} = $cbox->x; $self->{_c}{'cw'}{'y'} = $cbox->y; $self->{_c}{'cw'}{'width'} = $cbox->width; $self->{_c}{'cw'}{'height'} = $cbox->height; $self->{_c}{'cw'}{'is_parent'} = FALSE; #~ print $self->{_c}{'cw'}{'x'}, " - ", #~ $self->{_c}{'cw'}{'y'}, " - ", #~ $self->{_c}{'cw'}{'width'}, " - ", #~ $self->{_c}{'cw'}{'height'}, " \n "; } } return TRUE; } sub select_window { my $self = shift; my $event = shift; my $active_workspace = shift; #select child window my $depth = shift; my $limit = shift; my $type_hint = shift; #root window size is minimum at startup $self->{_min_size} = $self->{_root}->{w} * $self->{_root}->{h}; #if there is no window already selected unless ($self->{_c}{'ws'}) { $self->find_current_parent_window($event, $active_workspace); #parent window selected/no grab, search for children now }elsif ( ( $self->{_mode} eq "section" || $self->{_mode} eq "tray_section" ) && $self->{_c}{'ws'} ) { $self->find_current_child_window($event, $self->{_c}{'ws'}->XWINDOW, $self->{_c}{'ws'}->XWINDOW, $depth, $limit, $type_hint); } #draw highlighter if needed if ( (Gtk2::Gdk->pointer_is_grabbed && ($self->{_c}{'lw'}{'gdk_window'} ne $self->{_c}{'cw'}{'gdk_window'})) || (Gtk2::Gdk->pointer_is_grabbed && $self->{_c}{'ws_init'}) ) { $self->update_highlighter(); #reset flag $self->{_c}{'ws_init'} = FALSE; } return TRUE; } sub window { my $self = shift; #return value my $output = 5; #current workspace my $active_workspace = $self->{_wnck_screen}->get_active_workspace; #something went wrong here, no active workspace detected unless ( $active_workspace ) { $output = 0; return $output; } #grab pointer and keyboard #when mode is section or window unless($self->{_mode} eq "menu" || $self->{_mode} eq "tray_menu" || $self->{_mode} eq "tooltip" || $self->{_mode} eq "tray_tooltip" || $self->{_mode} eq "awindow" || $self->{_mode} eq "tray_awindow"){ $self->{_highlighter}->realize; my $grab_counter = 0; while ( !Gtk2::Gdk->pointer_is_grabbed && $grab_counter < 100 ) { Gtk2::Gdk->pointer_grab( $self->{_root}, FALSE, [qw/pointer-motion-mask button-press-mask button-release-mask/], undef, Gtk2::Gdk::Cursor->new('GDK_HAND2'), Gtk2->get_current_event_time ); Gtk2::Gdk->keyboard_grab( $self->{_highlighter}->window, 0, Gtk2->get_current_event_time ); $grab_counter++; } } #init $self->{_c} = (); $self->{_c}{'ws'} = undef; $self->{_c}{'ws_init'} = FALSE; $self->{_c}{'lw'}{'gdk_window'} = 0; #root window size is minimum at startup $self->{_min_size} = $self->{_root}->{w} * $self->{_root}->{h}; $self->{_c}{'cw'}{'gdk_window'} = $self->{_root}; $self->{_c}{'cw'}{'x'} = $self->{_root}->{x}; $self->{_c}{'cw'}{'y'} = $self->{_root}->{y}; $self->{_c}{'cw'}{'width'} = $self->{_root}->{w}; $self->{_c}{'cw'}{'height'} = $self->{_root}->{h}; #get initial window under cursor my ( $window_at_pointer, $initx, $inity, $mask ) = $self->{_root}->get_pointer; #create event for current coordinates my $initevent = Gtk2::Gdk::Event->new ('motion-notify'); $initevent->set_time(Gtk2->get_current_event_time); $initevent->window($self->{_root}); $initevent->x($initx); $initevent->y($inity); if ( Gtk2::Gdk->pointer_is_grabbed && !($self->{_mode} eq "menu" || $self->{_mode} eq "tray_menu" || $self->{_mode} eq "tooltip" || $self->{_mode} eq "tray_tooltip" || $self->{_mode} eq "awindow" || $self->{_mode} eq "tray_awindow") ) { #simulate mouse movement $self->select_window($initevent, $active_workspace); Gtk2::Gdk::Event->handler_set( sub { my ( $event, $data ) = @_; return FALSE unless defined $event; #KEY-PRESS if ( $event->type eq 'key-press' ) { next unless defined $event->keyval; if ( $event->keyval == Gtk2::Gdk->keyval_from_name('Escape') ) { #destroy highlighter window $self->{_highlighter}->destroy; $self->quit; $output = 5; } #BUTTON-PRESS } elsif ( $event->type eq 'button-press' ) { print "Type: " . $event->type . "\n" if ( defined $event && $self->{_sc}->get_debug ); #user selects window or section $self->select_window($event, $active_workspace); #BUTTON-RELEASE } elsif ( $event->type eq 'button-release' ) { print "Type: " . $event->type . "\n" if ( defined $event && $self->{_sc}->get_debug ); my ( $xp, $yp, $wp, $hp, $xc, $yc, $wc, $hc ) = (0, 0, 0, 0, 0, 0, 0, 0); if ( defined $self->{_c}{'lw'} && $self->{_c}{'lw'}{'gdk_window'} ) { #size (we need to do this again because of autoresizing) if ( ( $self->{_mode} eq "window" || $self->{_mode} eq "tray_window" || $self->{_mode} eq "awindow" || $self->{_mode} eq "tray_awindow" ) ) { ( $xc, $yc, $wc, $hc ) = $self->get_window_size( $self->{_c}{'lw'}{'window'}, $self->{_c}{'lw'}{'gdk_window'}, $self->{_include_border}, TRUE ); ( $xp, $yp, $wp, $hp ) = $self->get_window_size( $self->{_c}{'lw'}{'window'}, $self->{_c}{'lw'}{'gdk_window'}, $self->{_include_border} ); $self->{_c}{'cw'}{'x'} = $xp; $self->{_c}{'cw'}{'y'} = $yp; $self->{_c}{'cw'}{'width'} = $wp; $self->{_c}{'cw'}{'height'} = $hp; } #focus selected window (maybe it is hidden) $self->{_c}{'lw'}{'gdk_window'}->focus($event->time); Gtk2::Gdk->flush; #something went wrong here, no window on screen detected } else { $output = 0; $self->quit; return $output; } #looking for a section of a window? #keep current window in mind and search for children if ( ( $self->{_mode} eq "section" || $self->{_mode} eq "tray_section" ) && !$self->{_c}{'ws'} ) { #mark as selected parent window $self->{_c}{'ws'} = $self->{_c}{'cw'}{'gdk_window'}; $self->{_c}{'ws_init'} = TRUE; #and select current subwindow $self->select_window($event); #we don't take the screenshot yet return TRUE; } #stop event handler $self->quit_eventh_only; #destroy highlighter window $self->{_highlighter}->destroy; #A short timeout to give the server a chance to #redraw the area Glib::Timeout->add ($self->{_hide_time}, sub{ Gtk2->main_quit; return FALSE; }); Gtk2->main(); my ($output_new, $l_cropped, $r_cropped, $t_cropped, $b_cropped) = $self->get_pixbuf_from_drawable( $self->{_root}, $self->{_c}{'cw'}{'x'}, $self->{_c}{'cw'}{'y'}, $self->{_c}{'cw'}{'width'}, $self->{_c}{'cw'}{'height'} ); #save return value to current $output variable #-> ugly but fastest and safest solution now $output = $output_new; #respect rounded corners of wm decorations (metacity for example - does not work with compiz currently) if($self->{_include_border}){ my $xid = $self->{_c}{ 'cw' }{ 'gdk_window' }->get_xid; #do not try this for child windows foreach my $win ($self->{_wnck_screen}->get_windows){ if($win->get_xid == $xid){ $output = $self->get_shape($xid, $output, $l_cropped, $r_cropped, $t_cropped, $b_cropped); last; } } } #restore window size when autoresizing was used if($self->{_mode} eq "window" || $self->{_mode} eq "tray_window" || $self->{_mode} eq "awindow" || $self->{_mode} eq "tray_awindow"){ if(defined $self->{_windowresize} && $self->{_windowresize}) { if($wc != $wp || $hc != $hp){ if($self->{_include_border}){ $self->{_c}{'lw'}{'window'}->set_geometry ('current', [qw/width height/], $xc, $yc, $wc, $hc); }else{ $self->{_c}{'lw'}{'gdk_window'}->resize ($wc, $hc); } } } } #set name of the captured window #e.g. for use in wildcards if($output =~ /Gtk2/ && defined $self->{_c}{'cw'}{'window'}){ $self->{_action_name} = $self->{_c}{'cw'}{'window'}->get_name; } #set history object $self->{_history} = Shutter::Screenshot::History->new($self->{_sc}, $self->{_root}, $self->{_c}{'cw'}{'x'}, $self->{_c}{'cw'}{'y'}, $self->{_c}{'cw'}{'width'}, $self->{_c}{'cw'}{'height'}, undef, $self->{_c}{'cw'}{'window'}->get_xid, $self->{_c}{'cw'}{'gdk_window'}->get_xid ); $self->quit; #MOTION-NOTIFY } elsif ( $event->type eq 'motion-notify' ) { print "Type: " . $event->type . "\n" if ( defined $event && $self->{_sc}->get_debug ); #user selects window or section $self->select_window($event, $active_workspace); } else { Gtk2->main_do_event($event); } } ); Gtk2->main; #pointer not grabbed } else { $output = 0; my ( $xp, $yp, $wp, $hp, $xc, $yc, $wc, $hc ) = (0, 0, 0, 0, 0, 0, 0, 0); if ( ( $self->{_mode} eq "window" || $self->{_mode} eq "tray_window" || $self->{_mode} eq "awindow" || $self->{_mode} eq "tray_awindow" ) ) { #and select current parent window my ($wnck_window, $gdk_window) = $self->find_active_window; if(defined $wnck_window && $wnck_window && defined $gdk_window && $gdk_window){ #get_size of it ( $xc, $yc, $wc, $hc ) = $self->get_window_size($wnck_window, $gdk_window, $self->{_include_border}, TRUE); ( $xp, $yp, $wp, $hp ) = $self->get_window_size($wnck_window, $gdk_window, $self->{_include_border}); $self->{_c}{'cw'}{'window'} = $wnck_window; $self->{_c}{'cw'}{'gdk_window'} = $gdk_window; $self->{_c}{'cw'}{'x'} = $xp; $self->{_c}{'cw'}{'y'} = $yp; $self->{_c}{'cw'}{'width'} = $wp; $self->{_c}{'cw'}{'height'} = $hp; $self->{_c}{'cw'}{'is_parent'} = TRUE; } }elsif ( ( $self->{_mode} eq "menu" || $self->{_mode} eq "tray_menu" ) ) { #and select current menu $self->find_region_for_window_type( $self->{_root}->XWINDOW, 'menu' ); #no window with type_hint eq 'menu' detected unless (defined $self->{_c}{'cw'}{'window_region'}){ if($self->{_ignore_type}){ warn "WARNING: No window with type hint 'menu' detected -> window type hint will be ignored, because workaround is enabled\n"; $self->find_region_for_window_type( $self->{_root}->XWINDOW ); }else{ return 2; } } }elsif ( ( $self->{_mode} eq "tooltip" || $self->{_mode} eq "tray_tooltip" ) ) { #and select current tooltip $self->find_region_for_window_type( $self->{_root}->XWINDOW, 'tooltip' ); #no window with type_hint eq 'tooltip' detected unless (defined $self->{_c}{'cw'}{'window_region'}){ if($self->{_ignore_type}){ warn "WARNING: No window with type hint 'tooltip' detected -> window type hint will be ignored, because workaround is enabled\n"; $self->find_region_for_window_type( $self->{_root}->XWINDOW ); }else{ return 2; } } #looking for a section of a window? #keep current window in mind and search for children }elsif ( ( $self->{_mode} eq "section" || $self->{_mode} eq "tray_section" ) ) { #mark as selected parent window $self->{_c}{'ws'} = $self->{_root}; #and select current subwindow $self->select_window($initevent); } my ($output_new, $l_cropped, $r_cropped, $t_cropped, $b_cropped) = $self->get_pixbuf_from_drawable( $self->{_root}, $self->{_c}{'cw'}{'x'}, $self->{_c}{'cw'}{'y'}, $self->{_c}{'cw'}{'width'}, $self->{_c}{'cw'}{'height'}, $self->{_c}{'cw'}{'window_region'} ); #save return value to current $output variable #-> ugly but fastest and safest solution now $output = $output_new; #respect rounded corners of wm decorations #(metacity for example - does not work with compiz currently) #only if toplevel window was selected if ( ( $self->{_mode} eq "window" || $self->{_mode} eq "tray_window" || $self->{_mode} eq "awindow" || $self->{_mode} eq "tray_awindow" ) ) { if($self->{_include_border}){ my $xid = $self->{_c}{ 'cw' }{ 'gdk_window' }->get_xid; #do not try this for child windows foreach my $win ($self->{_wnck_screen}->get_windows){ if($win->get_xid == $xid){ $output = $self->get_shape($xid, $output, $l_cropped, $r_cropped, $t_cropped, $b_cropped); last; } } } } #restore window size when autoresizing was used if($self->{_mode} eq "window" || $self->{_mode} eq "tray_window" || $self->{_mode} eq "awindow" || $self->{_mode} eq "tray_awindow"){ if(defined $self->{_windowresize} && $self->{_windowresize}) { if($wc != $wp || $hc != $hp){ if($self->{_include_border}){ $self->{_c}{'cw'}{'window'}->set_geometry ('current', [qw/width height/], $xc, $yc, $wc, $hc); }else{ $self->{_c}{'cw'}{'gdk_window'}->resize ($wc, $hc); } } } } #set name of the captured window #e.g. for use in wildcards my $d = $self->{_sc}->get_gettext; if ( ( $self->{_mode} eq "window" || $self->{_mode} eq "tray_window" || $self->{_mode} eq "awindow" || $self->{_mode} eq "tray_awindow" ) ) { if($output =~ /Gtk2/ && defined $self->{_c}{'cw'}{'window'}){ $self->{_action_name} = $self->{_c}{'cw'}{'window'}->get_name; } }elsif ( ( $self->{_mode} eq "section" || $self->{_mode} eq "tray_section" ) ) { if($output =~ /Gtk2/ && defined $self->{_c}{'cw'}{'window'}){ $self->{_action_name} = $self->{_action_name} = $self->{_c}{'cw'}{'window'}->get_name; } }elsif ( ( $self->{_mode} eq "menu" || $self->{_mode} eq "tray_menu" ) ) { if($output =~ /Gtk2/){ $self->{_action_name} = $d->get( "Menu" ); } }elsif ( ( $self->{_mode} eq "tooltip" || $self->{_mode} eq "tray_tooltip" ) ) { if($output =~ /Gtk2/){ $self->{_action_name} = $d->get( "Tooltip" ); } } if(defined $self->{_c}{'cw'}{'window'} && $self->{_c}{'cw'}{'gdk_window'}){ #set history object $self->{_history} = Shutter::Screenshot::History->new($self->{_sc}, $self->{_root}, $self->{_c}{'cw'}{'x'}, $self->{_c}{'cw'}{'y'}, $self->{_c}{'cw'}{'width'}, $self->{_c}{'cw'}{'height'}, $self->{_c}{'cw'}{'window_region'}, $self->{_c}{'cw'}{'window'}->get_xid, $self->{_c}{'cw'}{'gdk_window'}->get_xid ); }else{ #set history object $self->{_history} = Shutter::Screenshot::History->new($self->{_sc}, $self->{_root}, $self->{_c}{'cw'}{'x'}, $self->{_c}{'cw'}{'y'}, $self->{_c}{'cw'}{'width'}, $self->{_c}{'cw'}{'height'}, $self->{_c}{'cw'}{'window_region'}, ); } } return $output; } sub get_mode { my $self = shift; return $self->{_mode}; } sub redo_capture { my $self = shift; my $output = 3; if(defined $self->{_history}){ my ($last_drawable, $lxp, $lyp, $lwp, $lhp, $lregion, $wxid, $gxid) = $self->{_history}->get_last_capture; if(defined $gxid && defined $wxid){ #create windows my $gdk_window = Gtk2::Gdk::Window->foreign_new( $gxid ); my $wnck_window = Gnome2::Wnck::Window->get( $wxid ); if(defined $gdk_window && defined $wnck_window){ #store size my ( $xp, $yp, $wp, $hp, $xc, $yc, $wc, $hc ) = (0, 0, 0, 0, 0, 0, 0, 0); if($self->{_mode} eq "section" || $self->{_mode} eq "tray_section" ){ ( $xp, $yp, $wp, $hp ) = $gdk_window->get_geometry; ( $xp, $yp ) = $gdk_window->get_origin; #find parent window my $pxid = $self->find_wm_window($gxid); my $parent = Gtk2::Gdk::Window->foreign_new( $pxid ); if(defined $parent && $parent){ #and focus parent window (maybe it is hidden) $parent->focus(Gtk2->get_current_event_time); Gtk2::Gdk->flush; } }elsif($self->{_mode} eq "window" || $self->{_mode} eq "tray_window" || $self->{_mode} eq "awindow" || $self->{_mode} eq "tray_awindow"){ #get_size of it ( $xc, $yc, $wc, $hc ) = $self->get_window_size($wnck_window, $gdk_window, $self->{_include_border}, TRUE); ( $xp, $yp, $wp, $hp ) = $self->get_window_size($wnck_window, $gdk_window, $self->{_include_border}); } #focus selected window (maybe it is hidden) $gdk_window->focus(Gtk2->get_current_event_time); Gtk2::Gdk->flush; #A short timeout to give the server a chance to #redraw the area Glib::Timeout->add ($self->{_hide_time}, sub{ Gtk2->main_quit; return FALSE; }); Gtk2->main(); my ($output_new, $l_cropped, $r_cropped, $t_cropped, $b_cropped) = $self->get_pixbuf_from_drawable($self->{_root}, $xp, $yp, $wp, $hp); #save return value to current $output variable #-> ugly but fastest and safest solution now $output = $output_new; if($self->{_mode} eq "window" || $self->{_mode} eq "tray_window" || $self->{_mode} eq "awindow" || $self->{_mode} eq "tray_awindow"){ if($self->{_include_border}){ $output = $self->get_shape($gxid, $output, $l_cropped, $r_cropped, $t_cropped, $b_cropped); } } #restore window size when autoresizing was used if($self->{_mode} eq "window" || $self->{_mode} eq "tray_window" || $self->{_mode} eq "awindow" || $self->{_mode} eq "tray_awindow"){ if(defined $self->{_windowresize} && $self->{_windowresize}) { if($wc != $wp || $hc != $hp){ if($self->{_include_border}){ $wnck_window->set_geometry ('current', [qw/width height/], $xc, $yc, $wc, $hc); }else{ $gdk_window->resize ($wc, $hc); } } } } $self->quit_eventh_only; }else{ warn "WARNING: Could not get window with id $gxid\n"; $output = 4; } #no xid }else{ ($output) = $self->get_pixbuf_from_drawable($self->{_history}->get_last_capture); } } return $output; } sub get_history { my $self = shift; return $self->{_history}; } sub get_error_text { my $self = shift; return $self->{_error_text}; } sub get_action_name { my $self = shift; return $self->{_action_name}; } sub quit { my $self = shift; $self->ungrab_pointer_and_keyboard( FALSE, TRUE, TRUE ); Gtk2::Gdk->flush; } sub quit_eventh_only { my $self = shift; $self->ungrab_pointer_and_keyboard( FALSE, TRUE, FALSE ); Gtk2::Gdk->flush; } 1; shutter-0.90.1/share/shutter/resources/modules/Shutter/Screenshot/Workspace.pm0000644000175000017500000002074612206477313026646 0ustar mariomario################################################### # # Copyright (C) 2008-2013 Mario Kemper # # This file is part of Shutter. # # Shutter is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 3 of the License, or # (at your option) any later version. # # Shutter is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License # along with Shutter; if not, write to the Free Software # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA # ################################################### package Shutter::Screenshot::Workspace; #modules #-------------------------------------- use utf8; use strict; use warnings; use Shutter::Screenshot::Main; use Shutter::Screenshot::History; use Data::Dumper; our @ISA = qw(Shutter::Screenshot::Main); #Glib use Glib qw/TRUE FALSE/; #-------------------------------------- sub new { my $class = shift; #call constructor of super class (shutter_common, include_cursor, delay, notify_timeout) my $self = $class->SUPER::new( shift, shift, shift, shift ); $self->{_selected_workspace} = shift; $self->{_vpx} = shift; $self->{_vpy} = shift; $self->{_current_monitor_only} = shift; bless $self, $class; return $self; } #~ sub DESTROY { #~ my $self = shift; #~ print "$self dying at\n"; #~ } sub workspaces { my $self = shift; my $d = $self->{_sc}->get_gettext; my $active_workspace = $self->{_wnck_screen}->get_active_workspace; #valid workspace? return TRUE unless $active_workspace; my $active_vpx = $active_workspace->get_viewport_x; my $active_vpy = $active_workspace->get_viewport_y; #create shutter region object my $sr = Shutter::Geometry::Region->new(); #variables to save the pixbuf my $output = undef; my $pixbuf = undef; my $wspaces_region = Gtk2::Gdk::Region->new; my @pixbuf_array; my @rects_array; my $row = 0; my $column = 0; my $height = 0; my $width = 0; foreach my $space ( @{ $self->{_workspaces} } ) { next unless defined $space; #compiz if ( $self->{_wm_manager_name} =~ /compiz/i ){ #calculate viewports with size of workspace my $vpx = $space->get_viewport_x; my $vpy = $space->get_viewport_y; my $n_viewports_column = int( $space->get_width / $self->{_wnck_screen}->get_width ); my $n_viewports_rows = int( $space->get_height / $self->{_wnck_screen}->get_height ); #rows for ( my $j = 0; $j < $n_viewports_rows; $j++ ) { #columns for ( my $i = 0; $i < $n_viewports_column; $i++ ) { my @vp = ( $i * $self->{_wnck_screen}->get_width, $j * $self->{_wnck_screen}->get_height ); #set coordinates $self->{_vpx} = $vp[0]; $self->{_vpy} = $vp[1]; #and disable workspace $self->{_selected_workspace} = undef; #capture viewport $pixbuf = $self->workspace(TRUE, TRUE); my $rect = Gtk2::Gdk::Rectangle->new($width, $height, $pixbuf->get_width, $pixbuf->get_height); $wspaces_region->union_with_rect($rect); push @pixbuf_array, $pixbuf; push @rects_array, $rect; #increase width according to current column $width += $pixbuf->get_width; } #next row # > set height to clipbox-height # > set width to 0, because we start in column 0 again $height = $sr->get_clipbox($wspaces_region)->height; $width = 0; } #all other wm manager like metacity etc. }else{ #capture next workspace $self->{_selected_workspace} = $space->get_number; #~ print "Capturing Workspace: ".$space->get_number." Layout-Row:". $space->get_layout_row ." Layout-Column:". $space->get_layout_column ."\n"; $pixbuf = $self->workspace(TRUE, TRUE); if ($column < $space->get_layout_column){ $width += $pixbuf->get_width; }elsif ($column > $space->get_layout_column){ $width = 0; } $column = $space->get_layout_column; $height = $sr->get_clipbox($wspaces_region)->height if ($row != $space->get_layout_row); $row = $space->get_layout_row; my $rect = Gtk2::Gdk::Rectangle->new($width, $height, $pixbuf->get_width, $pixbuf->get_height); $wspaces_region->union_with_rect($rect); push @pixbuf_array, $pixbuf; push @rects_array, $rect; } } if($wspaces_region->get_rectangles){ $output = Gtk2::Gdk::Pixbuf->new ('rgb', TRUE, 8, $sr->get_clipbox($wspaces_region)->width, $sr->get_clipbox($wspaces_region)->height); $output->fill(0x00000000); #copy images to the blank pixbuf my $rect_counter = 0; foreach my $pixbuf (@pixbuf_array){ $pixbuf->copy_area (0, 0, $pixbuf->get_width, $pixbuf->get_height, $output, $rects_array[$rect_counter]->x, $rects_array[$rect_counter]->y); $rect_counter++; } } #this value will be overwritten - restore for history $self->{_selected_workspace} = 'all'; #set history object $self->{_history} = Shutter::Screenshot::History->new($self->{_sc}); #set name of the captured workspace #e.g. for use in wildcards if($output =~ /Gtk2/){ $self->{_action_name} = $d->get("Workspaces"); } #compiz if ( $self->{_wm_manager_name} =~ /compiz/i ){ $self->{_wnck_screen}->move_viewport( $active_vpx, $active_vpy ); #metacity etc. }else{ $active_workspace->activate(Gtk2->get_current_event_time); } return $output; } sub workspace { my $self = shift; my $no_active_check = shift || FALSE; my $no_finishing = shift || FALSE; my $wrksp_changed = FALSE; my $active_workspace = $self->{_wnck_screen}->get_active_workspace; #valid workspace? return TRUE unless $active_workspace; my $active_vpx = $active_workspace->get_viewport_x; my $active_vpy = $active_workspace->get_viewport_y; #metacity etc if ( defined $self->{_selected_workspace} ) { foreach my $space ( @{ $self->{_workspaces} } ) { next unless defined $space; if ( $self->{_selected_workspace} == $space->get_number && ($no_active_check || $self->{_selected_workspace} != $active_workspace->get_number) ) { $space->activate(Gtk2->get_current_event_time); $wrksp_changed = TRUE; } } #compiz } else { $self->{_wnck_screen}->move_viewport( $self->{_vpx}, $self->{_vpy} ); $wrksp_changed = TRUE; } #we need a minimum delay of 1 second #to give the server a chance to #redraw after switching workspaces if ( $self->{_delay} < 2 && $wrksp_changed ) { $self->{_delay} = 1; } my $output = undef; if ( $self->{_current_monitor_only} || $self->{_gdk_screen}->get_n_monitors <= 1) { ($output) = $self->get_pixbuf_from_drawable( $self->get_root_and_current_monitor_geometry ); #When there are multiple monitors with different resolutions, the visible area #within the root window may not be rectangular (it may have an L-shape, for #example). In that case, mask out the areas of the root window which would #not be visible in the monitors, so that screenshot do not end up with content #that the user won't ever see. # #comment copied from gnome-screenshot #http://svn.gnome.org/viewvc/gnome-utils/trunk/gnome-screenshot/screenshot-utils.c?view=markup } elsif($self->{_gdk_screen}->get_n_monitors > 1) { ($output) = $self->get_pixbuf_from_drawable( $self->get_root_and_geometry, $self->get_monitor_region ); } unless($no_finishing){ #set history object $self->{_history} = Shutter::Screenshot::History->new($self->{_sc}); #set name of the captured workspace #e.g. for use in wildcards if($output =~ /Gtk2/){ $self->{_action_name} = $self->{_wnck_screen}->get_active_workspace->get_name; } #metacity etc if ( $self->{_selected_workspace} ) { $active_workspace->activate(Gtk2->get_current_event_time) if $wrksp_changed; #compiz } else { $self->{_wnck_screen}->move_viewport( $active_vpx, $active_vpy ); } } return $output; } sub redo_capture { my $self = shift; my $output = 3; if(defined $self->{_history} && $self->{_selected_workspace} eq 'all'){ $output = $self->workspaces(); }elsif(defined $self->{_history}){ $output = $self->workspace(); } return $output; } sub get_history { my $self = shift; return $self->{_history}; } sub get_error_text { my $self = shift; return $self->{_error_text}; } sub get_action_name { my $self = shift; return $self->{_action_name}; } 1; shutter-0.90.1/share/shutter/resources/modules/Shutter/Screenshot/WindowXid.pm0000644000175000017500000001055612206477313026622 0ustar mariomario################################################### # # Copyright (C) 2008-2013 Mario Kemper # # This file is part of Shutter. # # Shutter is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 3 of the License, or # (at your option) any later version. # # Shutter is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License # along with Shutter; if not, write to the Free Software # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA # ################################################### package Shutter::Screenshot::WindowXid; #modules #-------------------------------------- use utf8; use strict; use warnings; use Shutter::Screenshot::Window; use Data::Dumper; our @ISA = qw(Shutter::Screenshot::Window); #Glib and Gtk2 use Gtk2; use Glib qw/TRUE FALSE/; #-------------------------------------- sub new { my $class = shift; #call constructor of super class (shutter_common, include_cursor, delay, notify_timeout, include_border, windowresize_active, windowresize_w, windowresize_h, hide_time, mode, autoshape) my $self = $class->SUPER::new( shift, shift, shift, shift, shift, shift, shift, shift, shift, shift, shift ); bless $self, $class; return $self; } #~ sub DESTROY { #~ my $self = shift; #~ print "$self dying at\n"; #~ } #~ sub window_by_xid { my $self = shift; my $xid = shift; my $gdk_window = Gtk2::Gdk::Window->foreign_new( $xid ); my $wnck_window = Gnome2::Wnck::Window->get( $xid ); #~ print $xid, " - ", $gdk_window, " - ", $wnck_window, "\n"; my $output = 0; if (defined $gdk_window && defined $wnck_window){ my ( $xc, $yc, $wc, $hc ) = $self->get_window_size( $wnck_window, $gdk_window, $self->{_include_border}, TRUE ); my ( $xp, $yp, $wp, $hp ) = $self->get_window_size( $wnck_window, $gdk_window, $self->{_include_border} ); #focus selected window (maybe it is hidden) $gdk_window->focus(Gtk2->get_current_event_time); Gtk2::Gdk->flush; #A short timeout to give the server a chance to #redraw the area Glib::Timeout->add ($self->{_hide_time}, sub{ Gtk2->main_quit; return FALSE; }); Gtk2->main(); my ($output_new, $l_cropped, $r_cropped, $t_cropped, $b_cropped) = $self->get_pixbuf_from_drawable($self->{_root}, $xp, $yp, $wp, $hp); #save return value to current $output variable #-> ugly but fastest and safest solution now $output = $output_new; #respect rounded corners of wm decorations (metacity for example - does not work with compiz currently) if($self->{_include_border}){ $output = $self->get_shape($xid, $output, $l_cropped, $r_cropped, $t_cropped, $b_cropped); } #restore window size when autoresizing was used if($self->{_mode} eq "window" || $self->{_mode} eq "tray_window" || $self->{_mode} eq "awindow" || $self->{_mode} eq "tray_awindow"){ if(defined $self->{_windowresize} && $self->{_windowresize}) { if($wc != $wp || $hc != $hp){ if($self->{_include_border}){ $wnck_window->set_geometry ('current', [qw/width height/], $xc, $yc, $wc, $hc); }else{ $gdk_window->resize ($wc, $hc); } } } } #set name of the captured window #e.g. for use in wildcards if($output =~ /Gtk2/){ $self->{_action_name} = $wnck_window->get_name; } #set history object $self->{_history} = Shutter::Screenshot::History->new($self->{_sc}, $self->{_root}, $xp, $yp, $wp, $hp, undef, $xid, $xid); $self->quit; }else{ $output = 4; } return $output; } sub redo_capture { my $self = shift; my $output = 3; if(defined $self->{_history}){ my ($last_drawable, $lxp, $lyp, $lwp, $lhp, $lregion, $wxid, $gxid) = $self->{_history}->get_last_capture; ($output) = $self->window_by_xid($wxid); } return $output; } sub get_history { my $self = shift; return $self->{_history}; } sub get_error_text { my $self = shift; return $self->{_error_text}; } sub get_action_name { my $self = shift; return $self->{_action_name}; } sub quit { my $self = shift; $self->ungrab_pointer_and_keyboard( FALSE, TRUE, FALSE ); Gtk2::Gdk->flush; } 1; shutter-0.90.1/share/shutter/resources/modules/Shutter/Screenshot/Web.pm0000644000175000017500000002060512206477313025417 0ustar mariomario################################################### # # Copyright (C) 2008-2013 Mario Kemper # # This file is part of Shutter. # # Shutter is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 3 of the License, or # (at your option) any later version. # # Shutter is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License # along with Shutter; if not, write to the Free Software # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA # ################################################### package Shutter::Screenshot::Web; #modules #-------------------------------------- use utf8; use strict; use warnings; use Proc::Killfam; use File::Temp qw/ tempfile tempdir /; #timing issues use Time::HiRes qw/ time usleep /; use Shutter::Screenshot::History; #Glib and Gtk2 use Gtk2; use Glib qw/TRUE FALSE/; #-------------------------------------- sub new { my $class = shift; my $self = { _sc => shift, _timeout => shift, _width => shift, }; bless $self, $class; return $self; } #~ sub DESTROY { #~ my $self = shift; #~ print "$self dying at\n"; #~ } sub web { my $self = shift; #use http:// when nothing provided unless($self->{_url} =~ /^(http\:\/\/|https\:\/\/|file\:\/\/)/i){ $self->{_url} = "http://".$self->{_url}; } system("gnome-web-photo --timeout=$self->{_timeout} --mode=photo --width=$self->{_width} '$self->{_url}' '$self->{_dest_filename}'"); return TRUE; } sub dlg_website { my $self = shift; my $url = shift; #gettext my $d = $self->{_sc}->get_gettext; #load modules at custom path #-------------------------------------- require lib; import lib $self->{_sc}->get_root."/share/shutter/resources/modules"; require Proc::Simple; my $output = 6; my $web_process = Proc::Simple->new; #gwp result will be saved to tempfile my ( $tmpfh, $tmpfilename ) = tempfile(UNLINK => 1); #redirect outputs my ( $tmpfh_stdout, $tmpfilename_stdout ) = tempfile(UNLINK => 1); my ( $tmpfh_stderr, $tmpfilename_sterr ) = tempfile(UNLINK => 1); #~ $web_process->redirect_output ("$ENV{'HOME'}/shutter-debug-stdout.log", "$ENV{'HOME'}/shutter-debug-err.log"); $web_process->redirect_output ($tmpfilename_stdout, $tmpfilename_sterr); my $website_dialog = Gtk2::MessageDialog->new( $self->{_sc}->get_mainwindow, [qw/modal destroy-with-parent/], 'other', 'none', undef ); $website_dialog->set_title("Shutter"); $website_dialog->set( 'text' => $d->get("Take a screenshot of a website") ); $website_dialog->set( 'secondary-text' => $d->get("URL to capture") . ": " ); if($self->{_sc}->get_theme->has_icon('web-browser')){ $website_dialog->set( 'image' => Gtk2::Image->new_from_icon_name( 'web-browser', 'dialog' ) ); }else{ $website_dialog->set( 'image' => Gtk2::Image->new_from_pixbuf( Gtk2::Gdk::Pixbuf->new_from_file_at_size( $self->{_sc}->get_root."/share/shutter/resources/icons/web_image.svg", Gtk2::IconSize->lookup('dialog') ) ) ); } #cancel button my $cancel_btn = Gtk2::Button->new_from_stock('gtk-cancel'); #capture button my $execute_btn = Gtk2::Button->new_with_mnemonic( $d->get("C_apture") ); $execute_btn->set_image( Gtk2::Image->new_from_stock( 'gtk-execute', 'button' ) ); $execute_btn->set_sensitive(FALSE); $execute_btn->can_default(TRUE); $website_dialog->add_action_widget( $cancel_btn, 'cancel' ); $website_dialog->add_action_widget( $execute_btn, 'accept' ); $website_dialog->set_default_response('accept'); my $website_hbox = Gtk2::HBox->new(); my $website_hbox2 = Gtk2::HBox->new(); my $website = Gtk2::Entry->new; $website->set_activates_default(TRUE); #check if url is valid $website->signal_connect('changed' => sub { unless ( $website->get_text ) { $execute_btn->set_sensitive(FALSE); }else{ $execute_btn->set_sensitive(TRUE); } return FALSE; }); my $clipboard = Gtk2::Clipboard->get( Gtk2::Gdk->SELECTION_CLIPBOARD ); my $clipboard_string = $clipboard->wait_for_text; print "Content of clipboard is: $clipboard_string\n" if $self->{_sc}->get_debug and defined $clipboard_string; #set textbox to url if(defined $url){ $website->set_text($url); #or paste clipboard content }else{ if ( defined $clipboard_string ) { if ( $clipboard_string =~ /^http/ || $clipboard_string =~ /^file/ || $clipboard_string =~ /^www\./ ) { $website->set_text($clipboard_string); } } } $website_hbox->pack_start( $website, TRUE, TRUE, 12 ); $website_dialog->vbox->add($website_hbox); my $website_progress = Gtk2::ProgressBar->new; $website_progress->set_no_show_all(TRUE); $website_progress->set_ellipsize('middle'); $website_progress->set_orientation('left-to-right'); $website_progress->set_fraction(0); $website_hbox2->pack_start( $website_progress, TRUE, TRUE, 12 ); $website_dialog->vbox->add($website_hbox2); $website_dialog->show_all; my $website_response = "accept"; if($url){ $website_dialog->response("accept"); }else{ $website_response = $website_dialog->run; } if ( $website_response eq "accept" ) { $execute_btn->set_sensitive(FALSE); #show progress bar while executing gnome-web-photo $website_progress->show; $self->update_gui(); #set url and filename $self->{_url} = $website->get_text; $self->{_dest_filename} = $tmpfilename; print "gnome-web-photo --timeout=$self->{_timeout} --mode=photo --width=$self->{_width} '$self->{_url}' '$self->{_dest_filename}'\n" if $self->{_sc}->get_debug; Proc::Simple::debug(1) if $self->{_sc}->get_debug; $web_process->start( sub { #cleanup when catching TERM $SIG{TERM} = sub { killfam 'TERM', $$; }; #start gnome-web-photo $self->web(); POSIX::_exit(0); } ); $website_dialog->signal_connect( 'delete-event' => sub{ #kill process $web_process->kill; $output = 5; } ); $cancel_btn->signal_connect( 'clicked' => sub { #kill process $web_process->kill; $output = 5; } ); while ( $web_process->poll ) { $website_progress->pulse; $self->update_gui(); usleep 100000; } #we cannot kill the process anymore #closing the dialog will confuse the user #because the image will appear in the session later on $cancel_btn->set_sensitive(FALSE); $self->update_gui(); #exit status == OK if ( $web_process->exit_status() == 0 ) { $website_progress->set_fraction( 2 / 3 ); $self->update_gui(); eval { $output = Gtk2::Gdk::Pixbuf->new_from_file($tmpfilename) }; if ($@) { #reading stdout from file while (<$tmpfh_stdout>){ $self->{_error_text} .= $_; } #reading stderr from file while (<$tmpfh_stderr>){ $self->{_error_text} .= $_; } unlink $tmpfilename, $tmpfilename_stdout, $tmpfilename_sterr; $website_dialog->destroy(); }else{ #set name of the captured window #e.g. for use in wildcards $self->{_action_name} = $self->{_url}; $self->{_action_name} =~ s/(http:\/\/|https:\/\/|file:\/\/)//g; #set history object $self->{_history} = Shutter::Screenshot::History->new($self->{_sc}); } $website_progress->set_fraction( 3 / 3 ); $self->update_gui(); #exit status == FAIL }else{ #reading stdout from file while (<$tmpfh_stdout>){ $self->{_error_text} .= $_; } #reading stderr from file while (<$tmpfh_stderr>){ $self->{_error_text} .= $_; } } #kill process, destroy dialog $web_process->kill('SIGKILL'); $website_dialog->destroy(); return $output; } else { #kill process, destroy dialog $web_process->kill('SIGKILL'); $website_dialog->destroy(); return 5; } } sub update_gui { my $self = shift; while ( Gtk2->events_pending ) { Gtk2->main_iteration; } Gtk2::Gdk->flush; return TRUE; } sub redo_capture { my $self = shift; my $output = 3; if(defined $self->{_history}){ $output = $self->dlg_website($self->{_url}); } return $output; } sub get_history { my $self = shift; return $self->{_history}; } sub get_error_text { my $self = shift; return $self->{_error_text}; } sub get_action_name { my $self = shift; return $self->{_action_name}; } 1; shutter-0.90.1/share/shutter/resources/modules/Shutter/Screenshot/Error.pm0000644000175000017500000001217712206477313026000 0ustar mariomario################################################### # # Copyright (C) 2008-2013 Mario Kemper # # This file is part of Shutter. # # Shutter is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 3 of the License, or # (at your option) any later version. # # Shutter is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License # along with Shutter; if not, write to the Free Software # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA # ################################################### package Shutter::Screenshot::Error; #modules #-------------------------------------- use utf8; use strict; use warnings; #Glib use Glib qw/TRUE FALSE/; #-------------------------------------- sub new { my $class = shift; my $self = { _sc => shift, _code => shift, _data => shift, _extra => shift }; ############# # code = 0 - pointer could not be grabbed - or invalid region # code = 1 - keyboard could not be grabbed # code = 2 - no window with type xy detected # code = 3 - no history object stored # code = 4 - window no longer available # code = 5 - user aborted # code = 6 - gnome-web-photo failed # code = 7 - no window with name xy detected # code = 8 - invalid pattern ############# bless $self, $class; return $self; } sub get_error { my $self = shift; return ($self->{_code}, $self->{_data}, $self->{_extra}); } sub is_aborted_by_user { my $self = shift; if(defined $self->{_code} && $self->{_code} == 5){ return TRUE; }else{ return FALSE; } } sub is_error { my $self = shift; if(defined $self->{_code} && $self->{_code} =~ /^\d+$/){ return TRUE; }else{ return FALSE; } } sub set_error { my $self = shift; if (@_) { $self->{_code} = shift; $self->{_data} = shift; $self->{_extra} = shift; } return ($self->{_code}, $self->{_data}, $self->{_extra}); } sub show_dialog { my $self = shift; my $detailed_error_text = shift || ''; #load modules at custom path #-------------------------------------- require lib; import lib $self->{_sc}->get_root."/share/shutter/resources/modules"; require Shutter::App::SimpleDialogs; my $sd = Shutter::App::SimpleDialogs->new($self->{_sc}->get_mainwindow); #gettext my $d = $self->{_sc}->get_gettext; my $response; my $status_text = $d->get("Error while taking the screenshot."); #handle error codes if( $self->{_code} == 0 ) { #show error dialog my $response = $sd->dlg_error_message( $d->get( "Maybe mouse pointer could not be grabbed or the selected area is invalid." ), $d->get( "Error while taking the screenshot." ) ); #keyboard could not be grabbed }elsif( $self->{_code} == 1 ) { $response = $sd->dlg_error_message( $d->get( "Keyboard could not be grabbed." ), $d->get( "Error while taking the screenshot." ) ); #no window with type xy detected }elsif( $self->{_code} == 2 ) { my $type = undef; if ( $self->{_data} eq "menu" || $self->{_data} eq "tray_menu" ) { $type = $d->get( "menu" ); }elsif ( $self->{_data} eq "tooltip" || $self->{_data} eq "tray_tooltip" ) { $type = $d->get( "tooltip" ); } $response = $sd->dlg_error_message( sprintf( $d->get( "No window with type %s detected." ), "'".$type."'"), $d->get( "Error while taking the screenshot." ) ); #no history object stored }elsif( $self->{_code} == 3 ) { $response = $sd->dlg_error_message( $d->get( "There is no last capture that can be redone." ), $d->get( "Error while taking the screenshot." ) ); #window no longer available }elsif( $self->{_code} == 4 ) { $response = $sd->dlg_error_message( $d->get( "The window is no longer available." ), $d->get( "Error while taking the screenshot." ) ); #user aborted screenshot }elsif ( $self->{_code} == 5 ) { $status_text = $d->get("Capture aborted by user"); #gnome-web-photo failed }elsif ( $self->{_code} == 6 ) { $response = $sd->dlg_error_message( $d->get("Unable to capture website"), $d->get( "Error while taking the screenshot." ), undef, undef, undef, undef, undef, undef, $detailed_error_text ); $status_text = $d->get("Unable to capture website"); #no window with name $pattern detected }elsif( $self->{_code} == 7 ) { my $name_pattern = $self->{_extra}; $response = $sd->dlg_error_message( sprintf( $d->get( "No window with name pattern %s detected." ), "'".$name_pattern."'"), $d->get( "Error while taking the screenshot." ) ); #invalid pattern }elsif( $self->{_code} == 8 ) { my $name_pattern = $self->{_extra}; $response = $sd->dlg_error_message( sprintf( $d->get( "Invalid pattern %s detected." ), "'".$name_pattern."'"), $d->get( "Error while taking the screenshot." ), undef, undef, undef, undef, undef, undef, $detailed_error_text ); } return ($response, $status_text); } 1; shutter-0.90.1/share/shutter/resources/modules/Shutter/Screenshot/Main.pm0000644000175000017500000003373512206477313025576 0ustar mariomario################################################### # # Copyright (C) 2008-2013 Mario Kemper # # This file is part of Shutter. # # Shutter is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 3 of the License, or # (at your option) any later version. # # Shutter is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License # along with Shutter; if not, write to the Free Software # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA # ################################################### package Shutter::Screenshot::Main; #modules #-------------------------------------- use utf8; use strict; use warnings; use File::Temp qw/ tempfile tempdir /; #Glib use Glib qw/TRUE FALSE/; #stringified perl data structures, suitable for both printing and eval use Data::Dumper; #-------------------------------------- sub new { my $class = shift; my $self = { _sc => shift, _include_cursor => shift, _delay => shift, _notify_timeout => shift, }; #root window $self->{ _root } = Gtk2::Gdk->get_default_root_window; ( $self->{ _root }->{ x }, $self->{ _root }->{ y }, $self->{ _root }->{ w }, $self->{ _root }->{ h } ) = $self->{ _root }->get_geometry; ( $self->{ _root }->{ x }, $self->{ _root }->{ y } ) = $self->{ _root }->get_origin; #import modules require lib; import lib $self->{_sc}->get_root."/share/shutter/resources/modules"; #shutter region module require Shutter::Geometry::Region; #wnck screen $self->{_wnck_screen} = Gnome2::Wnck::Screen->get_default; $self->{_wnck_screen}->force_update(); #gdk screen $self->{_gdk_screen} = Gtk2::Gdk::Screen->get_default; #gdk display $self->{_gdk_display} = $self->{_gdk_screen}->get_display; #we determine the wm name but on older #version of libwnck (or the bindings) #the needed method is not available #in this case we use gdk to do it # #this leads to a known problem when switching #the wm => wm_name will still remain the old one $self->{_wm_manager_name} = $self->{_gdk_screen}->get_window_manager_name; if($self->{_wnck_screen}->can('get_window_manager_name')){ $self->{_wm_manager_name} = $self->{_wnck_screen}->get_window_manager_name; } #workspaces $self->{_workspaces} = (); for ( my $wcount = 0 ; $wcount < $self->{_wnck_screen}->get_workspace_count ; $wcount++ ) { push( @{$self->{_workspaces}}, $self->{_wnck_screen}->get_workspace( $wcount ) ); } bless $self, $class; return $self; } sub get_clipbox { my $self = shift; my $region = shift; #create shutter region object my $sr = Shutter::Geometry::Region->new(); return $sr->get_clipbox($region); } sub update_workspaces { my $self = shift; for ( my $wcount = 0 ; $wcount < $self->{_wnck_screen}->get_workspace_count ; $wcount++ ) { push( @{$self->{_workspaces}}, $self->{_wnck_screen}->get_workspace( $wcount ) ); } return $self->{_wnck_screen}->get_workspace_count; } sub get_root_and_geometry { my $self = shift; return ($self->{_root}, $self->{_root}->{x}, $self->{_root}->{y}, $self->{_root}->{w}, $self->{_root}->{h}); } sub get_root_and_current_monitor_geometry { my $self = shift; my $mainwindow = $self->{_sc}->get_mainwindow->window || $self->{_root}; my $mon1 = $self->{_gdk_screen} ->get_monitor_geometry( $self->{_gdk_screen}->get_monitor_at_window($mainwindow) ); return ($self->{_root}, $mon1->x, $mon1->y, $mon1->width, $mon1->height); } sub get_current_monitor { my $self = shift; my ( $window_at_pointer, $x, $y, $mask ) = $self->{_root}->get_pointer; my $mon = $self->{_gdk_screen} ->get_monitor_geometry( $self->{_gdk_screen}->get_monitor_at_point ($x, $y)); return ($mon); } sub get_monitor_region { my $self = shift; my $region = Gtk2::Gdk::Region->new; for(my $i = 0; $i < $self->{_gdk_screen}->get_n_monitors; $i++){ $region->union_with_rect ($self->{_gdk_screen}->get_monitor_geometry ($i)); } return $region; } sub ungrab_pointer_and_keyboard { my ( $self, $ungrab_server, $quit_event_handler, $quit_main ) = @_; #ungrab pointer and keyboard Gtk2::Gdk::X11->ungrab_server if $ungrab_server; Gtk2::Gdk->pointer_ungrab( Gtk2->get_current_event_time ); Gtk2::Gdk->keyboard_ungrab( Gtk2->get_current_event_time ); Gtk2::Gdk::Event->handler_set( undef, undef ) if $quit_event_handler; Gtk2->main_quit if $quit_main; return TRUE unless Gtk2::Gdk->pointer_is_grabbed; return FALSE; } #~ sub get_scrollable_from_drawable { #~ my ( $self, $drawable, $x, $y, $width, $height, $cursor, $sleep ) = @_; #~ #~ #save pixbuf to file #~ my $pixbuf_save = Shutter::Pixbuf::Save->new( $self->{_sc}, $self->{_sc}->get_mainwindow ); #~ #~ my @steps; #~ while(1){ #~ #~ #create tempfile #~ my ( $tmpfh, $tmpfilename ) = tempfile(UNLINK => 1); #~ #~ my ($pixbuf, $l_cropped, $r_cropped, $t_cropped, $b_cropped) = $self->get_pixbuf_from_drawable($drawable, $x, $y, $width, $height, FALSE, 1); #~ $pixbuf_save->save_pixbuf_to_file($pixbuf, $tmpfilename, 'miff'); #~ #~ push @steps, $tmpfilename; #~ #~ my $curr_index = scalar @steps; #~ if($curr_index > 1){ #~ #~ my $compare = `compare -metric PSNR $steps[$curr_index-2] $steps[$curr_index-1] null: 2>&1`; #~ if ($compare =~ /inf/){ #~ print "Finish\n"; #~ last; #~ } #~ }else{ #~ my $line_size = 67; #~ $y += $height - $line_size; #~ $height = $line_size; #~ } #~ #~ #cursor can only be on the first page #~ $self->{_include_cursor} = FALSE; #~ #~ #next scroll step #~ my $xdo = `xdotool click 5`; #~ #~ } #~ #~ my $append_cmd = 'convert'; #~ foreach(@steps){ #~ $append_cmd .= " $_"; #~ } #~ #~ #create tempfile #~ my ( $tmpfh_fin, $tmpfilename_fin ) = tempfile(UNLINK => 1); #~ $append_cmd .= " -append $tmpfilename_fin"; #~ #~ print $append_cmd."\n"; #~ #~ my $append_res = `$append_cmd`; #~ #~ my $app_pixbuf = Gtk2::Gdk::Pixbuf->new_from_file($tmpfilename_fin); #~ print $app_pixbuf."\n"; #~ return ($app_pixbuf, 0, 0, 0, 0); #~ #~ } sub get_pixbuf_from_drawable { my ( $self, $drawable, $x, $y, $width, $height, $region ) = @_; my ($pixbuf, $l_cropped, $r_cropped, $t_cropped, $b_cropped) = (0, 0, 0, 0, 0); #show notification messages displaying the countdown if($self->{_delay} && $self->{_notify_timeout}){ my $notify = $self->{_sc}->get_notification_object; my $ttw = $self->{_delay}; #gettext my $d = $self->{_sc}->get_gettext; #first notification immediately $notify->show( sprintf($d->nget("Screenshot will be taken in %s second", "Screenshot will be taken in %s seconds", $ttw) , $ttw), "" ); $ttw--; #delay is only 1 second #do not show any further messages if($ttw >= 1){ #then controlled via timeout Glib::Timeout->add (1000, sub{ $notify->show( sprintf($d->nget("Screenshot will be taken in %s second", "Screenshot will be taken in %s seconds", $ttw) , $ttw), "" ); $ttw--; if($ttw == 0){ #close last message with a short delay (less than a second) Glib::Timeout->add (500, sub{ $notify->close; return FALSE; }); return FALSE; }else{ return TRUE; } }); }else{ #close last message with a short delay (less than a second) Glib::Timeout->add (500, sub{ $notify->close; return FALSE; }); } } #Add a timeout if there is any delay Glib::Timeout->add ($self->{_delay}*1000, sub{ #get the pixbuf from drawable and save the file # #maybe window is partially not on the screen #right if ( $x + $width > $self->{ _root }->{ w } ) { $r_cropped = $x + $width - $self->{ _root }->{ w }; $width -= $x + $width - $self->{ _root }->{ w }; } #bottom if ( $y + $height > $self->{ _root }->{ h } ) { $b_cropped = $y + $height - $self->{ _root }->{ h }; $height -= $y + $height - $self->{ _root }->{ h }; } #left if ( $x < $self->{ _root }->{ x } ) { $l_cropped = $self->{ _root }->{ x } - $x; $width = $width + $x; $x = 0; } #top if ( $y < $self->{ _root }->{ y } ) { $t_cropped = $self->{ _root }->{ y } - $y; $height = $height + $y; $y = 0; } #get the pixbuf from drawable and save the file eval{ if($width > 0 && $height > 0){ $pixbuf = Gtk2::Gdk::Pixbuf->get_from_drawable( $drawable, undef, $x, $y, 0, 0, $width, $height ); } }; if($@){ $pixbuf = 5; return FALSE; } #include cursor if($self->{_include_cursor}){ $pixbuf = $self->include_cursor( $x, $y, $width, $height, $drawable, $pixbuf ); } #region is optional #it is used to handle multiple monitors (root window may not be rectangular) #or to cut out the screen contents when capturing menus if($region){ #get clipbox #~ my $clipbox = $region->get_clipbox; my $clipbox = $self->get_clipbox($region); #~ print "Clipbox: ", $clipbox->width, " - ", $clipbox->height, "\n"; #create target pixbuf with dimension of clipbox my $target = Gtk2::Gdk::Pixbuf->new ($pixbuf->get_colorspace, TRUE, 8, $clipbox->width, $clipbox->height); #whole pixbuf is transparent $target->fill(0x00000000); #determine low x and y my $small_x = $self->{ _root }->{ w }; my $small_y = $self->{ _root }->{ h }; foreach my $r ($region->get_rectangles){ $small_x = $r->x if $r->x < $small_x; $small_y = $r->y if $r->y < $small_y; } #copy each rectangle foreach my $r ($region->get_rectangles){ #~ print $r->x, " - ", $r->y, " - ", $r->width, " - ", $r->height, "\n"; $pixbuf->copy_area ($r->x - $small_x, $r->y - $small_y, $r->width, $r->height, $target, $r->x - $small_x, $r->y - $small_y); } $pixbuf = $target->copy; } Gtk2->main_quit; return FALSE; }); Gtk2->main(); return ($pixbuf, $l_cropped, $r_cropped, $t_cropped, $b_cropped); } #code ported and partially borrowed from gnome-screenshot and Gimp sub include_cursor { my ( $self, $xp, $yp, $widthp, $heightp, $gdk_window, $pixbuf ) = @_; require lib; import lib $self->{_sc}->get_root."/share/shutter/resources/modules"; require X11::Protocol; #X11 protocol and XFIXES ext $self->{_x11} = X11::Protocol->new( $ENV{ 'DISPLAY' } ); $self->{_x11}{ext_xfixes} = $self->{_x11}->init_extension('XFIXES'); #pixbuf my $cursor_pixbuf = undef; #Cursor position (root window coordinates) my $cursor_pixbuf_xroot = undef; my $cursor_pixbuf_yroot = undef; #The "hotspot" position my $cursor_pixbuf_xhot = undef; my $cursor_pixbuf_yhot = undef; if($self->{_x11}{ext_xfixes}){ my ($root_x, $root_y, $width, $height, $xhot, $yhot, $serial, $pixels) = $self->{_x11}->XFixesGetCursorImage; #packed data string my $data; my $pos = 0; foreach my $y (0 .. $height-1) { foreach my $x (0 .. $width-1) { my $argb = unpack 'L', substr($pixels,$pos,4); my $a = ($argb >> 24) & 0xFF; my $r = ($argb >> 16) & 0xFF; my $g = ($argb >> 8) & 0xFF; my $b = ($argb >> 0) & 0xFF; $pos += 4; #~ print "r:$r,g:$g,b:$b,a:$a\n"; $r = ($r * 255) / $a if($a); $g = ($g * 255) / $a if($a); $b = ($b * 255) / $a if($a); $data .= pack ('C*', $r, $g, $b, $a); } } if($width > 1 && $height > 1){ $cursor_pixbuf = Gtk2::Gdk::Pixbuf->new_from_data($data,'rgb',1,8,$width,$height-1,4*$width); $cursor_pixbuf_xhot = $xhot; $cursor_pixbuf_yhot = $yhot; $cursor_pixbuf_xroot = $root_x; $cursor_pixbuf_yroot = $root_y; }else{ warn "WARNING: There was an error while getting the cursor image (XFIXESGetCursorImage)\n"; } }else{ warn "WARNING: XFIXES extension not found - using a default cursor image\n"; my ( $window_at_pointer, $root_x, $root_y, $mask ) = $gdk_window->get_pointer; my $cursor = Gtk2::Gdk::Cursor->new( 'GDK_LEFT_PTR' ); $cursor_pixbuf = $cursor->get_image; #try to use default cursor if there was an error unless ( $cursor_pixbuf) { warn "WARNING: There was an error while getting the default cursor image - using one of our image files\n"; my $icons_path = $self->{_sc}->get_root . "/share/shutter/resources/icons"; eval{ $cursor_pixbuf = Gtk2::Gdk::Pixbuf->new_from_file($icons_path."/Normal.cur"); }; if($@){ warn "ERROR: There was an error while loading the image file: $@\n"; } } if( $cursor_pixbuf ){ $cursor_pixbuf_xhot = $cursor_pixbuf->get_option('x_hot'); $cursor_pixbuf_yhot = $cursor_pixbuf->get_option('y_hot'); $cursor_pixbuf_xroot = $root_x; $cursor_pixbuf_yroot = $root_y; } } if ( $cursor_pixbuf ) { #x,y pos (cursor) my $x = $cursor_pixbuf_xroot; my $y = $cursor_pixbuf_yroot; #screenshot dimensions saved in a rect (global x, y) my $scshot = Gtk2::Gdk::Rectangle->new( $xp, $yp, $widthp, $heightp ); #see 'man xcursor' for a detailed description #of these values my $xhot = $cursor_pixbuf_xhot; my $yhot = $cursor_pixbuf_yhot; #cursor dimensions (global x, y and width and height of the pixbuf) my $cursor = Gtk2::Gdk::Rectangle->new( $x, $y, $cursor_pixbuf->get_width, $cursor_pixbuf->get_height ); #is the cursor visible in the current screenshot? #(do the rects intersect?) if ( $cursor = $scshot->intersect( $cursor ) ) { #calculate dest_x, dest_y #be careful here when subtracting xhot and yhot, #because negative values are not allowed when #using composite # #example: moving the cursor to the coords 0, 0 #would lead to an error my $dest_x = $x - $xp - $xhot; my $dest_y = $y - $yp - $yhot; $dest_x = 0 if $dest_x < 0; $dest_y = 0 if $dest_y < 0; $cursor_pixbuf->composite( $pixbuf, $dest_x, $dest_y, $cursor->width, $cursor->height, $x - $xp - $xhot, $y - $yp - $yhot, 1.0, 1.0, 'bilinear', 255 ); } } return $pixbuf; } 1; shutter-0.90.1/share/shutter/resources/modules/Shutter/Screenshot/History.pm0000644000175000017500000000413712206477313026345 0ustar mariomario################################################### # # Copyright (C) 2008-2013 Mario Kemper # # This file is part of Shutter. # # Shutter is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 3 of the License, or # (at your option) any later version. # # Shutter is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License # along with Shutter; if not, write to the Free Software # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA # ################################################### package Shutter::Screenshot::History; #modules #-------------------------------------- use utf8; use strict; use warnings; #Glib use Glib qw/TRUE FALSE/; #-------------------------------------- sub new { my $class = shift; my $self = { _sc => shift }; #last capture $self->{_drawable} = shift; $self->{_x} = shift; $self->{_y} = shift; $self->{_w} = shift; $self->{_h} = shift; $self->{_region} = shift; $self->{_wxid} = shift; $self->{_gxid} = shift; bless $self, $class; return $self; } sub get_last_capture { my $self = shift; return ($self->{_drawable}, $self->{_x}, $self->{_y}, $self->{_w}, $self->{_h}, $self->{_region}, $self->{_wxid}, $self->{_gxid}); } sub set_last_capture { my $self = shift; if (scalar @_ >= 5) { $self->{_drawable} = shift; $self->{_x} = shift; $self->{_y} = shift; $self->{_w} = shift; $self->{_h} = shift; $self->{_region} = shift; $self->{_wxid} = shift; $self->{_gxid} = shift; }else{ warn "WARNING: Wrong number of arguments in Shutter::Screenshot::History::set_last_capture\n"; } return ($self->{_drawable}, $self->{_x}, $self->{_y}, $self->{_w}, $self->{_h}, $self->{_region}, $self->{_wxid}, $self->{_gxid}); } 1; shutter-0.90.1/share/shutter/resources/modules/Shutter/Screenshot/WindowName.pm0000644000175000017500000000462412206477313026755 0ustar mariomario################################################### # # Copyright (C) 2008-2013 Mario Kemper # # This file is part of Shutter. # # Shutter is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 3 of the License, or # (at your option) any later version. # # Shutter is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License # along with Shutter; if not, write to the Free Software # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA # ################################################### package Shutter::Screenshot::WindowName; #modules #-------------------------------------- use utf8; use strict; use warnings; use Shutter::Screenshot::WindowXid; use Data::Dumper; our @ISA = qw(Shutter::Screenshot::WindowXid); #Glib and Gtk2 use Gtk2; use Glib qw/TRUE FALSE/; #-------------------------------------- sub new { my $class = shift; #call constructor of super class (shutter_common, include_cursor, delay, notify_timeout, include_border, windowresize_active, windowresize_w, windowresize_h, hide_time, mode, autoshape) my $self = $class->SUPER::new( shift, shift, shift, shift, shift, shift, shift, shift, shift, shift, shift ); bless $self, $class; return $self; } #~ sub DESTROY { #~ my $self = shift; #~ print "$self dying at\n"; #~ } #~ sub window_find_by_name { my $self = shift; my $name_pattern = shift; my $active_workspace = $self->{_wnck_screen}->get_active_workspace; #cycle through all windows my $output = 7; foreach my $win ( $self->{_wnck_screen}->get_windows_stacked ) { #ignore shutter window if ( $self->{_sc}->get_mainwindow->window ) { next if ( $win->get_xid == $self->{_sc}->get_mainwindow->window->get_xid ); } #check if window is on active workspace if ( $active_workspace && $win->is_on_workspace( $active_workspace ) ) { eval{ if ( $win->get_name =~ m/$name_pattern/i ) { $output = $self->window_by_xid($win->get_xid); last; } }; if($@){ $output = 8; $self->{_error_text} = $@; } } } return $output; } 1; shutter-0.90.1/share/shutter/resources/modules/X11/0000755000175000017500000000000012206477312021136 5ustar mariomarioshutter-0.90.1/share/shutter/resources/modules/X11/Protocol/0000755000175000017500000000000012206477312022737 5ustar mariomarioshutter-0.90.1/share/shutter/resources/modules/X11/Protocol/Ext/0000755000175000017500000000000012206477313023500 5ustar mariomarioshutter-0.90.1/share/shutter/resources/modules/X11/Protocol/Ext/XFIXES.pm0000644000175000017500000007637412206477313025065 0ustar mariomario# Copyright 2011 Kevin Ryde # This file is part of X11-Protocol-Other. # # X11-Protocol-Other is free software; you can redistribute it and/or # modify it under the terms of the GNU General Public License as published # by the Free Software Foundation; either version 3, or (at your option) any # later version. # # X11-Protocol-Other is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General # Public License for more details. # # You should have received a copy of the GNU General Public License along # with X11-Protocol-Other. If not, see . BEGIN { require 5 } package X11::Protocol::Ext::XFIXES; use X11::Protocol 'padded'; use strict; use Carp; use vars '$VERSION', '@CARP_NOT'; $VERSION = 9; @CARP_NOT = ('X11::Protocol'); # uncomment this to run the ### lines #use Smart::Comments; # /usr/share/doc/x11proto-fixes-dev/fixesproto.txt.gz # http://cgit.freedesktop.org/xorg/proto/fixesproto/tree/fixesproto.txt # # /usr/include/X11/extensions/Xfixes.h # /usr/include/X11/extensions/xfixesproto.h # /usr/include/X11/extensions/xfixeswire.h # # /usr/share/doc/x11proto-xext-dev/shape.txt.gz ### XFIXES.pm loads # these not documented yet ... use constant CLIENT_MAJOR_VERSION => 4; use constant CLIENT_MINOR_VERSION => 0; #------------------------------------------------------------------------------ # symbolic constants my %const_arrays = ( XFixesWindowRegionKind => ['Bounding', 'Clip'], XFixesSaveSetMode => ['Insert', 'Delete'], XFixesSaveSetTarget => ['Nearest', 'Root'], XFixesSaveSetMap => ['Map', 'Unmap'], XFixesSelectionNotifySubtype => [ 'SetSelectionOwner', 'SelectionWindowDestroy', 'SelectionClientClose' ], XFixesCursorNotifySubtype => [ 'DisplayCursor' ], # Not sure about these two ... # XFixesSelectionEventMask => [ 'SetSelectionOwner', # 'SelectionWindowDestroy', # 'SelectionClientClose' ], # XFixesCursorEventMask => [ 'DisplayCursor' ], ); my %const_hashes = (map { $_ => { X11::Protocol::make_num_hash($const_arrays{$_}) } } keys %const_arrays); #------------------------------------------------------------------------------ # events my $XFixesSelectionNotify_event = [ 'xCxxL5', ['subtype','XFixesSelectionNotifySubtype'], 'window', ['owner',['None']], # window 'selection', # atom 'time', 'selection_time', ]; my $XFixesCursorNotify_event = [ sub { my $X = shift; my $data = shift; ### XFixesCursorNotify unpack: @_ my ($subtype, $window, $cursor_serial, $time, $cursor_name) = unpack 'xCxxL4', $data; return (@_, # base fields subtype => $X->interp('XFixesCursorNotifySubtype',$subtype), window => _interp_none($X,$window), # probably not None though cursor_serial => $cursor_serial, time => _interp_time($time), # "name" field only in XFIXES 2.0 up, probably pad garbage # in 1.0, so omit there. Give it as "cursor_name" since # plain "name" is the event name. ($X->{'ext'}->{'XFIXES'}->[3]->{'major'} >= 2 ? (cursor_name => $cursor_name) : ())); }, sub { my ($X, %h) = @_; # "cursor_name" can be omitted as for a 1.0 event return (pack('xCxxL4x12', $X->num('XFixesCursorNotifySubtype',$h{'subtype'}), _num_none($h{'window'}), $h{'cursor_serial'}, _num_time($h{'time'}), _num_none($h{'cursor_name'} || 0)), 1); # "do_seq" put in sequence number } ]; #------------------------------------------------------------------------------ # requests my $reqs = [ [ 'XFixesQueryVersion', # 0 sub { my ($X, $major, $minor) = @_; ### XFixesQueryVersion request return pack 'LL', $major, $minor; }, sub { my ($X, $data) = @_; ### XFixesQueryVersion reply: "$X" my @ret = unpack 'x8SS', $data; my $self; if ($self = $X->{'ext'}->{'XFIXES'}->[3]) { ($self->{'major'},$self->{'minor'}) = @ret; } return @ret; }], [ 'XFixesChangeSaveSet', # 1 sub { my ($X, $window, $mode, $target, $map) = @_; return pack ('CCCxL', $X->num('XFixesSaveSetMode',$mode), $X->num('XFixesSaveSetTarget',$target), $X->num('XFixesSaveSetMap',$map), $window); }], [ 'XFixesSelectSelectionInput', # 2 # ($X, $window, $selection, $event_mask) # nothing special for $event_mask yet \&_request_card32s ], [ 'XFixesSelectCursorInput', # 3 # ($X, $window, $event_mask) nothing special for $event_mask yet \&_request_card32s ], [ 'XFixesGetCursorImage', # 4 \&_request_empty, sub { my ($X, $data) = @_; # (rootx,rooty, width,height, xhot,yhot, serial, ... then pixels) my @ret = unpack 'x8ssSSSSL', $data; return (@ret, substr ($data, 32, 4*$ret[2]*$ret[3])); # width*height }], #--------------------------------------------------------------------------- # version 2.0 [ 'XFixesCreateRegion', # 5 \&_request_region_and_rectangles ], [ 'XFixesCreateRegionFromBitmap', # 6 \&_request_xids ], [ 'XFixesCreateRegionFromWindow', # 7 sub { my ($X, $region, $window, $kind) = @_; ### XFixesCreateRegionFromWindow: $region, $window, $kind return pack ('LLCxxx', $region, $window, $X->num('XFixesWindowRegionKind',$kind)); }], [ 'XFixesCreateRegionFromGC', # 8 \&_request_xids ], [ 'XFixesCreateRegionFromPicture', # 9 \&_request_xids ], [ 'XFixesDestroyRegion', # 10 \&_request_xids ], [ 'XFixesSetRegion', # 11 \&_request_region_and_rectangles ], [ 'XFixesCopyRegion', # 12 \&_request_xids ], [ 'XFixesUnionRegion', # 13 \&_request_xids ], [ 'XFixesIntersectRegion', # 14 \&_request_xids ], [ 'XFixesSubtractRegion', # 15 \&_request_xids ], [ 'XFixesInvertRegion', # 16 sub { my ($X, $src, $rect, $dst) = @_; return pack 'LssSSL', $src, @$rect, $dst; }], [ 'XFixesTranslateRegion', # 17 sub { shift; # ($X, $region, $dx, $dy) return pack 'Lss', @_; }], [ 'XFixesRegionExtents', # 18 \&_request_card32s ], # ($X, $src, $dst) [ 'XFixesFetchRegion', # 19 \&_request_card32s, # ($X, $region) sub { my ($X, $data) = @_; ### XFixesFetchRegion reply: length($data) my @ret = ([ unpack 'x8ssSS', $data ]); # bounding for (my $pos = 32; $pos < length($data); $pos+=8) { push @ret, [ unpack 'ssSS', substr($data,$pos,8) ]; } return @ret; }], [ 'XFixesSetGCClipRegion', # 20 \&_request_xid_xy_region], # ($gc, $x, $y, $region) [ 'XFixesSetWindowShapeRegion', # 21 sub { my ($X, $window, $shape_kind, $x, $y, $region) = @_; # use ShapeKind if SHAPE initialized, otherwise same Bounding and # Clip from XFixesWindowRegionKind my $kind_type = ($X->{'ext_const'}->{'ShapeKind'} ? 'ShapeKind' : 'XFixesWindowRegionKind'); return pack ('LCxxxssL', $window, $X->num($kind_type,$shape_kind), $x,$y, _num_none ($region)); }], [ 'XFixesSetPictureClipRegion', # 22 \&_request_xid_xy_region ], # ($pict, $x, $y, $region) [ 'XFixesSetCursorName', # 23 sub { my ($X, $cursor, $str) = @_; ### XFixesSetCursorName request ### $cursor ### $str return pack('LSxx'.padded($str), $cursor, length($str), $str); }], [ 'XFixesGetCursorName', # 24 \&_request_xids, sub { my ($X, $data) = @_; ### XFixesGetCursorName reply my ($atom, $len) = unpack 'x8LS', $data; return (_interp_none($X,$atom), substr($data,32,$len)); }], [ 'XFixesGetCursorImageAndName', # 25 \&_request_empty, sub { my ($X, $data) = @_; # (x,y, w,h, xhot,yhot, serial, atom, $namelen, ... then pixels+name) my @ret = unpack 'x8ssSSSSLLSxx', $data; my $namelen = pop @ret; my $atom = pop @ret; my $pixelsize = 4 * $ret[2] * $ret[3]; return (@ret, substr ($data, 32, $pixelsize), # pixels _interp_none($X,$atom), substr ($data, 32 + $pixelsize, $namelen)); # name }], [ 'XFixesChangeCursor', # 26 sub { my ($X, $src, $dst) = @_; return pack 'LL', $src, $dst; }], [ 'XFixesChangeCursorByName', # 27 sub { my ($X, $src, $str) = @_; return pack ('LSxx'.padded($str), $src, length($str), $str); }], #--------------------------------------------------------------------------- # version 3.0 [ 'XFixesExpandRegion', # 28 sub { shift; # $X return pack 'LLSSSS', @_; # $src, $dst, $left,$right, $top,$bottom }], #--------------------------------------------------------------------------- # version 4.0 ['XFixesHideCursor', # 29 \&_request_xids ], ['XFixesShowCursor', # 30 \&_request_xids ], #--------------------------------------------------------------------------- # version 5.0 # untested, and not sure about how to take the directions arg # # ['XFixesCreatePointerBarrier', # 31 # sub { # my ($X, $barrier, $drawable, $x1,$y1, $x2,$y2, $directions, # @devices) = @_; # my $devices = pack 'S*', map{_num_xinputdevice($_)} @devices; # return pack ('LLssLxx'.padding($devices), # $barrier, # CARD32 # $drawable, # CARD32 # $x1,$y1, $x2,$y2, # INT16 # $X->num('XFixesBarrierDirections',$directions), # CARD32 # # pad16 # scalar(@devices), # CARD16 # $devices); # stringized # }], # # ['XFixesDestroyPointerBarrier', # 32 # \&_request_xids ], ]; sub new { my ($class, $X, $request_num, $event_num, $error_num) = @_; ### XFIXES new() # Constants %{$X->{'ext_const'}} = (%{$X->{'ext_const'} ||= {}}, %const_arrays); %{$X->{'ext_const_num'}} = (%{$X->{'ext_const_num'} ||= {}}, %const_hashes); # Events $X->{'ext_const'}{'Events'}[$event_num] = 'XFixesSelectionNotify'; $X->{'ext_events'}[$event_num] = $XFixesSelectionNotify_event; $event_num++; $X->{'ext_const'}{'Events'}[$event_num] = 'XFixesCursorNotify'; $X->{'ext_events'}[$event_num] = $XFixesCursorNotify_event; # Requests _ext_requests_install ($X, $request_num, $reqs); # the protocol spec says must query version with what we support # need it to know which error types are defined too, as otherwise oughtn't # touch anything at $event_num my ($server_major, $server_minor) = $X->req ('XFixesQueryVersion', CLIENT_MAJOR_VERSION, CLIENT_MINOR_VERSION); # Errors _ext_const_error_install ($X, $error_num, # version 2.0 ($server_major >= 2 ? ('Region') : ()), # version 5.0 ($server_major >= 5 ? ('Barrier') : ())); return bless { major => $server_major, minor => $server_minor, }, $class; } sub _request_empty { if (@_ > 1) { croak "No parameters in this request"; } return ''; } sub _request_xids { my $X = shift; ### _request_xids(): @_ return _request_card32s ($X, map {_num_none($_)} @_); } sub _request_card32s { shift; ### _request_card32s(): @_ return pack 'L*', @_; } sub _request_xid_xy_region { my ($X, $xid, $x, $y, $region) = @_; return pack ('LLss', $xid, _num_none($region), $x,$y); } sub _request_region_and_rectangles { shift; # $X ### _request_region_and_rectangles: @_ my $region = shift; ### ret: pack('L',$region) . _pack_rectangles(@_) return pack('L',$region) . _pack_rectangles(@_); } sub _pack_rectangles { return join ('', map {pack 'ssSS', @$_} @_); } sub _num_none { my ($xid) = @_; if (defined $xid && $xid eq 'None') { return 0; } else { return $xid; } } sub _interp_none { my ($X, $xid) = @_; if ($X->{'do_interp'} && $xid == 0) { return 'None'; } else { return $xid; } } sub _interp_time { my ($time) = @_; if ($time == 0) { return 'CurrentTime'; } else { return $time; } } sub _num_time { my ($time) = @_; if ($time eq 'CurrentTime') { return 0; } else { return $time; } } sub _num_xinputdevice { my ($device) = @_; if ($device eq 'AllDevices') { return 0; } if ($device eq 'AllMasterDevices') { return 1; } return $device; } sub _ext_requests_install { my ($X, $request_num, $reqs) = @_; $X->{'ext_request'}->{$request_num} = $reqs; my $href = $X->{'ext_request_num'}; my $i; foreach $i (0 .. $#$reqs) { $href->{$reqs->[$i]->[0]} = [$request_num, $i]; } } sub _ext_const_error_install { my $X = shift; ### _ext_const_error_install: @_ my $error_num = shift; my $aref = $X->{'ext_const'}{'Error'} # copy = [ @{$X->{'ext_const'}{'Error'} || []} ]; my $href = $X->{'ext_const_num'}{'Error'} # copy = { %{$X->{'ext_const_num'}{'Error'} || {}} }; my $i; foreach $i (0 .. $#_) { $aref->[$error_num + $i] = $_[$i]; $href->{$_[$i]} = $error_num + $i; } } 1; __END__ =for stopwords XFIXES XID reparent Unmap arrayref AARRGGBB GG pre-multiplied pixmap RENDER ShapeKind subwindow Ryde hotspot ARGB GC ie latin-1 DisplayCursor RGB bitmask XIDs YX-banded =head1 NAME X11::Protocol::Ext::XFIXES - miscellaneous "fixes" extension =head1 SYNOPSIS use X11::Protocol; my $X = X11::Protocol->new; $X->init_extension('XFIXES') or print "XFIXES extension not available"; =head1 DESCRIPTION The XFIXES extension adds some extra features conceived as "fixing" omissions in the core X11 protocol, including =over =item * Events for changes to the selection (the cut and paste between clients). =item * Current cursor image fetching, events for cursor change, and cursor naming and hiding. =item * Server-side "region" objects representing a set of rectangles. =back =head1 REQUESTS The following are made available with an C per L. my $bool = $X->init_extension('XFIXES'); =head2 XFIXES version 1.0 =over =item C<($server_major, $server_minor) = $X-EXFixesQueryVersion ($client_major, $client_minor)> Negotiate a protocol version with the server. C<$client_major> and C<$client_minor> is what the client would like, the returned C<$server_major> and C<$server_minor> is what the server will do, which might be less than requested (but not more than). The current code in this module supports up to 4.0 and automatically negotiates within C, so direct use of C is not necessary. Asking for higher than the code supports might be a bad idea. =item C<($atom, $str) = $X-EXFixesChangeSaveSet ($window, $mode, $target, $map)> Insert or delete C<$window> (an XID) from the "save set" of resources to be retained on the server when the client disconnects. This is an extended version of the core C request. C<$mode> is either "Insert" or "Delete". C<$target> is how to reparent C<$window> on client close-down, either "Nearest" or "Root". The core C is "Nearest" and means go to the next non-client ancestor window. "Root" means go to the root window. C<$map> is either "Map" or "Unmap" to apply to C<$window> on close-down. The core C is "Map". =item $X-EXFixesSelectSelectionInput ($window, $selection, $event_mask)> Select C events (see L below) to be sent to C<$window> when C<$selection> (an atom) changes. $X->XFixesSelectSelectionInput ($my_window, $X->atom('PRIMARY'), 0x07); C<$window> is given in the resulting C. It probably works to make it just a root window. Selections are global to the whole server, so the window doesn't implicitly choose a screen or anything. C<$event_mask> has three bits for which event subtypes should be reported. bitpos bitval SetSelectionOwner 0 0x01 SelectionWindowDestroy 1 0x02 SelectionClientClose 2 0x04 There's no pack function for these yet so just give an integer, for instance 0x07 for all three. =item $X-EXFixesSelectCursorInput ($window, $event_mask)> Select C events (see L below) to be sent to the client. C<$window> is given in the resulting C. It probably works to make it just a root window. The cursor image is global and the events are for any change, not merely within C<$window>. C<$event_mask> has only a single bit, asking for displayed cursor changes, bitpos bitval DisplayCursor 0 0x01 There's no pack function for this yet, just give integer 1 or 0. =item ($root_x,$root_y, $width,$height, $xhot,$yhot, $serial, $pixels) = $X-EXFixesGetCursorImage ()> Return the size and pixel contents of the currently displayed mouse pointer cursor. C<$root_x>,C<$root_y> is the pointer location in root window coordinates (similar to C). C<$width>,C<$height> is the size of the cursor image. C<$xhot>,C<$yhot> is the "hotspot" position within that, which is the pixel that follows the pointer location. C<$pixels> is a byte string of packed "ARGB" pixel values. Each is 32-bits in client byte order, with C<$width> many for each row and C<$height> such rows, no padding in between, for a total C<4*$width*$height> bytes. This can be unpacked with for instance my @argb = unpack 'L*', $pixels; # each 0xAARRGGBB # top left pixel is in $argb[0] my $blue = $argb[0] & 0xFF; # 0 to 255 my $green = ($argb[0] >> 8) & 0xFF; # components my $red = ($argb[0] >> 16) & 0xFF; my $alpha = ($argb[0] >> 24) & 0xFF; The alpha transparency is pre-multiplied into the RGB components, so if the alpha is zero (transparent) then the components are zero too. The core C bitmask makes only alpha=0 full-transparent or alpha=255 full-opaque pixels. The RENDER extension (see L) can make partially transparent cursors. There's no direct way to get the image of a cursor by its XID (beyond something dodgy like a C to make it the displayed cursor). Usually cursor XIDs are only ever created by a client itself (they can't be read back out of an arbitrary window for instance) so no need to read back. =back =head2 XFIXES version 2.0 A region object on the server represents a set of rectangles, each x,y,width,height, with positive or negative x,y, and the set possibly in disconnected sections, etc. Since a rectangle might be simply 1x1 it can represent any bitmap, but is geared towards the sort or rectangle arithmetic arising from overlapping rectangular window areas etc. =over =item C<$X-EXFixesCreateRegion ($region, $rect...)> Create C<$region> (a new XID) as a region and set it to the union of the given rectangles, or empty if none. Each C<$rect> is an arrayref C<[$x,$y,$width,$height]>. my $region = $X->new_rsrc; $X->XFixesCreateRegion ($region, [0,0,10,5], [100,100,1,1]); =item C<$X-EXFixesCreateRegionFromBitmap ($region, $bitmap)> Create a region initialized from the 1 bits of C<$bitmap> (a pixmap XID). my $region = $X->new_rsrc; $X->XFixesCreateRegionFromBitmap ($region, $bitmap); =item C<$X-EXFixesCreateRegionFromWindow ($region, $window, $kind)> Create a region initialized from the shape of C<$window> (an XID). C<$kind> is either "Bounding" or "Clip" as per the SHAPE extension (see L). my $region = $X->new_rsrc; $X->XFixesCreateRegionFromBitmap ($region, $window, 'Clip'); It's not necessary to C<$X-Einit_extension('SHAPE')> before using this request, the shape as such is just on the server and results in whatever rectangular or non-rectangular C<$region>. =item C<$X-EXFixesCreateRegionFromGC ($region, $gc)> Create a region initialized from the clip mask of C<$gc> (an XID). my $region = $X->new_rsrc; $X->XFixesCreateRegionFromGC ($region, $gc); The region is relative to the GC C and C, ie. those offsets are not applied to the X,Y in the region. =item C<$X-EXFixesCreateRegionFromPicture ($region, $picture)> Create a region initialized from a RENDER C<$picture> (an XID). my $region = $X->new_rsrc; $X->XFixesCreateRegionFromBitmap ($region, $picture); The region is relative to the picture C and C, ie. those offsets are not applied to the X,Y in the region. Picture objects are from the RENDER extension (see L). This request always exists, but is not useful without RENDER. =item C<$X-EXFixesDestroyRegion ($region)> Destroy C<$region>. =item C<$X-EXFixesSetRegion ($region, $rect...)> Set C<$region> to the union of the given rectangles, or empty if none. Each C<$rect> is an arrayref C<[$x,$y,$width,$height]>, as per C above. $X->XFixesSetRegion ($region, [0,0,20,10], [100,100,5,5]) =item C<$X-EXFixesCopyRegion ($dst, $src)> Copy a region C<$src> to region C<$dst>. =item C<$X-EXFixesUnionRegion ($src1, $src2, $dst)> =item C<$X-EXFixesIntersectRegion ($src1, $src2, $dst)> =item C<$X-EXFixesSubtractRegion ($src1, $src2, $dst)> Set region C<$dst> to respectively the union or intersection of C<$src1> and C<$src2>, or the subtraction C<$src1> - C<$src2>. C<$dst> can be one of the source regions if desired, to change in-place. =item C<$X-EXFixesInvertRegion ($src, $rect, $dst)> Set region C<$dst> to the inverse of C<$src> bounded by rectangle C<$rect>, ie. C<$rect> subtract C<$src>. C<$rect> is an arrayref C<[$x,$y,$width,$height]>. $X-XFixesInvertRegion ($src, [10,10, 200,100], $dst)> C<$dst> can be the same as C<$src> to do an "in-place" invert. =item C<$X-EXFixesTranslateRegion ($region, $dx, $dy)> Move the area covered by C<$region> by an offset C<$dx> and C<$dy> (integers). =item C<$X-EXFixesRegionExtents ($dst, $src)> Set region C<$dst> to the rectangular bounds of region C<$src>. If C<$src> is empty then C<$dst> is set to empty. =item C<($bounding, @parts) = $X-EXFixesFetchRegion ($region)> Return the rectangles which cover C<$region>. Each returned element is an arrayref [$x,$y,$width,$height] The first is a bounding rectangle, and after that the individual rectangles making up the region, in "YX-banded" order. my ($bounding, @rects) = $X->XFixesFetchRegion ($region); print "bounded by ",join(',',@$bounding); foreach my $rect (@rects) { print " rect part ",join(',',@$rect); } =item C<$X-EXFixesSetGCClipRegion ($gc, $clip_x_origin, $clip_y_origin, $region)> Set the clip mask of C<$gc> (an XID) to C<$region> (an XID), and set the clip origin to C<$clip_x_origin>,C<$clip_x_origin>. This is similar to the core C, but the rectangles are from C<$region> (and no "ordering" parameter). =item C<$X-EXFixesSetWindowShapeRegion ($window, $kind, $x_offset, $y_offset, $region)> Set the shape mask of C<$window> (an XID) to C<$region>, at offset C<$x_offset>,C<$y_offset> into the window. C<$kind> is a ShapeKind, either "Bounding" or "Clip". This is similar to C (see L) with operation "Set" and a a region instead of a bitmap. It's not necessary to C<$X-Einit_extension('SHAPE')> before using this request. If SHAPE is not available at all on the server then presumably this request gives an error reply. =item C<$X-EXFixesSetPictureClipRegion ($picture, $clip_x_origin, $clip_y_origin, $region)> Set the clip mask of RENDER C<$picture> (an XID) to C<$region>, and set the clip origin to C<$clip_x_origin>,C<$clip_x_origin>. This is similar to C, but the rectangles are from C<$region>. Picture objects are from the RENDER extension (see L). The request always exists, but is not useful without RENDER. =item C<$X-EXFixesSetCursorName ($cursor, $str)> Set a name for cursor object C<$cursor> (an XID). The name string C<$str> is interned as an atom within the server and therefore should consist only of latin-1 characters. (Perhaps in the future that might be enforced here, or wide chars converted.) =item C<($atom, $str) = $X-EXFixesGetCursorName ($cursor)> Get the name of mouse pointer cursor C<$cursor> (an XID), as set by C. The returned C<$atom> is the name atom (an integer) and C<$str> is the name string (which is the atom's name). If there's no name for C<$cursor> then C<$atom> is string "None" (or 0 if no C<$X-E{'do_interp'}>) and C<$str> is empty "". =item C<($x,$y, $width,$height, $xhot,$yhot, $serial, $pixels, $atom, $str) = $X-EXFixesGetCursorImageAndName ()> Get the image and name of the current mouse pointer cursor. The return is per C plus C described above. =item C<$X-EXFixesChangeCursor ($src, $dst)> Change the contents of cursor C<$dst> (an XID) to the contents of cursor C<$src> (an XID). =item C<$X-EXFixesChangeCursorByName ($src, $dst_str)> Change the contents of any cursors with name C<$dst_str> (a string) to the contents of cursor C<$src>. If there's no cursors with name C<$dst_str> then do nothing. =back =head2 XFIXES version 3.0 =over =item C<$X-EXFixesExpandRegion ($src, $dst, $left,$right,$top,$bottom)> Set region C<$dst> (an XID) to the rectangles of region C<$src>, with each rectangle expanded by C<$left>, C<$right>, C<$top>, C<$bottom> many pixels in those respective directions. It doesn't matter how C<$src> is expressed as rectangles, the effect is as if each pixel in C<$src> was individually expanded and the union of the result taken. =back =head2 XFIXES version 4.0 =over =item C<$X-EXFixesHideCursor ($window)> =item C<$X-EXFixesShowCursor ($window)> Hide or show the mouse pointer cursor while it's in C<$window> (an XID) or any subwindow of C<$window>. This hide/show for each window is a per-client setting. If more than one client requests hiding then the cursor remains hidden until all of them "show" again. If a client disconnects or is killed then any hides it has are undone. =back =head2 XFIXES version 5.0 Code waiting to be tested! =head1 EVENTS The following events have the usual fields name "XFixes..." synthetic true if from a SendEvent code integer opcode sequence_number integer =over =item C This is sent to the client when selected by C above. It reports changes to the selection. The event-specific fields are subtype enum string window XID owner XID of owner window, or "None" selection atom integer time integer, server timestamp selection_time integer, server timestamp C is one of SetSelectionOwner SelectionWindowDestroy SelectionClientClose C