diff options
author | nyamatongwe <unknown> | 2009-04-22 13:20:43 +0000 |
---|---|---|
committer | nyamatongwe <unknown> | 2009-04-22 13:20:43 +0000 |
commit | 865a213a8879baab1c67069ab1d2eae63deeea4b (patch) | |
tree | 98a6077613b017d50a85e1330092143920b4fa22 /src/PerLine.cxx | |
parent | ec2c38b2d808c46207aebb0c8642ecc42f641bc5 (diff) | |
download | scintilla-mirror-865a213a8879baab1c67069ab1d2eae63deeea4b.tar.gz |
Removed Document methods that returned parts of annotations in favour of
methods that return StyledText objects.
Provided LineLength call on StyledText rather than iterator objects.
Simplified code and made more things const.
Diffstat (limited to 'src/PerLine.cxx')
-rw-r--r-- | src/PerLine.cxx | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/PerLine.cxx b/src/PerLine.cxx index b90416abb..466d2fb31 100644 --- a/src/PerLine.cxx +++ b/src/PerLine.cxx @@ -377,9 +377,9 @@ const char *LineAnnotation::Text(int line) const { return 0; } -const char *LineAnnotation::Styles(int line) const { +const unsigned char *LineAnnotation::Styles(int line) const { if (annotations.Length() && (line < annotations.Length()) && annotations[line] && MultipleStyles(line)) - return annotations[line] + sizeof(AnnotationHeader) + Length(line); + return reinterpret_cast<unsigned char *>(annotations[line] + sizeof(AnnotationHeader) + Length(line)); else return 0; } @@ -428,7 +428,7 @@ void LineAnnotation::SetStyle(int line, int style) { reinterpret_cast<AnnotationHeader *>(annotations[line])->style = static_cast<short>(style); } -void LineAnnotation::SetStyles(int line, const char *styles) { +void LineAnnotation::SetStyles(int line, const unsigned char *styles) { annotations.EnsureLength(line+1); if (!annotations[line]) { annotations[line] = AllocateAnnotation(0, IndividualStyles); |