summaryrefslogtreecommitdiffstats
path: root/src/ui/dialog
diff options
context:
space:
mode:
authorLiam P. White <inkscapebrony@gmail.com>2014-08-30 15:49:40 +0000
committerLiam P. White <inkscapebrony@gmail.com>2014-08-30 15:49:40 +0000
commit18770eebe339cdc673812a48c5e05c7cdcb3a82e (patch)
tree1e3846a72decad64d24100cdbe0a2e0d42f252b8 /src/ui/dialog
parentUpdate to experimental r13464 (diff)
parentFix paint-selector orientation (diff)
downloadinkscape-18770eebe339cdc673812a48c5e05c7cdcb3a82e.tar.gz
inkscape-18770eebe339cdc673812a48c5e05c7cdcb3a82e.zip
Update to experimental r13527
(bzr r13341.5.15)
Diffstat (limited to 'src/ui/dialog')
-rw-r--r--src/ui/dialog/aboutbox.cpp6
-rw-r--r--src/ui/dialog/aboutbox.h6
-rw-r--r--src/ui/dialog/clonetiler.h1
-rw-r--r--src/ui/dialog/dialog.cpp16
-rw-r--r--src/ui/dialog/document-properties.cpp7
-rw-r--r--src/ui/dialog/export.h9
-rw-r--r--src/ui/dialog/filedialogimpl-gtkmm.cpp1
-rw-r--r--src/ui/dialog/grid-arrange-tab.h8
-rw-r--r--src/ui/dialog/inkscape-preferences.cpp8
-rw-r--r--src/ui/dialog/inkscape-preferences.h5
-rw-r--r--src/ui/dialog/lpe-fillet-chamfer-properties.cpp18
-rw-r--r--src/ui/dialog/lpe-fillet-chamfer-properties.h21
-rw-r--r--src/ui/dialog/new-from-template.cpp15
-rw-r--r--src/ui/dialog/polar-arrange-tab.cpp32
-rw-r--r--src/ui/dialog/polar-arrange-tab.h19
-rw-r--r--src/ui/dialog/print.cpp21
-rw-r--r--src/ui/dialog/text-edit.cpp6
-rw-r--r--src/ui/dialog/xml-tree.cpp1
18 files changed, 147 insertions, 53 deletions
diff --git a/src/ui/dialog/aboutbox.cpp b/src/ui/dialog/aboutbox.cpp
index a66855b2a..44ed3b58f 100644
--- a/src/ui/dialog/aboutbox.cpp
+++ b/src/ui/dialog/aboutbox.cpp
@@ -941,13 +941,13 @@ void AboutBox::initStrings() {
} // namespace UI
} // namespace Inkscape
-/*
+/*
Local Variables:
mode:c++
c-file-style:"stroustrup"
- c-file-offsets:((innamespace . 0)(inline-open . 0))
+ c-file-offsets:((innamespace . 0)(inline-open . 0)(case-label . +))
indent-tabs-mode:nil
fill-column:99
End:
*/
-// vim: filetype=c++:expandtab:shiftwidth=4:tabstop=8:softtabstop=4 :
+// vim: filetype=cpp:expandtab:shiftwidth=4:tabstop=8:softtabstop=4:fileencoding=utf-8:textwidth=99 :
diff --git a/src/ui/dialog/aboutbox.h b/src/ui/dialog/aboutbox.h
index 7b3308672..015e344a1 100644
--- a/src/ui/dialog/aboutbox.h
+++ b/src/ui/dialog/aboutbox.h
@@ -55,13 +55,13 @@ private:
#endif // INKSCAPE_UI_DIALOG_ABOUTBOX_H
-/*
+/*
Local Variables:
mode:c++
c-file-style:"stroustrup"
- c-file-offsets:((innamespace . 0)(inline-open . 0))
+ c-file-offsets:((innamespace . 0)(inline-open . 0)(case-label . +))
indent-tabs-mode:nil
fill-column:99
End:
*/
-// vim: filetype=c++:expandtab:shiftwidth=4:tabstop=8:softtabstop=4 :
+// vim: filetype=cpp:expandtab:shiftwidth=4:tabstop=8:softtabstop=4:fileencoding=utf-8:textwidth=99 :
diff --git a/src/ui/dialog/clonetiler.h b/src/ui/dialog/clonetiler.h
index 879fed8c2..e5f5638b2 100644
--- a/src/ui/dialog/clonetiler.h
+++ b/src/ui/dialog/clonetiler.h
@@ -11,7 +11,6 @@
#define __SP_CLONE_TILER_H__
#include "ui/widget/panel.h"
-#include <gtk/gtk.h>
#include "ui/dialog/desktop-tracker.h"
#include "ui/widget/color-picker.h"
diff --git a/src/ui/dialog/dialog.cpp b/src/ui/dialog/dialog.cpp
index 70f9c6a70..13e828337 100644
--- a/src/ui/dialog/dialog.cpp
+++ b/src/ui/dialog/dialog.cpp
@@ -287,20 +287,8 @@ void Dialog::_apply()
void Dialog::_close()
{
- GtkWidget *dlg = GTK_WIDGET(_behavior->gobj());
-
- GdkEventAny event;
- event.type = GDK_DELETE;
- event.window = gtk_widget_get_window(dlg);
- event.send_event = TRUE;
-
- if (event.window)
- g_object_ref(G_OBJECT(event.window));
-
- gtk_main_do_event ((GdkEvent*)&event);
-
- if (event.window)
- g_object_unref(G_OBJECT(event.window));
+ _behavior->hide();
+ _onDeleteEvent(NULL);
}
void Dialog::_defocus()
diff --git a/src/ui/dialog/document-properties.cpp b/src/ui/dialog/document-properties.cpp
index 00b54017c..559cd6bbc 100644
--- a/src/ui/dialog/document-properties.cpp
+++ b/src/ui/dialog/document-properties.cpp
@@ -45,6 +45,7 @@
#include "widgets/icon.h"
#include "xml/node-event-vector.h"
#include "xml/repr.h"
+#include <algorithm> // std::min
#include "rdf.h"
#include "ui/widget/entity-entry.h"
@@ -1735,9 +1736,9 @@ void DocumentProperties::onDocUnitChange()
prefs->setBool("/options/transform/gradient", true);
{
ShapeEditor::blockSetItem(true);
- gdouble viewscale = doc->getWidth().value("px")/doc->getRoot()->viewBox.width();
- if (doc->getHeight().value("px")/doc->getRoot()->viewBox.height() < viewscale)
- viewscale = doc->getHeight().value("px")/doc->getRoot()->viewBox.height();
+ gdouble viewscale_w = doc->getWidth().value("px")/doc->getRoot()->viewBox.width();
+ gdouble viewscale_h = doc->getHeight().value("px")/doc->getRoot()->viewBox.height();
+ gdouble viewscale = std::min(viewscale_h, viewscale_w);
gdouble scale = Inkscape::Util::Quantity::convert(1, old_doc_unit, doc_unit);
doc->getRoot()->scaleChildItemsRec(Geom::Scale(scale), Geom::Point(-viewscale*doc->getRoot()->viewBox.min()[Geom::X] +
(doc->getWidth().value("px") - viewscale*doc->getRoot()->viewBox.width())/2,
diff --git a/src/ui/dialog/export.h b/src/ui/dialog/export.h
index 6f3c0dfac..23af0109b 100644
--- a/src/ui/dialog/export.h
+++ b/src/ui/dialog/export.h
@@ -12,20 +12,11 @@
#ifndef SP_EXPORT_H
#define SP_EXPORT_H
-#include <gtk/gtk.h>
-#include <glibmm/i18n.h>
-
-#include <gtkmm/comboboxtext.h>
-#include <gtkmm/expander.h>
-#include <gtkmm/frame.h>
#include <gtkmm/progressbar.h>
-#include <gtkmm/textview.h>
-#include "desktop.h"
#include "ui/dialog/desktop-tracker.h"
#include "ui/widget/panel.h"
#include "ui/widget/button.h"
-#include "ui/widget/entry.h"
namespace Gtk {
class Dialog;
diff --git a/src/ui/dialog/filedialogimpl-gtkmm.cpp b/src/ui/dialog/filedialogimpl-gtkmm.cpp
index 2abe78e49..9b75d360a 100644
--- a/src/ui/dialog/filedialogimpl-gtkmm.cpp
+++ b/src/ui/dialog/filedialogimpl-gtkmm.cpp
@@ -40,6 +40,7 @@
#include <glibmm/i18n.h>
#include <glibmm/miscutils.h>
+#include "document.h"
#include "extension/input.h"
#include "extension/output.h"
#include "extension/db.h"
diff --git a/src/ui/dialog/grid-arrange-tab.h b/src/ui/dialog/grid-arrange-tab.h
index 9d6700b39..a137d1694 100644
--- a/src/ui/dialog/grid-arrange-tab.h
+++ b/src/ui/dialog/grid-arrange-tab.h
@@ -17,14 +17,16 @@
#ifndef INKSCAPE_UI_DIALOG_GRID_ARRANGE_TAB_H
#define INKSCAPE_UI_DIALOG_GRID_ARRANGE_TAB_H
-#include <gtkmm.h>
-
+#include "ui/widget/scalar-unit.h"
#include "ui/dialog/arrange-tab.h"
#include "ui/widget/anchor-selector.h"
-#include "ui/widget/scalar-unit.h"
#include "ui/widget/spinbutton.h"
+#include <gtkmm/checkbutton.h>
+#include <gtkmm/radiobutton.h>
+#include <gtkmm/radiobuttongroup.h>
+
namespace Inkscape {
namespace UI {
namespace Dialog {
diff --git a/src/ui/dialog/inkscape-preferences.cpp b/src/ui/dialog/inkscape-preferences.cpp
index 5e698355c..2b1198ba0 100644
--- a/src/ui/dialog/inkscape-preferences.cpp
+++ b/src/ui/dialog/inkscape-preferences.cpp
@@ -76,7 +76,8 @@ InkscapePreferences::InkscapePreferences()
: UI::Widget::Panel ("", "/dialogs/preferences", SP_VERB_DIALOG_DISPLAY),
_max_dialog_width(0),
_max_dialog_height(0),
- _current_page(0)
+ _current_page(0),
+ _init(true)
{
//get the width of a spinbutton
Inkscape::UI::Widget::SpinButton* sb = new Inkscape::UI::Widget::SpinButton;
@@ -2000,6 +2001,7 @@ bool InkscapePreferences::PresentPage(const Gtk::TreeModel::iterator& iter)
Gtk::TreeModel::Row row = *iter;
Inkscape::Preferences *prefs = Inkscape::Preferences::get();
int desired_page = prefs->getInt("/dialogs/preferences/page", 0);
+ _init = false;
if (desired_page == row[_page_list_columns._col_id])
{
if (desired_page >= PREFS_PAGE_TOOLS && desired_page <= PREFS_PAGE_TOOLS_CONNECTOR)
@@ -2049,7 +2051,9 @@ void InkscapePreferences::on_pagelist_selection_changed()
Gtk::TreeModel::Row row = *iter;
_current_page = row[_page_list_columns._col_page];
Inkscape::Preferences *prefs = Inkscape::Preferences::get();
- prefs->setInt("/dialogs/preferences/page", row[_page_list_columns._col_id]);
+ if (!_init) {
+ prefs->setInt("/dialogs/preferences/page", row[_page_list_columns._col_id]);
+ }
_page_title.set_markup("<span size='large'><b>" + row[_page_list_columns._col_name] + "</b></span>");
_page_frame.add(*_current_page);
_current_page->show();
diff --git a/src/ui/dialog/inkscape-preferences.h b/src/ui/dialog/inkscape-preferences.h
index 1c2151605..dcea91741 100644
--- a/src/ui/dialog/inkscape-preferences.h
+++ b/src/ui/dialog/inkscape-preferences.h
@@ -532,6 +532,7 @@ private:
InkscapePreferences();
InkscapePreferences(InkscapePreferences const &d);
InkscapePreferences operator=(InkscapePreferences const &d);
+ bool _init;
};
} // namespace Dialog
@@ -544,9 +545,9 @@ private:
Local Variables:
mode:c++
c-file-style:"stroustrup"
- c-file-offsets:((innamespace . 0)(inline-open . 0))
+ c-file-offsets:((innamespace . 0)(inline-open . 0)(case-label . +))
indent-tabs-mode:nil
fill-column:99
End:
*/
-// vim: filetype=c++:expandtab:shiftwidth=4:tabstop=8:softtabstop=4 :
+// vim: filetype=cpp:expandtab:shiftwidth=4:tabstop=8:softtabstop=4:fileencoding=utf-8:textwidth=99 :
diff --git a/src/ui/dialog/lpe-fillet-chamfer-properties.cpp b/src/ui/dialog/lpe-fillet-chamfer-properties.cpp
index a68c7ee08..eef32d10d 100644
--- a/src/ui/dialog/lpe-fillet-chamfer-properties.cpp
+++ b/src/ui/dialog/lpe-fillet-chamfer-properties.cpp
@@ -44,20 +44,38 @@ namespace Dialogs {
FilletChamferPropertiesDialog::FilletChamferPropertiesDialog()
: _desktop(NULL), _knotpoint(NULL), _position_visible(false)
{
+#if WITH_GTKMM_3_0
+ Gtk::Box *mainVBox = get_content_area();
+#else
Gtk::Box *mainVBox = get_vbox();
+#endif
+
mainVBox->set_homogeneous(false);
+
+#if WITH_GTKMM_3_0
+ _layout_table.set_row_spacing(4);
+ _layout_table.set_column_spacing(4);
+#else
_layout_table.set_spacings(4);
_layout_table.resize(2, 2);
+#endif
// Layer name widgets
_fillet_chamfer_position_entry.set_activates_default(true);
_fillet_chamfer_position_label.set_label(_("Radius (pixels):"));
_fillet_chamfer_position_label.set_alignment(1.0, 0.5);
+#if WITH_GTKMM_3_0
+ _layout_table.attach(_fillet_chamfer_position_label, 0, 0, 1, 1);
+ _layout_table.attach(_fillet_chamfer_position_entry, 1, 0, 1, 1);
+ _fillet_chamfer_position_entry.set_hexpand();
+#else
_layout_table.attach(_fillet_chamfer_position_label, 0, 1, 0, 1, Gtk::FILL,
Gtk::FILL);
_layout_table.attach(_fillet_chamfer_position_entry, 1, 2, 0, 1,
Gtk::FILL | Gtk::EXPAND, Gtk::FILL);
+#endif
+
_fillet_chamfer_type_fillet.set_label(_("Fillet"));
_fillet_chamfer_type_fillet.set_group(_fillet_chamfer_type_group);
_fillet_chamfer_type_inverse_fillet.set_label(_("Inverse fillet"));
diff --git a/src/ui/dialog/lpe-fillet-chamfer-properties.h b/src/ui/dialog/lpe-fillet-chamfer-properties.h
index d3e859bff..9beca02e1 100644
--- a/src/ui/dialog/lpe-fillet-chamfer-properties.h
+++ b/src/ui/dialog/lpe-fillet-chamfer-properties.h
@@ -8,10 +8,24 @@
#ifndef INKSCAPE_DIALOG_FILLET_CHAMFER_PROPERTIES_H
#define INKSCAPE_DIALOG_FILLET_CHAMFER_PROPERTIES_H
+#if HAVE_CONFIG_H
+ #include "config.h"
+#endif
+
+#include <gtkmm/dialog.h>
#include <2geom/point.h>
-#include <gtkmm.h>
#include "live_effects/parameter/filletchamferpointarray.h"
+#include <gtkmm/entry.h>
+#include <gtkmm/label.h>
+#include <gtkmm/radiobutton.h>
+
+#if WITH_GTKMM_3_0
+ #include <gtkmm/grid.h>
+#else
+ #include <gtkmm/table.h>
+#endif
+
class SPDesktop;
namespace Inkscape {
@@ -46,7 +60,12 @@ protected:
Gtk::RadioButton _fillet_chamfer_type_chamfer;
Gtk::RadioButton _fillet_chamfer_type_double_chamfer;
+#if WITH_GTKMM_3_0
+ Gtk::Grid _layout_table;
+#else
Gtk::Table _layout_table;
+#endif
+
bool _position_visible;
double _index;
diff --git a/src/ui/dialog/new-from-template.cpp b/src/ui/dialog/new-from-template.cpp
index f326bb3ee..e30b148bb 100644
--- a/src/ui/dialog/new-from-template.cpp
+++ b/src/ui/dialog/new-from-template.cpp
@@ -8,6 +8,9 @@
* Released under GNU GPL, read the file 'COPYING' for more information
*/
+#if HAVE_CONFIG_H
+ #include "config.h"
+#endif
#include "new-from-template.h"
#include "file.h"
@@ -25,12 +28,22 @@ NewFromTemplate::NewFromTemplate()
{
set_title(_("New From Template"));
resize(400, 400);
-
+
+#if WITH_GTKMM_3_0
+ get_content_area()->pack_start(_main_widget);
+#else
get_vbox()->pack_start(_main_widget);
+#endif
Gtk::Alignment *align;
align = Gtk::manage(new Gtk::Alignment(Gtk::ALIGN_END, Gtk::ALIGN_CENTER, 0.0, 0.0));
+
+#if WITH_GTKMM_3_0
+ get_content_area()->pack_end(*align, Gtk::PACK_SHRINK);
+#else
get_vbox()->pack_end(*align, Gtk::PACK_SHRINK);
+#endif
+
align->set_padding(0, 0, 0, 15);
align->add(_create_template_button);
diff --git a/src/ui/dialog/polar-arrange-tab.cpp b/src/ui/dialog/polar-arrange-tab.cpp
index a00b8fc02..80579c9d3 100644
--- a/src/ui/dialog/polar-arrange-tab.cpp
+++ b/src/ui/dialog/polar-arrange-tab.cpp
@@ -25,6 +25,7 @@
#include "desktop.h"
#include "sp-ellipse.h"
#include "sp-item-transform.h"
+#include <gtkmm/messagedialog.h>
namespace Inkscape {
namespace UI {
@@ -32,7 +33,11 @@ namespace Dialog {
PolarArrangeTab::PolarArrangeTab(ArrangeDialog *parent_)
: parent(parent_),
+#if WITH_GTKMM_3_0
+ parametersTable(),
+#else
parametersTable(3, 3, false),
+#endif
centerY("", "Y coordinate of the center", UNIT_TYPE_LINEAR),
centerX("", "X coordinate of the center", centerY),
radiusY("", "Y coordinate of the radius", UNIT_TYPE_LINEAR),
@@ -76,7 +81,11 @@ PolarArrangeTab::PolarArrangeTab(ArrangeDialog *parent_)
pack_start(arrangeOnParametersRadio, false, false);
centerLabel.set_text(_("Center X/Y:"));
+#if WITH_GTKMM_3_0
+ parametersTable.attach(centerLabel, 0, 0, 1, 1);
+#else
parametersTable.attach(centerLabel, 0, 1, 0, 1, Gtk::FILL);
+#endif
centerX.setDigits(2);
centerX.setIncrements(0.2, 0);
centerX.setRange(-10000, 10000);
@@ -85,11 +94,20 @@ PolarArrangeTab::PolarArrangeTab(ArrangeDialog *parent_)
centerY.setIncrements(0.2, 0);
centerY.setRange(-10000, 10000);
centerY.setValue(0, "px");
+#if WITH_GTKMM_3_0
+ parametersTable.attach(centerX, 1, 0, 1, 1);
+ parametersTable.attach(centerY, 2, 0, 1, 1);
+#else
parametersTable.attach(centerX, 1, 2, 0, 1, Gtk::FILL);
parametersTable.attach(centerY, 2, 3, 0, 1, Gtk::FILL);
+#endif
radiusLabel.set_text(_("Radius X/Y:"));
+#if WITH_GTKMM_3_0
+ parametersTable.attach(radiusLabel, 0, 1, 1, 1);
+#else
parametersTable.attach(radiusLabel, 0, 1, 1, 2, Gtk::FILL);
+#endif
radiusX.setDigits(2);
radiusX.setIncrements(0.2, 0);
radiusX.setRange(0.001, 10000);
@@ -98,11 +116,20 @@ PolarArrangeTab::PolarArrangeTab(ArrangeDialog *parent_)
radiusY.setIncrements(0.2, 0);
radiusY.setRange(0.001, 10000);
radiusY.setValue(100, "px");
+#if WITH_GTKMM_3_0
+ parametersTable.attach(radiusX, 1, 1, 1, 1);
+ parametersTable.attach(radiusY, 2, 1, 1, 1);
+#else
parametersTable.attach(radiusX, 1, 2, 1, 2, Gtk::FILL);
parametersTable.attach(radiusY, 2, 3, 1, 2, Gtk::FILL);
+#endif
angleLabel.set_text(_("Angle X/Y:"));
+#if WITH_GTKMM_3_0
+ parametersTable.attach(angleLabel, 0, 2, 1, 1);
+#else
parametersTable.attach(angleLabel, 0, 1, 2, 3, Gtk::FILL);
+#endif
angleX.setDigits(2);
angleX.setIncrements(0.2, 0);
angleX.setRange(-10000, 10000);
@@ -111,8 +138,13 @@ PolarArrangeTab::PolarArrangeTab(ArrangeDialog *parent_)
angleY.setIncrements(0.2, 0);
angleY.setRange(-10000, 10000);
angleY.setValue(180, "°");
+#if WITH_GTKMM_3_0
+ parametersTable.attach(angleX, 1, 2, 1, 1);
+ parametersTable.attach(angleY, 2, 2, 1, 1);
+#else
parametersTable.attach(angleX, 1, 2, 2, 3, Gtk::FILL);
parametersTable.attach(angleY, 2, 3, 2, 3, Gtk::FILL);
+#endif
pack_start(parametersTable, false, false);
rotateObjectsCheckBox.set_label(_("Rotate objects"));
diff --git a/src/ui/dialog/polar-arrange-tab.h b/src/ui/dialog/polar-arrange-tab.h
index f6c3b2906..f7d7bf11f 100644
--- a/src/ui/dialog/polar-arrange-tab.h
+++ b/src/ui/dialog/polar-arrange-tab.h
@@ -10,9 +10,22 @@
#ifndef INKSCAPE_UI_DIALOG_POLAR_ARRANGE_TAB_H
#define INKSCAPE_UI_DIALOG_POLAR_ARRANGE_TAB_H
+#if HAVE_CONFIG_H
+ #include "config.h"
+#endif
+
+#include "ui/widget/scalar-unit.h"
#include "ui/widget/anchor-selector.h"
#include "ui/dialog/arrange-tab.h"
-#include "ui/widget/scalar-unit.h"
+
+#include <gtkmm/radiobutton.h>
+#include <gtkmm/radiobuttongroup.h>
+
+#if WITH_GTKMM_3_0
+ #include <gtkmm/grid.h>
+#else
+ #include <gtkmm/table.h>
+#endif
namespace Inkscape {
namespace UI {
@@ -62,7 +75,11 @@ private:
Gtk::RadioButton arrangeOnLastCircleRadio;
Gtk::RadioButton arrangeOnParametersRadio;
+#if WITH_GTKMM_3_0
+ Gtk::Grid parametersTable;
+#else
Gtk::Table parametersTable;
+#endif
Gtk::Label centerLabel;
Inkscape::UI::Widget::ScalarUnit centerY;
diff --git a/src/ui/dialog/print.cpp b/src/ui/dialog/print.cpp
index 459e64041..a015d28f9 100644
--- a/src/ui/dialog/print.cpp
+++ b/src/ui/dialog/print.cpp
@@ -14,8 +14,15 @@
# include <config.h>
#endif
+#include <gtkmm.h>
+
+#ifdef WIN32
+#include <io.h>
+#include <windows.h>
+#endif
+
+#include "preferences.h"
#include "print.h"
-#include <gtkmm/stock.h>
#include "extension/internal/cairo-render-context.h"
#include "extension/internal/cairo-renderer.h"
@@ -29,11 +36,6 @@
#include <glibmm/i18n.h>
-#ifdef WIN32
-#include <io.h>
-#include <windows.h>
-#endif
-
static void draw_page(
#ifdef WIN32
@@ -45,14 +47,18 @@ static void draw_page(
gint /*page_nr*/,
gpointer user_data)
{
+ Inkscape::Preferences *prefs = Inkscape::Preferences::get();
struct workaround_gtkmm *junk = (struct workaround_gtkmm*)user_data;
//printf("%s %d\n",__FUNCTION__, page_nr);
if (junk->_tab->as_bitmap()) {
// Render as exported PNG
+ prefs->setBool("/dialogs/printing/asbitmap", true);
gdouble width = (junk->_doc)->getWidth().value("px");
gdouble height = (junk->_doc)->getHeight().value("px");
gdouble dpi = junk->_tab->bitmap_dpi();
+ prefs->setDouble("/dialogs/printing/dpi", dpi);
+
std::string tmp_png;
std::string tmp_base = "inkscape-print-png-XXXXXX";
@@ -93,7 +99,7 @@ static void draw_page(
cairo_get_matrix(cr, &m);
cairo_scale(cr, Inkscape::Util::Quantity::convert(1, "in", "pt") / dpi, Inkscape::Util::Quantity::convert(1, "in", "pt") / dpi);
// FIXME: why is the origin offset??
- cairo_set_source_surface(cr, png->cobj(), -16.0, -16.0);
+ cairo_set_source_surface(cr, png->cobj(), 0, 0);
cairo_paint(cr);
cairo_set_matrix(cr, &m);
}
@@ -107,6 +113,7 @@ static void draw_page(
}
else {
// Render as vectors
+ prefs->setBool("/dialogs/printing/asbitmap", false);
Inkscape::Extension::Internal::CairoRenderer renderer;
Inkscape::Extension::Internal::CairoRenderContext *ctx = renderer.createContext();
diff --git a/src/ui/dialog/text-edit.cpp b/src/ui/dialog/text-edit.cpp
index c1ebb32e0..e44809c65 100644
--- a/src/ui/dialog/text-edit.cpp
+++ b/src/ui/dialog/text-edit.cpp
@@ -344,9 +344,9 @@ void TextEdit::onReadSelection ( gboolean dostyle, gboolean /*docontent*/ )
Inkscape::FontLister* fontlister = Inkscape::FontLister::get_instance();
- // This is done for us by text-toolbar. No need to do it twice.
- // fontlister->update_font_list( sp_desktop_document( SP_ACTIVE_DESKTOP ));
- // fontlister->selection_update();
+ // This is normally done for us by text-toolbar but only when we are in text editing context
+ fontlister->update_font_list(sp_desktop_document(this->desktop));
+ fontlister->selection_update();
Glib::ustring fontspec = fontlister->get_fontspec();
diff --git a/src/ui/dialog/xml-tree.cpp b/src/ui/dialog/xml-tree.cpp
index 55d0aff09..c87e42633 100644
--- a/src/ui/dialog/xml-tree.cpp
+++ b/src/ui/dialog/xml-tree.cpp
@@ -1033,6 +1033,7 @@ void XmlTree::cmd_set_attr()
updated->updateRepr();
}
+ reinterpret_cast<SPObject *>(current_desktop->currentLayer())->requestDisplayUpdate(SP_OBJECT_MODIFIED_FLAG);
DocumentUndo::done(current_document, SP_VERB_DIALOG_XML_EDITOR,
_("Change attribute"));