* As we moved the VERSION macro to a .c file, we don't have to
recompile the whole project when we change the version number.
* Removed the version number from gui.xml
* Removed the invalid first menu item that might appear in the root
menu when the gui.xml version is outdated in debug mode.
If ContextWriter thrown an exception (i.e. we cannot lock the sprite
for writing purposes), the "Mask by Color" ui::Window would persist
with its signal slots, and it creates an unstable scenario where color
change signals are generated from sliders and crashes the program
because we were using a deleted ContextReader variable which was
stored in the stack in MaskByColorCommand::onExecute().
This fix solves u,v set calculation when 'image brush' are used.
The cause of this bug is that we considered the set m_u, m_v as constants.
We have several cases when we are working on X axis:
- Scanline entirely contained in a tile, but OUTSIDE of the reference tile.
- Scanline entirely contained in a tile, but INSIDE of the reference tile.
- The left side of a scanline which was sliced (by the tile limit).
- The right side of a scanline which was sliced (by the tile limit).
Each one has its own m_u, so we need to recalculate it before every loop->getInk()->inkHline(...).
We have to take similar considerations when we are working in the Y axis.
We need recalculate m_v according if 'y+scanline.y' is INSIDE or OUTSIDE of the reference tile, each case has its own m_v.
Bug reports:
* https://community.aseprite.org/t/1183
* https://community.aseprite.org/t/4695
Here we avoid two ExpandCelCanvas at the same time with
MovingPixelsState + DrawingState. Double-clicking inside the selection
when we are moving it (MovingPixelsState) could start a new
DrawingState which creates a new ToolLoopImpl that needs a new
ExpandCelCanvas. So we have to drop the pixels before.
If we use two sprites with different canvas sizes, and both sprites
have a similar cel, they can share the inTextureBounds, but not the
original size (which is the original sprite canvas size of each cel).
This can be reproduced using the CLI and creating a texture
atlas (-sheet) with two or more sprites.