Results 21 to 30 of 30
Thread: need an advise please
- 07-24-2010, 11:02 PM #21
- 07-24-2010, 11:04 PM #22
You can choose the font in a JTextArea, but it will be the same font throughout the Area.
You can allow the user to change the font at run time, but again it will be the same font for the whole JTextArea.
I think a JTextPane will be too advanced for a new user. Its possible to use, but if its completely new to you and you only have until wednesday Id stay away from it for now.
berkeleybross
-
You're getting a bit ahead of yourself here. If it were my project, I'd worry much more about getting the overall logic correct and would worry about the font and all dress-up last. I will second the recommendation to stick with the simpler JTextArea and forget using a JTextPane for now.
- 07-25-2010, 07:39 PM #24
Member
- Join Date
- Jun 2010
- Posts
- 42
- Rep Power
- 0
i faced a problem,
there is a method call "save",i don't know how to use it
- 07-25-2010, 07:47 PM #25
I think you need to explain a bit more..
Where is the 'save' method? In what object?
Or are you asking how should you save the text?
berkeleybross
- 07-25-2010, 08:11 PM #26
Member
- Join Date
- Jun 2010
- Posts
- 42
- Rep Power
- 0
yes how can i save the text???
- 07-25-2010, 08:12 PM #27
Member
- Join Date
- Jun 2010
- Posts
- 42
- Rep Power
- 0
and can i save it as not pad file??? .txt???
- 07-25-2010, 09:14 PM #28
Yes you could save the text as a .txt file.
What is a "pad file"?
- 07-25-2010, 09:17 PM #29
Member
- Join Date
- Jun 2010
- Posts
- 42
- Rep Power
- 0
what i meant is NotePad
so how can i save the text as .txt???
i found a method call "saveFile" and a class name fileManager but i didn't know how to use them :(
could you please help me???
- 07-25-2010, 09:21 PM #30
I don't know of a java class named fileManager. All proper java classes have names starting with uppercase letters.
Normally when you want to use a class, you read the API doc:Java Platform SE 6
The syntax for all the classes and methods are defined there.
If you need more help, look at the Java Tutorial: The Java™ Tutorials
Look in the sections regarding reading and writing files.
There are lots of codes samples on this forum. Use Search to find them.
Similar Threads
-
Need advise for choosing book
By Teodor__b in forum New To JavaReplies: 2Last Post: 02-19-2010, 01:13 PM -
Some advise please!!!
By PVL268 in forum New To JavaReplies: 2Last Post: 04-17-2009, 09:36 AM -
need advise...
By chkm8 in forum AWT / SwingReplies: 4Last Post: 02-10-2009, 05:57 AM -
advise on designing an ejb application
By bobD in forum New To JavaReplies: 0Last Post: 09-03-2008, 09:04 AM -
give me a advise
By sireesha in forum New To JavaReplies: 3Last Post: 12-11-2007, 01:38 AM


LinkBack URL
About LinkBacks
Reply With Quote

Bookmarks