Commit Graph

3286 Commits

Author SHA1 Message Date
David Capello
b5b59dece4 Add ability to clear colors from ColorBar 2015-05-10 19:19:48 -03:00
David Capello
c1324d196e Fix ColorBar::onCanPaste() to return true when we can still paste colors 2015-05-09 20:27:40 -03:00
David Capello
f395a0c768 Disable data recovery on trial mode 2015-05-09 20:18:10 -03:00
David Capello
2bbaa45844 Unify Cut/Copy/Paste/Clear handling with InputChain class 2015-05-09 19:55:33 -03:00
David Capello
e60236640a Destroy ColorMap remap information when Undo/Redo is executed 2015-05-09 16:18:27 -03:00
David Capello
11d86bb7c5 Add ability to copy colors using Ctrl + drag & drop 2015-05-09 15:57:46 -03:00
David Capello
cea0970d9d Fix several bugs with tooltip arrows/location
The tooltip arrow is now aligned to the target. And the tooltip is
relocated to the other side if it intersects its target bounds.
2015-05-09 13:20:57 -03:00
David Capello
06d1929729 Remove background color as an option in "New File" 2015-05-09 12:46:07 -03:00
David Capello
352eff2fd6 Add tooltips to ColorBar buttons 2015-05-09 12:30:05 -03:00
David Capello
62a3594598 Add ability to copy & paste colors with Ctrl+C and Ctrl+V
This commit includes the new doc::PalettePicks class. It's a helper
class to identify which entries are selected in the ColorBar.

