-
Notifications
You must be signed in to change notification settings - Fork 362
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Multicolored Comments #7437
Comments
The customizable block colours addon already has an option to change the colour of comments, but not individually. |
Also note that the border of comments that are attached to blocks inherit the color of the block, so, for example, if a comment is attached to a motion block, its border will be colored blue. But I don't think that would be a big problem. |
No one wants to say where the color would be stored? |
It could be a JSON tag stored in the comment text field. Non addon users would see that tag, addon users won't see the tag, but a colored comment. |
Those comments would be quite hard (unpleasant) to read by non addon users. |
Would it hurt to store color data internally in the project file? That wouldn't corrupt anything, right? We could also store the data in a configuration comment in the stage (much like we do with Gamepad support). Every comment has an invisible ID, so this comment could contain key-value pairs, with the color associated with each comment by ID. |
Also, instead of using a color picker, we could show a palette of preset colors to choose from, or we could do both. It just means you could select colors faster. |
If we store the full RGB code then we could do both. I'd like to have a customisable palette of 8 or so colours which would apply to each comment (changing colour 1 changes all comments with it) |
Why not just add the hex color code to the comment text (no JSON)? |
Would that be more vulnerable to false positives? Maybe it could be preceded by a zero-width-space to help verify we added it? |
I'm fine with there not being a picker, as long as we're not storing the hex code but a palette index. That would make it very hard to change the colours |
Not to say that customization is a bad thing, but this is one reason having only predetermined colors to choose from can be simpler to design and a nicer user experience. Or, some ways to keep the color picker and make it easy to change all occurrences of a color could be:
or
|
I think in general the guideline we use is that if it can be done with the backpack, then it can be done with an addon. For example, the debugger blocks (log, breakpoint, etc.) do not have any definitions within the same sprite, but you can also achieve that in vanilla Scratch by using the backpack, you just need to define those custom blocks in some other project and drag the custom block calls to the backpack. |
Maybe this extension by SharkPool could spark some new ideas |
That's what I was trying to say. Instead of storing the RGB value we store an index of the palette. |
If the palette index is too large (palette is too small), they should either repeat or use the default colour. |
Why this would be helpful
Useful for when organizing code with comments.
How this addon works
Adds a button next to the delete button on comments that when clicked brings up the default or scratch color picker and changes the color of the comment.
Option to change the default comment color in the addon settings.
Presets maybe?
Possible alternatives
No response
Additional context
The text was updated successfully, but these errors were encountered: