sluicebox
2775987cba
MACGUI: Expose font families in MacFontManager
...
MacFontManager didn't have a mechanism to report which fonts it loaded
from an external resource. It also requires that any fonts that aren't
built-in be explicitly registered by name by the client before they can
be used. This combination meant that a client couldn't load fonts from
an external file and use them by their properties (id / size / style).
SCI contains Mac fonts in its executable along with a table that maps
each SCI font id to a Mac font id and size. The font name isn't a part
of this since the Classic Mac Toolbox API took id / size / style as
input when drawing text.
Now MacFontManager exposes the font families it has loaded along with
their names. This allows a client to see which fonts were loaded,
register them by name, and proceed to use them with the existing API.
2022-11-06 23:05:20 -08:00
Roland van Laar
b517ab6635
GRAPHICS: MACGUI: Fix memory leak in scaleFont
...
Free all surfaces after use.
2022-09-20 11:04:58 +02:00
Donovan Watteau
5b1ec56f96
JANITORIAL: Fix some lost or outdated URLs in comments
2022-05-19 07:57:31 +03:00
Eugene Sandulenko
abea37c9bb
ALL: Update ScummVM project license to GPLv3+
2021-12-26 18:48:43 +01:00
Orgad Shaneh
7a4e5612de
JANITORIAL: Replace new[]/memset with new[]()
...
Mostly done using the following Ruby script:
(Dir.glob('**/*.cpp') + Dir.glob('**/*.h')).each do |file|
s = File.read(file, encoding: 'iso8859-1')
t = s.gsub(/(([\w_.\[\]]+)\s*=\s*new\s+\S+?\[[^\]]+?\](?!\())([^\{\}]*?)\n\s+memset\(\s*\2\s*,\s*0\s*,[^;]*;/m, '\1()\3')
if t != s
File.open(file, 'w') { |io| io.write(t) }
end
end
2021-11-10 19:53:15 +01:00
Alexandre Detiste
6044504762
JANITORIAL: typos
...
some in the variable names, some in the comments;
no change for the strings that interract with original games assets
2021-10-31 20:46:31 +01:00
ysj1173886760
948604d79d
GRAPHICS: MACGUI: text length should not bigger than maxWidth - 1
2021-07-29 12:04:20 +08:00
ysj1173886760
a2d453a8f9
GRAPHICS: MACGUI: don't apply the kerning offset for the generated font
...
because we have already applied it when we are generating the font.
2021-07-26 20:55:49 +08:00
ysj1173886760
238971bc46
GRAPHICS: MACGUI: initialize slant of macFontfont.
2021-07-23 18:16:22 +08:00
ysj1173886760
7e2f3edc61
GRAPHICS: MACGUI: initialize bitImage to 0.
2021-07-23 17:06:38 +08:00
ysj1173886760
dc8418b547
GRAPHICS: MACGUI: implement shadow font.
2021-07-23 17:06:38 +08:00
ysj1173886760
1d7e82bf3e
GRAPHICS: MACGUI: amend makeOutline
2021-07-23 17:06:38 +08:00
ysj1173886760
cae8166101
GRAPHICS: MACGUI: organize the code for extension.
2021-07-23 17:06:38 +08:00
ysj1173886760
822ca12ab2
GRAPHICS: MACGUI: draw the underLine in kerning area when we are dealing with underLine font.
2021-07-23 17:06:38 +08:00
ysj1173886760
0aa7518c5b
GRAPHICS: MACGUI: set the kerning offset to 0 when dealing with underLined space.
2021-07-23 17:06:38 +08:00
ysj1173886760
6752b923b9
GRAPHICS: MACGUI: amend makeOutline in macFont.
2021-07-23 17:06:38 +08:00
ysj1173886760
e434198924
GRAPHICS: MACGUI: implement underline font.
2021-07-23 17:06:38 +08:00
ysj1173886760
3d0b7d5130
GRAPHICS: MACGUI: modify the parameter of scaleFont in macFont
2021-07-23 17:06:38 +08:00
ysj1173886760
4dd8e71fb9
GRAPHICS: MACGUI: fix outline style font.
2021-07-22 21:42:19 +08:00
ysj1173886760
e02911f283
GRAPHICS: MACGUI: add 1 to the width of outline font.
2021-07-22 21:42:19 +08:00
ysj1173886760
9ec4a2449e
GRAPHICS: MACGUI: using bitmapWidth to replace width when dealing with bitmap.
2021-07-22 21:42:19 +08:00
ysj1173886760
63b9ae3679
GRAPHICS: MACGUI: enhance italic font. Fix the implementation for generating slant fonts.
2021-07-22 21:42:19 +08:00
ysj1173886760
79755cfb02
GRAPHICS: MACGUI: implement basic italic supporting.
2021-07-22 21:42:18 +08:00
ysj1173886760
a319074c86
GRAPHICS: MACGUI: add kerning offset when drawing single char
2021-07-20 16:49:01 +08:00
ysj1173886760
296750d5de
GRAPHICS: MACGUI: implement reading styleWidths and glyph-width table for macfont
2021-07-20 16:49:01 +08:00
ysj1173886760
e24b22ed56
GRAPHICS: MACGUI: eliminate some TODO in load macFontFamily
2021-07-20 16:49:01 +08:00
Torbjörn Andersson
2fb992ed4e
GRAPHICS: Clip Mac font glyphs to the destination surface
...
This was probably causing instabilities in the MacVenture engine. The
engine is pretty broken at the moment, and the command window is so
small that text doesn't fit in it at all. Hopefully this will make the
remaining errors easier to debug... some day.
2021-04-04 10:23:20 +02:00
Eugene Sandulenko
b221999e1e
GRAPHICS: Allocate more memory on generating scaled Mac fonts
2020-08-17 00:50:56 +02:00
Eugene Sandulenko
a7f73321d5
GRAPHICS: Fix clash with Amiga #define
2020-04-29 00:01:30 +02:00
Eugene Sandulenko
80f1132e22
GRAPHICS: FONTS: Fix Mac outline font generation
2020-03-22 18:08:30 +01:00
Eugene Sandulenko
930cf4df03
GRAPHICS: Generate Mac outline fonts
2020-03-22 17:41:21 +01:00
Eugene Sandulenko
6774d7aced
GRAPHICS: MACGUI: Initial code for generating outlined fonts
2020-03-22 01:39:29 +01:00
Eugene Sandulenko
da8bfeca5e
GRAPHICS: FONTS: Improved visuals for generated bold fonts
2020-01-07 22:46:24 +01:00
Eugene Sandulenko
858f8791ec
GRAPHICS: FONTS: Fix memory override
2020-01-07 22:09:59 +01:00
Eugene Sandulenko
a98d3832d9
GRAPHICS: FONTS: Fix warnings
2020-01-07 22:00:23 +01:00
Eugene Sandulenko
fc00b78a48
GRAPHICS: FONTS: Implement generation of bold fonts
2020-01-07 21:57:12 +01:00
Eugene Sandulenko
b5a95d4783
GRAPHICS: FONTS: Made scaling form MacFONT as a step
2020-01-07 21:57:12 +01:00
Eugene Sandulenko
90c305c904
GRAPHICS: FONTS: Use better algorithm for MacFONT scaling added debug output
2020-01-07 21:57:12 +01:00
Eugene Sandulenko
40cb3b8f92
GRAPHICS: FONT: Really fix mismatched new/delete
2019-12-26 17:31:42 +01:00
Eugene Sandulenko
043acc1ccc
GRAPHICS: FONTS: Fix mismatched new/delete.
2019-12-26 17:25:31 +01:00
Eugene Sandulenko
bfb757c3c0
GRAPHICS: Load Mac font heights too (still unused)
2017-08-01 10:42:21 +02:00
Eugene Sandulenko
7808005841
JANITORIAL: Cleanup
2017-01-27 10:22:23 +01:00
Eugene Sandulenko
d99036a480
GRAPHICS: More fixes to MacFont scaling. Now it does work
2017-01-26 18:45:24 +01:00
Eugene Sandulenko
f7ada97cf8
GRAPHICS: Fixes to MacFont scaling
2017-01-26 18:08:03 +01:00
Eugene Sandulenko
e2b1cd5c80
GRAPHICS: Implemented test for MacFont scaling
2017-01-25 12:44:24 +01:00
Eugene Sandulenko
b84ab35363
GRAPHICS: Plug MacFont scaler in
2017-01-24 23:33:59 +01:00
Eugene Sandulenko
41e93fca16
GRAPHICS: Further work on MacFont scaling
2017-01-24 23:21:29 +01:00
Eugene Sandulenko
7396965005
GRAPHICS: Fix number of memory leaks and wanrings
2017-01-23 20:27:00 +01:00
Eugene Sandulenko
8a476715f6
GRAPHICS: More work on MacFont scaling
2017-01-21 23:46:21 +01:00
Eugene Sandulenko
76cfde0722
GRAPHICS: Further work on MacFont font scaling
2017-01-20 09:01:01 +01:00