From 9162c73355b47219d24ddba152fe931fdfabbcfc Mon Sep 17 00:00:00 2001 From: nyamatongwe Date: Tue, 5 Feb 2013 09:28:07 +1100 Subject: Add allocation of extended styles. --- test/simpleTests.py | 12 ++++++++++++ 1 file changed, 12 insertions(+) (limited to 'test/simpleTests.py') diff --git a/test/simpleTests.py b/test/simpleTests.py index 04c9ed145..4d397261a 100644 --- a/test/simpleTests.py +++ b/test/simpleTests.py @@ -1181,6 +1181,18 @@ class TestAnnotation(unittest.TestCase): self.assertEquals(result, styles) self.ed.AnnotationClearAll() + def testExtendedStyles(self): + start0 = self.ed.AllocateExtendedStyles(0) + self.assertEquals(start0, 256) + start1 = self.ed.AllocateExtendedStyles(10) + self.assertEquals(start1, 256) + start2 = self.ed.AllocateExtendedStyles(20) + self.assertEquals(start2, start1 + 10) + # Reset by changing lexer + self.ed.ReleaseAllExtendedStyles() + start0 = self.ed.AllocateExtendedStyles(0) + self.assertEquals(start0, 256) + def testTextAnnotationStyleOffset(self): self.ed.AnnotationSetStyleOffset(300) self.assertEquals(self.ed.AnnotationGetStyleOffset(), 300) -- cgit v1.2.3