Code

Allowed Private Use Area chacters to be entered.
authorjoncruz <joncruz@users.sourceforge.net>
Mon, 27 Feb 2006 00:25:30 +0000 (00:25 +0000)
committerjoncruz <joncruz@users.sourceforge.net>
Mon, 27 Feb 2006 00:25:30 +0000 (00:25 +0000)
ChangeLog
src/text-context.cpp

index 71b3ec9032bf836895a55ef31497092be7142860..9396039eb4e4882ef5a4fd36d01bc1825bb49332 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+2006-02-26  Jon A. Cruz  <jon@joncruz.org>
+       * src/text-context.cpp:
+
+         Allow Private Use Area characters. Fixes bug #1439016.
+       
 2006-02-18  Jon A. Cruz  <jon@joncruz.org>
        * src/dialogs/swatches.cpp, src/dialogs/iconpreview.cpp,
          src/ui/widget/panel.cpp, src/ui/widget/panel.h:
index d59ba6bdf0b464a855420e93d6deac3edcc5fb8b..5f4bbdba7e62835bcdbbdb2350cd226cce6c82e9 100644 (file)
@@ -519,7 +519,8 @@ insert_uni_char(SPTextContext *const tc)
     tc->unipos = 0;
     tc->uni[tc->unipos] = '\0';
 
-    if (!g_unichar_isprint((gunichar) uv)) {
+    if ( !g_unichar_isprint(static_cast<gunichar>(uv))
+         && !(g_unichar_validate(static_cast<gunichar>(uv)) && (g_unichar_type(static_cast<gunichar>(uv)) == G_UNICODE_PRIVATE_USE) ) ) {
         // This may be due to bad input, so it goes to statusbar.
         tc->desktop->messageStack()->flash(Inkscape::ERROR_MESSAGE,
                                            _("Non-printable character"));