It is possible to disable the custom color picker color?

Hi guys!

I searched in the discussions on the color picker, but I found something...

It is possible to disable the option to select a custom color? I work in a company that makes software to Brazilian clients, and not everyone understands English phrases...

In other words it is the translation of the option, but I don't know if it is possible also.

Thank you!

You certainly need to add the stylesheet to the scene, not to anything else. If you take my example and change

scene.getStylesheets ()...

TO

root.getStylesheets ()...

you will see that it won't work anymore.

The difference between that and the css that you used, it's that the css you used is applied to the selector button display color; You should apply styles to the popup (color palette), who does not appear in your VBox or AnchorPanes. Notice how the police changed to the name of the color in the button, but it has not changed for the label of 'Personal colour' you are trying to remove.

Somewhere there is a code that adds the VBox you are subclassing of a scene and this decoration in a stadium. Your best option (maybe second best option, see below) is to find this code, you can add the style sheet to the scene itself.

If you are working within a framework of someone else wrote and cannot access or modify the code where the scene is set, you have another option I see. Each node has a stage property that refers to the scene which this node belongs. So you can observe the changes made to this property and when it is updated, add the style sheet to the scene.

So here's a hack to make my original hack works, in case you can not directly access the scene for some reason any:

final String suppressCustomColorCss = getClass().getResource( "noCustomColorPicker.css").toExternalForm();
colorPicker.sceneProperty().addListener(new ChangeListener() {
 @Override
  public void changed(ObservableValue observable,
  Scene oldScene, Scene newScene) {
  if (newScene != null) {
  List cssClasses = newScene.getStylesheets();
  if (!cssClasses.contains(suppressCustomColorCss)) {
  cssClasses.add(suppressCustomColorCss);
  }
  }
  }
});

This code basically says "when the color selector becomes an integral part of a new scene, add the stylesheet to this scene.

At this point, you're applying notch on top of hack to get the effect you need. I think if I were in this situation I would not go ahead and define my own color chart. What you really need is a menu button, a property for the selected color and a popup with a layout of controls allowing to choose an arbitrary color. It would be a bit of work, but shouldn't be too hard. If you take this option (which I think may be your best bet), it's more work now but it will be clear what you do - when you (or other programmers on your team) eventually return to the code, you will understand how it works much better.

You must also file two requests for features. An API toggle the option of choosing a custom color, as this seems to be a reasonable piece of functionality to have. The other should be properly internationalized text for the labels in the selector of colors, which are currently just hard coded in the code source in English.

Tags: Java

