Commit Graph

45 Commits

Author SHA1 Message Date
David Capello 271865e13d Remove unused Command::clone() member function 2019-01-07 17:03:38 -03:00
David Capello 26d510fffd Support more commands without UI
- BackgroundFromLayer
- CelOpacity
- LayerFromBackground
- RemoveLayer
2018-09-06 14:18:59 -03:00
David Capello 853415332b NewLayer can be called in batch mode 2018-09-04 17:30:34 -03:00
Gaspar Capello 93d0b94929 Enhancement new layer below (issue #1822) 2018-08-30 13:31:48 -03:00
David Capello 70629d6f89 Use Tx instead of Transaction in commands 2018-08-20 16:00:59 -03:00
David Capello b83eddf2ea Fix uninitialized var 2018-08-16 12:30:23 -03:00
David Capello 9c79ea2b77 Rename app::Document -> Doc 2018-07-07 11:54:44 -03:00
David Capello ee5842cde3 Rename DocumentApi -> DocApi 2018-07-07 03:07:16 -03:00
David Capello e0a60b6748 Generate the list of command IDs from en.ini file 2017-12-01 15:10:21 -03:00
David Capello ccee49c02b Move command friendly names to the strings file
Related to #124
2017-11-30 23:41:45 -03:00
David Capello eb3143ce21 Rename CommandsModule to Commands 2017-11-30 12:24:07 -03:00
David Capello 49d2cd14f0 Don't add a reference layer if the user cancels the dialog 2017-09-05 15:26:21 -03:00
David Capello 5ef6aac925 Add --dithering-matrix CLI option
Now the dithering matrix used in ordered dithering algorithm is configurable.
2017-05-19 15:49:31 -03:00
David Capello 23272895c4 Move doc::DitheringMethod -> render::DitheringAlgorithm 2017-05-15 16:26:44 -03:00
David Capello 492e71918f Fix undo of a new ref layer 2016-11-02 16:10:42 -03:00
David Capello f895938dbb Fix adding a reference layer with a different color mode 2016-11-01 19:02:11 -03:00
David Capello bf4d6f1e4e Ask for a file when we add a new reference layer
Also the new reference layer is added centered in the sprite and scaling
it to make it fully visible in the canvas.
2016-10-12 14:41:58 -03:00
David Capello 99f37ef242 Add LayerFlags::Reference flag to identify a reference layers
With this flag we can show reference layers in a special way on the
Timeline.
2016-10-04 20:06:24 -03:00
David Capello 7cf546c826 Add menu option to insert a reference layer 2016-10-04 19:55:30 -03:00
David Capello 20b726f73b Merge branch 'master' into beta 2016-08-31 19:53:52 -03:00
David Capello 5ecc356a41 Replace GPL license with the new EULA 2016-08-29 13:08:21 -03:00
David Capello e9871543be Timeline: Add drag & drop of layers as first child in a group 2016-08-26 18:18:25 -03:00
David Capello 36719da7b2 Convert SelectedLayers into a class 2016-08-12 18:01:12 -03:00
David Capello 0f77bf0712 Move selected layers into the new group
If the Timeline has an active selected range of layers and the user
creates a new layer group, the selected layers will be be grouped as
children of the new layer 'group'.
2016-06-21 00:02:13 -03:00
David Capello 58f8ed6476 Prefer LayerGroup::layers() instead of iterators 2016-06-08 16:46:15 -03:00
David Capello 64c1ecf555 Add support to create layers inside groups 2016-06-08 15:55:44 -03:00
David Capello f6fa39ba52 Merge NewGroup command into NewLayer command 2016-06-08 15:43:13 -03:00
David Capello 2f91122c26 Rename layer folder/set -> layer group 2016-06-07 19:38:56 -03:00
David Capello 5f90ef7c9b Add properties in App to access directly to timeline/contextBar/workspace 2016-04-22 13:19:06 -03:00
David Capello 06be4f7fa6 Rename ui::Window::getKiller() -> closer() 2015-12-04 14:54:15 -03:00
David Capello 1aaeacc460 Refactor several "getNoun()" getters to "noun()"
This is a work-in-progress to create a consistent API and finally
separate the whole Aseprite base/gfx/ui libs into a reusable C++ library.

Classes:
app::IFileItem, app::AppMenuItem, app::skin::SkinPart,
gfx::Rect, gfx::Border, she::FileDialog,
ui::IButtonIcon, ui::Graphics, ui::Overlay, ui::Widget,
ui::ScrollableViewDelegate, and UI events
2015-12-04 14:39:04 -03:00
David Capello 214f886a0e Fix bug showing invalid layer name in Layer Props dialog after "New Layer" command 2015-08-21 14:55:34 -03:00
David Capello fa8afc02e9 Create new layers above the current one
We've added a "top" parameter to have the previous behavior.
2015-05-04 11:45:08 -03:00
David Capello 0cb4b2234d Always load params when a command is executed
This is to avoid leaving commands with old params (a problem with
keyboard shortcuts). To make sure, we've changed arguments from Params*
to Params&, so we always have params to load.

Also, in this change we introduce a new way to give parameters to executed
commands from menu items using AppMenuItem::setContextParams(). Before
showing a popup, we can call setContextParams() to give extra params to
the command (e.g. the specific FrameTag to remove or change properties).
In this way "contextparams" attribute for <item> in gui.xml is not
available anymore.
2015-03-11 15:40:22 -03:00
David Capello ad856b2a55 Use std:: when necessary, and std::numeric_limits instead of INT_MAX 2015-03-04 21:35:11 -03:00
David Capello 2c6067f7e4 Update license of app/ module to GPLv2 2015-02-12 12:16:25 -03:00
David Capello e55865843e Replace undo impl: replace undoers with cmds
Undoers were little objects to swap/revert an action. They didn't
execute the action itself, they just revert its previous state. Now
undoers were replaced with cmds: A cmd is an object that
executes/undoes/redoes just one action.

Changes:
* Remove old undo library and app/objects_container_impl.cpp
  (now we use the doc::ObjectId directly to store undo info)
* Remove all Undoers from app/undoers/
* Replace DocumentApi impl with little Cmds in app/cmd/, these
  cmds handle execute/undo/redo of each action at the logic layer
* Remove doc::Dirty object
* Remove doc::Settings: all undo configuration is in the app side
* Move undo options from app:ISettings to app::Preferences
* Rename UndoTransaction to Transaction
* Create a CmdSequence to store a sequence of Cmds (as now the new
  undo library doesn't support open/close groups)
* Add doc::get<T>(ObjectId) function to get any kind of object
  from the doc library by its ID
* Add Cel::document() and Sprite::document() members
* Add Sprite::cels(frame_t) to get all cels in the given frame
* Add Layer::displaceFrames() member function
* Move the "allow non-linear history" flag from undo2::UndoHistory
  to app::DocumentUndo
2015-01-18 22:05:33 -03:00
David Capello 63995c6f0a Merge "raster" namespace into "doc" library 2014-10-20 22:21:31 -03:00
David Capello 6824570c4b Remove base/override.h (use override keyword directly) 2014-08-14 23:07:47 -03:00
David Capello 91b0c2d071 Refactor: Remove "get" part for member functions that act like a simple getter
Additional change:
- Added Cel::image() to get the related image of the cel directly
2014-07-30 01:28:15 -03:00
David Capello 3c4bbbe30c Replace jwidget_set_min/max_size() with Width::setMin/MaxSize() 2014-04-21 22:15:29 -03:00
David Capello 44d3e228fd Add missing OVERRIDE modifier to Command::clone() overrides
It fixes some invalid clone() overrides without const modifier.
2014-03-29 17:08:40 -03:00
David Capello 3c861f1a7e Show timeline automatically when a new frame/layer is created (configurable option) 2013-12-15 12:58:14 -03:00
David Capello cde54f3682 Change BSD license to MIT in sublibraries and fix headers 2013-08-08 21:01:20 -03:00
David Capello c88f9b172b Refactor: Move app files to src/app subdirectory inside app namespace
- Add HAVE_CONFIG_H wrapper to #include "config.h"
- Removed widgets namespace (it's in app now)
- Move some functions from src/file/file.h to src/base/cfile.h
- Move Vector2d to base library
- Rename MenuItem2 to AppMenuItem
2013-08-05 21:20:19 -03:00