We've removed the Copy/Paste buttons from the Palette Editor window.
2015-05-09 12:20:58 -03:00
David Capello
feb592db73 Remove Ramp and Quantize buttons from PaletteEntryEditor
These actions are now in the options above the ColorBar.
2015-05-08 17:37:41 -03:00
David Capello
1ef1f9e3e7 Add option for color quantization in the ColorBar options popup 2015-05-08 17:34:51 -03:00
David Capello
2995190d00 Fix crash making palette entries too small using scroll wheel 2015-05-08 17:00:44 -03:00
David Capello
ca1ebf02b5 Add option to create color gradients in the ColorBar 2015-05-08 16:55:08 -03:00
David Capello
5f46ffc5e0 Change position of "Remap" button so it's more noticeable 2015-05-08 16:17:42 -03:00
David Capello
d31f83e098 Add option to load/save default palette preset (fix #626)
Now the default palette is saved in the user configuration
directory, so we can set any palette as the default (it doesn't
matter if it's related or not to a file, it will be copied into
the user directory anyway).
2015-05-08 16:08:55 -03:00
David Capello
d3dbc11451 Add options to change palette entry size 2015-05-08 14:59:52 -03:00
David Capello
5437ccd2a2 Move palette menu to color bar options button 2015-05-08 14:36:54 -03:00
David Capello
6a9382a975 Add option to reverse colors 2015-05-08 14:28:27 -03:00
David Capello
575e94e559 Add popup menu to sort palette colors 2015-05-08 13:03:06 -03:00
David Capello
dab8c96fa8 Fix bug getting ANSI clipboard text on Windows
Sometimes the clipboard content is in CF_TEXT format and there is
no implicit CF_UNICODETEXT conversion.
2015-05-07 22:56:02 -03:00
David Capello
bea61fab88 subpixelPos can be in [-1,0] range when we zoom outside sprite bounds 2015-05-07 21:50:15 -03:00
David Capello
146460ea1b Merge branch 'master' of git@github.com:aseprite/aseprite.git 2015-05-07 19:19:46 -03:00
David Capello
804330788b Add right-click popup menu in play buttons to change animation speed (fix #595) 2015-05-07 19:08:24 -03:00
David Capello
0bd85f93a5 Merge pull request #666 from agateau/build-fixes
Fix build with g++ 4.9
2015-05-07 18:56:16 -03:00
Aurélien Gâteau
2855180dd9 Fix build with g++ 4.9 2015-05-07 22:59:10 +02:00
David Capello
ee3d4ca63c Improve zoom movement using a "subpixel" factor
This factor indicates exactly where the mouse is inside the zoomed pixel,
and uses it to locate the new zoom with the same factor (if it's possible).
2015-05-07 17:23:44 -03:00
David Capello
11929dfd60 Fix the mouse position in scroll wheel events from she layer 2015-05-07 17:21:37 -03:00
David Capello
b74727489d Fix limiting splitter position when it's hidden (with no bounds) 2015-05-07 15:59:29 -03:00
David Capello
97609b6504 Add option to change the zoom behavior with keys 2015-05-07 15:56:38 -03:00
David Capello
b2955d58ad Add option to change the zoom behavior with scroll wheel 2015-05-07 15:52:26 -03:00
David Capello
3d29adcbdf Fix zoom behavior when the zoom is changed from the center 2015-05-07 15:13:26 -03:00
David Capello
bfaf8a5921 Add ability to change the Preview zoom using 1...6 keys above the Preview 2015-05-07 14:43:33 -03:00
David Capello
35c8cc893b Add some help text in ContextBar when SelectBoxState is running 2015-05-07 13:11:44 -03:00
David Capello
18b067ee77 Add ContextBar::updateForCurrentTool() which is a common thing to do 2015-05-07 12:32:08 -03:00
David Capello
e398a1f21f Allow any size of boundaries for brushes
As now the eraser must show the boundaries of custom brushes, the fixed
maximum limit we were using (MAX_SAVED) for boundaries is not enough.
So now we use a std::vector for saved pixels.
2015-05-07 12:18:58 -03:00
David Capello
c90677333b Show current brush bounds for eraser tool (even for custom brushes) 2015-05-07 12:10:04 -03:00
David Capello
7b1b667a8a Fix problem resizing splitters with pixel-based position outside its own bounds (fix #663) 2015-05-07 11:40:39 -03:00
David Capello
cc2a5e8cc5 Pressing two times BrushTypeField was making its popup always visible
There was an ugly combination of events:
1. When ContextBar::BrushTypeField receives an onItemChange is because the
   mouse button is pressed on it (a kMouseDownMessage)
2. It shows the BrushPopup window (which is a PopupWindow
   with kCloseOnClickInOtherWindow click behavior)
3. When other click is made in BrushTypeField, the BrushPopup is closed
   because it is filtering messages (since it's
   kCloseOnClickInOtherWindow). This generates a kCloseMessage in the
   queue.
4. BrushTypeField::onItemChange() is executed again (for the same
   click in point 3), and it checks that the popup is closed (recently
   closed, by this click), so it shows the BrushPopup again.
5. The enqueued kCloseMessage is receved by PopupWindow, and it calls
   stopFilteringMessages().

So in this case we have a visible PopupWindow that is not filtering
messages. To fix this bug we have included a startFilteringMessages()
in kOpenMessage. So when the popup is shown again, it filters messages
and the popup cannot stay visible.
2015-05-06 19:58:41 -03:00
David Capello
f7465771b0 Add Ctrl+A (or Cmd+A) to select the whole text in ui::Entry 2015-05-06 18:11:29 -03:00
David Capello
24c3c3e3a3 Add '=' key has alternative to '+' (as in US keyboards plus sign is Shift+'=') 2015-05-06 18:02:59 -03:00
David Capello
9f39f4384c Add a menu option to lock/unlock each brush
This is an alternative to lock brushes using its keyboard shortcut.
2015-05-06 17:39:40 -03:00
David Capello
9dfd5ae0d3 Fix conflict between two classes named app::Item (in brush_popup.cpp and data_recovery_view.cpp)
This conflict was generating a crash when the "Recover Lost Sprites"
button was pressed.
2015-05-06 17:23:43 -03:00
David Capello
cb5fd3963f Fix problem where the cel opacity slider in StatusBar was not activated
After creating a new cel from a tool loop, we have to generate an
ActiveSiteChange notification (because now we have a cel in the active
position). In this way the StatusBar can update/enable the opacity slider.
2015-05-06 17:08:08 -03:00
David Capello
c6c7439566 Close autocomplete popup when we change the active folder in FileSelector 2015-05-06 16:58:32 -03:00
David Capello
05fb32bb84 Fix navigation keys for OS X and Windows
On OS X we can use Cmd+[ or Cmd+] to navigate the history. And Cmd+Up/Down
to go to the enclosing folder, or enter in a folder respectively.

On Windows we can use Alt+Left/Right to navigate the history. And Alt+Up
to go to the enclosing folder. (Alt+Down is an extra shortcut to enter
in the folder).
2015-05-06 16:47:43 -03:00
David Capello
4e911b7eea Esc key close the combobox popup 2015-05-06 16:27:45 -03:00
David Capello
a30f374bd5 Don't popup an empty listbox if the combobox is editable and has open-on-click style 2015-05-06 13:07:54 -03:00
David Capello
a0ea3ae07b Fix bug trying to remove one keyboard shortcut when other is removed instead
We've to regenerate all buttons that modify a specific keyboard shortcut
because they are listening the Click signal with the specific index of
the that shortcut. The index is given as parameter to the Signal connect()
function.

We've converted all buttons to shared pointers to simplify the code.
2015-05-06 12:13:35 -03:00
David Capello
decaa6510f Add TODO comment for SkinParts enum 2015-05-06 10:53:01 -03:00