[gtkmm] Gtkmm-forge digest, Vol 1 #246 - 4 msgs



Send Gtkmm-forge mailing list submissions to
	gtkmm-forge lists sourceforge net

To subscribe or unsubscribe via the World Wide Web, visit
	https://lists.sourceforge.net/lists/listinfo/gtkmm-forge
or, via email, send a message with subject or body 'help' to
	gtkmm-forge-request lists sourceforge net

You can reach the person managing the list at
	gtkmm-forge-admin lists sourceforge net

When replying, please edit your Subject line so it is more specific
than "Re: Contents of Gtkmm-forge digest..."


gtkmm-forge is the mailing list that receives gtkmm bug reports from bugzilla.  A daily digest is sent to gtkmm-main, to encourage people to help fixing the bugs.


Today's Topics:

   1. [Bug 93787] Changed - Outputting ustring with operator << converts implicitly (bugzilla-daemon widget gnome org)
   2. [Bug 94829] New - Lifetime issues again (bugzilla-daemon widget gnome org)
   3. [Bug 94829] Changed - Lifetime issues again (bugzilla-daemon widget gnome org)
   4. [Bug 94110] Changed - proposed API additions to Glib::TimeVal (bugzilla-daemon widget gnome org)

--__--__--

Message: 1
From: bugzilla-daemon widget gnome org
To: gtkmm-forge lists sourceforge net
Cc: 
Date: Thu,  3 Oct 2002 16:09:27 -0400 (EDT)
Subject: [gtkmm bugzilla] [Bug 93787] Changed - Outputting ustring with operator << converts implicitly

Please do not reply to this email- if you want to comment on the bug, go to the
URL shown below and enter your comments there.

http://bugzilla.gnome.org/show_bug.cgi?id=93787

Changed by olau hardworking dk 

--- shadow/93787	Wed Oct  2 06:12:25 2002
+++ shadow/93787.tmp.17072	Thu Oct  3 16:09:27 2002
@@ -187,6 +187,41 @@
 verbatim keys, then.
 
 ------- Additional Comments From murrayc usa net  2002-10-02 06:12 -------
 I don't want to read and understand all of that. Can you both tell me
 whether you think this is still a bug, or an enhancement, and
 summarise why.
+
+------- Additional Comments From olau hardworking dk  2002-10-03 16:09 -------
+I think it's more of a bug than an enhancement.
+
+To summarize: the problem is that the standard streams treat their
+characters in a locale-dependent way (i.e. with different encodings
+for different locales). 
+
+Currently, ustrings convert their contents to the locale-dependent
+encoding when used in conjuction with operator <<. This makes sense
+since the stream needs to get the data in the same encoding as the
+characters it already contains. But it also means that using ustrings
+in conjuction with stringstreams will silently result in a string
+which isn't in UTF-8 (i.e., unless the locale happens to be UTF-8).
+
+Unless you're running the program in an i18nized environment, you'll
+never discover this problem. Pango refuses to show labels with invalid
+UTF-8, so e.g. it might cause error messages to never show up.
+
+So I propose the following:
+
+ * make the decision that std::strings should always be in
+   locale-dependent encoding
+ * when converting std::strings to ustrings, always convert
+   implicitly from locale-dependent encoding to UTF-8
+ * keep a few overrides, like raw(), which still produces
+   UTF-8 std::strings
+ * put a big notice in the tutorial and in the documentation
+   for ustrings
+
+This would give a more seamless integration with the standard library.
+I don't think it's possible to guarantee that all characters survive
+the conversion back and forth, but hopefully people will use a locale
+that supports all the characters of their language. So this might be a
+non-existant problem.



--__--__--

Message: 2
From: bugzilla-daemon widget gnome org
To: gtkmm-forge lists sourceforge net
Cc: madmaxer poczta fm
Date: Fri,  4 Oct 2002 02:30:30 -0400 (EDT)
Subject: [gtkmm bugzilla] [Bug 94829] New - Lifetime issues again

Please do not reply to this email- if you want to comment on the bug, go to the
URL shown below and enter your comments there.

http://bugzilla.gnome.org/show_bug.cgi?id=94829

Changed by madmaxer poczta fm 

