OpenGL contexts normally can't be nested. Previously, when the main
renderer for the DemoRunner was set to OpenGL, we would forcibly reset
the engine to the software renderer when displaying any heavyweight
demo, including the OpenGL demos.
19061e6d introduced a regression, where the rendering engine was no
longer reset on Windows, so displaying an OpenGL demo while the global
renderer was also set to OpenGL would cause an assertion to fire in the
OpenGL Graphics context, after which rendering would fail.
With this change in place, we now fall back to the Direct2D renderer,
instead of the software renderer, when displaying a heavyweight demo.
Prior to this commit the returned values were always normalised to the
value returned by getHeightInPoints().
I.e. getAscentInPoints() + getDescentInPoints() would always equal
getHeightInPoints(), even if ascent or descent overrides were in place.
With this change in place getAscentInPoints() + getDescentInPoints()
will always equal
getHeightInPoints() * (getAscentOverride() + getDescentOverride())
JUCE classes don't use this value for layout logic, so this commit
causes no visible changes in how JUCE draws text.
This commit removes the possibility to construct BidiParagraph and
BidiLine objects with non-zero offsets. We don't use these features,
and the assumption that these offsets are always zero simplifies our
visual ordering algorithm.
Prior to this commit we overallocated the s32 buffer. The buffer was
unnecessarily padded by zeros, and the line stating this, wasn't
actually dropping the null terminator.
After reviewing the NSAttributedString API it seems justified to have
two different functions for additive and multiplicative line spacing
settings. For NSAttributedString they are setLineSpacing and
setLineHeightMultiple.
Using this function, when appropriate, exercises it lessening the
likelihood of code rot.
This makes Direct2DMetrics and current frameId accessible to implementation subclasses.
It also replaces JUCE_WRITE_TRACE_LOG with JUCE_WRITE_TRACE_LOG_VA as intended in original implementation.
Co-authored-by: Matt Gonzalez <matt@echoaudio.com>