summaryrefslogtreecommitdiffstats
path: root/src/extension/internal/cdr-input.cpp
diff options
context:
space:
mode:
authorJabiertxof <jtx@jtx>2017-01-24 14:16:06 +0000
committerJabiertxof <jtx@jtx>2017-01-24 14:16:06 +0000
commitb25ebda10578c5d697db9716e3c2b70950d33e45 (patch)
tree4635b8b3f65600cfd54b5465b906ae42165b0674 /src/extension/internal/cdr-input.cpp
parentFix some bugs (diff)
parentfix nodes reverting back during editing (diff)
downloadinkscape-b25ebda10578c5d697db9716e3c2b70950d33e45.tar.gz
inkscape-b25ebda10578c5d697db9716e3c2b70950d33e45.zip
fixing to new trunk
(bzr r15142.1.38)
Diffstat (limited to 'src/extension/internal/cdr-input.cpp')
-rw-r--r--src/extension/internal/cdr-input.cpp11
1 files changed, 9 insertions, 2 deletions
diff --git a/src/extension/internal/cdr-input.cpp b/src/extension/internal/cdr-input.cpp
index b94b6d019..0435f1396 100644
--- a/src/extension/internal/cdr-input.cpp
+++ b/src/extension/internal/cdr-input.cpp
@@ -116,8 +116,8 @@ CdrImportDialog::CdrImportDialog(const std::vector<RVNGString> &vec)
// CONTROLS
// Buttons
- cancelbutton = Gtk::manage(new class Gtk::Button(Gtk::StockID("gtk-cancel")));
- okbutton = Gtk::manage(new class Gtk::Button(Gtk::StockID("gtk-ok")));
+ cancelbutton = Gtk::manage(new Gtk::Button(_("_Cancel"), true));
+ okbutton = Gtk::manage(new Gtk::Button(_("_OK"), true));
// Labels
_labelSelect = Gtk::manage(new class Gtk::Label(_("Select page:")));
@@ -214,6 +214,13 @@ void CdrImportDialog::_setPreviewPage()
SPDocument *CdrInput::open(Inkscape::Extension::Input * /*mod*/, const gchar * uri)
{
+ #ifdef WIN32
+ // RVNGFileStream uses fopen() internally which unfortunately only uses ANSI encoding on Windows
+ // therefore attempt to convert uri to the system codepage
+ // even if this is not possible the alternate short (8.3) file name will be used if available
+ uri = g_win32_locale_filename_from_utf8(uri);
+ #endif
+
RVNGFileStream input(uri);
if (!libcdr::CDRDocument::isSupported(&input)) {