Code

These files were separated out from filedialog.cpp and filedialog.h, so to facilitate...
[inkscape.git] / src / ui / dialog / inkscape-preferences.cpp
index 3627b2e6b74a9d39e69de626793d9c6502308a4b..cd6cd0b9f3ee2b80416cedf3dee7ee8ec4c7a22e 100644 (file)
@@ -175,6 +175,12 @@ void InkscapePreferences::initPageScrolling()
     _scroll_auto_thres.init ( "options.autoscrolldistance", "value", -600.0, 600.0, 1.0, 1.0, -10.0, true, false);
     _page_scrolling.add_line( true, _("Threshold:"), _scroll_auto_thres, _("pixels"), 
                            _("How far (in screen pixels) you need to be from the canvas edge to trigger autoscroll; positive is outside the canvas, negative is within the canvas"), false);
+    _scroll_space.init ( _("Left mouse button pans when Space is pressed"), "options.spacepans", "value", false);
+    _page_scrolling.add_line( false, "", _scroll_space, "", 
+                            _("When on, pressing and holding Space and dragging with left mouse button pans canvas (as in Adobe Illustrator). When off, Space temporarily switches to Selector tool (default)."));
+    _wheel_zoom.init ( _("Mouse wheel zooms by default"), "options.wheelzooms", "value", false);
+    _page_scrolling.add_line( false, "", _wheel_zoom, "", 
+                            _("When on, mouse wheel zooms without Ctrl and scrolls canvas with Ctrl; when off, it zooms with Ctrl and scrolls without Ctrl."));
 }
 
 void InkscapePreferences::initPageSteps()
@@ -195,9 +201,9 @@ void InkscapePreferences::initPageSteps()
     _steps_compass.init ( _("Compass-like display of angles"), "options.compassangledisplay", "value", true);
     _page_steps.add_line( false, "", _steps_compass, "", 
                             _("When on, angles are displayed with 0 at north, 0 to 360 range, positive clockwise; otherwise with 0 at east, -180 to 180 range, positive counterclockwise"));
