(no subject)



hello!

i was a bit unhappy because you guys changed something in the sendmsg-window.c
part of the code a few days ago. to be exact 19-01-2001. there you removed the
old size of the window and replaced it with a new routine. i have already
written of an unbehave to this mailinglist. after no response, i made my own
walktroughs to the code and guess.

- i have *set* warp outgoing messages in the preferences window
- i set the value to 200, because i dislike having text wrapped at all, so the
  value of 200 make sure i don't get that problem that easy.

but then i got a compose window that was nearly twice as width as my screensize
(1280*1024) so i got nearly 2650 pixels (never counted them) after reviewing the
code i found the routine and what caused the problems. please would you be so
kind, to add something there, that make sure that the window wouldn't become
bigger than my screensize?. i would say you add the possibility to scroll with
an horizontal scrollbar, instead counting the value to the windowsize.

################################################################################
--- /tmp/balsa-1.0.1/src/sendmsg-window.c	Sun Dec 17 11:10:46 2000
+++ /tmp/balsa/src/sendmsg-window.c	Fri Jan 19 10:31:04 2001
@@ -1447,11 +1463,27 @@
      */
     init_menus(msg);
     gtk_notebook_set_page(GTK_NOTEBOOK(msg->notebook), mail_headers_page);
-    gtk_window_set_default_size(GTK_WINDOW(window),
-				(82 * 7) +
-				(2 * msg->text->style->klass->xthickness),
-				35 * 12);
+
+    /*
+     * Set the size of the text widget according to the user
+     * preferences (font and line_wrap).
+     */
+    if (balsa_app.wordwrap && (balsa_app.wraplength > 0))
+	/* Text of wrap + text of gtk_text next-line character */
+	width = balsa_app.wraplength + 2;
+    else
+	width = 82;
+    gtk_widget_set_usize(msg->text,
+	    		 /* Width of the text. */
+			 (width * gdk_char_width(msg->font, 'M')) +
+			 /* Width of the borders inside/outside box */
+			 (2 * msg->text->style->klass->xthickness),
+	    		 /* Height of the text. */
+			 (20 * gdk_char_height(msg->font, 'M')) +
+			 /* Height of the borders inside/outside box */
+			 (2 * msg->text->style->klass->ythickness));
     gtk_window_set_wmclass(GTK_WINDOW(window), "compose", "Balsa");
+
     gtk_widget_show(window);
################################################################################

################################################################################

this is the affected part of above code. it would really be better to scroll
horizontal in an predefined window, instead of having an window that blows the
screensize.

+    if (balsa_app.wordwrap && (balsa_app.wraplength > 0))
+	/* Text of wrap + text of gtk_text next-line character */
+	width = balsa_app.wraplength + 2;
+    else
+	width = 82;

################################################################################

-- 
Name....: Ali Akcaagac
Status..: Student Of Computer & Economic Science
E-Mail..: mailto:ali.akcaagac@stud.fh-wilhelmshaven.de
WWW.....: http://www.fh-wilhelmshaven.de/~akcaagaa





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