summaryrefslogtreecommitdiff
path: root/Build/source/libs/graphite2/graphite2-src/src/inc/Rule.h
diff options
context:
space:
mode:
Diffstat (limited to 'Build/source/libs/graphite2/graphite2-src/src/inc/Rule.h')
-rw-r--r--Build/source/libs/graphite2/graphite2-src/src/inc/Rule.h9
1 files changed, 6 insertions, 3 deletions
diff --git a/Build/source/libs/graphite2/graphite2-src/src/inc/Rule.h b/Build/source/libs/graphite2/graphite2-src/src/inc/Rule.h
index 36c8d89a63d..5ac21a17598 100644
--- a/Build/source/libs/graphite2/graphite2-src/src/inc/Rule.h
+++ b/Build/source/libs/graphite2/graphite2-src/src/inc/Rule.h
@@ -102,7 +102,7 @@ class SlotMap
{
public:
enum {MAX_SLOTS=64};
- SlotMap(Segment & seg, uint8 direction);
+ SlotMap(Segment & seg, uint8 direction, int maxSize);
Slot * * begin();
Slot * * end();
@@ -121,6 +121,7 @@ public:
void highpassed(bool v) { m_highpassed = v; }
uint8 dir() const { return m_dir; }
+ int decMax() { return --m_maxSize; }
Segment & segment;
private:
@@ -128,6 +129,7 @@ private:
unsigned short m_size;
unsigned short m_precontext;
Slot * m_highwater;
+ int m_maxSize;
uint8 m_dir;
bool m_highpassed;
};
@@ -242,8 +244,9 @@ void FiniteStateMachine::Rules::accumulate_rules(const State &state)
}
inline
-SlotMap::SlotMap(Segment & seg, uint8 direction)
-: segment(seg), m_size(0), m_precontext(0), m_highwater(0), m_dir(direction), m_highpassed(false)
+SlotMap::SlotMap(Segment & seg, uint8 direction, int maxSize)
+: segment(seg), m_size(0), m_precontext(0), m_highwater(0),
+ m_maxSize(maxSize), m_dir(direction), m_highpassed(false)
{
m_slot_map[0] = 0;
}