How to get the user to change the background color of a JtextAreaHow to get an enum value from a string value in Java?How do I get the color from a hexadecimal color code using .NET?Changing org.eclipse.swt.widgets background color in WindowsHow do I change the full background color of the console window in C#?Java Change Button Background ColorBackground color, notepad++ for highlighting purposesChanging color of selected text in jTextPaneBoton61.setBackground(Color.red);; changing button background colorsHow do I change the color of an actual JButton in Java? Not the background and not the textJTextArea change next append's background color
How do I anonymously report the Establishment Clause being broken?
When is it legal to castle moving the rook first?
How do I make my fill-in-the-blank exercise more obvious?
Would you recommend a keyboard for beginners with or without lights in keys for learning?
ASCII Maze Rendering 3000
Is it possible to observe space debris with Binoculars?
Never make public members virtual/abstract - really?
A Meal fit for a King
Global variables and information security
How were the names on the memorial stones in Avengers: Endgame chosen, out-of-universe?
Do I have to rename all creatures in a new world?
Resizing attribute form in QGIS 3
Is a paralyzed creature limp or rigid?
Left my gmail logged in when I was fired
Shoes for commuting
Are treasury bonds more liquid than USD?
Life post thesis submission is terrifying - Help!
Are buttons really enough to bound validities by S4.2?
What is the statistical difference between "choose either total" or "choose new total" when rerolling damage die?
Bidirectional Dictionary
What drugs were used in England during the High Middle Ages?
Was "The Hobbit" ever abridged?
Is using different public keys for different peers safer than reusing the public key, beyond forward secrecy - x25519
Tiny image scraper for xkcd.com
How to get the user to change the background color of a JtextArea
How to get an enum value from a string value in Java?How do I get the color from a hexadecimal color code using .NET?Changing org.eclipse.swt.widgets background color in WindowsHow do I change the full background color of the console window in C#?Java Change Button Background ColorBackground color, notepad++ for highlighting purposesChanging color of selected text in jTextPaneBoton61.setBackground(Color.red);; changing button background colorsHow do I change the color of an actual JButton in Java? Not the background and not the textJTextArea change next append's background color
.everyoneloves__top-leaderboard:empty,.everyoneloves__mid-leaderboard:empty,.everyoneloves__bot-mid-leaderboard:empty margin-bottom:0;
I am coding a basic text editor and i want to give the user the option to change the background color. Right it can only be changed to red, here's my code snippet.
private void MiColorActionPerformed(java.awt.event.ActionEvent evt)
jTextArea2.setSize(350, 350);
jTextArea2.setVisible(true);
jTextArea2.setBackground(Color.red);
java colors background jtextarea
add a comment |
I am coding a basic text editor and i want to give the user the option to change the background color. Right it can only be changed to red, here's my code snippet.
private void MiColorActionPerformed(java.awt.event.ActionEvent evt)
jTextArea2.setSize(350, 350);
jTextArea2.setVisible(true);
jTextArea2.setBackground(Color.red);
java colors background jtextarea
add a comment |
I am coding a basic text editor and i want to give the user the option to change the background color. Right it can only be changed to red, here's my code snippet.
private void MiColorActionPerformed(java.awt.event.ActionEvent evt)
jTextArea2.setSize(350, 350);
jTextArea2.setVisible(true);
jTextArea2.setBackground(Color.red);
java colors background jtextarea
I am coding a basic text editor and i want to give the user the option to change the background color. Right it can only be changed to red, here's my code snippet.
private void MiColorActionPerformed(java.awt.event.ActionEvent evt)
jTextArea2.setSize(350, 350);
jTextArea2.setVisible(true);
jTextArea2.setBackground(Color.red);
java colors background jtextarea
java colors background jtextarea
asked Mar 28 at 3:45
CharliemkaCharliemka
1
1
add a comment |
add a comment |
1 Answer
1
active
oldest
votes
I would suggest you to use a JFrame or a JPanel, which is what I use when working JTextFields. You can then later on add the text field on the frame, with frame.add(textField).
add a comment |
Your Answer
StackExchange.ifUsing("editor", function ()
StackExchange.using("externalEditor", function ()
StackExchange.using("snippets", function ()
StackExchange.snippets.init();
);
);
, "code-snippets");
StackExchange.ready(function()
var channelOptions =
tags: "".split(" "),
id: "1"
;
initTagRenderer("".split(" "), "".split(" "), channelOptions);
StackExchange.using("externalEditor", function()
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled)
StackExchange.using("snippets", function()
createEditor();
);
else
createEditor();
);
function createEditor()
StackExchange.prepareEditor(
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: true,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: 10,
bindNavPrevention: true,
postfix: "",
imageUploader:
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
,
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
);
);
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f55389863%2fhow-to-get-the-user-to-change-the-background-color-of-a-jtextarea%23new-answer', 'question_page');
);
Post as a guest
Required, but never shown
1 Answer
1
active
oldest
votes
1 Answer
1
active
oldest
votes
active
oldest
votes
active
oldest
votes
I would suggest you to use a JFrame or a JPanel, which is what I use when working JTextFields. You can then later on add the text field on the frame, with frame.add(textField).
add a comment |
I would suggest you to use a JFrame or a JPanel, which is what I use when working JTextFields. You can then later on add the text field on the frame, with frame.add(textField).
add a comment |
I would suggest you to use a JFrame or a JPanel, which is what I use when working JTextFields. You can then later on add the text field on the frame, with frame.add(textField).
I would suggest you to use a JFrame or a JPanel, which is what I use when working JTextFields. You can then later on add the text field on the frame, with frame.add(textField).
answered Mar 28 at 6:20
AbhinavAbhinav
1297 bronze badges
1297 bronze badges
add a comment |
add a comment |
Got a question that you can’t ask on public Stack Overflow? Learn more about sharing private information with Stack Overflow for Teams.
Got a question that you can’t ask on public Stack Overflow? Learn more about sharing private information with Stack Overflow for Teams.
Thanks for contributing an answer to Stack Overflow!
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f55389863%2fhow-to-get-the-user-to-change-the-background-color-of-a-jtextarea%23new-answer', 'question_page');
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown