FPGA-Research-Manchester / FABulator

Fabric generator and CAD tools graphical frontend
Apache License 2.0
7 stars 3 forks source link

Custom colors cannot be selected and break the colouring functionality #2

Closed IAmMarcelJung closed 6 months ago

IAmMarcelJung commented 6 months ago

When trying to set a custom color, a white "subwindow" opens for a short time and then disappears, so no colors can be selected. Additionally, after this I cannot set any color for a wire. Only the dialog opens with the last selected color (which can also not be selected). This can only be solved by reloading the geometry.

To replicate this: Right click on a wire to view the color dialog. Click on the dialog. Select custom color. Try to set a color for a wire.

Maybe this feature is not yet implemented? However it should still not break the functionality, so if it is not implemented yet, it could just be deactivated, since it is not that important and I stumbled upon it when trying to reset the color.

I'm running Ubuntu 22.04 with i3 as a window manager if this is of any help (e.g. if the error cannot be reproduced on other systems).

If any additional information is needed, I can of course provide it.

JakobTernes commented 6 months ago

Hi, it seems like because the custom color selection is a Dialog, it cannot be embedded into a ContextMenu (for some JavaFX specific reasons). I just pushed a commit that removes the link to the custom color selection. (Also, I changed the style to blend in better with the rest of FABulator). While this is not a perfect solution, it should clear up any confusion and most importantly prevent any functionality breaking. Also, the color palette probably provides enough colors? Let me know if this resolved the issue for you as well.

Cheers

IAmMarcelJung commented 6 months ago

Thanks for the quick reply and fix! Yes, the issue is solved by this, since the custom color dialog can no longer be selected. I also think that the current color palette already provides enough colors. I was just looking for white and completely ignored the second row where the grayscales are located...