--- shadow/94829	Fri Oct  4 02:30:30 2002
+++ shadow/94829.tmp.29717	Fri Oct  4 02:30:30 2002
@@ -0,0 +1,92 @@
+Bug#: 94829
+Product: gtkmm
+Version: 2.0
+OS: Linux
+OS Details: 
+Status: NEW   
+Resolution: 
+Severity: normal
+Priority: Normal
+Component: general
+AssignedTo: gtkmm-forge lists sourceforge net                            
+ReportedBy: madmaxer poczta fm               
+TargetMilestone: ---
+URL: 
+Cc: madmaxer poczta fm
+Summary: Lifetime issues again
+
+Here is a copy/paste of my conversation with Daniel on IRC and he asked me
+to file a bug:
+
+<madmaxer> yesterday i had a very strange crash in my app
+<madmaxer> you saw gex some time ago, remember?
+<danielk> yes
+<madmaxer> so, it has hpaned, inside right pane there's a vbox
+<madmaxer> this vbox contains treeview, hbox, and statusbar
+<madmaxer> now the hbox: it is a class derived from hbox actually
+<madmaxer> in ctor i dynamically create two managed buttons and pack them
+into the hbox
+<madmaxer> now, when i close the application -> segfault
+<madmaxer> so i changed these buttons from dynamically allocated to class
+members -> no more crash
+<madmaxer> all that with g++ 3.2 and gtkmm 1.3.23
+<danielk> ah yes
+<danielk> lifetime issues
+<madmaxer> but this crash was only if i right clicked the button so it had
+focus
+<madmaxer> when button wasn't focussed on close there was no crash
+<danielk> is there anything connected to the button?
+<madmaxer> is that description meaningful for you in any manner?
+<danielk> any code accessing it?
+<madmaxer> yes, but it didn't matter, i removed all signals and nothing changed
+<madmaxer> ah, i forgot, the crash was quite strange
+<danielk> that's weird
+<danielk> tell
+<madmaxer> because actuall segfault was in gtk_paned_calculate_position or
+something like that
+<madmaxer> i don't remember exact function's name
+<madmaxer> this function was called somewhere from the dtor of one of objects
+<danielk> hmm
+<madmaxer> i tried to recreate a simple sample code showing this bug but i
+failed
+<danielk> interesting
+<madmaxer> but i think if it was some bug in my code changing objects from
+dynamic on heap to class members would not solve the problem?
+<danielk> did you include the paned in your sample code?
+<madmaxer> yes
+<madmaxer> but in my application i have many paneds, h/vboxes and other stuff
+<madmaxer> my gui is already very complex, so i wasn't patient enough to
+find which element exactly causes the problem
+<danielk> what's funny about this is that lifetime issues usually occur
+with class members and go away if you manage them, not the other way around
+<madmaxer> to be honest i had similar case some time ago while i was still
+using gcc 2.95
+<danielk> I don't think it's a compiler problem
+<madmaxer> but then it happened together with other stability problems i
+reported
+<madmaxer> and then i thought it was a compiler issue
+<madmaxer> but now it happened again
+<danielk> gtkmm lifetime handling is horribly complex.  Murray worked on it
+recently, so I don't even know the current state.
+<danielk> It's full of work-arounds and special casing
+<madmaxer> not good
+<danielk> file a bug
+<madmaxer> but murray will say "provide simple as possible code showing the
+bug" and i won't be able to do it
+<danielk> that's right, but I'd like to have this recorded somewhere
+<danielk> even if we don't find a quick fix
+<madmaxer> if you can wait some time i'll check something
+<danielk> no rush
+<madmaxer> i downloaded a release tarball of my app from sf and i will build it
+<madmaxer> to see if it also crases in the same way
+<madmaxer> i've found the bug very recently, but it may be there since a
+long time
+
+I failed to recreate a simple example showing this bug, but if you want to
+investigate the problem please go here:
+http://sourceforge.net/project/showfiles.php?group_id=52990
+and get Gex 0.0.6B or earlier (0.0.6B is for Gtkmm 1.2.23).
+
+To make Gex segfault run it, if command line is not visible choose menu:
+View/Command Line. Then right click the small 'Run terminal' icon to focus
+it and close the application. It will segfault.



--__--__--

Message: 3
From: bugzilla-daemon widget gnome org
To: gtkmm-forge lists sourceforge net
Cc: madmaxer poczta fm
Date: Fri,  4 Oct 2002 14:46:04 -0400 (EDT)
Subject: [gtkmm bugzilla] [Bug 94829] Changed - Lifetime issues again

Please do not reply to this email- if you want to comment on the bug, go to the
URL shown below and enter your comments there.

http://bugzilla.gnome.org/show_bug.cgi?id=94829

Changed by murrayc usa net 

--- shadow/94829	Fri Oct  4 02:30:30 2002
+++ shadow/94829.tmp.22343	Fri Oct  4 14:46:04 2002
@@ -87,6 +87,12 @@
 http://sourceforge.net/project/showfiles.php?group_id=52990
 and get Gex 0.0.6B or earlier (0.0.6B is for Gtkmm 1.2.23).
 
 To make Gex segfault run it, if command line is not visible choose menu:
 View/Command Line. Then right click the small 'Run terminal' icon to focus
 it and close the application. It will segfault.
+
+------- Additional Comments From murrayc usa net  2002-10-04 14:46 -------
+Please submit a bug report. I don't want to read an irc thread.
+
+And yes, if you don't give me sensible example code then this bug will
+be closed.



--__--__--

Message: 4
From: bugzilla-daemon widget gnome org
To: gtkmm-forge lists sourceforge net, puchs ap univie ac at
Cc: 
Date: Fri,  4 Oct 2002 14:50:11 -0400 (EDT)
Subject: [gtkmm bugzilla] [Bug 94110] Changed - proposed API additions to Glib::TimeVal

Please do not reply to this email- if you want to comment on the bug, go to the
URL shown below and enter your comments there.

http://bugzilla.gnome.org/show_bug.cgi?id=94110

Changed by murrayc usa net 

--- shadow/94110	Thu Oct  3 03:53:14 2002
+++ shadow/94110.tmp.23407	Fri Oct  4 14:50:11 2002
@@ -111,6 +111,10 @@
 "as_double" would in this case make more sense to me than
 "get_total_seconds()". I know that the double is expressed in the
 return type, but I still think that they are more suitable. Anyone is
 welcome to suggest a different name. My imagination is somewhat
 limited in this area and I can't come up with anything that is
 suitable and does not contain "double" right now.
+
+------- Additional Comments From murrayc usa net  2002-10-04 14:50 -------
+Then you'll have to explain exactly why you do that calculation to get
+the double. Why would I want a double instead of an int?




--__--__--

_______________________________________________
Gtkmm-forge mailing list
Gtkmm-forge lists sourceforge net
https://lists.sourceforge.net/lists/listinfo/gtkmm-forge


End of Gtkmm-forge Digest



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