Commit Graph
119 Commits
Author SHA1 Message Date
Eugene Sandulenko 5719847354 GRAPHICS: MACGUI: Pass setMarkdownText through MacTextWindow 2023-09-17 00:56:28 +02:00
Harishankar Kumar 442c1a5d41 DIRECTOR: Implement events for scroll type text cast
This patch implements events for scrolltype text cast members, callbacks
in MacTextWindow is used to redirect events to director engine.

`ATD\HD\bbTWRFL2.DXR@392` of 'totaldistortion-win' uses `mouseUp` score
script attached to scrolltype text cast member, which when clicked calls
`getMouseLine` to find the clicked book, thus opening it.
2023-08-03 09:49:20 +02:00
Harishankar Kumar 14c6939a9c GRAPHICS: MACGUI: Execute window _callback in MacTextWindow
This patch ensures that the `_callback` function is executed in the
MacTextWindow class.
2023-08-03 09:49:20 +02:00
Harishankar Kumar f3a6c27df6 GRAPHICS: MACGUI: Add no-border scrollbar, Win95 Border Refactored
Win95 scrollbar loading is refactored to use existing `borders` array
in `datafiles.cpp`, Added no-border scrollbar for MacOS, Win95.

This is to support scrollable text cast members in Director, which
will be used by `totaldistortion-win` game.
--start-movie="ATD\HD\bbTWRFL2.DXR@392" totaldistortion-win
2023-08-03 09:49:20 +02:00
Harishankar Kumar 23f1229e67 GRAPHICS: MACGUI: Refactor resize() to extract inner window resizing
resize function is extracted to new function resize and resizeInner,
also a new private function rebuildSurface is created to handle common
code of refreshing/rebuilding surface after modifying inner or outer
window dimensions.
2023-05-31 13:29:33 +02:00
Avijeet dc52ccaec9 GRAPHICS: MACGUI: Enable blinking cursor on input line 2022-08-05 20:15:03 +02:00
Avijeet d933b504ed GRAPHICS: MACGUI: Change MacText's dimensions when MacTextWindow's dimensions are changed 2022-08-05 20:15:03 +02:00
Avijeet 007cc0a5c0 GRAPHICS: MACGUI: Scroll MacText whenever MacTextWindow is scrolled 2022-08-05 20:15:03 +02:00
Avijeet dfed81dfff COMMON: MACGUI: Fix MacTextWindow scrolling 2022-06-30 22:43:06 +02:00
Eugene Sandulenko abea37c9bb ALL: Update ScummVM project license to GPLv3+ 2021-12-26 18:48:43 +01:00
ysj1173886760 83615f0d86 GRAPHICS: MACGUI: fix text display issue in mactextwindow. 2021-09-06 20:58:53 +08:00
djsrv 5bc3ad06c0 GRAPHICS: MACGUI: Move encoding tracking to MacFontRun
Font is basically the only way to determine a piece of text's encoding
in Director. Since MacFontRun tracks fonts, it's the nicest place to
handle encoding too.
2021-07-12 00:38:05 -04:00
Le Philousophe 25426c0a80 MACGUI: Fix int/int32 build failures
All of this is because Rect and Surface have moved to int32
2021-07-05 23:54:34 +02:00
ysj1173886760 e7e09e6bee GRAPHICS: MACGUI: make mactextwindow suit for new WM clipboard 2021-06-03 13:19:10 +02:00
ysj1173886760 f89977b4a2 GRAPHICS: MACGUI: fix and add the basic text operations in mactextwindow which is used in WAGE 2021-06-03 13:19:10 +02:00
Eugene Sandulenko 6e17562492 GUI: MACGUI: Make MacTextWindow working with plain fonts 2021-05-02 01:03:02 +02:00
ysj1173886760 9c9b553d7a GRAPHICS: MACGUI: fix the logic when calc the coordinate of scrollbar 2021-04-25 02:24:15 +02:00
ysj1173886760 fb7ed6f845 GRAPHICS: MACGUI: add textRGB for mactextwindow to suit new logic of mactext when drawing the text with color. add window feature DynamicScrollbar 2021-04-25 02:24:15 +02:00
ysj1173886760 98cb026f70 GRAPHICS: MACGUI: fix the behaviour when we enable win95 mode when drawing scrollbar 2021-04-25 02:24:15 +02:00
ysj1173886760 c317ca1900 GRAPHICS: MACGUI: load win95scrollbar border as default when enable win95 mode 2021-04-25 02:24:15 +02:00
ysj1173886760 fc702ea9fe GRAPHICS: MACGUI: re-organize the code for drawing scrollbar for macwindow 2021-04-25 02:24:15 +02:00
ysj1173886760 d437b22b6b GRAPHICS: MACGUI: fix the behaviour of scrollbar of win95 mode 2021-04-25 02:24:15 +02:00
ysj1173886760 b993ab021d GRAPHICS: MACGUI: fix the algorithm when we calc the coordinate of scrollbar, modify the offsets 2021-04-25 02:24:15 +02:00
ysj1173886760 fa4aaa7608 GRAPHICS: MACGUI: modify the offset when drawing the mactext to suit for pink 2021-04-25 02:24:15 +02:00
ysj1173886760 7ef3b88a94 GRAPHICS: MACGUI: save background color for mactextwindow, add new behaviour for win95 mode 2021-04-25 02:24:15 +02:00
ysj1173886760 0dcde7c96a GRAPHICS: MACGUI: add new feature that when scroll wheel, the scroll bar will also display 2021-04-01 16:08:56 +02:00
ysj1173886760 aba96cb38f GRAPHICS: MACGUI: recalc the scrollSize and scrollPos, in order to fix scroll bar for mactextwindow 2021-04-01 16:08:56 +02:00
ysj1173886760 c5481d9c02 GRAPHICS: MACGUI: modify the logic of drawInput and appendText, in order to fix the bug of cursor dislocation and incorrectly drawing the input 2021-04-01 16:08:56 +02:00
ysj1173886760 db6a0fce54 GRAPHICS: MACGUI: fix the problem of incorrectly render the cursor and selected area 2021-03-27 13:05:31 +01:00
ysj1173886760 8e8219d0ea GRAPHICS: MACGUI: fix the bug when splitting a new line 2021-03-27 13:05:31 +01:00
ysj1173886760 6aea4cb68b GRAPHICS: MACGUI: fix the bug of MacTextWindow incorrectly drawing the surface 2021-03-27 13:05:31 +01:00
Cameron Cawley c877097b49 ALL: Remove use of "" in Common::U32String constructors 2020-11-16 16:56:58 +00:00
Vladimir Serbinenko 3fc822e55c COMMON: introduce substr for U32String (#2585)
It's safer than direct array manipulation. Replace current uses
of subsetting with substr.
2020-11-01 22:53:03 +01:00
djsrv 61cfbdc469 GRAPHICS: MACGUI: Add more colors as properties
Finding the closets color in the current palette is necessary for
transparency in bitmap borders to work.
2020-08-07 16:47:19 -04:00
Nathanael Gentry a7426c2872 GRAPHICS: MACGUI: Eliminate window composition surface
Now there is just the composeSurface from the widget. This fixes a bug where the
inner window contents would be blitted with transparency and also eliminates a
redundant copying. Now the border and inner surfaces are composed together on demand.
2020-07-21 14:48:27 -04:00
Eugene Sandulenko 927825f6ac GRAPHICS: MACGUI: Fix overridden method footprint 2020-07-07 12:17:18 +02:00
Eugene Sandulenko 430915ce00 GRAPHICS: MACGUI: Const'ness 2020-04-27 13:57:35 +02:00
Eugene Sandulenko 7a4d5f45e9 GRAPHICS: MACGUI: Renamed clashing methods 2020-04-25 13:44:18 +02:00
Eugene Sandulenko f382d0fd01 GRAPHICS: MACGUI: Clear cursor flag after redrawing 2020-04-25 00:57:22 +02:00
Eugene Sandulenko 2fb21ba90a GRAPHICS: MACGUI: Split drawing and blitting operations for widgets 2020-04-14 00:42:39 +02:00
Eugene Sandulenko 419cb1e7c7 GRAPHICS: MACGUI: Switched MacText to U32String internally 2019-10-18 17:20:27 +02:00
Eugene Sandulenko 695ba47063 GRAPHICS: MACGUI: Added possibility to create read only text windows 2019-10-15 23:58:00 +02:00
Filippos Karapetis 7346b69d88 GRAPHICS: Initialize potentially uninitialized variables 2019-05-27 14:53:46 +03:00
Paul Gilbert e232d024c5 GLK: Standardizing uint vs uint32 usage 2018-12-09 14:47:15 -08:00
Andrei Prykhodko ed384a0deb GRAPHICS: MACGUI: fixed memory leaks in MacTextWindow 2018-07-30 07:03:00 +03:00
Andrei Prykhodko 75eceedfa5 GRAPHICS: MACGUI: add additional arg to MacTextWindow's constructor to disable cursor handler 2018-07-29 21:23:04 +03:00
Andrei Prykhodko 841e0c11d8 GRAPHICS: MACGUI: fixed SIGSEGV when ptr to menu in MacTextWindow is NULL 2018-07-29 21:23:04 +03:00
Eugene Sandulenko 5684134ef6 GRAPHICS: MACGUI: Do not use hardcoded colors 2018-07-12 00:41:11 +02:00
Eugene Sandulenko 8458630e50 GRAPHICS: MACGUI: Added support for scrolling with mouse wheel 2017-08-22 10:25:00 +02:00
Eugene Sandulenko a7dbacb5c3 GRAPHICS: MACGUI: Ignore keys with modifiers in MacTextWindow 2017-08-22 10:25:00 +02:00