The theme layout padding values are parsed and stored as 16 bit
signed integers. However ThemeLayout::setPadding treated the
values as 8 bit signed integeres.
The padding values parsed from the STX file suited for the screen
resolution are multiplied with the device content scale factor.
The scale factor determines how content is mapped from the logical
coordinate space (measured in points) to the device coordinate
space (measured in pixels).
If the scale factor and the padding value results in a value
greater than 255 it will wrap since the 8 bit type can't hold
bigger values than that.
Running the iOS backend in debug configuration on an iPhone 12
mini, having the content scale factor value 3, and drawing the
launcher in vertical mode where the bottom padding value is 92,
the result became 3 * 92 = 276 which would wrap to 20.
That resulted in incorrect layout where the GameList was too
high and the buttons in the bottom would not fit on the screen.
Change the input type to int16 in ThemeLayout::setPadding to
conform with the padding type used everywhere else.
The stream becomes owned by the Archive as soon as openStream()
is called, so freeing the Archive object also frees the stream.
Trying to delete it a second time will blow up.
GOG has not included the AdLib instruments file with their release of Simon the
Sorcerer 1 DOS version. The game would not start in ScummVM when this file was
missing and AdLib was selected. Added a fallback to the generic AdLib driver
with built-in instruments.
GOG has not included the AdLib instruments file with their release of Simon the
Sorcerer 2 DOS version. The game would not start in ScummVM when this file was
missing and AdLib was selected. Added a fallback to the generic AdLib driver
with built-in instruments.
Also made the Windows version start with AdLib if an OPL2-only emulator is used.
leading of a font is added to the height of the font when returning font
height, additionally the definition of leading says:
`Alternatively called line spacing, leading is the space between lines`
This fixes alignment of texts in `warlock-100` while also fixing the
line heights in `theapartment`.
This commit removes Mac Roman from plainByteMode(), this partially
reverts commit `9d4ac18be542eed5fdbb52519fd95ea7ac47a9e4` from
PR #3823, this change breaks Hebrew rendering in Pink.
Fixes rendering of texts in `theapartment` using MacRoman fonts.
This drops the _castArchive->hasResource() check that was placed
before loading 'FOND' resource type.
Fixes texts fonts for 'theapartment-4' where 'shared.dir' has
'DecoText' font in the resource-fork.
This patch fixes the alignment issue for multiline text in text castMember
it increases the line height of each line by one, this added change over
multiple lines result in fixed alignment. This patch also removes the height
reduction due to empty line (which cumulatively caused the alignment issue).
`DATA/SUPPORT/INTRODUCTION@111` of 'warlock-100' has this alignment issue
where the text "The Blaster" was above the button it was supposed to be.
Newer versions of Clang can tell us when UBSan has been enabled, which
is useful to define SCUMM_NEED_ALIGNMENT when -fsanitize=alignment is
in use (https://reviews.llvm.org/D52386).
Can be useful to avoid some false positives about alignment when doing
a build with UBSan but without using the "configure" script which
already tries to detect this setting.
See earlier commit 8a73f5d496.
This ensures that the surfaces mantain a format supported by Allegro,
and is required after commit b458ced:
"IMAGE: Speed up 16/24/32bpp BMP decoding"
to support 24bpp