Commit Graph
3567 Commits
Author SHA1 Message Date
Eugene Sandulenko d9e7cbaf96 GRAPHICS: MACGUI: Implement MacText resize 2017-08-04 21:54:19 +02:00
Eugene Sandulenko 8609572b87 GRAPHICS: MACGUI: Correctly set MacTextWindow internal MacText size 2017-08-04 21:54:19 +02:00
Eugene Sandulenko b6970ade92 GRAPHICS: MACGUI: Remove redundant method from MacTextWindow 2017-08-04 21:54:19 +02:00
Eugene Sandulenko 47d87e059d GRAPHICS: MACGUI: Fix input text displaying 2017-08-04 21:54:19 +02:00
Eugene Sandulenko 50078a808c GRAPHICS: MACGUI: Remove unused variable 2017-08-04 21:54:19 +02:00
Eugene Sandulenko f79a7d049b GRAPHICS: MACGUI: Fixed input line replacement in MacTextWindow 2017-08-04 21:54:19 +02:00
Eugene Sandulenko bc8d059f38 GRAPHICS: MACGUI: Draw input on MacTextWindow redraw 2017-08-04 21:54:19 +02:00
Eugene Sandulenko 61eb58186c GRAPHICS: MACGUI: Cleanup 2017-08-04 21:54:19 +02:00
Eugene Sandulenko a95899c1b6 GRAPHICS: MACGUI: Fix formatting of the first added text in MacText 2017-08-04 21:54:19 +02:00
Eugene Sandulenko e236db8c3f GRAPHICS: MACGUI: Fixed appendText() in MacGui: formatting was not passed 2017-08-04 21:54:19 +02:00
Eugene Sandulenko 2e458671f6 GRAPHICS: MACGUI: Fix copy/paste bug in MacText 2017-08-04 21:54:19 +02:00
Eugene Sandulenko fe8ef60e08 GRAPHICS: MACGUI: Added more debug output to MacText 2017-08-04 21:54:19 +02:00
Eugene Sandulenko 77932d5838 GRAPHICS: MACGUI: Mark content as dirty when text is changed 2017-08-04 21:54:19 +02:00
Eugene Sandulenko 4897f6618b GRAPHICS: MACGUI: Pass default formatting to MacText 2017-08-04 21:54:19 +02:00
D G Turner 485a00b675 GRAPHICS: MACGUI: Suppress Unused Variable Compiler Warning. 2017-08-02 13:27:53 +01:00
Eugene Sandulenko b02d9a0174 GRAPHICS: MACGUI: unk3f is not needed in MacText 2017-08-01 10:42:22 +02:00
Eugene Sandulenko 115a7407e9 GRAPHICS: MACGUI: Keep original string in MacText 2017-08-01 10:42:22 +02:00
Eugene Sandulenko 48f07f0276 GRAPHICS: MACGUI: Render MacTextWindow internally 2017-08-01 10:42:22 +02:00
Eugene Sandulenko f7ba4f1b0b GRAPHICS: MACGUI: Properly process border dragging in MacTextWindow 2017-08-01 10:42:22 +02:00
Eugene Sandulenko a5c99c99f5 GRAPHICS: MACGUI: Remove redundant method from MacTextWindow 2017-08-01 10:42:22 +02:00
Eugene Sandulenko 8319e4093f GRAPHICS: MACGUI: Force redraw of dirty part of MacTextWindow 2017-08-01 10:42:22 +02:00
Eugene Sandulenko 2c0b73aaef GRAPHICS: MACGUI: Set MacTextWindow as active when keys are pressed 2017-08-01 10:42:22 +02:00
Eugene Sandulenko ebcff3a0aa GRAPHICS: MACGUI: Do not pass event when ascii characters are pressed 2017-08-01 10:42:22 +02:00
Eugene Sandulenko da9e02cebb GRAPHICS: MACGUI: Fix crash on backspace in MacTextWindow input 2017-08-01 10:42:22 +02:00
Eugene Sandulenko 81c26caaf8 GRAPHICS: MACGUI: Exposed input text from the MacTextWindow 2017-08-01 10:42:22 +02:00
Eugene Sandulenko 3e96a0909d GRAPHICS: MACGUI: Replace magic numbers with named constants 2017-08-01 10:42:22 +02:00
Eugene Sandulenko e832f1d650 GRAPHICS: MACGUI: Update cursor position as text being added to MacTextWindow 2017-08-01 10:42:22 +02:00
Eugene Sandulenko 94a0eadd30 GRAPHICS: MACGUI: Added hack for fixing cursor position in MacTextWindow 2017-08-01 10:42:22 +02:00
Eugene Sandulenko c2944fb5b8 GRAPHICS: MACGUI: Simplified cursor code is MacTextWindow 2017-08-01 10:42:22 +02:00
Eugene Sandulenko a2427fddd7 GRAPHICS: MACGUI: Initial code for cursor drawing in MacTextWindow 2017-08-01 10:42:22 +02:00
Eugene Sandulenko 62a2ac8c2b GRAPHICS: MACGUI: Added more getters to MacText 2017-08-01 10:42:22 +02:00
Eugene Sandulenko 511b21d3cf GRAPHICS: MACGUI: Added font specifying to MacTextWindow 2017-08-01 10:42:21 +02:00
Eugene Sandulenko 645ee64da0 GRAPHICS: MACGUI: Avoid double free of MacTextWindow 2017-08-01 10:42:21 +02:00
Eugene Sandulenko 73b6b12cbb GRAPHICS: MACGUI: Correctly process empty inpt strings in MacTextWindow 2017-08-01 10:42:21 +02:00
Eugene Sandulenko dbc247cc3f JANITORIAL: Code formatting 2017-08-01 10:42:21 +02:00
Eugene Sandulenko 9fe79b9e19 GRAPHICS: MACGUI: Made MacTextWindow processing keyboard input 2017-08-01 10:42:21 +02:00
Eugene Sandulenko ff8a2ade68 GRAPHICS: MACGUI: Made more MacWindow methods public 2017-08-01 10:42:21 +02:00
Eugene Sandulenko 68cd5c8868 GRAPHICS: MACGUI: Added method to remove last line from MacText 2017-08-01 10:42:21 +02:00
Eugene Sandulenko bfb757c3c0 GRAPHICS: Load Mac font heights too (still unused) 2017-08-01 10:42:21 +02:00
Vincent Pelletier bcd1066540 TINYGL: Move initialisation code outside of loop
Readability-only change.
Clarifies that these variables will be initialised before they get
accessed in the loop.
Also, initialise update_left and update_right to true, and only clear the
one needed for given triangle.
2017-07-20 01:56:35 +00:00
Vincent Pelletier 218d3214d7 TINYGL: Move remaining line counter decrement near y increment
Readability-only change.
Both represent the same notion, and nb_lines is only accessed as loop
condition.
2017-07-20 01:53:34 +00:00
Vincent Pelletier a6af3a38a3 TINYGL: Fix vertice color when clipped and lighting is disabled
longcurrent_color is assigned per vertex, but it is not saved on each
vertex on creation (unlike their "color" attribute, used when lighting
is enabled).
As a consequence, and because rendering happens asynchronously (rather,
following the draw call queue managed by zdirtyrect.cpp when requested
to flip current buffer), longcurrent_color at clipping time can be
different to the one at vertex declaration time, causing color artifacts.

