14 return (ch ==
'\r') || (ch ==
'\n');
18 return ch ==
' ' || ch ==
'\t';
69 std::unique_ptr<unsigned char[]>
styles;
88 void Resize(
int maxLineLength_);
93 enum class
Scope { visibleOnly, includeEnd };
96 bool InLine(
int offset,
int line)
const noexcept;
99 char bracesMatchStyle,
int xHighlight,
bool ignoreStyle);
111 std::vector<std::unique_ptr<LineLayout>>
cache;
115 void Allocate(
size_t length_);
125 void Deallocate() noexcept;
133 void SetLevel(
int level_)
noexcept;
154 void Set(
unsigned int styleNumber_, const
char *s_,
unsigned int len_, const
XYPOSITION *positions_,
unsigned int clock_);
155 void Clear() noexcept;
156 bool Retrieve(
unsigned int styleNumber_, const
char *s_,
unsigned int len_,
XYPOSITION *positions_) const noexcept;
157 static
unsigned int Hash(
unsigned int styleNumber_, const
char *s,
unsigned int len_) noexcept;
159 void ResetClock() noexcept;
173 short startByteHasReprs[0x100];
176 void SetRepresentation(
const char *charBytes,
const char *value);
177 void ClearRepresentation(
const char *charBytes);
178 const Representation *RepresentationFromCharacter(
const char *charBytes,
size_t len)
const;
179 bool Contains(
const char *charBytes,
size_t len)
const;
188 start(start_), length(length_), representation(representation_) {
190 int end() const noexcept {
191 return start + length;
212 enum { lengthStartSubdivision = 300 };
214 enum { lengthEachSubdivision = 100 };
224 bool More() const noexcept;
228 std::vector<PositionCacheEntry>
pces;
239 void Clear() noexcept;
240 void SetSize(
size_t size_);
241 size_t GetSize() const noexcept {
return pces.size(); }
242 void MeasureWidths(
Surface *surface,
const ViewStyle &vstyle,
unsigned int styleNumber,
#define SC_CACHE_DOCUMENT
Sci::Position posLineStart
EncodingFamily encodingFamily
unsigned int saeCurrentPos
BreakFinder(const BreakFinder &)=delete
void operator=(BreakFinder &&)=delete
BreakFinder(BreakFinder &&)=delete
std::vector< int > selAndEdge
const SpecialRepresentations * preprs
void operator=(const BreakFinder &)=delete
void operator=(const LineLayoutCache &)=delete
LineLayoutCache(const LineLayoutCache &)=delete
LineLayoutCache(LineLayoutCache &&)=delete
int GetLevel() const noexcept
std::vector< std::unique_ptr< LineLayout > > cache
void operator=(LineLayoutCache &&)=delete
int LineLastVisible(int line, Scope scope) const noexcept
LineLayout(const LineLayout &)=delete
int FindPositionFromX(XYPOSITION x, Range range, bool charPosition) const noexcept
std::unique_ptr< int[]> lineStarts
void operator=(const LineLayout &)=delete
int FindBefore(XYPOSITION x, Range range) const noexcept
int LineLength(int line) const noexcept
void operator=(LineLayout &&)=delete
int LineStart(int line) const noexcept
void Resize(int maxLineLength_)
Range SubLineRange(int subLine, Scope scope) const noexcept
std::unique_ptr< char[]> chars
LineLayout(LineLayout &&)=delete
void SetBracesHighlight(Range rangeLine, const Sci::Position braces[], char bracesMatchStyle, int xHighlight, bool ignoreStyle)
char bracePreviousStyles[2]
enum Scintilla::LineLayout::ValidLevel validity
std::unique_ptr< XYPOSITION[]> positions
friend class LineLayoutCache
int EndLineStyle() const noexcept
std::unique_ptr< unsigned char[]> styles
Sci::Line lineNumber
Drawing is only performed for maxLineLength characters on each line.
bool InLine(int offset, int line) const noexcept
LineLayout(int maxLineLength_)
void SetLineStart(int line, int start)
void Invalidate(ValidLevel validity_) noexcept
Point PointFromPosition(int posInLine, int lineHeight, PointEnd pe) const noexcept
void RestoreBracesHighlight(Range rangeLine, const Sci::Position braces[], bool ignoreStyle)
A point in document space.
PointDocument(Point pt) noexcept
PointDocument(double x_=0, double y_=0) noexcept
std::unique_ptr< XYPOSITION[]> positions
void operator=(const PositionCache &)=delete
std::vector< PositionCacheEntry > pces
void operator=(PositionCache &&)=delete
PositionCache(const PositionCache &)=delete
PositionCache(PositionCache &&)=delete
The range class represents a range of text in a document.
Representation(const char *value="")
MapRepresentation mapReprs
A surface abstracts a place to draw.
Styling buffer using one element for each run rather than using a filled buffer.
constexpr bool IsEOLChar(int ch) noexcept
constexpr bool IsSpaceOrTab(int ch) noexcept
std::map< unsigned int, Representation > MapRepresentation
const Representation * representation
TextSegment(int start_=0, int length_=0, const Representation *representation_=nullptr) noexcept