Commit Graph

494 Commits (master)

Author SHA1 Message Date
Sven Eberhardt e13bd62f94 Editor: Keep current shape list separate from property holders
This prevents shapes from being re-created (and temporary state lost) if the holding property moves within the list.
2016-11-10 21:43:42 -05:00
Sven Eberhardt ebda8193ef Replace NULL by nullptr in C++ sources
We don't support pre-C++0x any more, so nullptr should be fine everywhere (except in the plain C source files)
2016-11-02 19:58:02 -04:00
Sven Eberhardt 54e8c14666 Editor: Add graph, polyline and polygon shape delegates 2016-11-02 09:54:31 -04:00
Sven Eberhardt 5c5e1a5fa3 Fix editor selection after object duplication on remote clients
Also remove some remaining EditCursorSelection/EditCursorDeselection callbacks
2016-10-30 22:26:14 -04:00
David Dormagen c2f391e565 editor: don't crash on selecting object when EditorBase doesn't have member EditorProps
This crash happened for me in a custom scenario but with unmodified original objects. No idea why, but it seemed defective anyway.
2016-10-23 18:47:44 +02:00
Julius Michaelis 376ca5a9df Prevent using USE_CONSOLE in lib{misc,c4script} 2016-10-22 17:42:23 +02:00
Julius Michaelis 8d2f2846b5 Fix mac build
Also move some stuff around once again…
2016-10-21 01:25:48 +02:00
Julius Michaelis 34a9a1de8d Twiddle with header organization: lib{misc,c4script} do no longer include GL/glew.h
(Yes, it is just that complicated.)
2016-10-20 18:46:32 +02:00
Sven Eberhardt 24c386c67f Editor: Fix recent scenario display on welcome page if a recent entry was opened via path including Scenario.txt
Always show the name of the enclosing .ocs file.
2016-10-16 09:52:48 -04:00
Sven Eberhardt cd9d6f5c6f Editor: Show full path name in sound delegate display string 2016-10-16 01:15:38 -04:00
Sven Eberhardt 38cf275de7 Editor: Implement saving of editable enum delegates 2016-10-16 01:12:21 -04:00
Sven Eberhardt 386f178568 Editor: Auto-focus enum child editors for int, string, color and any types 2016-10-15 18:26:03 -04:00
Sven Eberhardt 028b576ab3 Editor: Change initial tool to "object edit" 2016-10-15 11:43:55 -04:00
Sven Eberhardt c44a776090 Editor: Fix object list update on object removal 2016-10-15 11:43:12 -04:00
Sven Eberhardt 978afbc4a2 Editor: Focus object script box on double-clicking item in object list 2016-10-15 10:39:33 -04:00
Sven Eberhardt d24afbe835 Editor: Fix display of non-object properties
Fixes property display of definitions, Global and Scenario.
2016-10-15 10:06:44 -04:00
Sven Eberhardt 06a438e05e Editor object list: Remove effects; add Global and Scenario 2016-10-15 10:06:44 -04:00
Sven Eberhardt 4b3f8c0fef Remove EditCursorSelection and EditCursorDeselection callbacks
They never worked properly in network mode because all users would see the changes.

EditorProps, EditorActions and shape delegates now provide the functionality to have custom object editing widgets.