Similar Questions

  • Is it possible to disable a spot color

    Hello

    Probably a stupid question, but I'll ask anyway. Is it possible to disable a spot color in CS4. I can do effectively by creating a white spot and merging the spot color I want to remove the white spot by using the ink alias. However, this leaves a spot color in the pdf high resolution at the end of th of employment. Then, this is a problem since we use an online proofing system that fails the flightcheck given that a spot color in the pdf file.

    See you soon

    Beeefcake

    Put it on a layer of its own and change the print no attributes or change the color of 0% CMYK. Just leave the name of the spot color so that you can return to it if necessary.

  • Is it possible to change the external color of the iPhone?

    I wanted to know if its possible to change the external color of the iPhone. My mother bought a pink iPhone, but she could not get used to it, so she gave it to me, and I want to know if its possible to pass to a rose grey.

    Thank you.

    None

  • Is it possible to disable the firefox search option when you long press the button home on Samsung Galaxy S5 Active?

    I have a S5 Active and sometimes the home button sticks and registered as a prolonged pressure that makes it appear the Firefox search instead of going to the home screen. Is it possible to disable the search for Firefox so that it does not happen. I love the Firefox browser, but if this continues to be I have to uninstall it.

    Hello djpianalto, you could delete the default settings for firefox on android in the control panel (as described in this external article).

    or try an app like https://play.google.com/store/apps/details?id=hk.sld.SwipeLaunchDisabler

  • Is it possible to disable the new feature that lists the previous pages in thumbnails when opening a new page?

    Is it possible to disable the new feature that displays thumbnails of the previous page when you open a new tab?

    Hello, please see the following article for help in order to disable the new feature: customize the page new tab

  • Is it possible to disable the GPU dedicated Satellite L850

    Is it possible to disable the GPU dedicated on the L850.
    Through the BIOS or something else, so that the laptop works on the onboard graphics on the CPU.

    Thank you

    Hello

    What L850-xxx you exactly and what dedicated GPU support?

    Laptops that support technology Optimus (with nVidia GPU) could switch automatically between the GPU (Intel) internal and external nVidia GPU and it depends on the application running.

    In some cases, you might choose weather, that an application must use internal GPU Intel or NVidia GPU.
    Here's a great youtube video:
    http://www.YouTube.com/watch?v=Zh4HCadTY_A

  • Is it possible to disable the webcam on the Equium A300D toolbar

    Is it possible to disable the webcam on the Equium A300D toolbar at all? (i.e. just access controls of the webcam from the control panel or start menu orsomething).

    The toolbar is on the left of the screen, it's extremely annoying when everytime my mouse wanders to the left of the screen, to the top appears the toolbar.

    On some applications that I use no app anchored to the left of the screen, and when the toolbar appears, covering half of them, I have to wait that the toolbar disappear again, which can be extremely annoying if I hurried to do something.

    Is it possible to disable to appear?

    Yes, you can disable the automatic loading webcam software.

    In RUN, type * msconfig and start this tool.
    You will see the Startup tab. Click this tab and disable the webcam software (remove the mark).
    Apply the changes, and then restart the laptop.

    Now windows should start without the webcam software.

    Good bye

  • is it possible to set the background color of a table or chart to be transparent?

    is it possible to set the background color of a table or chart to be transparent?

    Thank you

    Yes.

    Select tools palette (view > tool palette) and set the background of the graph as well as the control in transperent.

  • Is it possible to draw the same color for each curve automatically

    Hello

    Is it possible to draw the same color for each curve automatically. I use graphic XY basis with data set.

    Lol you'll either need to set the properties through the dialog box.  Or use the nodes property of the graph to adjust the Active plot and then set the color of the plot.  This can be done in a loop For.

  • Is it possible to disable the side buttons on the Laser 7000 Microsoft?

    I keep hitting when I leave the mouse and by disabling everything that I just entered. And I never use them. A supersizes also the screen when I can't.
    Thank you.

    Hello

    It is not possible to disable the side buttons on the Microsoft Laser 7000 mouse. However, if you install the Sidewinder software you can try to change the settings of the side buttons and check if it helps.

    http://www.Microsoft.com/hardware/en-us/d/wireless-laser-mouse-7000

    See also: http://support.microsoft.com/kb/258892

    If you have already installed the Sidewinder uninstall and check software testing.

    I also suggest you to contact the Microsoft Hardware support for assistance.

    http://www.Microsoft.com/hardware/en-us/support

  • Error: "it is not possible to disable the connection at this time. "This connection may be using one or more protocols that don't support Plug-and-play, or it may have been initiated by another user or the system account.

    Original title: unable to disable my lan connection

    Remember - this is a public forum so never post private information such as numbers of mail or telephone!

    Ideas:

    • I turn off my connection to the local network, it is showing message.

      It is not possible to disable the connection at this time. This connection may be using one or more protocols that don't support Plug-and-play, or it may have been initiated by another user or the system account.

      Please answer soon

      You have problems with programs

    • Error messages
    • Recent changes to your computer
    • What you have already tried to solve the problem

    Hi MVTDA,

    You can try the following methods and check to see if it helps:

    Method 1:

    a. Click Start and select run, type cmd and click OK.

    b. type net stop cryptsvc and press ENTER.

    c. type ren %systemroot%\System32\Catroot2 oldcatroot2, and then press the Enter key.

    d. restart the computer.

    e. open new command prompt and Type net start cryptsvc, and press ENTER.

    Method 2:

    If the same problem persists then you can try to uninstall the network drivers and check.

    a. click the Start button. Select run, type devmgmt.msc and press OK.

    b. Select the network card and right click on it.

    c. now, select Properties.

    d. in the Properties window, on the driver tab, click Uninstall.

    e. After you have uninstalled the drivers, restart the computer.

    Hope this information is useful.

    Jeremy K
    Microsoft Answers Support Engineer
    Visit our Microsoft answers feedback Forum and let us know what you think.

    If this post can help solve your problem, please click the 'Mark as answer' or 'Useful' at the top of this message. Marking a post as answer, or relatively useful, you help others find the answer more quickly.

  • Is it possible to disable the button on a touchscreen 1 X of carbon?

    I am new on this forum and has received a new carbon X 1 touch a few weeks ago.

    Is it possible to disable the touch screen feature (in preparation for my 2.5 year old jump on my lap and stitch it to the screen).

    Thank you

    Hi Brian,.

    Thanks for your comments, but I couldn't find it there. I'm short W8 and it seems that this feature has been removed. I found another solution that worked well.

    Device mgr-> Human Interface Devices-> disable 5th down "HID-Compliant Device".

    Seems to work.

    Thanks again

  • Is it possible to disable the caps lock shift key on a laptop?

    Is it possible to disable the caps lock shift key on a laptop?  I am running Windows 7 64 bit on a Lenovo laptop
    Thank you

    I understand that you have found some suggestions on editing the registry - they aren't so bad. If you don't want to download all of the files that allow you to disable the LOCKING of the capital LETTERS, you can create it by yourself:

    1. Press the Windows key + R > type notepad , and then press enter
    2. Paste to Notepad:

      Windows Registry Editor Version 5.00

      [HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Keyboard Layout]
      "Scancode Map" = hex: 00, 00, 00, 00, 00, 00, 00, 00, 02, 00, 00, 00, 00, 00, 3A, 00, 00, 00, 00, 00

    3. File > record under...
      • Select to Save as: all files
      • Enter the file name : disable_caps_lock.reg
      • Click Save
    4. Right-click on the created file > merge
    5. Restart your system

    In case you want to turn CAPS LOCK on again, you must remove this registry entry, so you must do the following:

    1. Press the Windows key + R > type regedit and press enter
    2. Go to HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Keyboard Layout
    3. Right click on the Card of Scancode > delete
    4. Restart your system

    I guess that it is perhaps the only way to turn off the CAPS LOCK.

    In case you still don't want to do this, Windows 7 offers something different to disable the LOCKING of the upper CASE. You can turn the ToggleKeys, then you will hear a beep when you press CAPS LOCK. To do this follow these steps:

    1. Press Start > Control Panel > access >easy access Center > make the keyboard easier to use
    2. Check the box to enable the ToggleKeys
  • Is it possible to disable the disk formatting?

    Hello everyone,
    I would like to know if it is possible to disable the option of formatting disk by modifying the Windows registry.
    Best regards
    Daniel

    The command is located in C:\Windows\System32\ and is called format.com
    I would just rename it rather than remove it as you will need it at some point.

    I hope this helps.

  • Is it possible to disable the State of C4e processor in windows?

    I use a Core i5 - 450 M CPU. There is a high pitched noise when the CPU is idle.

    I searched and found that some portable computers thinkpad, they eliminated the noise by turning off 'Power state C4' in the BIOS.

    But the bios of my laptop would not turn it off.

    So, it is possible to disable the C4 mode in windows (or some software)?

    Have you read the link posted? or the answer posted? -its a problem intel/thinkpad, nothing to do with MS or Win

