Kotcrab.com

import com.kotcrab.Brain;

VisEditor 0.3.0 Released

VisEditor 0.3.0 was released. This release is aimed at cleaning up and improving runtime API so there aren’t many new editor features. Those will be added in upcoming 0.3.1. Some biggest changes:

  • Runtime API was cleaned up and improved, components classes were renamed.
  • Bigger control of how Scene systems are loaded, eg. you can set priorities and disable built-in systems.
  • Editor scenes are now saved using JSON format.
  • You can store multiple assets types in single directory.
  • Runtime was updated to latest Artemis 1.2.1 (0.2.x were running on 0.13.x) and libGDX 1.7.1

If you have existing 0.2.x project then you will need to convert it. There are quite many breaking API changes but it should not be very hard to update. See runtime changes for starting point.

As always please report any issues you have found, especially those in 0.2.x project converter. Enjoy!

Useful links:

If you need 0.2.x support:

VisUI 0.9.5 Released

VisUI 0.9.5 was released. This is a small bugfix release before 1.0.0. Also changelog is now in markdown format.

Version: 0.9.5 (LibGDX 1.7.1)

  • Added: constructor SimpleFormValidator(Disableable).
  • Added: ActorUtils#keepWithinStage(Actor).
  • Deprecated: ColumnGroup. Will be removed in future versions. Use libGDX’s VerticalGroup which supports more features.
  • Fixed: BasicColorPicker palette color selection were flipped.
  • Fixed: BasicColorPicker removed unnecessary right padding.
  • Fixed: MenuItem sub menu could appear outside screen.
  • Fixed: DialogUtils’s ConfirmDialog text label was not centered.

Status of VisEditor 0.3.0

Hi everyone, this is an update about what’s happening with VisEditor development. It’s been quite some time since last version release so I decided it would be good to tell you what’s going on.

First things first, I haven’t stopped working on 0.3.0 so you don’t need to worry :) Next version (0.3.0) is being made in separate branch, I try to push something new every day. It simply takes a lot of time and don’t forget I’m working on this project alone. I still fix bugs in 0.2.5, I try to do it the next day they are reported and you if you look in repository issues page you will see that there isn’t any reported bug. I’m sure 0.3.0 will be released somewhere in the middle of December.

Let’s take a quick look on biggest changes:

  • You can now mix assets types in single directory, previously each asset type had to be stored in one single directory (eg. music files in ‘music’ directory) but not anymore. You can store what you want where you want however they are some limitations. Eg. you can’t store music and sound in single directory so first you have to mark it as music root, this is very nicely displayed in UI: Directories can also be sorted. If you mark directory as Spine animation you will see most important files at the top:
  • Scene are now saved in JSON. It’s qutie big change, VisEditor scenes becomes a lot more VCS friendly, now it’s simple to store scenes in eg. Git repository and see what changed between commits. It also simplified how plugins can save additional scene data.
  • Updated to latest Artemis 1.2.1. VisEditor 0.2.5 is running on old 0.13.1. There will be some API changes but it shouldn’t be too hard to update.
  • Those are changes you wouldn’t notice: I refactored editor source structure, I have also completely rewritten selection system in editor, it’s now much simpler to work with entities selection.
  • And of course I fixed bugs that I found during making 0.3.0.

Those are all things I had done already but there are still some tasks left. There will be API changes in VisRuntime but it shouldn’t be too hard to update, and I will provide an project converter for VisEditor 0.2.5/0.2.6-SNAPSHOT projects.

VisUI 0.9.3 and 0.9.4 Released

PSA: Released 0.9.4 which fixes GWT support.

VisUI 0.9.3 was released. We are getting pretty close to 1.0.0! This time let’s start with changes description and you will see change log later. Biggest change in this release are around ColorPicker. It was rewritten using shaders, previously it was using pixmaps which was fine for desktop but quite slow for GWT and low end Android devices. Shaders gave a huge performance boost and decreased picker creation time. ColorPicker is now an embeddable widget, see BasicColorPicker and ExtendedColorPicker, they extend VisTable so you can add them pretty much anywhere. It also got slight UI redesign.

