scrollbar hides when I minimize the pane.

Hi all,I have a JScrollPane in which i have no of small panels in two coloumnswhenever i minimize the pane the scroll bar hides behind the panels.
[167 byte] By [Soma_Sena] at [2007-11-27 7:03:58]
# 1

Sounds like you might be mixing AWT components in your Swing application. AWT components will paint over top of Swing components.

If you need further help then you need to create a [url http://homepage1.nifty.com/algafield/sscce.html]Short, Self Contained, Compilable and Executable, Example Program[/url] (SSCCE) that demonstrates the incorrect behaviour, because I can't guess exactly what you are doing based on the information provided.

Don't forget to use the [url http://forum.java.sun.com/help.jspa?sec=formatting]Code Formatting Tags[/url] so the posted code retains its original formatting.

camickra at 2007-7-12 18:55:15 > top of Java-index,Desktop,Core GUI APIs...
# 2
yes i am using bot awt and swing.How do i pant the swing componet above the awt?
Soma_Sena at 2007-7-12 18:55:15 > top of Java-index,Desktop,Core GUI APIs...
# 3
> How do i pant the swing componet above the awt? You can't. Read the article on [url http://java.sun.com/products/jfc/tsc/articles/mixing/index.html]Mixing Light and Heavy Weight Components[/url].
camickra at 2007-7-12 18:55:15 > top of Java-index,Desktop,Core GUI APIs...
# 4
ok then I'll try changing the textarea to jtextarea.
Soma_Sena at 2007-7-12 18:55:15 > top of Java-index,Desktop,Core GUI APIs...
# 5
Thanks.
Soma_Sena at 2007-7-12 18:55:15 > top of Java-index,Desktop,Core GUI APIs...
# 6
is there any way like attaching a listner to the JScrollPane and minimizing the text area accordingly?
Soma_Sena at 2007-7-12 18:55:15 > top of Java-index,Desktop,Core GUI APIs...
# 7
Why are you still trying to use a TextArea? Swing components are more flexible. What is your problem with using a JTextArea?
camickra at 2007-7-12 18:55:15 > top of Java-index,Desktop,Core GUI APIs...
# 8
jetext area doesn't have a scroller embedded in it
Soma_Sena at 2007-7-12 18:55:15 > top of Java-index,Desktop,Core GUI APIs...
# 9
> jetext area doesn't have a scroller embedded in itJScrollPane scrollPane = new JScrollPane(theJTextAreaYouShouldBeUsing);frame.getContentPane().add(scrollPane);doesn't get any simpler than this
Michael_Dunna at 2007-7-12 18:55:15 > top of Java-index,Desktop,Core GUI APIs...
# 10
i need a scroll pane in which i have variable no. of textareas and these text areas should have individual scrollers inside them.
Soma_Sena at 2007-7-12 18:55:15 > top of Java-index,Desktop,Core GUI APIs...
# 11
h
Soma_Sena at 2007-7-12 18:55:15 > top of Java-index,Desktop,Core GUI APIs...
# 12

> i need a scroll pane in which i have variable no. of textareas and these text

> areas should have individual scrollers inside them.

can you add a textArea to a scrollpane?

can you add multiple scrollpane's to a panel?

can you add a panel to the contentPane?

if you can do the above, you should be able to add the panel to a scrollpane,

then add the scrollpane to the contentpane.

if this is all too much, post a small compilable/runnable program that

demonstrates your problem

Michael_Dunna at 2007-7-12 18:55:15 > top of Java-index,Desktop,Core GUI APIs...