Skip to content

Styles Workflow Redesign#2738

Draft
Jowan-Spooner wants to merge 27 commits into
dialogic-godot:mainfrom
Jowan-Spooner:investigate-styles
Draft

Styles Workflow Redesign#2738
Jowan-Spooner wants to merge 27 commits into
dialogic-godot:mainfrom
Jowan-Spooner:investigate-styles

Conversation

@Jowan-Spooner
Copy link
Copy Markdown
Member

This is a draft PR for now, a lot more work needed.

For now it implements

  • a new layout scene sidebar, allowing to drag in properties from any node in the scene that will then be exposed in the style editor (also allows setting a display name and tooltip, though the latter isn't displayed anywhere yet). Options can be reordered in this list and it does support undo-redo. Via an inspector plugin, properties that have been overwritten display a little icon in the inspector. If clicked it highlights the property in the sidebar list. The sidebar also warns when editing a built-in layout scene. This list is stored as metadata on the root node of the scene.
    This entirely removes the need for any magic script exposing and applying properties. And makes it very obvious what's happening. For now this completely breaks all the preset layers/styles as they have not been updated.

  • New fields in the style editor. These are EditorProperty instances, so the same things used by godot in the inspector. This is great, as it stream-lines the experience between the style editor and the actual scene. Tbh, at this point, the style editor is more like "favorites" from the scene node properties. I actually thought about using godots favorites, but they do not work like this (not per node but per node type) and aren't easily accessible. However the new EditorProperty fields come with some quirks, so they need further testing. Especially resources, as I think sometimes it creates invalid resources or it doesn't handle local resources well right now (I think str_to_var doesn't, and that's used to store them). Right now this is used for ALL field types, so also in the custom portrait fields Export list, but this could be adjusted later, even on a type by type basis, if we dislike godots default field for some reason.

  • There is now hot-reloading of style layer scenes (it reacts to the scene_saved signal and if that scene is the one of the current layer, it just reloads). To make this a bit smoother the style editor now remembers both the layer and the tab of that layer that it was on.

- Avoid effect duplication on DialogText node
- New animations "In Fade", "Out Fade", "Action Hop", "Action Pop"
- fix how "New Text" animation is played (adds Text.new_text_animation() method, which gets called in the text event)
- animation_textbox_*** signals now have an argument (compat break), so that the signal can know which textbox (textbox_identifier) is actually shown
- fix Collapse button state of LayoutSceneSidebar
- simplify names of core nodes in BasicTextbox layer
- move canvas layer base "follow viewport" expose to "Advanced" section
- fixes error on layer list icon assign
- makes Make Custom Full Layout" create scenes with "editable children" enabled for the layers that had settings applied
- also changes how dialogic editors identify their dedicated resource to allow the style editor to edit style resources (.tres). Previously only special extensions where possible. Now the style editor opens when you double-click a style in the file-system dock.
-  Adds a somewhat better form of undo-redo to Make Full Layout Custom
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant