[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Re: Re: Windows PSPPIRE/PSPP is pretty wonky

From: John Darrington
Subject: Re: Re: Re: Windows PSPPIRE/PSPP is pretty wonky
Date: Wed, 7 Jan 2015 06:58:06 +0100
User-agent: Mutt/1.5.21 (2010-09-15)


Can you try the attached patch and see if it makes any improvement.


On Tue, Jan 06, 2015 at 10:55:51PM +0100, Harry Thijssen wrote:
     > On Thu, Jan 01, 2015 at 08:43:38PM +0100, Harry Thijssen wrote:
     >      >
     >      > On Tue, Dec 30, 2014 at 04:58:48PM -0600, Alan Mead wrote:
     >      >      John and Harry,
     >      >
     >      >      PSPPIRE.exe 0.8.4-g5ce6b1 (and the associated PSPP) is pretty
     > wonky.
     >      >      Paste doesn't work correctly (I believe that's a know 
     > To
     >      > paste
     >      >      syntax into the syntax window, I had to right-click and 
     > paste;
     >      >      neither Control-v or Edit > Paste would paste the text.
     >      >
     >      I could reproduce this and it is indeed realy strange. It is not
     > limited to
     >      the syntax window, but the same happens in the dataview. If you copy
     > some
     >      data from outside PSPPIRE (for example from notepad to psppire)  you
     > can
     >      only paste it in PSPPIRE when you right-click. Data copied from 
     >      PSPPIRE (for instance from dataview to syntax editor) can be copied
     > pasted
     >      the usual way!
     >      A reason for this.......I have no idea...
     > Looking at the code near line 385 in psppire-syntax-window.c  I am
     > guessing that this is due
     > to the encoding type declared by the clipboard contents.
     > Perhaps you could do some experiements to see if the functions
     > on_edit_paste and/or contents_received_callback are actually called?
     > And if the latter does get called, what is the value of the type field
     > in the GtkSelectionData ?
     Always fun with MSWindows address@hidden&*
     If I copy a text, start the syntaxeditor and paste the text. The text get
     pasted and I get no printf that on_edit_paste and/or
     contents_received_callback is entered. But I get the error message:
     <psppire.exe:968>:Gdk-CRITICAL **: gdk_property_delete: assertion 'window
     != NULL' failed
     If I start the syntaxeditor and then copy a text and try to paste it, Prinf
     reports that on_edit_paste and contents_received_callback are entered. The
     text is NOT pasted and I get the error
     <psppire.exe:968>:Gdk-CRITICAL **: gtk_text_buffer_emit_insertion:
     assertion 'g_utf8_validate <text, len, NULL>'  failed
     My other 2 printf's are not triggered.
     I don't know how to printf  GtkSelectionData . So if it is needed, I need
     the printf statemet for that.
     I used the attached patch.
     Anything more I could do?
     Have fun
     iff -r -u b/src/ui/gui/psppire-syntax-window.c
     --- b/src/ui/gui/psppire-syntax-window.c    2014-12-14 01:52:34.000000000
     +++ a/src/ui/gui/psppire-syntax-window.c    2015-01-06 21:23:14.449820019
     @@ -376,13 +376,20 @@
                      GtkSelectionData *sd,
                      gpointer data)
     +      printf ("%s:%d contents_received_callback\n", __FILE__, __LINE__);
        PsppireSyntaxWindow *syntax_window = data;
        if ( sd->length < 0 )
     +  {
     +          printf ("%s:%d contents_received_callback sd->length < 0 \n",
     __FILE__, __LINE__);
     +  }
        if ( sd->type != gdk_atom_intern ("UTF8_STRING", FALSE))
     +  {
     +              printf ("%s:%d contents_received_callback sd->type !=
     gdk_atom_intern ('UTF8_STRING', FALSE)) \n", __FILE__, __LINE__);
     +  }
        gtk_text_buffer_insert_at_cursor (GTK_TEXT_BUFFER
                          (gchar *) sd->data,
     @@ -393,6 +400,7 @@
      static void
      on_edit_paste (PsppireSyntaxWindow *sw)
     +    printf ("%s:%d on_edit_paste\n", __FILE__, __LINE__);
        GdkDisplay *display = gtk_widget_get_display (GTK_WIDGET (sw));
        GtkClipboard *clipboard =
          gtk_clipboard_get_for_display (display, GDK_SELECTION_CLIPBOARD);

     pspp-dev mailing list

PGP Public key ID: 1024D/2DE827B3 
fingerprint = 8797 A26D 0854 2EAB 0285  A290 8A67 719C 2DE8 27B3
See or any PGP keyserver for public key.

Attachment: clipboard.patch
Description: Text Data

Attachment: signature.asc
Description: Digital signature

reply via email to

[Prev in Thread] Current Thread [Next in Thread]