How to change TextColor of LabelField

Hello

I want to change the color of the text of the LabelField

I tried following code.

_labelField = new LabelField ("Email") {}
{} public void paint (Graphics graphics)
               
graphics.setColor (Color.WHITE);
Graphics.Clear;
Super.Paint (Graphics);
}
};

but it shows me a white box instead of LabelField
I don't want to change the background color

Is it possible without using CustomLabelField?

Hello

Thanks for the Suggestion

But I myself found the solution by playing

with the paintground method and paint as suggested by you (Simon_hain)

Here is my solution

_emailLabel = new LabelField ("Email", LabelField.USE_ALL_WIDTH |) LabelField.NON_FOCUSABLE) {}
{} public void paintBackground (Graphics g)
g.setBackgroundColor (Color.WHITE);
g.setGlobalAlpha (0);
g.Clear ();
Super.Paint (g);
}
{} public void paint (Graphics g)
g.setColor (Color.WHITE);
g.setGlobalAlpha (255);
Super.Paint (g);
}
};

Thanks for the suggestion

Tags: BlackBerry Developers

Similar Questions

  • How to change the background color

    How to change the background color of the label field, how to do it thanks

    I can change the color of labelfield, but I want to change the background,

    How can I do this

    Thank you.

    I do not know mantaker do not want to forget the call to super...

    public void paint (Graphics gs) {}

    gs.setBackgroundColor (0x00FF0000); red background

    GS. Clear();

    Super.Paint (GS);

    }

  • How to change the default color of GaugeField?

    Hi all

    BlackBerry GaugeField the default color is blue. How to change the default of GaugeField color? How to override?

    Thank you

    Try with this example a and modify according to your needs

    Field GaugeField = new GaugeField ("", 0, 100, 20, GaugeField.FOCUSABLE) {}
    protected void paint (Graphics graphics) {}
    graphics.setColor (Color.RED);
    graphics.fillRect (0, 0, (Display.getWidth (/getValueMax ())) * getValue (), getHeight());
    }
    };

    There is no label for gauge field.

    If you want a labelfield and sepately use a labelfield and add this labelfield with this gaugefield in a horizontal handler, then use getwidth() instead of Display.getWidth ().

  • How to change the iPhone camera shutter sound 7

    How to change the iPhone camera shutter sound 7?

    Hello

    To adjust the volume of the sound of the camera shutter:

    • Use the settings ringer and alerts:
      • On iPhone 7 and iPhone 7 more, go to: settings > sounds and haptic.
      • (Other models, go to settings > sounds).
    • Or turn mute off / on using the switch on the side of your iPhone's ring/silent.
      • (The mute function is disabled in some countries).
  • How to change the number of minutes for the exercise of the activity of the application

    How to change the number of minutes for the exercise of the activity of the application

    Hello

    It is not currently possible to change the goal of daily exercise.

    If you want to suggest that Apple consider adding this option, you can submit a request here:

    https://www.Apple.com/feedback/watch.html

  • Our phone will make more phone calls, and we do not know how to change the settings to restore the capabilities of phoning.

    Our phone will make more phone calls, and we do not know how to change the settings to restore the capabilities of phoning.

    Greetings jenniferfrom46,

    From your post, I see that you are unable to make phone calls. I count on the ability to use my phone a lot to make calls, so I can understand your concern. I will be happy to provide you with some information for you.

    If you can not make or receive calls on your iPhone, this article goes on measures to take to help with the issue you are experiencing.

    Have a good!

  • ios10 clock background - how to change?

    Just updated to ios10. The base of the clock is now black. This triggers the migrene for me. The contrast is strong for me to manage.

    Does anyone know how can I change this? Or return to ios9. I use the alarm settings a lot and it does not work for me.

    Even!

    I have an eye diffract which makes it very difficult to read and gives me a headache. Please please how to change this back?

  • How to change my Apple ID primary e-mail address?

    How to change my Apple ID primary e-mail address?

    The instructions of change of your Apple - Apple Support ID no longer work.

    For problems with your Apple

    1. Forgotten password to iCloud
    2. Forgotten ID Apple
    3. Apple ID - Apple Support
    4. Manage your Apple ID primary, rescue, alternatives, and e-mail addresses of notification - Apple Support
    5. On your Apple ID email addresses - Apple Support
    6. Get help with Apple ID
  • How to change shortcuts on a mac?

    How to change shortcuts on a mac? As the order is spotlight, is it possible to change this?

    System Preferences > keyboard

  • How to change the color of pre-rendered screen.

    My question is how to change the color of the page that is displayed before a site is fully charged. So let's say I go to a site where the background color is red. Before the end of Firefox loading it will appear as white. Also yes I have known that I have an add-on which changes the default color of YouTube. However the first picture comes on all websites no matter if their background is white or not.

    You can try the userChrome.css code or elegant.

    Add code to the file userChrome.css below default @namespace.

    @namespace url("http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul"); /* only needed once */
    
    browser {background-color:#f0f0f0!important}
    

    The file userChrome.css (UI) customization and userContent.css (Web sites) are located in the folder of chrome in the Firefox profile folder.

    You can use this button to go to the current Firefox profile folder:

    • Create the folder chrome (lowercase) in the .default < xxxxxxxx > profile folder if the folder does not exist
    • Use a text editor like Notepad to create a userChrome.css (new) file in the folder chrome (file name is case sensitive)
    • Paste the code in the userChrome.css file in the Editor window
    • Make sure that the userChrome.css file starts with the default @namespace line
    • Make sure that you select "All files" and not "text files" when you save the file via "save file as" in the text editor as userChrome.css.
      Otherwise, Windows can add a hidden .txt file extension and you end up with one does not not userChrome.css.txt file
  • How to change default browser from Yahoo to Google on Android?

    I wonder how to change the default browser on Firefox from Yahoo to Google. I personally prefer Google for research and who want by default if it is possible

    Hi devinat1, if the battery-dot-3 icon does not appear, it means that Firefox has detected a button menu 'material' on your device. In general it's near the home button below the screen. If you can't find a menu button down there, do you want to talk about device you have? Perhaps one of the volunteer support can figure out what is happening.

  • How to change the sequence of films in iMovie Theater

    By exporting iMovie projects in iMovie Theater, the sequence of films is determined by the time of download. How to change the sequence of films in iMovie Theater list?

    HI, breeaz,

    I have not found a way to change the sequence of films shown in the movie screen.

    If you access your movies in the Finder folder, then Ctrl-click on the folder of the theatre, you will find your movies to the poster

    in the alphabetical order in archival records.   I was not able to manually rearrange it.   They can be rearranged in some categories, through the view menu item at the top of the screen and the changes applied to the entire window, but it was not carrying at the display of iMovie.  In General, I'd like to make changes to the structure of iMovie in the finder.  It can cause serious problems.

    Best,

    Rich

  • It is difficult to see how to change the color of the scrollbar in gray on gray background?

    It is difficult to see how to change the color of the scrollbar in gray on gray background?

    I think you should probably use an extension or theme to replace the default colors.

    If you are not interested in all the changes that might come with a new theme, is the next extension compatible with Linux?

    https://addons.Mozilla.org/firefox/addon/noiascrollbars/

  • How to change fontsize list of the mailbox in Mail.app?

    I've closed and relaunched Mail.app, and when he returned, the list of mailboxes on the left side of the main window was oddly displayed in a significantly larger fontsize that I'm used to. I don't know how or why it happened, and I can't seem to find a way to remedy. Help? (I'm using Mail.app v9.3 - 3124).

    Check your preferences.   See if the tips here help:

    http://osxdaily.com/2014/09/16/how-to-change-the-mail-font-size-in-Mac-OS-x/

  • How to change identity upon receipt of messages?

    I move from Outlook Express to Thunderbird (I finally leave XP). I have three identities on an email account with Earthlink. I can't understand how to switch between these identities when messages are received. In OE, I choose "switch identity" and a list will appear and I choose a different identity to receive messages from. He keeps them all separate. I've successfully created a second identity in "Manage identities" and I can see the two identities, creating new messages, in the tab 'from', but I can't receive mail from the second identity because I do not see how to change identities when mail is received. I'm sure it's something simple, but I can't put my finger on it.

    I had put it in place without delay. Looks exactly like the example that you have demonstrated. Thanks again!

Maybe you are looking for