On WinXP classic theme we receive a WM_NCHITTEST messages for the
scrollbars, and as they overlap the resize borders (see WM_NCCALCSIZE
handler) we have to return a proper value as if they really were the
borders of the window.
Note: Scrollbars are still visible in classic theme, that is just ugly,
but at least the user can resize the window from bottom and right edges.
This is an huge refactor to avoid handling Allegro FONT directly. Some
changes:
* Add she::System::defaultDisplay/Font, createRgbaSurface, loadSurface,
and loadRgbaSurface.
* Rename she::CreateSystem/Instance to she::create_system/instance.
* Remove ui/font.cpp and move ui/fontbmp.cpp to she library.
* ui::IButtonIcon uses she::Surface instead of BITMAP.
* Rename she::LockedSurface::drawAlphaSurface -> drawRgbaSurface
* Rename ui::SetDisplay -> set_display
* Rename _ji_font_text_len -> ui::Graphics::measureUIStringLength
If the transparent/mask color has alpha = 0, we cannot filter by
RGB/Grayscale values, we have to blend all colors anyway. Only when
the mask has alpha > 0 we can check if the RGB values are different to
the mask RGB values. In other words, comparing the source color with the
mask, makes sense only when the mask has alpha > 0.
The new default location is %AppData%/Aseprite folder. This will be useful
for a future setup program. So if aseprite.ini is located in aseprite.exe
directory, it acts like a portable program, in other case it acts like
an installed program.
When we create a new image for the sprite, we've to adjust the image mask
color to the sprite mask color (as the image isn't in the Stock yet).
This problem appears in v1.0.1 (9dfec919e4)
because now we don't change the mask color of sprite images in the
rendering process. This kind of bug can be detected running on debug
mode with an assert in the render procedure.
This bug is because the mask color of cel images were fixed when they
were used in the rendering process. Now, the mask color is fixed when the
image is added to the raster::Stock structure.