10-30-2024 05:25 PM
Hello again,
Please could you help me with a problem that I have not been able to solve. It happens that I have 3 text files with items NUM1, NUM2, NUM3 ... NUM10. and those items are displayed in a combobox. In addition to this I have 6 string cells where the same items appear (NUM1, NUM2, ... NUM10) but at random order. The user can modify these cells with random or consecutive values of the NUM. My intention is to color the text depending on the user's selection. For example, if I select NUM 3 (left box) manually and select green option on combobox, I want that NUM 5 to turn green.
I think one way is to use the combobox where all the options are and select the option I require, the color and the apply button. Or manually select the letters I want to color, select the color and click apply.
What would you do?
Solved! Go to Solution.
10-30-2024 06:14 PM
I would use lisboxes.
10-31-2024 08:30 AM
I don't think you can change the color of different string lines, since they are on the same String indicator/control.
One way to accomplish what you want is to replace the string boxes with a cluster with strings , in this case each string indicator will be independent and you can change the color independently with property nodes.
The cluster property node will give you an array of references for each string control/indicator, using a FOr loop you can setup the color of each individual.
10-31-2024 08:54 AM
@LVNinja wrote:
I don't think you can change the color of different string lines, since they are on the same String indicator/control.
One way to accomplish what you want is to replace the string boxes with a cluster with strings , in this case each string indicator will be independent and you can change the color independently with property nodes.
The cluster property node will give you an array of references for each string control/indicator, using a FOr loop you can setup the color of each individual.
You should be able to use the text selection property along with text.text color (foreground and background) to get the desired results. It will get ugly with the string match indices (there may be an unusual off-by-one to account for the index after matches.)
By ugly, I mean even CA won't get that to fit on a postage stamp! But highly doable.
10-31-2024 09:55 AM - edited 11-01-2024 10:13 AM
As I said, use listboxes and rings.
Can you explain how the saved files should look like? For example do you only want to save the colored items? (A plain text file will not retain color information).
You still have some glaring issues in general:
10-31-2024 10:56 AM
See if this quick draft can give you some ideas.
I still have absolutely no idea what you are trying to save, so I left that out.
You also should format your "masterlist.txt a little better. Having long sequences of spaces is not a good delimiter!