From 7124ef7839ecba143e3a6fa7b30cee13bf6458b5 Mon Sep 17 00:00:00 2001 From: Neil Date: Fri, 18 Jul 2014 12:01:14 +1000 Subject: Allow extreme ascenders and descenders to overlap into adjacent lines with multiple phase drawing option. --- doc/ScintillaDoc.html | 49 ++++++++++++++++++++++++++++++++++++------------- 1 file changed, 36 insertions(+), 13 deletions(-) (limited to 'doc/ScintillaDoc.html') diff --git a/doc/ScintillaDoc.html b/doc/ScintillaDoc.html index 7187eeb24..54b8b50d9 100644 --- a/doc/ScintillaDoc.html +++ b/doc/ScintillaDoc.html @@ -117,7 +117,7 @@

The GTK+ version also uses messages in a similar way to the Windows version. This is different to normal GTK+ practice but made it easier to implement rapidly.

-

Scintilla also builds with Cocoa on OS X and with Qt, and follows the conventions of +

Scintilla also builds with Cocoa on OS X and with Qt, and follows the conventions of those platforms.

Scintilla does not properly support right-to-left languages like Arabic and Hebrew. @@ -256,7 +256,7 @@ o Caret, selection, and hotspot styles - + o Character representations o Margins @@ -1737,7 +1737,7 @@ struct Sci_TextToFind { effect until SCI_SETSELFORE and SCI_SETSELBACK are called with useSelection*Colour value set to true. Subsequent calls to - SCI_SETSELFORE, + SCI_SETSELFORE, and SCI_SETSELBACK will overwrite the values set by SCI_SETADDITIONALSEL* functions.

@@ -3161,6 +3161,8 @@ struct Sci_TextToFind {

Other settings

SCI_SETBUFFEREDDRAW(bool isBuffered)
SCI_GETBUFFEREDDRAW
+ SCI_SETPHASESDRAW(int phases)
+ SCI_GETPHASESDRAW
SCI_SETTWOPHASEDRAW(bool twoPhase)
SCI_GETTWOPHASEDRAW
SCI_SETTECHNOLOGY(int technology)
@@ -3199,17 +3201,38 @@ struct Sci_TextToFind { bitmap to the screen. This avoids flickering although it does take longer. The default is for drawing to be buffered.

-

SCI_SETTWOPHASEDRAW(bool twoPhase)
- SCI_GETTWOPHASEDRAW
- Two phase drawing is a better but slower way of drawing text. - In single phase drawing each run of characters in one style is drawn along with its background. +

SCI_SETPHASESDRAW(int phases)
+ SCI_GETPHASESDRAW
+ There are several orders in which the text area may be drawn offering a trade-off between speed + and allowing all pixels of text to be seen even when they overlap other elements.

+

In single phase drawing (SC_PHASES_ONE) each + run of characters in one style is drawn along with its background. If a character overhangs the end of a run, such as in "V_" where the "V" is in a different style from the "_", then this can cause the right hand side of the "V" to be overdrawn by the background of the "_" which - cuts it off. Two phase drawing - fixes this by drawing all the backgrounds first and then drawing the text in - transparent mode. Two phase drawing may flicker more than single phase - unless buffered drawing is on. The default is for drawing to be two phase.

+ cuts it off.

+

Two phase drawing (SC_PHASES_TWO) + fixes this by drawing all the backgrounds of a line first and then drawing the text + in transparent mode. Lines are drawn separately and no line will overlap another + so any pixels that overlap into another line such as extreme ascenders and + descenders on characters will be cut off. + Two phase drawing may flicker more than single phase + unless buffered drawing is on or the platform is naturally buffered. + The default is for drawing to be two phase.

+

Multiple phase drawing (SC_PHASES_MULTIPLE) + draws the whole area multiple times, once for each feature, building up the + the appearance in layers or phases. The coloured backgrounds for all lines are + drawn before any text and then all the text is drawn in transparent mode over this + combined background without clipping text to the line boundaries. This allows + extreme ascenders and decenders to overflow into the adjacent lines. + Multiple phase drawing is slower than two phase drawing. + Setting the layout cache to SC_CACHE_PAGE + or higher can ensure that multiple phase drawing is not significantly slower.

+ +

SCI_SETTWOPHASEDRAW(bool twoPhase)
+ SCI_GETTWOPHASEDRAW
+ This property has been replaced with the preceding PHASESDRAW property which is more general, + allowing multiple phase drawing as well as one and two phase drawing.

SCI_SETTECHNOLOGY(int technology)
SCI_GETTECHNOLOGY
@@ -3545,7 +3568,7 @@ struct Sci_TextToFind { SC_MARK_BACKGROUND, SC_MARK_LEFTRECT, SC_MARK_FULLRECT, - SC_MARK_BOOKMARK, and + SC_MARK_BOOKMARK, and SC_MARK_UNDERLINE.

@@ -7422,7 +7445,7 @@ EM_FORMATRANGE SCI_GETUSEPALETTE Deprecated
Scintilla no longer supports palette mode. The last version to support palettes was 2.29. Any calls to these methods should be removed.

- +

The following are features that should be removed from calling code but are still defined to avoid breaking callers.

-- cgit v1.2.3