Maybe you are looking for

  • Need to purchase Satellite X 200

    Guy; I intend to get nine X 200, however through the forums found many problems in terms of driver XP. The machine is really nice and I'm really feeling for these stupid incompatibility problem concern. Otherwise I'll change Toshiba and another :)))

  • HP wireless optical mouse Mobile

    I have a HP Wireless Optical Mobile Mouse I would use with a laptop Sony 2007 which originally ran Vista and now runs Windows 8.1.  I am able to install the driver, but the mouse does not work. Flashing red light on the bottom of the mouse indicates

  • Xperia Z2 photos/movies

    Hello, do anyone know why the pictures are fuzzy after awhile (even photos of Sony). After reboot, phone pictures are clearly once again. I have the phone for only two days, so I don't know where I can find.

  • LaserJet 600 M601: Laser jet 600 M601

    I have a Laser Jet M601 600 which is fairly new.  When the 2 paper tray is declining by 500 sheets for about 150 sheets, he thinks that the tray is empty. So, it does not print. If I fillup the paper tray it starts printing again. It is a nuisance th

  • componentcanvas is not drawing components in addition to other fields

    Hello I try to use ComponentCanvas to make a button at the top of the video field. but it is not drawing field above it. It is add field componentcanvas first, then adding videofield.  behaves as verticalfield Manager. If someone can give me right wa