aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/ViewStyle.h
diff options
context:
space:
mode:
authornyamatongwe <devnull@localhost>2007-06-24 12:02:23 +0000
committernyamatongwe <devnull@localhost>2007-06-24 12:02:23 +0000
commit48974cb7802717896ed7560bf0520cf942b8c245 (patch)
treefd041ad1e922734432d617c50c2c80575a71ec84 /src/ViewStyle.h
parentbd5472e347f8cfc139197a64c59d8a79d654ec0c (diff)
downloadscintilla-mirror-48974cb7802717896ed7560bf0520cf942b8c245.tar.gz
Make the styles array variable length so it can be increased to 256 entries
without always taking 24K.
Diffstat (limited to 'src/ViewStyle.h')
-rw-r--r--src/ViewStyle.h7
1 files changed, 5 insertions, 2 deletions
diff --git a/src/ViewStyle.h b/src/ViewStyle.h
index 39adf81e8..a41e5f452 100644
--- a/src/ViewStyle.h
+++ b/src/ViewStyle.h
@@ -45,7 +45,8 @@ enum WhiteSpaceVisibility {wsInvisible=0, wsVisibleAlways=1, wsVisibleAfterInden
class ViewStyle {
public:
FontNames fontNames;
- Style styles[STYLE_MAX + 1];
+ size_t stylesSize;
+ Style *styles;
LineMarker markers[MARKER_MAX + 1];
Indicator indicators[INDIC_MAX + 1];
int lineHeight;
@@ -103,9 +104,11 @@ public:
ViewStyle();
ViewStyle(const ViewStyle &source);
~ViewStyle();
- void Init();
+ void Init(size_t stylesSize_=64);
void RefreshColourPalette(Palette &pal, bool want);
void Refresh(Surface &surface);
+ void AllocStyles(size_t sizeNew);
+ void EnsureStyle(size_t index);
void ResetDefaultStyle();
void ClearStyles();
void SetStyleFontName(int styleIndex, const char *name);