This also fixes a bug with the selection callback causing the object list to act up.
2016-10-15 10:06:43 -04:00
Sven Eberhardt 15d850e4ec Editor: Add effects to property viewer 2016-10-14 10:50:17 -04:00
Sven Eberhardt 510d91fd00 Editor: Allow movement of HorizontalFix items by holding Shift and on object duplication 2016-10-10 21:46:17 -04:00
Sven Eberhardt 5e4aefddb2 Editor: Fix Ctrl+Click in object creation mode to create contents 2016-10-10 21:35:04 -04:00
Sven Eberhardt 4eae2b28d7 Editor: Fix drop cursor drawing 2016-10-10 21:26:10 -04:00
Sven Eberhardt d670291aba Implement tool tips for EditorActions 2016-10-10 16:45:23 -04:00
Sven Eberhardt 20d234e324 Editor: Replace | by line breaks in descriptions and EditorHelp texts 2016-10-10 16:45:22 -04:00
Sven Eberhardt 5e3730fc3e Editor: Store+Restore maximized state 2016-10-08 20:53:01 -04:00
Sven Eberhardt 765648877f Editor: Fix window shutdown to correctly save editor geometry even if quitting via Application.Quit (e.g. Ctrl+Q) 2016-10-08 20:52:25 -04:00
Sven Eberhardt 45718ee44d Change tool hotkeys from <number> to to <Ctrl>+<number>
This allows better combined playing+editing experience [Maikel]
2016-10-08 19:15:28 -04:00
Sven Eberhardt 685513816f Editor: Raise focused viewport dock.
When switching viewports using F10, the selected dock may have been hidden
2016-10-08 19:15:27 -04:00
Sven Eberhardt 9e150f2bfb Viewport zoom towards center and fix scrolling 2016-10-08 19:15:26 -04:00
Lukas Werling c3cf464a83 Editor: Fix scenario open filter (#1817) 2016-09-18 23:22:39 +02:00
Sven Eberhardt 61b1ab08ad Editor: More shortcuts; show helper shortcuts in tools menu 2016-09-10 01:17:40 -04:00
Sven Eberhardt 2490ef4584 Editor: Add more shortcut keys 2016-09-09 00:56:16 -04:00
Sven Eberhardt e67e429fef Editor: Improve default layout and raise proper dialogues on tool change 2016-09-09 00:56:15 -04:00
Sven Eberhardt 53b365a6d2 Editor: Add shortcuts, menu items, tooltips 2016-09-08 01:56:01 -04:00
Sven Eberhardt 0e02bad837 Editor: Disable reinit scenario button if no scenario is loaded 2016-09-08 00:25:17 -04:00
Sven Eberhardt b95d1387a4 Editor: Add "reset to saved scenario" command 2016-09-07 01:53:54 -04:00
Lukas Werling 3d5f2f012a Fix openclonk-server build 2016-09-06 22:12:06 +02:00
Sven Eberhardt ba371db0e6 Editor property enum delegate: Improve grouping when an item is also a group 2016-09-05 19:19:33 -04:00
Sven Eberhardt d70506ee2e Improve GetDefinitionGroupPath script function
* Now works on _this instead of parameter
* Now works before editor window opened
2016-09-05 18:30:04 -04:00
Sven Eberhardt 41dde5e7d0 Add script function GetDefinitionGroupPath 2016-09-05 02:00:01 -04:00
Sven Eberhardt 3669f28b75 Fix array property delegate default value to write a copy instead of a reference when it's a static prop list 2016-09-04 02:14:30 -04:00
Sven Eberhardt 5a149b3b8a Add alpha mask option to editor property color delegate 2016-09-03 22:07:09 -04:00
Sven Eberhardt 31121d682c Rename option default value function property to DefaultValueFunction
It was "Get" and later "Set", which was always a bit confusing.
2016-09-01 18:32:24 -04:00
Sven Eberhardt 0093555b49 Fix sorting between groups and names in enum editor properties 2016-08-30 19:37:42 -04:00
Sven Eberhardt f53a4a6597 Fix enum parameter value resolution to nil when proplist value is undefined 2016-08-29 15:18:02 -04:00
Sven Eberhardt 80d5810c3e Another Mac/Linux build fix 2016-08-28 10:23:13 -04:00
Sven Eberhardt 5a2e96e25b Correct a format placeholder type 2016-08-28 10:17:36 -04:00
Sven Eberhardt 0acf8a36f9 Fix Linux/Mac build 2016-08-28 10:16:06 -04:00
Sven Eberhardt b763982f45 Fix scenario saving as network client to not delete saved scenario after game end (#1814) 2016-08-28 00:56:15 -04:00
Sven Eberhardt 3163332def EditorActions: Replace %player% by first local player number 2016-08-27 22:19:25 -04:00
Sven Eberhardt 949ab90fc8 Editor: Fix enum delegate setting a value on cancel undeer certain conditions 2016-08-27 21:33:25 -04:00
Sven Eberhardt aa8289b55b Editor: Always commit string property changes if text has been edited 2016-08-27 21:24:43 -04:00
Sven Eberhardt 528504d72e Editor: Hide grade circle in viewport when using rectangle or picker tool 2016-08-27 20:10:58 -04:00
Sven Eberhardt 4f74d88d51 Editor: Fix selected object property dropdown list 2016-08-27 19:56:46 -04:00
Sven Eberhardt c98f99b427 Editor: Do not reset landscape brush when switching tools 2016-08-27 19:43:34 -04:00
Sven Eberhardt 6070bb4782 Fix editor prop enum option Set function 2016-08-27 19:05:12 -04:00
Sven Eberhardt 6b9df3118c Sort UserAction evaluators and groups by name
Also merge effect group into ambience group.
2016-08-27 16:46:59 -04:00
Sven Eberhardt 00bc92e13f Use short names as main editor delegate display in property window.
Simplifies most user action displays by omitting things like "Constant" in the list.
2016-08-27 10:12:17 -04:00
Sven Eberhardt 357eb462bd Fix display of nil enum child delegate value if stored in a proplist and key is not defined.
It would fall back to the outer value instead.
2016-08-27 02:21:35 -04:00
Sven Eberhardt e4b4246500 Fix freezing and assignment of static names to child proplists created in Definition()-callbacks (#1798)
Also adjust editor props for the change:
1. enum needs to create a copy, not a reference for the default value of an option if it is defined inline
2. Always use proper GetName() resolution on property group names even if a static name would be available
2016-08-27 02:04:03 -04:00
Sven Eberhardt 568088aedb Editor: Add Copy+Paste functionality for properties 2016-08-19 16:13:28 -04:00
Lukas Werling 26a552473c Add support for two extra mouse buttons (#mantis-is-down-right-now)
This also fixes a missing definition for "MiddleDouble". Only
implemented for SDL and Qt, someone else will have to do Windows.
2016-08-18 22:43:42 +02:00
Lukas Werling 4f5ba57170 Allow scenario saving as editor client 2016-08-09 18:55:43 +02:00
Sven Eberhardt 9d715387f2 Qt editor: Store and restore window layout (docked dialogues, etc.) 2016-08-08 23:57:24 -04:00
Sven Eberhardt 60240ac05b Qt editor: Fix material size slider when adjusting with a method other than dragging 2016-08-08 17:39:10 -04:00
Sven Eberhardt 4c349b8c17 Qt editor: Fix enum parameter delegate initial value assignment 2016-08-07 23:42:41 -04:00
Sven Eberhardt 08d2e3f521 Qt editor: Fix material selection sorting and remove duplicates 2016-08-07 10:33:21 -04:00
Sven Eberhardt 39cfd4a0fe Fix non-editor build (this time for real!) 2016-08-07 02:18:01 -04:00
Sven Eberhardt 0b5e8723c2 Fix non-editor build 2016-08-07 01:42:29 -04:00
Sven Eberhardt 62fb460180 Qt editor: Make completer in script input box case sensitive 2016-08-06 23:54:47 -04:00
Sven Eberhardt 5c70c2aa42 Qt editor: Fix viewport titles and decorations
The custom title bar caused a lot of problems. Particularly turning it on and off between docked and undocked modes caused some internal trouble with the rendering going off. It also didn't have a close button.

Fortunately, the desired font and highlight effect of selected viewports can also be achieved with style sheets on the dock.
2016-08-06 23:39:44 -04:00
Sven Eberhardt 40abe71a8c Qt editor: Better placement of PlayerStart object in new scenario 2016-08-06 21:29:26 -04:00
Sven Eberhardt 3553cd54b5 Qt editor: Allow creation of larger map in new scenario 2016-08-06 21:29:09 -04:00
Sven Eberhardt a7fffcfd77 Qt editor: Clear definition list on game close 2016-08-06 21:19:24 -04:00
Sven Eberhardt b6e45daa24 Qt editor: Enable play button to start game in lobby 2016-08-06 21:16:28 -04:00
Sven Eberhardt 5bb204d69b Qt editor: Fix net menu
It didn't work, had the wrong labels and crashed.
2016-08-06 21:12:04 -04:00
Sven Eberhardt c0f95d97f7 Fix net menu popping up out of nowhere all the time 2016-08-06 20:29:15 -04:00
Sven Eberhardt 6dc4cb7f1d Remove some outdated todo comments in C4ConsoleQt 2016-08-06 20:28:50 -04:00
Sven Eberhardt 20eaaa97b3 Fix chatting in editor lobby 2016-08-06 20:22:33 -04:00
Sven Eberhardt a14f8597d2 Qt editor: Fix AsyncGet on bool delegate 2016-08-05 01:00:33 -04:00
Sven Eberhardt 6bd6c07195 Qt editor: Remove some debug logging 2016-08-04 22:22:14 -04:00
Lukas Werling b7359e0c27 Remove the GTK platform (USE_GTK)
The GTK code does not work with the Qt editor. The simpler SDL2 platform
does, so we have little reason to keep the GTK code.

Note that GTK is still a dependency for mape.

Discussion: http://forum.openclonk.org/topic_show.pl?tid=3328
2016-08-03 16:25:46 +02:00
Sven Eberhardt 24a5dc33db Qt editor: Sort properties in property list by localized name and priority 2016-08-02 01:12:08 -04:00
Sven Eberhardt 69fff71abf Qt editor: Fix crash on player removal 2016-07-31 23:22:09 -04:00
Sven Eberhardt d1e8bc39c5 Qt Editor: Fix enum property delegate option value lookup for undefined options 2016-07-31 10:35:15 -04:00
Sven Eberhardt 442b8e66df Qt Editor: Add short name for enum delegate options displayed as sub-delegate 2016-07-30 14:50:07 -04:00
Sven Eberhardt d55c988d2e Qt Editor: Support EmptyName enum delegate property for user-defined option lists
This can be used to clarify what happens e.g. when nil is selected in an object function delegate.
2016-07-30 14:13:23 -04:00
Sven Eberhardt 8840105f6c Qt editor: Auto-dropdown child enums on creation 2016-07-30 02:37:33 -04:00
Sven Eberhardt affa2aebb0 Qt Editor: Add point property delegate 2016-07-30 01:05:12 -04:00
Sven Eberhardt 37885a2e4f Qt Editor: Add AllowEditing flag for enum delegates.
Used for sound delegate
2016-07-28 00:24:28 -04:00
Sven Eberhardt b6fb7e884f Qt Editor: Put current selection name before EditorHelp/Description 2016-07-27 22:36:14 -04:00
Sven Eberhardt 73510d7fb1 Qt Editor: Add sound property delegate 2016-07-27 22:35:11 -04:00
Sven Eberhardt 11b317808f Qt Editor: Add toggle help button to "?" menu 2016-07-25 21:39:35 -04:00
Sven Eberhardt 4246a72485 Qt Editor: Add EditorHelp for enum options 2016-07-25 01:05:15 -04:00
Sven Eberhardt ee88a36f73 Qt Editor: Rename EditorInfo to EditorHelp
Fits better with "UsageHelp" and is more precise.
2016-07-24 23:10:43 -04:00
Sven Eberhardt 3a6a7626c1 Qt Editor: Add help hover button to editor props 2016-07-24 23:00:24 -04:00
Sven Eberhardt 4245f60e83 Qt Editor: Add help/description label for current selection 2016-07-24 10:12:38 -04:00
Kanibal a7d6a7dbd7 Use file selector instead of directory selector (select Scenario.txt for unpacked workspace) to select files 2016-07-23 22:47:15 -04:00
Martin Plicht 78f336c67c C4ConsoleQtViewport: Un-TODO some line for now 2016-07-23 18:20:36 +02:00
Sven Eberhardt 5bfd2b87c5 Qt Editor: Reorder array editing buttons below property action buttons 2016-07-23 02:34:08 -04:00