Łukasz Lenkiewicz
a1c8ed1409
MACTEXT: Fix clicking on links in helpmenu
...
Recent change replaced getRowCol in MacText::getMouseLink with getLineCharacter.
This commits reverts it because getLineCharacter counts lines by paragraph not
by rendered rows, which causes issues with clicking on links in help menu due to
long text in said menu.
2025-05-30 17:47:10 +08:00
Torbjörn Andersson
8c79b8e07f
MACGUI: Silence warnings
2025-05-10 22:06:29 +02:00
Scott Percival
b96a8dd703
MACGUI: Fix MacText::getMouse*
...
The output is expected to use line/character positioning instead of
row/column positioning; so if a line of text spans multiple rows, it
should be handled normally.
Fixes selecting inventory items after "Ptn of Random Teleport" in Derrat Sorcerum.
2025-05-09 06:18:28 +08:00
dasbidyendu
aec6e60066
JANITORIAL: Remove excessive vertical whitespaces
...
Remove unnecessary vertical whitespaces from code.
2025-04-25 18:32:49 +08:00
dasbidyendu
da1b772ca9
MACGUI: Null pointer and empty chunks tests in mactext , change cursor restoration issue in getmaxwidth.
...
- Check for null pointer before handling any operations in getChunkNum function.
- Check for empty chunks to avoid extra operations.
- avoid signed/unsigned issue in chunk position.
- avoid possible overflow in cursor restoration logic
2025-04-25 18:32:49 +08:00
D G Turner
c160631a5d
GRAPHICS: MACGUI: Fix Signed vs. Unsigned Comparison GCC Compiler Warnings
2025-04-19 13:56:26 +01:00
Scott Percival
1f99b81cf2
GRAPHICS: MACGUI: Fix getMouseChar and getMouseWord
2025-04-19 18:22:48 +08:00
Scott Percival
c79f84e787
GRAPHICS: MACGUI: Move scrollbar support into MacText
2025-04-19 18:22:48 +08:00
Scott Percival
2d58f99fd6
DIRECTOR: Overhaul TextCastMember
...
Include new properties/aliases introduced in D5, fixes crashes related
to incorrect casting to MacText.
2025-02-04 15:24:17 +01:00
Krish
a51e33f1de
GRAPHICS: MACGUl: Handle empty text in selection logic
...
Fixes crash in The Apartment version D4, movie "editableText"
./scummvm --start-movie=editableText theapartment4
2024-06-03 14:01:15 +02:00
Hubert Maier
9139412157
JANITORIAL: Fix refering typo in mactext.cpp
2024-05-18 13:52:31 +02:00
Cameron Cawley
248ab4ca15
GRAPHICS: MACGUI: Improve image quality in markdown documents
2024-05-09 15:19:17 +02:00
hecmar007
558167eaa2
MACGUI WAGE: Handle \n in end of string case
...
Add logic to correctly add new line when a \n is present at the end of a string.
2024-04-01 18:21:24 +02:00
Torbjörn Andersson
a1c8db3201
JANITORIAL: Clean up some whitespace and double semicolons
2024-01-29 19:32:00 +01:00
Scott Percival
0562ff567c
GRAPHICS: MACGUI: Move paragraph end marker when merging rows
...
Fixes issue where removing an empty line with backspace would remove the
previous empty line also.
2024-01-20 23:14:52 +01:00
Scott Percival
95b47042f0
GRAPHICS: MACGUI: Stop MacTextCanvas::chopChunk from removing last chunk
...
There needs to be at least one chunk per line of text, or else many
basic text operations will cause a crash.
2024-01-20 23:14:52 +01:00
Scott Percival
b9003c145f
GRAPHICS: MACGUI: Fix fgcolor conversion in MacText
2024-01-20 23:14:52 +01:00
Scott Percival
2f16bf2e9f
GRAPHICS: MACGUI: Remove pseudotransparency workaround in MacText
...
Needed in order to e.g. print white text on a black background in
Director.
This reverts 457b09cb4e
2024-01-20 23:14:52 +01:00
Le Philousophe
226de788c8
GRAPHICS: Make API use the Path class
2023-12-24 13:19:25 +01:00
Eugene Sandulenko
92b03145a2
GRAPHICS: MACGUI: Disable MacText with tables resizing
...
The problem is more complex than it appears, so, disabling this
before the release, because the current code is removing
tables on resize
2023-11-24 19:48:24 +01:00
Eugene Sandulenko
ff0abf2b69
GRAPHICS: MACGUI: Fix crashes when dealing with empty MacTexts
2023-11-16 00:23:09 +01:00
Eugene Sandulenko
ad5fe9f2bc
GRAPHICS: MACGUI: Factored out MacTextCanvas::setMaxWidth()
2023-10-30 01:14:29 +01:00
Eugene Sandulenko
3d237bccf1
GRAPHCS: MACGUI: Made MacText::setMaxWidth() use reshuffleParagraph()
...
This preserves all formatting
2023-10-30 01:08:40 +01:00
Eugene Sandulenko
526c116bbe
GRAPHICS: MACGUI: Break infinite loop triggered in some cases
...
Triggered in wage:afm on attempt to go to the shop
2023-10-30 00:40:21 +01:00
Eugene Sandulenko
867ec92bde
GRAPHICS: MACGUI: Removed superfluous warning
2023-10-27 01:14:52 +02:00
Eugene Sandulenko
67ab2657d8
GRAPHICS: MACGUI: Split out MacTextCanvas into a separate file
2023-10-24 02:38:17 +02:00
Eugene Sandulenko
37deafe413
GRAPHICS: MACGUI: Moved more methods to MacTextCanvas
2023-10-24 02:38:17 +02:00
Scott Percival
e44f40318e
GRAPHICS: MACGUI: Fix MacText::getMouseWord()/getMouseItem()
...
Fixes the text entry puzzles in Wrath of the Gods.
2023-10-22 17:19:54 +02:00
Eugene Sandulenko
d47d26547b
GRAPHICS: MACGUI: Reduced code duplication in MacText constructors
2023-10-22 09:18:32 -06:00
Eugene Sandulenko
0d40edb121
GRAPHICS: MACGUI: Renamed _bgcolor to _tbgcolor to avoid clashes with MacWidget
2023-10-19 22:28:37 -06:00
Eugene Sandulenko
9ee23562fd
GRAPHICS: MACGUI: Fix tail chunks in MacText
2023-10-19 22:28:37 -06:00
Eugene Sandulenko
4f15a3817a
GRAPHICS: MACGUI: Added more debug output to MacText rendering
2023-10-19 22:28:37 -06:00
Eugene Sandulenko
825fcda83c
GRAPHICS: MACGUI: Fix table parsing in MacText
2023-10-19 22:28:37 -06:00
Eugene Sandulenko
b859f7d013
GRAPHICS: MACGUI: Refactored more methods into MacTextCanvas
2023-10-19 22:28:37 -06:00
D G Turner
7ed7882640
GRAPHICS: MACGUI: Fix Signed vs. Unsigned GCC Compiler Warning
2023-10-15 19:13:07 +01:00
Eugene Sandulenko
c57bc10806
GRAPHICS: MACGUI: Fix crash when adding newline in MacText
...
The behaviour is now badly broken, but at least it will not crash
2023-10-14 17:29:02 -07:00
Eugene Sandulenko
f24f262877
GRAPHICS: MACGUI: Fix indented paragraph wrapping in MacText
...
Since the total width was miscalculated, we ended up with chopped words
2023-10-14 12:27:28 -07:00
Eugene Sandulenko
e8f008aaba
GRAPHICS: MACGUI: Fix indenting paragraphs in MacText
2023-10-14 12:27:28 -07:00
Eugene Sandulenko
93e393e943
GRAPHICS: MACGUI: Added more debug output to MacText
2023-10-14 01:54:05 +02:00
Eugene Sandulenko
0a32c7901c
GRAPHICS: MACGUI: Properly pass table cell alignment from Markdown to MacText
2023-10-14 01:54:05 +02:00
Eugene Sandulenko
bf851f574d
GRAPHICS: MACGUI: Fix table cell rendering in MacText
2023-10-14 01:54:04 +02:00
Eugene Sandulenko
8a2ebba04e
GRAPHICS: MACGUI: Properly compute table height in MacText
2023-10-14 01:54:04 +02:00
Eugene Sandulenko
9c17c1cb46
GRAPHICS: MACGUI: Fix compilation with debug output enabled in MacText
2023-10-13 00:14:48 +02:00
Eugene Sandulenko
ac388673e9
GRAPHICS: MACGUI: Fix table width computation in MacText
2023-10-10 23:23:39 +02:00
Eugene Sandulenko
fa3883c86e
GRAPHICS: MACGUI: Initial attempt to render tables in MacText
2023-10-10 01:45:36 +02:00
Eugene Sandulenko
4fba78c13d
GRAPHICS: MACGUI: Render table cells in MacText
2023-10-09 00:22:15 +02:00
Eugene Sandulenko
b2a7bad618
GRAPHICS: MACGUI: Moved more methods int MacTextCanvas
2023-10-09 00:22:15 +02:00
Eugene Sandulenko
6004d955ea
GRAPHICS: MACGUI: Moved several methods to MacTextCanvas
2023-10-09 00:22:15 +02:00
Eugene Sandulenko
74910523c3
GRAPHICS: MACGUI: Turned MacTextCanvas into a class
2023-10-09 00:22:15 +02:00
Eugene Sandulenko
b2fb4dcb3b
GRAPHUCS: MACGUI: Moved more variables to MacTextCanvas
2023-10-09 00:22:14 +02:00