JTextComponent is the base class for swing text components. It tries to be compatible with the java.awt.TextComponent class where it can reasonably do so. Also provided are other services for additional flexibility (beyond the pluggable UI and bean support).
Questions tagged [jtextcomponent]
149 questions
0
votes
1 answer
JTextPane lightweight alternatives?
I am working on simple Unix tail like utility (my first work in Java). There are a lots already available but none suit my specific requirements. I need additional log analysis help feature, config sharing, bookmark, edit, regex support and a bit…

Kamath
- 4,461
- 5
- 33
- 60
0
votes
3 answers
Java Library to load a document and tag parts of text
I am new to Swing development and I am creating a Java application where a user can load text documents and tag parts of text.
The tagged parts of text would then be highlighted and the user can click on the tagged text to edit/remove the tag. Is…

Ankit
- 6,772
- 11
- 48
- 84
0
votes
1 answer
How to use TextChanged event?
I have a text box in which the user enters a unique number. After he enters a number and press tab or enter. I want to write query to search record matching to that unique number. The number is an integer. It will be passport no, pan card no or etc.…

Anjali
- 269
- 2
- 6
- 13
-1
votes
2 answers
How do I make JTextArea or JTextPane columns clickable?
I'm working on a extremely basic Java video player project which is my coursework. I've 2 JTextPanes: 1 for listing all videos and 1 for creating playlist.
So far the only way I could add videos to the playlist is to put video id(from database) in…

alien45
- 306
- 2
- 8
-1
votes
1 answer
Implement undo/redo for tabbed JEditorPanes
I'm developing a basic editor within my application, which allows to view several components within a JTabbedPane. Each tab holds a JScrollPane which contains a JEditorPane.
Now I would like to implement an undo and redo functionality. So if I…

Phidelux
- 2,043
- 1
- 32
- 50
-1
votes
3 answers
how to fit text within jtextcomponent
I am trying to develop an editor without scrollbars using jtextarea, so if the text is too long to fit within jtextarea it should be splitted into smaller substrings which could be edited within the jtextarea without showing vertical scrollbar…

muaz
- 550
- 9
- 15
-1
votes
2 answers
Add text color while print - Python
I want to add text color while print output. How to do that ?
Example: Print('Hello Everyone.') I want output text
Hello Everyone will highlighted red color.
Thanks you!

trunghai
- 3
- 4
-1
votes
1 answer
Not entering while loop
I'm trying to write in a file whatever the user has written.
The file creates and all but the program fails to write whatever the user wrote from the program, to the file (The program is like notepad). It wont enter the while loop because the String…

vincentes
- 45
- 1
- 1
- 7
-1
votes
1 answer
Best suited JTextComponent
I've been messing around with various text components and I now come here for answers.
What I need is a area in which user can enter text using keyboard and/or copy/paste.
These are the requirements of the component:
Word wrap, ability to limit…

John Smith
- 19
- 4
-2
votes
1 answer
Linking two jtextarea with one scrollbar
I'm trying to have to jtextcompontes with one scrollbar. when I scroll I want the other jtextcomponte to scroll too.
Here's a screenshot:

SSM
- 379
- 5
- 16
-2
votes
1 answer
How do I dynamically resize a text component in Java Netbeans, when the text has filled the component, instead of it having scroll bars?
I've done a ton of research regarding this issue, but I haven't had any luck with anything I've found. It's a major roadblock in the application I'm developing.
My application has a Form, which contains a JScrollPane. After adding a JTextArea inside…

Ryan
- 511
- 1
- 8
- 18
-3
votes
1 answer
Custom swing JTextComponent
I want to create a JTextArea which looks like JTextArea, acts like JTextArea, responds like JTextArea, speaks like JTextArea, moves like JTextArea, etc, but is not JTextArea.
To make it short, I'd like to create a custom swing component based 100%…

Karlovsky120
- 6,212
- 8
- 41
- 94
-3
votes
1 answer
Custom tabs in jtextarea in java
How to set tab stops in jtextarea for different lengths,
first tab should stop 4
Second tab should stop at 20 (If i give tab from 4 it should stop at 20)
Third tab should stop at 30 (If i give tab from 0 it should stop at 30)

FirmView
- 3,130
- 8
- 34
- 50
-4
votes
1 answer
How to resize my text box?
Main reason for exception message is display only one line but my exception message is contains more than 4 lines.
How can i resize my text box?

Sriman Java
- 1
- 2