Commit Graph

3320 Commits

Author SHA1 Message Date
David Capello
f766763a92 Add CLA-signing step in CONTRIBUTING file 2015-05-04 15:18:15 -03:00
David Capello
116f0a760e Merge branch 'master' of git@github.com:aseprite/aseprite.git 2015-05-04 14:58:38 -03:00
David Capello
139e0cb8f5 Fix issues autocompleting the file name field in FileSelector
Now the file name field is an editable ComboBox, so we don't
autocomplete/modify the text inside the entry box.

With this commit we modified the editable ComboBox behavior too:
* When the ListBox is shown, the focus remain in the Entry field (now
  the ListBox cannot have the focus when the ComboBox is editable).
* When Up/down keys are received by the Entry, they are given to the
  ListBox to change the selected item. But the focus returns to the
  Entry anyway.
2015-05-04 14:58:24 -03:00
David Capello
ca3fade50d Don't call focusFirstChild() if the Window doesn't want the focus 2015-05-04 12:50:04 -03:00
David Capello
9528cae9db Merge pull request #656 from blackmiaool/fix_new_brush
Fix crash using NewBrush when Home tab is selected
2015-05-04 11:57:26 -03:00
David Capello
6f8603bcb1 Merge pull request #655 from blackmiaool/fix_palette
Show checkbox in Palette > Palette Editor
2015-05-04 11:47:40 -03:00
David Capello
8a2b1d46a1 Merge pull request #653 from blackmiaool/master
Select Home tab when it's not selected in HomeCommand
2015-05-04 11:47:24 -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
blackmiaool
00b45c3bd7 Fix crash using NewBrush when Home tab is selected 2015-05-04 22:38:15 +08:00
David Capello
883629b563 Fix bug triggering global keyboard shortcuts when a combobox popup is open
When a combobox popup is open, it creates a new non-foreground top window
(which is sibling of the window where the combobox widget is). When the
popup receives a key press, and it doesn't use it, the key is passed to
its parent (a ui::Manager), and then the latter has to process it.