Next up: DragPane which was contributed by MJ. It’s a wrapper around WidgetGroup that’s allows to drag it’s children and change their order. TabbedPane was modified to use it, so now you can change order of TabbedPane tabs! Also TabbedPane tabs can be disabled.

Fixed NumberSelector bugs and fixed weird issues with GridGroup and allowed to set width and height of it’s children independently. This brought small api change because GridGroup#getItemSize() was removed, you can use GridGroup#getItemWidth() or GridGroup#getItemWidth().

That’s all from biggest changes but I’ve got one more announcement: LML (templates for scene2d.ui with HTML-like syntax) now supports VisUI. Checkout gdx-lml-vis. We’ve got a very nice web demo for it: lml-vis web demo

Full change log for 0.9.3:

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
-API Change: FocusManager.getFocus(Stage) renamed to resetFocus
-API Change: FocusManager.getFocus(Stage, Focusable) renamed to switchFocus
-API Change: GridGroup#getItemSize() removed, use getItemWidth or getItemHeight
-API Change: Moved FileChooser's FavouritesIO to 'com.kotcrab.vis.ui.widget.file.internal' package (isn't VisUI public API)
-API Addition: FocusManager.resetFocus(Stage, Actor)
-API Addition: FileChooser#getCurrentDirectory()
-API Addition: GridGroup#setItemWidth(int), GridGroup#setItemWidth(int), GridGroup#getItemWidth(), GridGroup#getItemWidth()
-API Addition: GridGroup#getItemSize(int width, int height)
-API Addition: TabbedPane#disableTab(Tab tab, boolean disable), TabbedPane#isTabDisabled(Tab)
-API Addition: IntDigitsOnlyFilter
-API Addition: DragPane
-API Addition: VisValue, VisWidgetValue - standard Table Values can be used as lambadas if you are using Java 1.8
-APi Addition: PrefHeightIfVisibleValue
-ColorPicker:
 -API Change: added ColorPickerListener#reset (Color previousColor, Color newColor)
 -Rewritten using shaders, huge performance boost, now usable on gwt and low end devices
 -Internal ColorPicker classes moved to `com.kotcrab.vis.ui.widget.color.internal` package (remember that those classes aren't considered as public api)
 -ColorPicker can now be used as embeddable widget, see ExtendedColorPicker and BasicColorPicker
 -Added ColorPickerWidgetStyle used by ExtendedColorPicker and BasicColorPicker
  -Changed ColorPickerStyle, now uses ColorPickerWidgetStyle as composition
 -I18N: Removed entries: "old", "new" (no longer needed)
 -Style: removed fields: alphaBar10px and alphaBar25px, white (no longer needed)
-NumberSelector:
 -API Addition: setMaxLength(int), getMaxLength()
 -Fixed entering negative integer values
 -Fixed NumberSelector text field focus border when using SkinScale.X2
 -When selector loses focus and entered value is bigger than max it will be set to max value, if it's smaller than min it will be set to min value
  -Previous behavior was to restore last valid value
-Trying to use PopupMenu.add(Actor) with MenuItem will throw an exception (MenuItems must be added using addItem method)
-Fixed GridGroup too high when total items width in single row was equals to group width
-GridGroup now supports setting item width and height separately
-TabbedPane tabs order can be changed by mouse dragging
-Skin changes:
 -Removed drawables: alpha-bar-10px, alpha-bar-25px
-VisUI is now supported by LML (templates for scene2d.ui with HTML-like syntax), https://github.com/czyzby/gdx-lml-vis

VisUI 0.9.2 Released

VisUI 0.9.2 for latest libGDX 1.7.1 was released. This is a pretty big update! Changes:

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
-API Change: VisValidatableTextField#getValidator() removed, use getValidators() instead
-API Change: Removed constructors FileChooser taking I18NBundle
 -This way inconsistent with other widgets that did not support this, use VisUI class for setting global I18NBundles
-API Change: NumberSelector now supports float values, methods taking and returning integers are now using floats
-API Change: NumberSelectorListener#changed(int) is now NumberSelectorListener#changed(float)
-API Change: VisProgressBar and VisSlider now extends standard scene2d.ui ProgressBar and Slider (should not affect existing code)
 -VisSliderStyle was removed, use SliderStyle which is fully compatible with VisSliderStyle
-API Change: changed ColorPickerListener#canceled () to ColorPickerListener#canceled (Color oldColor)
-API Change: added ColorPickerListener#changed (Color newColor)
 -If you are using ColorPickerAdapter this does not affect you
-API Change: removed constructor LinkLabel (CharSequence text, String fontName, String colorName) because it was misleading
             with LinkLabel (CharSequence text, CharSequence url, String styleName)
-API Addition: NumberSelector#setPrecision
-API Addition: NumberSelector(String name, float initialValue, float min, float max, float step, int precision)
-API Addition: NumberSelector(String styleName, String name, float initialValue, float min, float max, float step, int precision)
-API Addition: NumberSelector(NumberSelectorStyle style, Sizes sizes, String name, float initialValue, float min, float max, float step, int precision)
-API Addition: InputDialog#setText(String text), InputDialog#setText(String text, boolean selectAll)
-API Addition: FileChooser#setSelectedFiles (FileHandle... files)
-API Addition: FloatDigitsOnlyFilter
-API Addition: VisUI.isLoaded()
-API Addition: constructor VisValidatableTextField (String text, String styleName)
-API Addition: constructor VisValidatableTextField (String text, VisTextFieldStyle style)
-API Addition: CollapsibleWidget#setTable()
-API Addition: VisWindow#setCenterOnAdd(boolean)
-API Addition: ColorPicker#setAllowAlphaEdit (boolean allowAlphaEdit)
-API Addition: ColorPicker#isDisposed()
API Addition: VisCheckBox.setStateInvalid(boolean) and VisCheckBox.isStateInvalid()
 -VisCheckBox and VisRadioButton can now be marked as invalid (error border will be drawn around them)
-CollapsibleWidget now supports creation without setting initial table
-Added default style for standard scene2d.ui TextTooltip
-Added VisTextField and TextArea "small" style with smaller font
-LinkLabel now uses LinkLabelStyle
-LinkLabel now has link underline on mouse over
-SimpleFormValidator (note that following also applies to FormValidator):
 -API Addition: constructor SimpleFormValidator (Disableable targetToDisable, Label messageLabel, String styleName)
 -API Addition: constructor SimpleFormValidator (Disableable targetToDisable, Label messageLabel, FormValidatorStyle style)
 -API Addition: SimpleFormValidator#setMessageLabel(), and #setSuccessMessage
 -API Addition: SimpleFormValidator#addDisableTarget(Disableable) and SimpleFormValidator#removeDisableTarget(Disableable)
 -Now using FormValidatorStyle: allows to set color for message label when form is valid or invalid
  -Two built-in styles: 'default' and 'smooth' with smooth transition between colors
 -Any object implementing Disableable interface may be passed to FormInputValidator as target to disable if form is invalid
 -Multiple Disableable targets are supported
 -Added CheckBox support (checking if checkbox is checked/unchecked)
-TextField/VisTextField.setMessageText(String text) now works properly.
-DialogUtils methods now return dialogs objects (was void)
-Focus border can now be disabled on all widgets having it
-Fixed VisTree taking VisTextField focus when it was placed inside tree node
-Fixed invalid key up/down events propagation when using multiple input processors
-Fixed font kerning for character pairs: Ma, Me, Mi
-Fixed TabbedPane listener called multiple times when user was switching current tab
-Fixed TabbedPane close tab buttons styles
-Fixed 'directory' validator in FormValidator
-Added libGDX version check before loading VisUI, in case of version mismatch warning will be printed to console
 -Can be suppressed by VisUI.setSkipGdxVersionCheck(true);

Yep, that’s it!

There are few small API changes, you shouldn’t have any problems updating. If you do however ask me on our forums!

There aren’t many new features, as you can see this version mostly introduces bug fixes. From new features we have: number selector supports float values, VisCheckBox now has optional error border. ColorPicker allows to disable alpha selection and few new constructors and methods.

FormValidator got slightly refactored, now it can check if check box is checked or unchecked, you can add multiple widgets that will be enabled/disabled if form is valid or invalid. You can set message for label if form is valid. FromValidator can also change color of label, smooth transitions are supported as well!

1
-Fixed font kerning for character pairs: Ma, Me, Mi

That was pretty interesting issue. Submitted on forums. I had to learn how to fix font kerning in FontForge. TrueType fonts are pretty complicated.

Alright, that’s probably all for this update,
Enjoy!

VisEditor 0.2.5 Released

VisEditor 0.2.5 was released! Download Link

Editor changes:

1
2
3
4
5
6
7
8
9
10
[0.2.5]
-Added PointComponent - can be placed on scene, for example for spawn points
-Music and Sound files can now be changed from Entity Properties
-Fixed text size was not possible to change for ttf fonts
-Fixed error when loading scene with ShaderComponent without shader set
-Added Ctrl+D for duplicating selected entities
-In scene editor, added "Move to Layer" in popup menu, for quick entity moving between layers
-Fixed groups issues
 -Grouping entities while inside group is now working properly
 -Fixed copy pasting groups

Runtime changes:

1
2
3
4
[0.2.5] [LibGDX 1.7.0] [Artemis 0.13.1]
-Updated to Artemis 0.13.1, LibGDX 1.7.0
-Added PointComponent
-Renamed PhysicsSettingsData to PhysicsSettings

VisUI 0.9.0 and 0.9.1 Released

VisUI 0.9.0 and 0.9.1 was released! VisUI 0.9.1 is the same as 0.9.0 but it’s for latest LibGDX 1.7.0. Changes:

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
[0.9.1] [LibGDX 1.7.0]
-Updated to LibGDX 1.7.0

[0.9.0] [LibGDX 1.6.5]
-API Change: Renamed VisValidableTextField to VisValidatableTextField (fixes typo in name)
-API Change: MenuItem#getShortcut() returns CharSequence (was String)
-API Addition: ColorPicker#setCloseAfterPickingFinished(boolean)
-Now Tab#onHide() is called before Tab#dispose()
-VisValidatableTextField ChangeEvent is now fired after input validation
 -Fixes bug with input dialog with validator, it was possible to enter invalid value
-Fixed MenuItem not properly updated after changing menu shortcut when item was already added to PopupMenu
-Fixed MenuItem not using bigger icons when using SkinScale.X2
-FileChooser:
 -Added tooltips for back, forward, and parent directory buttons
 -Added "New directory" button next to path field
 -Added popup menu icons
 -DefaultFileFilter class is now public so it's possible to extend it
 -If your project uses JNA library you can enable moving files to trash instead of deleting them permanently (chooser.setFileDeleter(new JNAFileDeleter()))
 -In file view added icons for common file types: text, images, audio and pdf. Custom icons can be supplied by setting FileIconProvider (see chooser.setIconProvider(...))
 -I18N changes: added entries: back, forward, parentDirectory, newDirectory, popupDeleteFileFailed, contextMenuMoveToTrash, contextMenuMoveToTrashWarning
 -Skin changes: added iconFolderNew, iconFolderStar, iconTrash, iconFileText, iconFileImage, iconFilePdf, iconFileAudio

The biggest breaking change in this release is renaming VisValidableTextField to VisValidatableTextField, that fixes typo that was there since very first versions of VisUI. FileChooser got some nice improvements, among others: you can now use system trash if your project uses JNA and change icons for files. As always there are some bug fixes for few things.

Enjoy!

VisEditor 0.2.4 Released

VisEditor 0.2.4 was released! Download Link

Editor changes:

1
2
3
4
5
6
7
8
9
10
11
[0.2.4] [LibGDX 1.6.4]
-Added Spriter support
-Added "Colors" settings
 -Changed default background and grid color
-Fixed crash after unexpectedly removing one of shader file (issue #21)
-Fixed crash after opening Select File Dialog but there isn't any available file to select
-Fixed "Auto Set Origin to Center" checkbox not updating EntityProperties UI after checking
-Fixed "Auto Adjust Origin" in PhysicsPropertiesComponent for scaled objects
-Fixed copy-paste at wrong position when using right click popup menu
-"Add Component" dialog now can be used for multiple selected entities
-Improved Twitter view

Runtime changes:

1
2
3
4
5
6
[0.2.4] [LibGDX 1.6.4]
-Added Spriter support
-Fixed GWT support
-Improved scene loading errors logging
-When loading Scene without using VisAssetManager#loadSceneNow you must now manually cal Scene#init()
-Fixed wrong particle rendering when there was two or more particle effects of same kind

VisUI 0.8.2 Released

VisUI 0.8.2 was released! Changes:

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
[0.8.2] [LibGDX 1.6.4]
-API Addition: VisValidableTextField#restoreLastValidText()
-API Addition: OsUtils.isAndroid(), OsUtils.getAndroidApiLevel(), OsUtils.isIos(), OsUtils.getShortcutFor(int... keycodes)
-API Addition: MenuItem#setShortcut(int... keycodes)
-API Addition: VisSplitPane#getFirstWidgetBounds(), VisSplitPane#getSecondWidgetBounds()
-API Addition: NumberSelector#setProgrammaticChangeEvents(boolean), NumberSelector#setValue(int value, boolean fireEvent)
-API Addition: NumberSelector#removeChangeListener(...)
-API Change: Removed MenuItem#setShortcut(int modifier, int keycode)
-API Change: FileUtils.isMac(), FileUtils.isUnix() and FileUtils.isWindows() moved to OsUtils
-Added ColumnGroup
-Fixed MenuItem shortcut label color when MenuItem is disabled
-If user clicks mouse before Tooltip appears, Tooltip won't be showed
-Fixed issue with GridGroup in ScrollPane - scroll bar appeared too late
-Fixed GWT compilation issues
-PopupMenu is now kept inside stage when displaying it
-FileChooser
 -API Change: Removed FileChooser#setVisble(boolean) (typo in name), use FileChooser#setVisible(boolean)
 -API Change: Renamed: setGroupMultiselectKey to setGroupMultiSelectKey, getGroupMultiselectKey to getGroupMultiSelectKey,
                       setMultiselectKey to setMultiSelectKey, getMultiselectKey to getMultiSelectKey
                       setMultiselectionEnabled to setMultiSelectionEnabled, isMultiselectionEnabled to isMultiSelectionEnabled
 -Fixed issue with very slow chooser creation on computers with floppy disk drivers installed ( https://github.com/kotcrab/VisEditor/issues/11#issuecomment-136892177 )
 -Fixed crash in when user tried to use history buttons for no longer existing directory
 -Fixed multiple selection when selection mode was set to FILES or DIRECTORIES
 -Added support for the back and forward mouse button for navigating in the history
 -I18N
  -added directoryNoLongerExists
  -added missing entries: newDirectoryDialogTitle, newDirectoryDialogText

FileChooser got some improvements and minimal API changes, MenuItem#setShortcut was removed but it is replaced by MenuItem#setShortcut(int... keycodes). Shortcut set this way is now platform dependent, it will show “Ctrl + S” on Windows and Linux but on Mac it will be “⌘S”.

VisEditor 0.2.3 Released

VisEditor 0.2.3 was released! Download link

There is new component for storing variables and I added snapping to grid so working with tiles is easier, snapping can be enabled on the toolbar or by holding ctrl key while dragging.

Editor changes:

1
2
3
4
5
6
7
8
9
[0.2.3] [LibGDX 1.6.4]
-Added VariablesComponent
-Fixed crash when moving entities group
-Fixed crash for very small grid sizes
-Fixed issue when Entity Properties dialog wasn't updated after entity remove undo
-Fixed issue when Entity Properties collapsed components panels would expand again after dragging entity
-When opening project from older version of VisEditor a project backup will be created
-Added Ctrl + E keyboard shortcut to export project
-Added snapping to grid

Runtime changes:

1
2
3
4
[0.2.3] [LibGDX 1.6.4]
-Added VariablesComponent
-API Addition: Scene#getLayerDataByName(String name)
-API Addition: SceneParameter#passiveSystems field - SceneParameter now supports adding passive systems