Commit Graph

7137 Commits

Author SHA1 Message Date
David Capello
1c8b8051a8 Rename FrameTag -> Tag 2019-10-01 14:55:08 -03:00
David Capello
c25c67733b Include ui/scroll_helper.h in ui/ui.h 2019-10-01 14:35:47 -03:00
David Capello
4e4cafece6 Rename FrameTags -> Tags in file spec/encoder/decoder functions 2019-10-01 13:16:35 -03:00
David Capello
cefeb9cbc0 Make "Duplicate Cels" commands behave like the timeline range is enabled even for the case of one cel
In this way we can use Alt+D to duplicate the active cel, and Alt+M to
link the active cel in the next frame.
2019-10-01 12:05:04 -03:00
David Capello
b6fceaf549 Keep the transparent color index on the output of Export Sprite Sheet 2019-10-01 10:08:07 -03:00
David Capello
5e25d5a021 [lua] Add support to call AddColor from scripts 2019-10-01 09:37:04 -03:00
David Capello
944634542e Refresh screen/current palette automatically on Transaction::commit() (#378)
Removed app_update_current_palette() with this patch.
2019-10-01 09:24:03 -03:00
Gaspar Capello
7c92fe207a Fix caret position when click on a text entry (#2160) 2019-09-30 16:22:01 -03:00
David Capello
b4c0a032e8 Fix previous commit 2019-09-27 17:48:51 -03:00
David Capello
46de0c95c3 Preserve links when moving cels to different layer (continuation of 75636afd64) 2019-09-27 14:37:19 -03:00
Gaspar Capello
3e1fe9771a Add LockAlpha ink type to Brush Ink (#2133)
Now we can use LockAlpha ink type with Image Brush.
In addition, we defined Simple ink type with Image Brush.
2019-09-26 19:21:25 -03:00
David Capello
75636afd64 Preserve cel links when we copy/move a range of cels/frames
This is a common solution in the DocApi wrapper that takes cares of
the duplicated cels that we're copying with copyCel() and that are
linked in the source, so then it maps the links into the destination.
Solving this in DocApi we fixed the problem on the timeline
drag-and-drop (doc_range_ops), copy/paste clipboard ranges, and merged
the code in NewFrame to duplicate (linked) cels.

We've also added 3 variants of Duplicate Cels with this change:
- Duplicate Cels: Copies the whole cel block without linking to
  previous cels.
- Duplicate Linked Cels: Copies the whole cel block linking all cels to
  previous cels.
- Duplicate Cels w/Layer Mode: Depending on the layer mode (continuous
  or not) the cels will be linked or not (this is how "duplicate
  linked cels" was working before, and was added just in case for
  backward compatibility).

Fixes: http://steamcommunity.com/app/431730/discussions/1/142261352649813598/
2019-09-26 19:09:23 -03:00
David Capello
4ff77a4d55 Fix auto-pick of layers when alpha in 1...127 range (fix #2156)
The threshold of 50% was chosen to select layers that are more visible
than others (whatever is the order of layers in the stack) but it
might not be working as expected (e.g. if both composed layers has
alpha < 128 it will select no layer at all). Maybe in the we could
choose a higher threshold than 1, but let's see how it works for
users.
2019-09-26 11:51:15 -03:00
David Capello
6adbf899d4 Fix progress bar applying filters (fix #2152, related to 1659401642)
Regression introduced in 4264f199cd
2019-09-25 14:33:56 -03:00
David Capello
f4bf7a22a3 Update laf module 2019-09-24 17:08:34 -03:00
David Capello
1659401642 Fix progress bar applying filters (fix #2152)
Regression introduced in 4264f199cd
2019-09-24 15:57:26 -03:00
David Capello
ccb9dc6f25 Add missing PngOptions (related to a532f21ec4, #2153) 2019-09-24 09:59:22 -03:00
David Capello
8d5133fe09 Move editor_type() -> Editor::Type() 2019-09-23 20:02:19 -03:00
David Capello
636531c6da Fix verbose text when a font is loaded 2019-09-23 15:33:27 -03:00
David Capello
a532f21ec4 Load/save unknown chunks from/to png files (fix #2153) 2019-09-23 15:32:33 -03:00
David Capello
de4a7454ce Minor changes in png_format.cpp
* Renamed png_ptr -> png
* Renamed info_ptr -> info
* Added DestroyReadPng and DestroyWritePng
2019-09-23 10:57:23 -03:00
David Capello
1748e4f59c [lua] Add some operations (add,sub,mul,etc.) to points/size/rectangles 2019-09-23 10:22:09 -03:00
David Capello
d43ff9b32b Check missing theme styles to avoid crashes w/broken themes 2019-09-23 09:03:10 -03:00
David Capello
79f4e892f1 Add missing strings for extensions panel 2019-09-23 08:54:04 -03:00
David Capello
2c9fe85748 Fix doc_api_tests.cpp compilation 2019-09-11 20:32:17 -03:00
David Capello
845c2071da [lua] Update API version to 6 2019-09-11 19:20:43 -03:00
David Capello
cbd3ee2cd7 [lua] Fix Sprite:resize() to resize non-active sprite 2019-09-11 19:19:58 -03:00
David Capello
b0a8b50246 Use one transaction per document (fix https://community.aseprite.org/t/3851) 2019-09-11 19:12:11 -03:00
David Capello
26fbacc772 Fix a crash selecting a tile or pasting clipboard when we are moving the selection boundaries
This is because the MovingSelectionState freeze the document mask, and
we should unfreeze it before we execute any other command.
2019-09-11 18:19:29 -03:00
David Capello
76681dc416 Minor changes in editor.cpp (using some auto) 2019-09-11 18:18:31 -03:00
David Capello
602d844085 Restore DropPixelsField on ContextBar when switch to a editor in MovingPixelsState 2019-09-11 16:08:58 -03:00
David Capello
d588777b40 Remove unnecessary calls to Doc::resetTransformation/generateMaskBoundaries() 2019-09-11 15:41:35 -03:00
David Capello
fe42245ed9 [lua] Fix Sprite:newTag() so it generates undo info and can be used in transactions 2019-09-11 15:02:27 -03:00
David Capello
138cd2970c Add option to disable transforming multiple cels when we have only layers/frames selected on the Timeline 2019-09-11 14:01:50 -03:00
Gaspar Capello
492576de3c Fix Contour Tool: cannot draw one pixel in excepcional condition
Before this fix, with Contour Tool activated (Pixel Perfect = OFF), if
we did click while we were moving the mouse inside the same pixel, it
wasn't drawn.

Related to: https://community.aseprite.org/t/3509
2019-09-11 13:18:09 -03:00
David Capello
761ccd8217 Fix invalidation of the Timeline range on kMouseDownMessage 2019-09-10 15:19:41 -03:00
David Capello
559c3df6de Fix crash using Edit > Cut after pasting the clipboard content on an empty cel 2019-09-07 11:43:22 -03:00
David Capello
5eb3119877 Update libpng 2019-09-05 20:15:44 -03:00
David Capello
0b44b83cf3 Add a timer to MovingPixelsState to avoid RotSprite on each mouse move
We can use the fast algorithm for fast feedback, and use a timer to
draw with RotSprite when the mouse doesn't move after 50ms.
2019-09-05 20:03:16 -03:00
David Capello
d03f5e9145 Add option to force RotSprite usage (as in old versions) 2019-09-05 18:22:51 -03:00
David Capello
3e391670b9 Fix preview of certain tools in tiled mode (fix #2145)
Fixes #2145 and https://community.aseprite.org/t/3833
Regression introduced in: 6a88713213
2019-09-05 18:04:38 -03:00
David Capello
1c68c25594 Fix preview center when tiled mode is enabled 2019-09-05 17:56:55 -03:00
David Capello
42b1154c25 Remove unused variable 2019-09-05 17:56:41 -03:00
David Capello
4acd3675b0 Remove unused code 2019-09-05 15:34:01 -03:00
David Capello
3e478d3efa Transform/scale/rotate multiple cels at the same time (fix #1148, #1172, #1238, #1364)
Requested in twitter, the forum, and in several other places and
frequently over all these years:
https://community.aseprite.org/t/scaling-multiple-frames-simultaneously/240
2019-09-05 15:03:13 -03:00
David Capello
2d979c521c Update status bar info immediately after rotating/transforming the selection 2019-09-03 16:37:12 -03:00
David Capello
e19119cae2 Keep rotation angle inside -180...180 range when using Edit > Rotate commands 2019-09-03 16:34:47 -03:00
David Capello
47ff85e871 Avoid RotSprite for 90/180 degree rotations
Reported several times:
https://community.aseprite.org/t/better-90-180-rotation-from-menu/2937
https://community.aseprite.org/t/rotate-90-should-not-use-rotsprite/3267
https://community.aseprite.org/t/improvements-to-rotsprite/3613/4
https://community.aseprite.org/t/buggy-90-degree-rotation/3793
2019-09-03 15:10:02 -03:00
David Capello
dcdde74cba Print layers/tags/slices on stdout only if there are no export params -sheet/-data (fix #2143) 2019-08-30 18:24:31 -03:00
David Capello
eb2e0e52dc Fix crash using Sprite:close() Lua API on modified sprites (fix #2142) 2019-08-30 17:17:58 -03:00