Before this commit, CustomizedGuiManager::onProcessMessage() was
filtering shortcuts for foreground window, but it was working only
when the key was pressed in the foreground window itself (not when a
combination of foreground and background windows were open). Now the
filter is done in Manager::onProcessMessage() (which returns true,
i.e. key was used, for every pressed key when a foreground window
is found in its children hierarchy).
2015-05-04 11:25:42 -03:00
David Capello
ac8387a408 Move some ui::Combobox member functions to the header file 2015-05-04 10:41:05 -03:00
David Capello
c219e4dc07 Minor format change in ui/widget.cpp 2015-05-04 10:40:23 -03:00
blackmiaool
1d98f51197 Show checkbox in Palette > Palette Editor menu item when the Palette Editor is visible 2015-05-04 13:02:58 +08:00
blackmiaool
b2257752b3 Select Home tab when it's not selected in HomeCommand 2015-05-04 10:33:33 +08:00
David Capello
9bf11e0b40 Merge pull request #648 from blackmiaool/patch-2
Show checkbox in View > Timeline menu item when the Timeline is visible
2015-05-02 10:35:33 -03:00
blackmiaool
ffab635acd add override
add onChecked() function to Timeline command
2015-05-02 20:51:49 +08:00
blackmiaool
e646ee7047 add onChecked() function to Timeline command 2015-05-02 17:28:22 +08:00
David Capello
a49a36d7e1 Change Command::short_name() to id() (and from const char* to std::string) 2015-05-01 19:41:18 -03:00
David Capello
82bcc090c0 Stop animation with right-click 2015-04-30 19:54:30 -03:00
David Capello
b8a319ed6b Stop the animation when a command is executed and the Editor is in PlayState
This is to restore an old behavior were the animation was stopped pressing
other keys (e.g. arrow keys to move to another frame or layer).
2015-04-30 19:44:20 -03:00
David Capello
20120f432a Fix crash trying to move an empty cel with Move tool 2015-04-30 17:26:46 -03:00
David Capello
91bacca270 Fix bug introduced in a2cbf3f285: trim transparent layers correctly 2015-04-30 17:04:11 -03:00
David Capello
b519901cef Add support to specify tags in --filename-format option (related to #607)
Now we can use "{tag}" (or "{innertag}") and "{outertag}" in the filename
format.
2015-04-30 17:02:57 -03:00
David Capello
c81aa88fc7 Add --format option to specify JSON array format (fix #641) 2015-04-30 12:33:32 -03:00
David Capello
90dd876654 Merge branch 'agateau-build-fixes' 2015-04-30 12:30:52 -03:00
David Capello
35e951ec70 Merge branch 'build-fixes' of https://github.com/agateau/aseprite into agateau-build-fixes 2015-04-30 12:03:29 -03:00
David Capello
88a0e8c806 Merge branch 'brush' 2015-04-30 12:00:49 -03:00
David Capello
f1d522f548 Replace brush slots until the user presses the shortcut
We replace brush slots until the user presses its keyboard shortcut, which
means he is interested in reusing the brush. In this way, if we want to
keep a brush, we can press Ctrl+B, select the brush area, and then Alt+1
to keep the first brush, then the next brush slot will be used/replaced
until Alt+2 is pressed, etc.
2015-04-30 11:59:47 -03:00
David Capello
03faee9ce4 Add option to delete all brushes 2015-04-29 17:26:25 -03:00
David Capello
733d0a8e74 Minor fix in ButtonSet 2015-04-29 17:16:48 -03:00
David Capello
562df34f40 Show brushes in a ButtonSet with 3 columns 2015-04-29 17:16:43 -03:00
David Capello
f5b7fd84dc Connect to BrushPopup::BrushChange just one time 2015-04-29 16:34:21 -03:00
David Capello
2932add184 Fix BrushInkProcessing so we can use brushes between different pixel formats 2015-04-29 16:04:57 -03:00
David Capello
c5e79bb940 Optimize CompressedImage to get only bitmap information
When we create a CompressedImage from a Brush image, we want to know what
pixels are != the mask color, just to generate the PointShape (we don't
care the specific color of the scaneline/each pixel, that information is
used in the "ink processing" step).
2015-04-29 15:43:52 -03:00
David Capello
57156bddb7 Remove unused param 2015-04-29 15:00:17 -03:00
David Capello
edbff42dc8 We can delete brushes right-clicking them and selecting "Delete" 2015-04-29 15:00:05 -03:00
David Capello
1b25c4e9e9 Add slots in the ContextBar to select brushes with Alt+1, Alt+2, etc.
Now the ContextBar contains a set of brushes. The ChangeBrushCommand
supports a new "slot" parameter and "change" = "custom" to select a
specific custom brush from the ContextBar. Alt+1, Alt+2, etc. are mapped
to this ChangeBrushCommand (see changes in gui.xml).

Also, as the ButtonSet that represent different brushes in the ContextBar
uses icons generated from the brush, we don't need the skin parts that
represent each brush type (we can generate those icons from some standard
brushes). Those skin parts were removed.
2015-04-29 12:32:44 -03:00
David Capello
b08b226aef Move active brush information to ContextBar 2015-04-28 18:21:33 -03:00
David Capello
303bd120dc Keep one instance of BrushPopup in memory 2015-04-28 12:53:02 -03:00
David Capello
058682bcaa Avoid creating consecutive SelectBoxStates with Ctrl+B
If we press several times Ctrl+B, we could create several SelectBoxStates,
and as it backs to the previous state, it's like we will select several
brushes instead of backing to the original state.
2015-04-28 12:46:50 -03:00
David Capello
f09db4d9aa Add new BrushPopup (now the image brush is previewed)
This is the first step to create a bigger BrushPopup to select brushes
from an history of brushes. The general idea is to use Alt+1, Alt+2, etc.
to select different brushes from a stock.

Also the "discard brush" was removed. As the brush can be discarded
changing the brush type.
2015-04-28 12:38:15 -03:00
David Capello
274b903aad We can cancel the selection of the brush using the other mouse button 2015-04-27 15:28:17 -03:00
Aurélien Gâteau
ad1290b1c8 Fix build of document_api_test.cpp
Compiler could not find notifyActiveDocumentChanged.

/home/aurelien/src/aseprite/src/./doc/test_context.h: In instantiation of ‘void doc::TestContextT<Base>::onRemoveDocument(doc::Document*) [with Base = app::Context]’:
/home/aurelien/src/aseprite/src/app/document_api_tests.cpp:66:1:   required from here
/home/aurelien/src/aseprite/src/./doc/test_context.h:44:58: error: ‘notifyActiveDocumentChanged’ was not declared in this scope, and no declarations were found by argument-dependent lookup at the point of instantiation [-fpermissive]
         notifyActiveDocumentChanged(m_activeDoc = nullptr);
2015-04-27 18:08:21 +02:00
David Capello
8f500178fc Creating a brush with right-click clear the selected region with bg color (#154) 2015-04-27 13:03:02 -03:00
Aurélien Gâteau
db8f0e1f0d Fix aseprite binary link error
Was getting this when linking aseprite:

check_update.cpp:113: undefined reference to
net::HttpHeaders::setHeader(std::string const&, std::string const&)
2015-04-27 17:59:42 +02:00
David Capello
73fa7b2107 Define CURL_STATICLIB if we don't use libcurl shared version (might be related to #640)
This problem was introduced in d7bf504887
2015-04-27 12:23:54 -03:00
David Capello
51b6def023 Remove the "New Brush" button from the ContextBar 2015-04-27 12:07:23 -03:00
David Capello
955383f91a Add xor-ed bounding box in SelectBoxState when QUICKBOX style is enabled
This is useful when we want to select a brush in a black image (the
DARKOUTSIDE style is not useful in this case).
2015-04-27 12:03:18 -03:00
David Capello
96769d061e Rename BrushPattern::ALIGNED_FROM_SRC to ALIGNED_TO_SRC 2015-04-27 11:45:00 -03:00
David Capello
d9fb81e5d1 Now we can create brushes selecting the box directly (fix #154) 2015-04-27 11:31:48 -03:00