[Free] Voltage - UI Framework for Editor scripting

Like bootstrap for Unity!
AssetStore - Discord - API Reference (WIP) - Quickstart Guide

If you have found that the default UI layout for editor scripting is making it harder for you to build your tools or editors, then this is the asset for you.

  • Styles Editor: for easily managing all your styles on one window, now you wont have to trouble yourself coding your styles. You can edit them and see the changes on real time and use them on your code.
  • Nested Areas: easy to comprehend nested areas, combine all the different areas to control and organize your interface.
  • Split Area: if you where wondering how to provide your windows or editors with a split screen, now it will only take you one line of code.
  • Weighted Areas: for fitting elements in a simple way.
  • Stream Areas: for when you need a stream of tight fitted elements.
  • Foldout Areas: foldouts made easy with Voltage.
  • Tab Areas: a simple implementation of tabs.
  • List: A simple to implement nested list for you to use on whatever way you want. With right mouse click for deleting, duplicating.
  • Fields: All the classic drawers implemented, and the possibility to expand and add your own custom elements for you to use.





Power your tools with Voltage and save your time for something else!

3 Likes

EDIT: Update 0.9.2 is now Live
Next update will come with new features:

  • Toggle: classic on/off check toggle for true/false values (can’t believe I forgot to add it)
  • Switch: the modern version of toggle on/off slider for true/false values.
  • Popup: the previous release had EnumPopups but now you can make your own labels via code for more control
  • Flags: same as Popup, previously only EnumFlags where supported
  • List changes: List will be changed for better control.
  • [New] VoltageBuilder: to help you separate your windows and editors into multiple scrits (See DemoBuilder and DemoWindow for implementation examples).
    Fixes:
  • Style Editor: currently is not working as intended, fixes will be performed.
  • Scroll Area: fixed an error with mousePosition on EventCalls that prevented from tracking the correct Position inside a ScrollArea.

If you have any requests for new features or fixes please post them here. If you have any questions on how to use this asset don’t doubt on contacting me via PM or email, or better yet post your questions on this thread , or make a new one so everyone can benefit.

1 Like

Nice! Always happy to see people extending/adding functionality in the editor UI framework and then sharing it with the community. :slight_smile:

1 Like

Thanks!, happy to give back

Moving my comments over here as there is no value in giving my necro’d thread more air :wink:

Shweet. Turns out I had a similar approach (I had to go look my code up) so we’re thinking the same things. If there is anything from the editor designer code base you want to rip for a ‘window editor’ go ahead. The canvas implementation is probably not the best, but there was some good code in there for dynamically building properties panels via reflection. Might be a useful reference???

Will definitely check out Voltage and because I’ve not said it here, props for getting the asset live!

A

2 Likes

Thanks! same to you, feel free to disect my code if it’s useful for your asset.

1 Like

Update 0.9.3 is now Live

  • VoltageBuilder no longer inherits from MonoBehaviour. Now you can create them with the new keyword.
  • Minimum Unity version changed to 5.4

Version 0.9.4 is now Live

MAYOR CHANGES!

  • VoltageInternalConstruction added to the framework. This internal class will be present across all base classes of Voltage (VoltageWindow, VoltageEditor, VoltageHelper).
  • Constructor: From now on to code your UI you need to access the Constructor property. All AreaStart(), Field(), Label(),etc. will need to be accessed with Constructor.AreaStart(), Constructor.Field(), Constructor.Label(), Constructor.Etc().
  • VoltageStyles: VoltageStyles is now deprecated and was replaces by Styles and StyleBundle. Use the new tool Style Converter to update your old style file without loosing anything.

Before:

VoltageGUI ()
{
    WeightAreaStart();
        Field(myField);
        Label("Label");
    EndArea();
}

Now:

protected override void VoltageGUI ()
{
    Constructor.WeightAreaStart();
    Constructor.Field(myField);
    Constructor.Label("Label");
    Constructor.EndArea();
}

New Features

  • VoltageInternalConstructor: Is now used to manage Stored and Wild elements more comprehensively on VoltageWindow, VoltageEditor and VoltageHelper.

Use Constructor.StartStoredConstructor(myArea) to change focus to myArea and start constructing its Stored Layout. Use Constructor.EndStoredConstructor to finalize.

WeightArea myWeightArea;

protected override void VoltageInit ()
{
    myWeightArea = new WeightArea();

    //StartConstructing your area
    Constructor.StartStoredConstructor(myWeightArea);
        Constructor.Field(myField);
        Constructor.Label("Label");
        Constructor.StreamAreaStart();
            Constructor.Field(myField);
            Constructor.Label("Label");
        Constructor.EndArea();
    Constructor.EndStoredConstructor();

    // Start constructing more areas!
    Constructor.StartStoredConstructor(otherArea);
       // Area content
    Constructor.EndStoredConstructor();
}
protected override void VoltageGUI ()
{
    // Show your area with no allocation overheat!
    Constructor.AreaStart(myWeightArea);
}
  • Styles: used to manage your bundles. Previous VoltageStyles.GetStyle should be replaced by Styles.GetStyle(styleID). Now you can access other StyleBundles on “Assets/Splime/Voltage Style Bundles/” folder using Styles.GetStyle(bundleName,styleID).
  • StyleBundle: manage different styles and organize them within different bundles. Create a new bundle on the right click “Create” menu on the Project Manager. Place your bundles under “Splime/Voltage Style Bundles” to be able to edit them through the Voltage Style Editor.
  • Style Editor: added functionality to edit multiple StyleBundles.

Changes

  • VoltageBuilder: changed name to VoltageHelper.
  • VoltageHelper: now can call other VoltageHelpers thanks to the Constructor.

Fixes

  • WeightArea: fixed EventCall and DrawCall for stored Elements
  • StreamArea: fixed EventCall for stored Elements
  • SplitArea: fixed issue with tracking mouse position when inside other areas.

As always special thanks goes to @Delarn and @GengarGames777

[Voltage UI] unofficial Discord Server

1 Like

Update 0.9.5 is now Live

New Features

  • Style Editor: “Duplicate” and “New” option added to list’s right click menu. New Bundle and Reload buttons added.
  • VoltageList: added DeleteItem and RenameItem public methods for more control.

Changes

  • Button style: Changed a bit.

Fixes

  • Styles: Style Bundles will now load when requested instead of just when the Style Editor is opened.
  • Tab Area: Now EventCalls will be passed to child areas and elements. Before it preveted child elements using Votage event system to respond to mouse and keyboard events.
  • Password: Will now properly select basic style.
  • Split Area: Will now calculate its size properly.
  • Switch: Will now calculate its size properly.
  • Toggle: Will now calculate its size properly.

I’m currently working on the API Reference document. It’s not finished yet but you might find it helpful.

The Voltage Quickstart Guide is being written at the moment. For now you will find a quick explanation about how areas work and how to use them. More will come so stay Tuned

Hi. Thanks for the great asset! Do you still support it? Don’t you publish source code on github? I found an issue - when you creating a VoltageText and write into it something Text property still gets empty (Also if you unfocus your VoltageWindow you see that text gets disappeared and if focusing again it appears)