summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 329e69a)
raw | patch | inline | side by side (parent: 329e69a)
author | Jon A. Cruz <jon@joncruz.org> | |
Thu, 6 May 2010 07:20:39 +0000 (00:20 -0700) | ||
committer | Jon A. Cruz <jon@joncruz.org> | |
Thu, 6 May 2010 07:20:39 +0000 (00:20 -0700) |
src/ui/dialog/icon-preview.cpp | patch | blob | history | |
src/ui/dialog/icon-preview.h | patch | blob | history |
index f768df4f34fac024fe35acff2ad931b0370ab856..946eed4ca64cd32066fc0a27e92c4695e0e6ee71 100644 (file)
timer(0),
pending(false),
hot(1),
- refreshButton(0),
selectionButton(0),
desktopChangeConn(),
docReplacedConn(),
Gtk::VBox* magBox = new Gtk::VBox();
- magBox->pack_start( magnified );
+ Gtk::Frame *magFrame = Gtk::manage(new Gtk::Frame(_("Magnified:")));
+ magFrame->add( magnified );
+
+ magBox->pack_start( *magFrame, Gtk::PACK_EXPAND_WIDGET );
magBox->pack_start( magLabel, Gtk::PACK_SHRINK );
iconBox.pack_start(splitter);
splitter.pack1( *magBox, true, true );
- splitter.pack2( *verts, false, false );
-
-
- //## The Refresh button
+ Gtk::Frame *actuals = Gtk::manage(new Gtk::Frame(_("Actual Size:")));
+ actuals->add(*verts);
+ splitter.pack2( *actuals, false, false );
- Gtk::HButtonBox* holder = new Gtk::HButtonBox( Gtk::BUTTONBOX_END );
- _getContents()->pack_end(*holder, false, false);
-
- selectionButton = new Gtk::ToggleButton(_("Selection")); // , GTK_RESPONSE_APPLY
- holder->pack_start( *selectionButton, false, false );
+ selectionButton = new Gtk::CheckButton(_("Selection")); // , GTK_RESPONSE_APPLY
+ magBox->pack_start( *selectionButton, Gtk::PACK_SHRINK );
tips.set_tip((*selectionButton), _("Selection only or whole document"));
selectionButton->signal_clicked().connect( sigc::mem_fun(*this, &IconPreviewPanel::modeToggled) );
gint val = prefs->getBool("/iconpreview/selectionOnly");
selectionButton->set_active( val != 0 );
- refreshButton = new Gtk::Button(Gtk::Stock::REFRESH); // , GTK_RESPONSE_APPLY
- holder->pack_end( *refreshButton, false, false );
- tips.set_tip((*refreshButton), _("Refresh the icons"));
- refreshButton->signal_clicked().connect( sigc::mem_fun(*this, &IconPreviewPanel::refreshPreview) );
-
- _getContents()->pack_start(iconBox, Gtk::PACK_EXPAND_WIDGET);
+ _getContents()->pack_start(iconBox, Gtk::PACK_SHRINK);
show_all_children();
// Do not refresh too quickly
queueRefresh();
} else if ( desktop ) {
-
if ( selectionButton && selectionButton->get_active() )
{
Inkscape::Selection * sel = sp_desktop_selection(desktop);
renderPreview(target);
}
}
- }
- else
- {
+ } else {
SPObject *target = desktop->currentRoot();
if ( target ) {
renderPreview(target);
index d90c2b173e8b9ca1f1ce930648d1adb6723a44fb..a0f813b94e2cf6583a9b1e6f9287627cfebfac89 100644 (file)
Gtk::Image magnified;
Gtk::Label magLabel;
- Gtk::Button *refreshButton;
Gtk::ToggleButton *selectionButton;
guchar** pixMem;
#endif // SEEN_ICON_PREVIEW_H
+
+/*
+ Local Variables:
+ mode:c++
+ c-file-style:"stroustrup"
+ c-file-offsets:((innamespace . 0)(inline-open . 0)(case-label . +))
+ indent-tabs-mode:nil
+ fill-column:99
+ End:
+*/
+// vim: filetype=cpp:expandtab:shiftwidth=4:tabstop=8:softtabstop=4:encoding=utf-8:textwidth=99 :