-    int const num_items = 12;
-    Glib::ustring labels[num_items] = {"90", "60", "45", "30", "15", "10", "7.5", "6", "3", "2", "1", _("None")};
-    int values[num_items] = {2, 3, 4, 6, 12, 18, 24, 30, 60, 90, 180, 0};
+    int const num_items = 17;
+    Glib::ustring labels[num_items] = {"90", "60", "45", "36", "30", "22.5", "18", "15", "12", "10", "7.5", "6", "3", "2", "1", "0.5", _("None")};
+    int values[num_items] = {2, 3, 4, 5, 6, 8, 10, 12, 15, 18, 24, 30, 60, 90, 180, 360, 0};
     _steps_rot_snap.set_size_request(_sb_width);
     _steps_rot_snap.init("options.rotationsnapsperpi", "value", labels, values, num_items, 12);
     _page_steps.add_line( false, _("Rotation snaps every:"), _steps_rot_snap, _("degrees"), 
@@ -362,6 +368,9 @@ void InkscapePreferences::initPageTools()
     //Rectangle
     this->AddPage(_page_rectangle, _("Rectangle"), iter_shapes, PREFS_PAGE_TOOLS_SHAPES_RECT);
     this->AddNewObjectsStyle(_page_rectangle, "tools.shapes.rect");
+    //3D box
+    this->AddPage(_page_3dbox, _("3D Box"), iter_shapes, PREFS_PAGE_TOOLS_SHAPES_3DBOX);
+    this->AddNewObjectsStyle(_page_3dbox, "tools.shapes.3dbox");
     //ellipse
     this->AddPage(_page_ellipse, _("Ellipse"), iter_shapes, PREFS_PAGE_TOOLS_SHAPES_ELLIPSE);
     this->AddNewObjectsStyle(_page_ellipse, "tools.shapes.arc");
@@ -414,7 +423,10 @@ void InkscapePreferences::initPageTools()
 
 void InkscapePreferences::initPageWindows()
 {
-    _win_save_geom.init ( _("Save window geometry"), "options.savewindowgeometry", "value", true);
+    _win_save_geom.init ( _("Save and restore window geometry for each document"), "options.savewindowgeometry", "value", 1, true, 0);
+    _win_save_geom_prefs.init ( _("Remember and use last window's geometry"), "options.savewindowgeometry", "value", 2, false, &_win_save_geom);
+    _win_save_geom_off.init ( _("Don't save window geometry"), "options.savewindowgeometry", "value", 0, false, &_win_save_geom);
+
     _win_hide_task.init ( _("Dialogs are hidden in taskbar"), "options.dialogsskiptaskbar", "value", true);
     _win_zoom_resize.init ( _("Zoom when window is resized"), "options.stickyzoom", "value", false);
     _win_show_close.init ( _("Show close button on dialogs"), "dialogs", "showclose", false);
@@ -427,16 +439,14 @@ void InkscapePreferences::initPageWindows()
     _win_ontop_win32.init ( _("Dialogs stay on top (experimental!)"), "options.dialogsontopwin32", "value", false);
 #endif 
 
+    _page_windows.add_group_header( _("Saving window geometry (size and position):"));
+    _page_windows.add_line( false, "", _win_save_geom_off, "", 
+                            _("Let the window manager determine placement of all windows"));
+    _page_windows.add_line( false, "", _win_save_geom_prefs, "", 
+                            _("Remember and use the last window's geometry (saves geometry to user preferences)"));
     _page_windows.add_line( false, "", _win_save_geom, "", 
-                            _("Save the window size and position with each document (only for Inkscape SVG format)"));
-#ifndef WIN32 // FIXME: Temporary Win32 special code to enable transient dialogs
-    _page_windows.add_line( false, "", _win_hide_task, "", 
-                            _("Whether dialog windows are to be hidden in the window manager taskbar"));
-#endif                           
-    _page_windows.add_line( false, "", _win_zoom_resize, "", 
-                            _("Zoom drawing when document window is resized, to keep the same area visible (this is the default which can be changed in any window using the button above the right scrollbar)"));
-    _page_windows.add_line( false, "", _win_show_close, "", 
-                            _("Whether dialog windows have a close button (requires restart)"));
+                            _("Save and restore window geometry for each document (saves geometry in the document)"));
+
     _page_windows.add_group_header( _("Dialogs on top:"));
 #ifndef WIN32 // FIXME: Temporary Win32 special code to enable transient dialogs
     _page_windows.add_line( true, "", _win_ontop_none, "", 
@@ -450,6 +460,15 @@ void InkscapePreferences::initPageWindows()
                             _("Whether dialogs should stay on top of document windows. Read the ReleaseNotes on this issue! (Rightclick the taskbar button and press 'Restore' to bring back a minimized document window)"));
 #endif                            
 
+    _page_windows.add_group_header( _("Miscellaneous:"));
+#ifndef WIN32 // FIXME: Temporary Win32 special code to enable transient dialogs
+    _page_windows.add_line( false, "", _win_hide_task, "", 
+                            _("Whether dialog windows are to be hidden in the window manager taskbar"));
+#endif                           
+    _page_windows.add_line( false, "", _win_zoom_resize, "", 
+                            _("Zoom drawing when document window is resized, to keep the same area visible (this is the default which can be changed in any window using the button above the right scrollbar)"));
+    _page_windows.add_line( false, "", _win_show_close, "", 
+                            _("Whether dialog windows have a close button (requires restart)"));
     this->AddPage(_page_windows, _("Windows"), PREFS_PAGE_WINDOWS);
 }
 
@@ -587,6 +606,9 @@ void InkscapePreferences::initPageMisc()
     _misc_comment.init( _("Add label comments to printing output"), "printing.debug", "show-label-comments", false);
     _page_misc.add_line( false, "", _misc_comment, "", 
                            _("When on, a comment will be added to the raw print output, marking the rendered output for an object with its label"), true);
+    _misc_small_toolbar.init( _("Make commands toolbar smaller"), "toolbox", "small", true);
+    _page_misc.add_line( false, "", _misc_small_toolbar, "",
+                           _("Make the commands toolbar use the 'secondary' toolbar size (requires restart)"), true);
     _misc_recent.init("options.maxrecentdocuments", "value", 0.0, 1000.0, 1.0, 1.0, 1.0, true, false);
     _page_misc.add_line( false, _("Max recent documents:"), _misc_recent, "", 
                            _("The maximum length of the Open Recent list in the File menu"), false);