The effect is most noticeable in EMI set shi, in the grog dispenser +
shipyard manager closeup angle, when Guybrush exits the screen by
crossing its right border: dark triangles become visible on his face.

Instead, always use the color attribute, which is already properly
initialised on vertex creation.
2017-07-20 01:51:07 +00:00
Vincent Pelletier 92130c138e TINYGL: Obey current shade model also when clipping lines.
The code was only interpolating color (in TGL_SMOOTH mode) when clipping
faces, extend it to lines.
Also, factorise color interpolation code.
No visual difference is expected in normal use, but it fixes wireframe
rendering when used for debugging.
2017-07-20 01:48:58 +00:00
Eugene Sandulenko 06e1445fd1 MACGUI: Fix warning 2017-07-18 00:02:45 +02:00
Eugene Sandulenko 49c72c884a MACGUI: Fix compilation 2017-07-18 00:01:46 +02:00
VelocityRa 3a2ce12288 WAGE: Fix resizing and text selection bug
Revise/Simplify old optional text rendering
Set things up a bit for selected text rendering
Add MacTextWindow::clearText and MacTextWindow::setSelection
Add MacTextWindow::appendText variant that accepts a MacFont
2017-07-17 23:45:22 +02:00
VelocityRa a169c7efb3 GRAPHICS: Use MacText::appendText to render formatted text
With this we can specify font, character size and slant that each
appended text will use.
2017-07-17 23:45:22 +02:00
VelocityRa 2b06c02d7d GRAPHICS: Add MacText::appendText() variants that accept text format args
Made 1 helper method and 1 function to reduce duplication size as much
as possible and still keep them useful for other purposes.
2017-07-17 23:45:22 +02:00
VelocityRa fe63eb7644 GRAPHICS: Introduce drawText, appendText and font in MacTextWindow 2017-07-17 23:45:22 +02:00
VelocityRa b127beb03c GRAPHICS: Fix bug in MacText::draw() on calculating bounding rect size
Change is _surface->w to _surface->h in the fourth arg to Common::Rect
2017-07-17 23:45:22 +02:00