summaryrefslogtreecommitdiff
path: root/libjava/jni
diff options
context:
space:
mode:
authortromey <tromey@138bc75d-0d04-0410-961f-82ee72b054a4>2003-12-02 01:01:07 +0000
committertromey <tromey@138bc75d-0d04-0410-961f-82ee72b054a4>2003-12-02 01:01:07 +0000
commit047627813008e8d2739687ab85b7883dca08347c (patch)
tree8d8942c9a3f0bf89981af378eac93bbb22d51e26 /libjava/jni
parent2bbde250e1221c1777c7f1e3f98a88f8e86092ec (diff)
downloadgcc-047627813008e8d2739687ab85b7883dca08347c.tar.gz
2003-12-01 Kim Ho <kho@redhat.com>
* jni/gtk-peer/gnu_java_awt_peer_gtk_GtkTextAreaPeer.c (create): Disable wrapping if TextArea has horizontal scroll bars. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@74141 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'libjava/jni')
-rw-r--r--libjava/jni/gtk-peer/gnu_java_awt_peer_gtk_GtkTextAreaPeer.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/libjava/jni/gtk-peer/gnu_java_awt_peer_gtk_GtkTextAreaPeer.c b/libjava/jni/gtk-peer/gnu_java_awt_peer_gtk_GtkTextAreaPeer.c
index a87be723cb3..c6d97d57620 100644
--- a/libjava/jni/gtk-peer/gnu_java_awt_peer_gtk_GtkTextAreaPeer.c
+++ b/libjava/jni/gtk-peer/gnu_java_awt_peer_gtk_GtkTextAreaPeer.c
@@ -1,5 +1,5 @@
/* gtktextareapeer.c -- Native implementation of GtkTextAreaPeer
- Copyright (C) 1998, 1999 Free Software Foundation, Inc.
+ Copyright (C) 1998, 1999, 2003 Free Software Foundation, Inc.
This file is part of GNU Classpath.
@@ -64,7 +64,10 @@ Java_gnu_java_awt_peer_gtk_GtkTextAreaPeer_create
|| scroll == AWT_TEXTAREA_SCROLLBARS_VERTICAL_ONLY) ?
GTK_POLICY_ALWAYS : GTK_POLICY_NEVER);
- gtk_text_view_set_wrap_mode (GTK_TEXT_VIEW(text), GTK_WRAP_WORD);
+ gtk_text_view_set_wrap_mode (GTK_TEXT_VIEW (text),
+ (scroll == AWT_TEXTAREA_SCROLLBARS_BOTH
+ || scroll == AWT_TEXTAREA_SCROLLBARS_HORIZONTAL_ONLY)
+ ? GTK_WRAP_NONE : GTK_WRAP_WORD);
gdk_threads_leave ();