Before this fix, when the Sprite Size dialog was opened using the
Ctrl+Alt+I key combination, then closed, the brush size changed as the
cursor moved (without even pressing Ctrl+Alt modifiers), keeping the
DraggingValueState alive.
These actions weren't working correctly because we have to take
special care when we change the tool group, i.e. the "initial
position" used to calculate the delta from "mouse pos - initial pos"
must be updated to reset the delta to change tools inside the same
tool (this is the new m_initialPosSameGroup member variable).
This is a patch, but we don't know why this can happen, so it's highly
probable that other kind of crashes might appear in the near
future (or this doesn't fix the original bug).
Regression in dd0c29620974e56d9e62653804b996740a89e88a (Use
tooltip_text style & color to paint tooltip windows #2554).
Prior this fix, text box does not update its bounds area because it
has not a style assigned.
Fix#3442, fix#3443
It looks like processing a specific kPaintMessage with
ui::Widget::sendMessage() might re-create the os::Surface and destroy
the previous one, so we need to keep a reference to the previous
surface just in case to keep it alive.
We aren't able to reproduce this crash, but we've received several
Sentry reports about it, only on Windows and since v1.2.34.1 (not sure
if it's related to that). We'll see if this does fix the crashes or we
have some kind of regression in the future.
The width/height of a reference layer cel cannot be < 1.0, but in the
extreme case where this happens, Ctrl+clicking the reference layer
shouldn't crash the program.
This was changed in df33744c85833d4f9042871dd9b417c2f2b8654e, but now
we're adding an option to switch between both behaviors. We prefer to
keep the old behavior as the default one and the new one as an
optional preference.
Related to: https://community.aseprite.org/t/15065
The tooltip_face style is not used in the beta version anymore, so
the problem in 504fb7b7f8d2e713664eb133ecdef873af2c469a is not present
in beta branch.
Fix crash reported on v1.2.36/v1.3-beta17, ctx->activeDocument() can
be nullptr.
This reverts commit 1f5e4cfc4f03c835010100c6011b220270b53dbe to fix#3431
* Removed conversion from RGB -> HSV/HSL for each pixel (we just pass
the HSV/HSL values directly to the shader). In this way we don't
lost some hue information for some special cases like white/black
colors (probably related to: https://community.aseprite.org/t/14904)
* Now Tint/Shade/Tone selector changes the aspect of the Hue slider
depending on the current saturation/value (this was changed in the
non-shader version too)
SpriteEvents can be re-created just when we're closing the sprite if
we access Sprite.events property in app 'sitechange' event. When this
second instance of SpriteEvents is deleted after the sprite was
closed, the document cannot be found (as it was already destroyed).
Associated test:
02a2f1f933
As app 'sitechange' event is generated when we close a sprite,
accessing Sprite.events on that event will re-create the
app::script::SpriteEvents instance associated with the sprite.
* Remove "%3d" for integers (just use "%d"), this is a legacy format
when the text was a monospace font (it was present from the very
beginning of the times, when we used the Allegro font)
* New :delta: icon (before :offset: which didn't exist in the theme)
* Show useful info for MovingCelState: mainly cel bounds
This is to show the brush image with the new fg color in the brush
popup instead of the original image when image colors shouldn't be
preserved for that specific slot.
Prior to this fix, moving a marquee selection while holding down the Ctrl key outside the left/top area of the canvas results in a 1px distortion of the marquee image. This distortion is due to a false transformation when it is required to get the corner bounds, due to rounding the float coordinates towards 0 instead of the nearest left/top integer. The discrepancy occurs within the `getDraggedImageCopy`, `redrawExtraImage`, `drawImage` and `drawMask` functions.
Before the fix the conversion from RGB to INDEXED color mode, in
transparent layers, always picked index 0 as transparent color, even
if the mask color was present in the palette.