You've already forked lazarus-ccr
* finished getstylerange win32 implementation (yet, too slow)
* fixed getstylerange test git-svn-id: https://svn.code.sf.net/p/lazarus-ccr/svn@851 8e941d3f-bd1b-0410-a28a-d453659cc2b4
This commit is contained in:
@ -6,7 +6,7 @@
|
|||||||
<MainUnit Value="0"/>
|
<MainUnit Value="0"/>
|
||||||
<TargetFileExt Value=""/>
|
<TargetFileExt Value=""/>
|
||||||
<UseXPManifest Value="True"/>
|
<UseXPManifest Value="True"/>
|
||||||
<ActiveEditorIndexAtStart Value="0"/>
|
<ActiveEditorIndexAtStart Value="2"/>
|
||||||
</General>
|
</General>
|
||||||
<VersionInfo>
|
<VersionInfo>
|
||||||
<ProjectVersion Value=""/>
|
<ProjectVersion Value=""/>
|
||||||
@ -32,14 +32,16 @@
|
|||||||
<PackageName Value="LCL"/>
|
<PackageName Value="LCL"/>
|
||||||
</Item2>
|
</Item2>
|
||||||
</RequiredPackages>
|
</RequiredPackages>
|
||||||
<Units Count="44">
|
<Units Count="45">
|
||||||
<Unit0>
|
<Unit0>
|
||||||
<Filename Value="project1.lpr"/>
|
<Filename Value="project1.lpr"/>
|
||||||
<IsPartOfProject Value="True"/>
|
<IsPartOfProject Value="True"/>
|
||||||
<UnitName Value="project1"/>
|
<UnitName Value="project1"/>
|
||||||
<CursorPos X="32" Y="12"/>
|
<CursorPos X="12" Y="6"/>
|
||||||
<TopLine Value="1"/>
|
<TopLine Value="3"/>
|
||||||
<UsageCount Value="56"/>
|
<EditorIndex Value="3"/>
|
||||||
|
<UsageCount Value="61"/>
|
||||||
|
<Loaded Value="True"/>
|
||||||
</Unit0>
|
</Unit0>
|
||||||
<Unit1>
|
<Unit1>
|
||||||
<Filename Value="unit1.pas"/>
|
<Filename Value="unit1.pas"/>
|
||||||
@ -47,10 +49,10 @@
|
|||||||
<IsPartOfProject Value="True"/>
|
<IsPartOfProject Value="True"/>
|
||||||
<ResourceBaseClass Value="Form"/>
|
<ResourceBaseClass Value="Form"/>
|
||||||
<UnitName Value="Unit1"/>
|
<UnitName Value="Unit1"/>
|
||||||
<CursorPos X="1" Y="98"/>
|
<CursorPos X="21" Y="116"/>
|
||||||
<TopLine Value="94"/>
|
<TopLine Value="103"/>
|
||||||
<EditorIndex Value="0"/>
|
<EditorIndex Value="0"/>
|
||||||
<UsageCount Value="56"/>
|
<UsageCount Value="61"/>
|
||||||
<Loaded Value="True"/>
|
<Loaded Value="True"/>
|
||||||
</Unit1>
|
</Unit1>
|
||||||
<Unit2>
|
<Unit2>
|
||||||
@ -135,7 +137,7 @@
|
|||||||
<UnitName Value="CarbonGDIObjects"/>
|
<UnitName Value="CarbonGDIObjects"/>
|
||||||
<CursorPos X="3" Y="1109"/>
|
<CursorPos X="3" Y="1109"/>
|
||||||
<TopLine Value="1100"/>
|
<TopLine Value="1100"/>
|
||||||
<UsageCount Value="28"/>
|
<UsageCount Value="30"/>
|
||||||
<Bookmarks Count="1">
|
<Bookmarks Count="1">
|
||||||
<Item0 X="25" Y="150" ID="1"/>
|
<Item0 X="25" Y="150" ID="1"/>
|
||||||
</Bookmarks>
|
</Bookmarks>
|
||||||
@ -190,7 +192,7 @@
|
|||||||
<UnitName Value="CarbonPrivate"/>
|
<UnitName Value="CarbonPrivate"/>
|
||||||
<CursorPos X="17" Y="649"/>
|
<CursorPos X="17" Y="649"/>
|
||||||
<TopLine Value="640"/>
|
<TopLine Value="640"/>
|
||||||
<UsageCount Value="27"/>
|
<UsageCount Value="29"/>
|
||||||
<Loaded Value="True"/>
|
<Loaded Value="True"/>
|
||||||
</Unit20>
|
</Unit20>
|
||||||
<Unit21>
|
<Unit21>
|
||||||
@ -238,17 +240,17 @@
|
|||||||
<UnitName Value="RichMemo"/>
|
<UnitName Value="RichMemo"/>
|
||||||
<CursorPos X="3" Y="249"/>
|
<CursorPos X="3" Y="249"/>
|
||||||
<TopLine Value="247"/>
|
<TopLine Value="247"/>
|
||||||
<EditorIndex Value="8"/>
|
<EditorIndex Value="7"/>
|
||||||
<UsageCount Value="24"/>
|
<UsageCount Value="26"/>
|
||||||
<Loaded Value="True"/>
|
<Loaded Value="True"/>
|
||||||
</Unit27>
|
</Unit27>
|
||||||
<Unit28>
|
<Unit28>
|
||||||
<Filename Value="../../wsrichmemo.pas"/>
|
<Filename Value="../../wsrichmemo.pas"/>
|
||||||
<UnitName Value="WSRichMemo"/>
|
<UnitName Value="WSRichMemo"/>
|
||||||
<CursorPos X="1" Y="36"/>
|
<CursorPos X="1" Y="36"/>
|
||||||
<TopLine Value="11"/>
|
<TopLine Value="18"/>
|
||||||
<EditorIndex Value="7"/>
|
<EditorIndex Value="6"/>
|
||||||
<UsageCount Value="24"/>
|
<UsageCount Value="26"/>
|
||||||
<Loaded Value="True"/>
|
<Loaded Value="True"/>
|
||||||
</Unit28>
|
</Unit28>
|
||||||
<Unit29>
|
<Unit29>
|
||||||
@ -292,7 +294,7 @@
|
|||||||
<UnitName Value="CarbonPaste"/>
|
<UnitName Value="CarbonPaste"/>
|
||||||
<CursorPos X="43" Y="9"/>
|
<CursorPos X="43" Y="9"/>
|
||||||
<TopLine Value="1"/>
|
<TopLine Value="1"/>
|
||||||
<UsageCount Value="40"/>
|
<UsageCount Value="45"/>
|
||||||
</Unit34>
|
</Unit34>
|
||||||
<Unit35>
|
<Unit35>
|
||||||
<Filename Value="../../../fpc/rtl/objpas/sysutils/sysutilh.inc"/>
|
<Filename Value="../../../fpc/rtl/objpas/sysutils/sysutilh.inc"/>
|
||||||
@ -317,19 +319,19 @@
|
|||||||
<Unit38>
|
<Unit38>
|
||||||
<Filename Value="../../win32/win32richmemo.pas"/>
|
<Filename Value="../../win32/win32richmemo.pas"/>
|
||||||
<UnitName Value="Win32RichMemo"/>
|
<UnitName Value="Win32RichMemo"/>
|
||||||
<CursorPos X="21" Y="190"/>
|
<CursorPos X="63" Y="179"/>
|
||||||
<TopLine Value="185"/>
|
<TopLine Value="177"/>
|
||||||
<EditorIndex Value="3"/>
|
<EditorIndex Value="1"/>
|
||||||
<UsageCount Value="14"/>
|
<UsageCount Value="16"/>
|
||||||
<Loaded Value="True"/>
|
<Loaded Value="True"/>
|
||||||
</Unit38>
|
</Unit38>
|
||||||
<Unit39>
|
<Unit39>
|
||||||
<Filename Value="../../win32/win32richmemoproc.pas"/>
|
<Filename Value="../../win32/win32richmemoproc.pas"/>
|
||||||
<UnitName Value="Win32RichMemoProc"/>
|
<UnitName Value="Win32RichMemoProc"/>
|
||||||
<CursorPos X="23" Y="230"/>
|
<CursorPos X="33" Y="214"/>
|
||||||
<TopLine Value="215"/>
|
<TopLine Value="191"/>
|
||||||
<EditorIndex Value="4"/>
|
<EditorIndex Value="2"/>
|
||||||
<UsageCount Value="14"/>
|
<UsageCount Value="16"/>
|
||||||
<Bookmarks Count="1">
|
<Bookmarks Count="1">
|
||||||
<Item0 X="1" Y="102" ID="2"/>
|
<Item0 X="1" Y="102" ID="2"/>
|
||||||
</Bookmarks>
|
</Bookmarks>
|
||||||
@ -338,10 +340,10 @@
|
|||||||
<Unit40>
|
<Unit40>
|
||||||
<Filename Value="../../../../../fpc/packages/winunits-base/src/richedit.pp"/>
|
<Filename Value="../../../../../fpc/packages/winunits-base/src/richedit.pp"/>
|
||||||
<UnitName Value="richedit"/>
|
<UnitName Value="richedit"/>
|
||||||
<CursorPos X="1" Y="372"/>
|
<CursorPos X="1" Y="41"/>
|
||||||
<TopLine Value="359"/>
|
<TopLine Value="26"/>
|
||||||
<EditorIndex Value="6"/>
|
<EditorIndex Value="5"/>
|
||||||
<UsageCount Value="10"/>
|
<UsageCount Value="12"/>
|
||||||
<Bookmarks Count="1">
|
<Bookmarks Count="1">
|
||||||
<Item0 X="98" Y="366" ID="3"/>
|
<Item0 X="98" Y="366" ID="3"/>
|
||||||
</Bookmarks>
|
</Bookmarks>
|
||||||
@ -351,147 +353,149 @@
|
|||||||
<Filename Value="../../../../../fpc/rtl/win/wininc/base.inc"/>
|
<Filename Value="../../../../../fpc/rtl/win/wininc/base.inc"/>
|
||||||
<CursorPos X="6" Y="211"/>
|
<CursorPos X="6" Y="211"/>
|
||||||
<TopLine Value="197"/>
|
<TopLine Value="197"/>
|
||||||
<EditorIndex Value="5"/>
|
<EditorIndex Value="4"/>
|
||||||
<UsageCount Value="10"/>
|
<UsageCount Value="12"/>
|
||||||
<Loaded Value="True"/>
|
<Loaded Value="True"/>
|
||||||
</Unit41>
|
</Unit41>
|
||||||
<Unit42>
|
<Unit42>
|
||||||
<Filename Value="../../../../../fpc/rtl/objpas/classes/classesh.inc"/>
|
<Filename Value="../../../../../fpc/rtl/objpas/classes/classesh.inc"/>
|
||||||
<CursorPos X="1" Y="791"/>
|
<CursorPos X="1" Y="791"/>
|
||||||
<TopLine Value="782"/>
|
<TopLine Value="782"/>
|
||||||
<EditorIndex Value="1"/>
|
|
||||||
<UsageCount Value="10"/>
|
<UsageCount Value="10"/>
|
||||||
<Loaded Value="True"/>
|
|
||||||
</Unit42>
|
</Unit42>
|
||||||
<Unit43>
|
<Unit43>
|
||||||
<Filename Value="../../../../../fpc/rtl/objpas/classes/streams.inc"/>
|
<Filename Value="../../../../../fpc/rtl/objpas/classes/streams.inc"/>
|
||||||
<CursorPos X="3" Y="465"/>
|
<CursorPos X="3" Y="465"/>
|
||||||
<TopLine Value="462"/>
|
<TopLine Value="462"/>
|
||||||
<EditorIndex Value="2"/>
|
|
||||||
<UsageCount Value="10"/>
|
<UsageCount Value="10"/>
|
||||||
<Loaded Value="True"/>
|
|
||||||
</Unit43>
|
</Unit43>
|
||||||
|
<Unit44>
|
||||||
|
<Filename Value="../../../../../fpc/rtl/win/wininc/ascdef.inc"/>
|
||||||
|
<CursorPos X="120" Y="182"/>
|
||||||
|
<TopLine Value="167"/>
|
||||||
|
<UsageCount Value="10"/>
|
||||||
|
</Unit44>
|
||||||
</Units>
|
</Units>
|
||||||
<JumpHistory Count="30" HistoryIndex="29">
|
<JumpHistory Count="30" HistoryIndex="29">
|
||||||
<Position1>
|
<Position1>
|
||||||
<Filename Value="../../win32/win32richmemo.pas"/>
|
<Filename Value="../../win32/win32richmemoproc.pas"/>
|
||||||
<Caret Line="189" Column="11" TopLine="164"/>
|
<Caret Line="238" Column="59" TopLine="220"/>
|
||||||
</Position1>
|
</Position1>
|
||||||
<Position2>
|
<Position2>
|
||||||
<Filename Value="../../win32/win32richmemoproc.pas"/>
|
<Filename Value="../../win32/win32richmemo.pas"/>
|
||||||
<Caret Line="30" Column="20" TopLine="15"/>
|
<Caret Line="193" Column="36" TopLine="186"/>
|
||||||
</Position2>
|
</Position2>
|
||||||
<Position3>
|
<Position3>
|
||||||
<Filename Value="../../win32/win32richmemoproc.pas"/>
|
<Filename Value="unit1.pas"/>
|
||||||
<Caret Line="29" Column="33" TopLine="15"/>
|
<Caret Line="102" Column="23" TopLine="94"/>
|
||||||
</Position3>
|
</Position3>
|
||||||
<Position4>
|
<Position4>
|
||||||
<Filename Value="../../win32/win32richmemoproc.pas"/>
|
<Filename Value="unit1.pas"/>
|
||||||
<Caret Line="197" Column="5" TopLine="167"/>
|
<Caret Line="99" Column="3" TopLine="94"/>
|
||||||
</Position4>
|
</Position4>
|
||||||
<Position5>
|
<Position5>
|
||||||
<Filename Value="../../win32/win32richmemoproc.pas"/>
|
<Filename Value="unit1.pas"/>
|
||||||
<Caret Line="30" Column="58" TopLine="15"/>
|
<Caret Line="105" Column="21" TopLine="96"/>
|
||||||
</Position5>
|
</Position5>
|
||||||
<Position6>
|
<Position6>
|
||||||
<Filename Value="../../win32/win32richmemoproc.pas"/>
|
<Filename Value="unit1.pas"/>
|
||||||
<Caret Line="200" Column="17" TopLine="187"/>
|
<Caret Line="40" Column="35" TopLine="33"/>
|
||||||
</Position6>
|
</Position6>
|
||||||
<Position7>
|
<Position7>
|
||||||
<Filename Value="../../../../../fpc/packages/winunits-base/src/richedit.pp"/>
|
<Filename Value="unit1.pas"/>
|
||||||
<Caret Line="366" Column="98" TopLine="356"/>
|
<Caret Line="42" Column="3" TopLine="33"/>
|
||||||
</Position7>
|
</Position7>
|
||||||
<Position8>
|
<Position8>
|
||||||
<Filename Value="../../../../../fpc/packages/winunits-base/src/richedit.pp"/>
|
<Filename Value="unit1.pas"/>
|
||||||
<Caret Line="1" Column="1" TopLine="1"/>
|
<Caret Line="139" Column="1" TopLine="138"/>
|
||||||
</Position8>
|
</Position8>
|
||||||
<Position9>
|
<Position9>
|
||||||
<Filename Value="../../win32/win32richmemoproc.pas"/>
|
<Filename Value="unit1.pas"/>
|
||||||
<Caret Line="194" Column="36" TopLine="187"/>
|
<Caret Line="39" Column="1" TopLine="33"/>
|
||||||
</Position9>
|
</Position9>
|
||||||
<Position10>
|
<Position10>
|
||||||
<Filename Value="../../win32/win32richmemoproc.pas"/>
|
<Filename Value="unit1.pas"/>
|
||||||
<Caret Line="203" Column="15" TopLine="187"/>
|
<Caret Line="112" Column="1" TopLine="112"/>
|
||||||
</Position10>
|
</Position10>
|
||||||
<Position11>
|
<Position11>
|
||||||
<Filename Value="../../win32/win32richmemoproc.pas"/>
|
<Filename Value="../../win32/win32richmemo.pas"/>
|
||||||
<Caret Line="246" Column="32" TopLine="218"/>
|
<Caret Line="164" Column="2" TopLine="153"/>
|
||||||
</Position11>
|
</Position11>
|
||||||
<Position12>
|
<Position12>
|
||||||
<Filename Value="../../win32/win32richmemoproc.pas"/>
|
<Filename Value="../../win32/win32richmemo.pas"/>
|
||||||
<Caret Line="237" Column="1" TopLine="210"/>
|
<Caret Line="20" Column="1" TopLine="9"/>
|
||||||
</Position12>
|
</Position12>
|
||||||
<Position13>
|
<Position13>
|
||||||
<Filename Value="../../win32/win32richmemoproc.pas"/>
|
<Filename Value="../../win32/win32richmemoproc.pas"/>
|
||||||
<Caret Line="206" Column="23" TopLine="191"/>
|
<Caret Line="26" Column="139" TopLine="17"/>
|
||||||
</Position13>
|
</Position13>
|
||||||
<Position14>
|
<Position14>
|
||||||
<Filename Value="../../win32/win32richmemoproc.pas"/>
|
<Filename Value="../../win32/win32richmemoproc.pas"/>
|
||||||
<Caret Line="207" Column="21" TopLine="192"/>
|
<Caret Line="151" Column="3" TopLine="143"/>
|
||||||
</Position14>
|
</Position14>
|
||||||
<Position15>
|
<Position15>
|
||||||
<Filename Value="../../win32/win32richmemoproc.pas"/>
|
<Filename Value="../../win32/win32richmemoproc.pas"/>
|
||||||
<Caret Line="214" Column="72" TopLine="203"/>
|
<Caret Line="26" Column="55" TopLine="11"/>
|
||||||
</Position15>
|
</Position15>
|
||||||
<Position16>
|
<Position16>
|
||||||
<Filename Value="../../win32/win32richmemoproc.pas"/>
|
<Filename Value="../../win32/win32richmemoproc.pas"/>
|
||||||
<Caret Line="31" Column="58" TopLine="30"/>
|
<Caret Line="168" Column="3" TopLine="166"/>
|
||||||
</Position16>
|
</Position16>
|
||||||
<Position17>
|
<Position17>
|
||||||
<Filename Value="../../win32/win32richmemoproc.pas"/>
|
<Filename Value="../../win32/win32richmemoproc.pas"/>
|
||||||
<Caret Line="196" Column="19" TopLine="182"/>
|
<Caret Line="179" Column="14" TopLine="166"/>
|
||||||
</Position17>
|
</Position17>
|
||||||
<Position18>
|
<Position18>
|
||||||
<Filename Value="../../win32/win32richmemoproc.pas"/>
|
<Filename Value="../../win32/win32richmemoproc.pas"/>
|
||||||
<Caret Line="218" Column="31" TopLine="203"/>
|
<Caret Line="184" Column="71" TopLine="164"/>
|
||||||
</Position18>
|
</Position18>
|
||||||
<Position19>
|
<Position19>
|
||||||
<Filename Value="../../win32/win32richmemoproc.pas"/>
|
<Filename Value="../../win32/win32richmemoproc.pas"/>
|
||||||
<Caret Line="242" Column="31" TopLine="217"/>
|
<Caret Line="178" Column="27" TopLine="157"/>
|
||||||
</Position19>
|
</Position19>
|
||||||
<Position20>
|
<Position20>
|
||||||
<Filename Value="../../win32/win32richmemoproc.pas"/>
|
<Filename Value="../../win32/win32richmemoproc.pas"/>
|
||||||
<Caret Line="238" Column="59" TopLine="220"/>
|
<Caret Line="177" Column="26" TopLine="167"/>
|
||||||
</Position20>
|
</Position20>
|
||||||
<Position21>
|
<Position21>
|
||||||
<Filename Value="../../win32/win32richmemo.pas"/>
|
<Filename Value="../../win32/win32richmemoproc.pas"/>
|
||||||
<Caret Line="193" Column="36" TopLine="186"/>
|
<Caret Line="178" Column="12" TopLine="167"/>
|
||||||
</Position21>
|
</Position21>
|
||||||
<Position22>
|
<Position22>
|
||||||
<Filename Value="unit1.pas"/>
|
<Filename Value="../../win32/win32richmemoproc.pas"/>
|
||||||
<Caret Line="53" Column="26" TopLine="77"/>
|
<Caret Line="211" Column="37" TopLine="188"/>
|
||||||
</Position22>
|
</Position22>
|
||||||
<Position23>
|
<Position23>
|
||||||
<Filename Value="unit1.pas"/>
|
<Filename Value="../../win32/win32richmemo.pas"/>
|
||||||
<Caret Line="102" Column="23" TopLine="94"/>
|
<Caret Line="188" Column="72" TopLine="178"/>
|
||||||
</Position23>
|
</Position23>
|
||||||
<Position24>
|
<Position24>
|
||||||
<Filename Value="unit1.pas"/>
|
<Filename Value="../../win32/win32richmemo.pas"/>
|
||||||
<Caret Line="99" Column="3" TopLine="94"/>
|
<Caret Line="185" Column="75" TopLine="173"/>
|
||||||
</Position24>
|
</Position24>
|
||||||
<Position25>
|
<Position25>
|
||||||
<Filename Value="unit1.pas"/>
|
<Filename Value="project1.lpr"/>
|
||||||
<Caret Line="105" Column="21" TopLine="96"/>
|
<Caret Line="12" Column="32" TopLine="1"/>
|
||||||
</Position25>
|
</Position25>
|
||||||
<Position26>
|
<Position26>
|
||||||
<Filename Value="unit1.pas"/>
|
<Filename Value="project1.lpr"/>
|
||||||
<Caret Line="40" Column="35" TopLine="33"/>
|
<Caret Line="17" Column="1" TopLine="3"/>
|
||||||
</Position26>
|
</Position26>
|
||||||
<Position27>
|
<Position27>
|
||||||
<Filename Value="unit1.pas"/>
|
<Filename Value="project1.lpr"/>
|
||||||
<Caret Line="42" Column="3" TopLine="33"/>
|
<Caret Line="18" Column="1" TopLine="3"/>
|
||||||
</Position27>
|
</Position27>
|
||||||
<Position28>
|
<Position28>
|
||||||
<Filename Value="unit1.pas"/>
|
<Filename Value="project1.lpr"/>
|
||||||
<Caret Line="139" Column="1" TopLine="138"/>
|
<Caret Line="16" Column="30" TopLine="3"/>
|
||||||
</Position28>
|
</Position28>
|
||||||
<Position29>
|
<Position29>
|
||||||
<Filename Value="unit1.pas"/>
|
<Filename Value="../../win32/win32richmemoproc.pas"/>
|
||||||
<Caret Line="39" Column="1" TopLine="33"/>
|
<Caret Line="222" Column="12" TopLine="208"/>
|
||||||
</Position29>
|
</Position29>
|
||||||
<Position30>
|
<Position30>
|
||||||
<Filename Value="unit1.pas"/>
|
<Filename Value="../../win32/win32richmemoproc.pas"/>
|
||||||
<Caret Line="112" Column="1" TopLine="112"/>
|
<Caret Line="219" Column="45" TopLine="209"/>
|
||||||
</Position30>
|
</Position30>
|
||||||
</JumpHistory>
|
</JumpHistory>
|
||||||
</ProjectOptions>
|
</ProjectOptions>
|
||||||
|
@ -10,8 +10,8 @@ object Form1: TForm1
|
|||||||
OnCreate = FormCreate
|
OnCreate = FormCreate
|
||||||
LCLVersion = '0.9.27'
|
LCLVersion = '0.9.27'
|
||||||
object RichMemo1: TRichMemo
|
object RichMemo1: TRichMemo
|
||||||
Left = 16
|
Left = 15
|
||||||
Height = 366
|
Height = 358
|
||||||
Top = 16
|
Top = 16
|
||||||
Width = 619
|
Width = 619
|
||||||
Anchors = [akTop, akLeft, akRight, akBottom]
|
Anchors = [akTop, akLeft, akRight, akBottom]
|
||||||
@ -34,6 +34,7 @@ object Form1: TForm1
|
|||||||
Caption = 'Make Bold and Red'
|
Caption = 'Make Bold and Red'
|
||||||
OnClick = Button1Click
|
OnClick = Button1Click
|
||||||
TabOrder = 1
|
TabOrder = 1
|
||||||
|
TabStop = False
|
||||||
end
|
end
|
||||||
object Button2: TButton
|
object Button2: TButton
|
||||||
Left = 192
|
Left = 192
|
||||||
@ -44,6 +45,7 @@ object Form1: TForm1
|
|||||||
Caption = 'Get Attribs'
|
Caption = 'Get Attribs'
|
||||||
OnClick = Button2Click
|
OnClick = Button2Click
|
||||||
TabOrder = 2
|
TabOrder = 2
|
||||||
|
TabStop = False
|
||||||
end
|
end
|
||||||
object Button3: TButton
|
object Button3: TButton
|
||||||
Left = 304
|
Left = 304
|
||||||
@ -54,6 +56,7 @@ object Form1: TForm1
|
|||||||
Caption = 'Select Font'
|
Caption = 'Select Font'
|
||||||
OnClick = Button3Click
|
OnClick = Button3Click
|
||||||
TabOrder = 3
|
TabOrder = 3
|
||||||
|
TabStop = False
|
||||||
end
|
end
|
||||||
object Button4: TButton
|
object Button4: TButton
|
||||||
Left = 528
|
Left = 528
|
||||||
@ -64,6 +67,7 @@ object Form1: TForm1
|
|||||||
Caption = 'Save RTF'
|
Caption = 'Save RTF'
|
||||||
OnClick = Button4Click
|
OnClick = Button4Click
|
||||||
TabOrder = 4
|
TabOrder = 4
|
||||||
|
TabStop = False
|
||||||
end
|
end
|
||||||
object Button5: TButton
|
object Button5: TButton
|
||||||
Left = 440
|
Left = 440
|
||||||
@ -74,6 +78,7 @@ object Form1: TForm1
|
|||||||
Caption = 'Load RTF'
|
Caption = 'Load RTF'
|
||||||
OnClick = Button5Click
|
OnClick = Button5Click
|
||||||
TabOrder = 5
|
TabOrder = 5
|
||||||
|
TabStop = False
|
||||||
end
|
end
|
||||||
object Button6: TButton
|
object Button6: TButton
|
||||||
Left = 24
|
Left = 24
|
||||||
@ -84,24 +89,25 @@ object Form1: TForm1
|
|||||||
Caption = 'Next Style Range'
|
Caption = 'Next Style Range'
|
||||||
OnClick = Button6Click
|
OnClick = Button6Click
|
||||||
TabOrder = 6
|
TabOrder = 6
|
||||||
|
TabStop = False
|
||||||
end
|
end
|
||||||
object FontDialog1: TFontDialog
|
object FontDialog1: TFontDialog
|
||||||
MinFontSize = 0
|
MinFontSize = 0
|
||||||
MaxFontSize = 0
|
MaxFontSize = 0
|
||||||
left = 352
|
left = 352
|
||||||
top = 552
|
top = 429
|
||||||
end
|
end
|
||||||
object SaveDialog1: TSaveDialog
|
object SaveDialog1: TSaveDialog
|
||||||
DefaultExt = '.rtf'
|
DefaultExt = '.rtf'
|
||||||
Filter = 'RichText file (*.rtf)|*.rtf'
|
Filter = 'RichText file (*.rtf)|*.rtf'
|
||||||
Options = [ofOverwritePrompt, ofEnableSizing, ofViewDetail]
|
Options = [ofOverwritePrompt, ofEnableSizing, ofViewDetail]
|
||||||
left = 280
|
left = 280
|
||||||
top = 552
|
top = 429
|
||||||
end
|
end
|
||||||
object OpenDialog1: TOpenDialog
|
object OpenDialog1: TOpenDialog
|
||||||
DefaultExt = '.rtf'
|
DefaultExt = '.rtf'
|
||||||
Filter = 'RichText file (*.rtf)|*.rtf'
|
Filter = 'RichText file (*.rtf)|*.rtf'
|
||||||
left = 208
|
left = 208
|
||||||
top = 552
|
top = 429
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
@ -4,31 +4,32 @@ LazarusResources.Add('TForm1','FORMDATA',[
|
|||||||
'TPF0'#6'TForm1'#5'Form1'#4'Left'#3#196#0#6'Height'#3#201#1#3'Top'#3#181#0#5
|
'TPF0'#6'TForm1'#5'Form1'#4'Left'#3#196#0#6'Height'#3#201#1#3'Top'#3#181#0#5
|
||||||
+'Width'#3'z'#2#13'ActiveControl'#7#9'RichMemo1'#7'Caption'#6#5'Form1'#12'Cli'
|
+'Width'#3'z'#2#13'ActiveControl'#7#9'RichMemo1'#7'Caption'#6#5'Form1'#12'Cli'
|
||||||
+'entHeight'#3#201#1#11'ClientWidth'#3'z'#2#8'OnCreate'#7#10'FormCreate'#10'L'
|
+'entHeight'#3#201#1#11'ClientWidth'#3'z'#2#8'OnCreate'#7#10'FormCreate'#10'L'
|
||||||
+'CLVersion'#6#6'0.9.27'#0#9'TRichMemo'#9'RichMemo1'#4'Left'#2#16#6'Height'#3
|
+'CLVersion'#6#6'0.9.27'#0#9'TRichMemo'#9'RichMemo1'#4'Left'#2#15#6'Height'#3
|
||||||
+'n'#1#3'Top'#2#16#5'Width'#3'k'#2#7'Anchors'#11#5'akTop'#6'akLeft'#7'akRight'
|
+'f'#1#3'Top'#2#16#5'Width'#3'k'#2#7'Anchors'#11#5'akTop'#6'akLeft'#7'akRight'
|
||||||
+#8'akBottom'#0#11'Font.Height'#2#243#9'Font.Name'#6#6'Tahoma'#13'HideSelecti'
|
+#8'akBottom'#0#11'Font.Height'#2#243#9'Font.Name'#6#6'Tahoma'#13'HideSelecti'
|
||||||
+'on'#8#13'Lines.Strings'#1#6#9'RichMemo1'#0#10'ParentFont'#8#10'ScrollBars'#7
|
+'on'#8#13'Lines.Strings'#1#6#9'RichMemo1'#0#10'ParentFont'#8#10'ScrollBars'#7
|
||||||
+#10'ssVertical'#8'TabOrder'#2#0#0#0#7'TButton'#7'Button1'#4'Left'#2#24#6'Hei'
|
+#10'ssVertical'#8'TabOrder'#2#0#0#0#7'TButton'#7'Button1'#4'Left'#2#24#6'Hei'
|
||||||
+'ght'#2#25#3'Top'#3'~'#1#5'Width'#3#160#0#7'Anchors'#11#6'akLeft'#8'akBottom'
|
+'ght'#2#25#3'Top'#3'~'#1#5'Width'#3#160#0#7'Anchors'#11#6'akLeft'#8'akBottom'
|
||||||
+#0#7'Caption'#6#17'Make Bold and Red'#7'OnClick'#7#12'Button1Click'#8'TabOrd'
|
+#0#7'Caption'#6#17'Make Bold and Red'#7'OnClick'#7#12'Button1Click'#8'TabOrd'
|
||||||
+'er'#2#1#0#0#7'TButton'#7'Button2'#4'Left'#3#192#0#6'Height'#2#25#3'Top'#3'~'
|
+'er'#2#1#7'TabStop'#8#0#0#7'TButton'#7'Button2'#4'Left'#3#192#0#6'Height'#2
|
||||||
+#1#5'Width'#2'a'#7'Anchors'#11#6'akLeft'#8'akBottom'#0#7'Caption'#6#11'Get A'
|
+#25#3'Top'#3'~'#1#5'Width'#2'a'#7'Anchors'#11#6'akLeft'#8'akBottom'#0#7'Capt'
|
||||||
+'ttribs'#7'OnClick'#7#12'Button2Click'#8'TabOrder'#2#2#0#0#7'TButton'#7'Butt'
|
+'ion'#6#11'Get Attribs'#7'OnClick'#7#12'Button2Click'#8'TabOrder'#2#2#7'TabS'
|
||||||
+'on3'#4'Left'#3'0'#1#6'Height'#2#25#3'Top'#3'~'#1#5'Width'#2'`'#7'Anchors'#11
|
+'top'#8#0#0#7'TButton'#7'Button3'#4'Left'#3'0'#1#6'Height'#2#25#3'Top'#3'~'#1
|
||||||
+#6'akLeft'#8'akBottom'#0#7'Caption'#6#11'Select Font'#7'OnClick'#7#12'Button'
|
+#5'Width'#2'`'#7'Anchors'#11#6'akLeft'#8'akBottom'#0#7'Caption'#6#11'Select '
|
||||||
+'3Click'#8'TabOrder'#2#3#0#0#7'TButton'#7'Button4'#4'Left'#3#16#2#6'Height'#2
|
+'Font'#7'OnClick'#7#12'Button3Click'#8'TabOrder'#2#3#7'TabStop'#8#0#0#7'TBut'
|
||||||
+#25#3'Top'#3'~'#1#5'Width'#2'K'#7'Anchors'#11#6'akLeft'#8'akBottom'#0#7'Capt'
|
+'ton'#7'Button4'#4'Left'#3#16#2#6'Height'#2#25#3'Top'#3'~'#1#5'Width'#2'K'#7
|
||||||
+'ion'#6#8'Save RTF'#7'OnClick'#7#12'Button4Click'#8'TabOrder'#2#4#0#0#7'TBut'
|
+'Anchors'#11#6'akLeft'#8'akBottom'#0#7'Caption'#6#8'Save RTF'#7'OnClick'#7#12
|
||||||
+'ton'#7'Button5'#4'Left'#3#184#1#6'Height'#2#25#3'Top'#3'~'#1#5'Width'#2'K'#7
|
+'Button4Click'#8'TabOrder'#2#4#7'TabStop'#8#0#0#7'TButton'#7'Button5'#4'Left'
|
||||||
+'Anchors'#11#6'akLeft'#8'akBottom'#0#7'Caption'#6#8'Load RTF'#7'OnClick'#7#12
|
+#3#184#1#6'Height'#2#25#3'Top'#3'~'#1#5'Width'#2'K'#7'Anchors'#11#6'akLeft'#8
|
||||||
+'Button5Click'#8'TabOrder'#2#5#0#0#7'TButton'#7'Button6'#4'Left'#2#24#6'Heig'
|
+'akBottom'#0#7'Caption'#6#8'Load RTF'#7'OnClick'#7#12'Button5Click'#8'TabOrd'
|
||||||
+'ht'#2#25#3'Top'#3#159#1#5'Width'#3#160#0#7'Anchors'#11#6'akLeft'#8'akBottom'
|
+'er'#2#5#7'TabStop'#8#0#0#7'TButton'#7'Button6'#4'Left'#2#24#6'Height'#2#25#3
|
||||||
+#0#7'Caption'#6#16'Next Style Range'#7'OnClick'#7#12'Button6Click'#8'TabOrde'
|
+'Top'#3#159#1#5'Width'#3#160#0#7'Anchors'#11#6'akLeft'#8'akBottom'#0#7'Capti'
|
||||||
+'r'#2#6#0#0#11'TFontDialog'#11'FontDialog1'#11'MinFontSize'#2#0#11'MaxFontSi'
|
+'on'#6#16'Next Style Range'#7'OnClick'#7#12'Button6Click'#8'TabOrder'#2#6#7
|
||||||
+'ze'#2#0#4'left'#3'`'#1#3'top'#3'('#2#0#0#11'TSaveDialog'#11'SaveDialog1'#10
|
+'TabStop'#8#0#0#11'TFontDialog'#11'FontDialog1'#11'MinFontSize'#2#0#11'MaxFo'
|
||||||
+'DefaultExt'#6#4'.rtf'#6'Filter'#6#27'RichText file (*.rtf)|*.rtf'#7'Options'
|
+'ntSize'#2#0#4'left'#3'`'#1#3'top'#3#173#1#0#0#11'TSaveDialog'#11'SaveDialog'
|
||||||
+#11#17'ofOverwritePrompt'#14'ofEnableSizing'#12'ofViewDetail'#0#4'left'#3#24
|
+'1'#10'DefaultExt'#6#4'.rtf'#6'Filter'#6#27'RichText file (*.rtf)|*.rtf'#7'O'
|
||||||
+#1#3'top'#3'('#2#0#0#11'TOpenDialog'#11'OpenDialog1'#10'DefaultExt'#6#4'.rtf'
|
+'ptions'#11#17'ofOverwritePrompt'#14'ofEnableSizing'#12'ofViewDetail'#0#4'le'
|
||||||
+#6'Filter'#6#27'RichText file (*.rtf)|*.rtf'#4'left'#3#208#0#3'top'#3'('#2#0
|
+'ft'#3#24#1#3'top'#3#173#1#0#0#11'TOpenDialog'#11'OpenDialog1'#10'DefaultExt'
|
||||||
+#0#0
|
+#6#4'.rtf'#6'Filter'#6#27'RichText file (*.rtf)|*.rtf'#4'left'#3#208#0#3'top'
|
||||||
|
+#3#173#1#0#0#0
|
||||||
]);
|
]);
|
||||||
|
@ -113,7 +113,7 @@ var
|
|||||||
begin
|
begin
|
||||||
RichMemo1.GetStyleRange( RichMemo1.SelStart, ofs, len );
|
RichMemo1.GetStyleRange( RichMemo1.SelStart, ofs, len );
|
||||||
if (ofs = RichMEmo1.SelStart) and (len = RichMemo1.SelLength) then begin
|
if (ofs = RichMEmo1.SelStart) and (len = RichMemo1.SelLength) then begin
|
||||||
ofs := ofs + len + 1;
|
ofs := ofs + len;
|
||||||
RichMemo1.GetStyleRange( ofs, ofs, len );
|
RichMemo1.GetStyleRange( ofs, ofs, len );
|
||||||
end;
|
end;
|
||||||
RichMemo1.SelStart := ofs;
|
RichMemo1.SelStart := ofs;
|
||||||
|
@ -172,8 +172,8 @@ var
|
|||||||
mask : LongWord;
|
mask : LongWord;
|
||||||
textlen : TGETTEXTEX;
|
textlen : TGETTEXTEX;
|
||||||
sel : TCHARRANGE;
|
sel : TCHARRANGE;
|
||||||
rngend : Integer;
|
|
||||||
d : Integer;
|
d : Integer;
|
||||||
|
last : Integer;
|
||||||
const
|
const
|
||||||
CP_UNICODE = 1200;
|
CP_UNICODE = 1200;
|
||||||
ALL_MASK = CFM_BOLD or CFM_ITALIC or CFM_STRIKEOUT or CFM_UNDERLINE or
|
ALL_MASK = CFM_BOLD or CFM_ITALIC or CFM_STRIKEOUT or CFM_UNDERLINE or
|
||||||
@ -185,6 +185,8 @@ begin
|
|||||||
textlen.flags := GTL_DEFAULT or GTL_NUMCHARS;
|
textlen.flags := GTL_DEFAULT or GTL_NUMCHARS;
|
||||||
textlen.codepage := CP_UNICODE;
|
textlen.codepage := CP_UNICODE;
|
||||||
len := SendMessage(RichEditWnd, EM_GETTEXTLENGTHEX, WPARAM(@textlen), 0);
|
len := SendMessage(RichEditWnd, EM_GETTEXTLENGTHEX, WPARAM(@textlen), 0);
|
||||||
|
writeln('TextStart = ', TextStart);
|
||||||
|
writeln('TextLength = ', len);
|
||||||
|
|
||||||
sel.cpMin := TextStart;
|
sel.cpMin := TextStart;
|
||||||
sel.cpMax := len;
|
sel.cpMax := len;
|
||||||
@ -192,13 +194,31 @@ begin
|
|||||||
|
|
||||||
FillChar(fmt, sizeof(fmt), 0);
|
FillChar(fmt, sizeof(fmt), 0);
|
||||||
fmt.cbSize := sizeof(fmt);
|
fmt.cbSize := sizeof(fmt);
|
||||||
SendMessage(RichEditWnd, EM_GETCHARFORMAT, SCF_SELECTION, PtrInt(@fmt));
|
|
||||||
|
//todo: BOOST PERFORMANCE!!!
|
||||||
|
sel.cpMax := TextStart;
|
||||||
|
repeat
|
||||||
|
inc(sel.cpMax);
|
||||||
|
SendMessage(RichEditWnd, EM_EXSETSEL, 0, LPARAM(@sel));
|
||||||
|
SendMessage(RichEditWnd, EM_GETCHARFORMAT, SCF_SELECTION, PtrInt(@fmt));
|
||||||
|
until (sel.cpMax > len) or ((fmt.dwMask and ALL_MASK) <> ALL_MASK);
|
||||||
|
|
||||||
|
last := sel.cpMax;
|
||||||
|
sel.cpMin := TextStart;
|
||||||
|
sel.cpMax := TextStart+1;
|
||||||
|
repeat
|
||||||
|
dec(sel.cpMin);
|
||||||
|
SendMessage(RichEditWnd, EM_EXSETSEL, 0, LPARAM(@sel));
|
||||||
|
SendMessage(RichEditWnd, EM_GETCHARFORMAT, SCF_SELECTION, PtrInt(@fmt));
|
||||||
|
until ((fmt.dwMask and ALL_MASK) <> ALL_MASK) or (sel.cpMin < 0);
|
||||||
|
inc(sel.cpMin);
|
||||||
|
|
||||||
|
{ SendMessage(RichEditWnd, EM_GETCHARFORMAT, SCF_SELECTION, PtrInt(@fmt));
|
||||||
|
|
||||||
|
|
||||||
if fmt.dwMask and ALL_MASK <> ALL_MASK then begin
|
if fmt.dwMask and ALL_MASK <> ALL_MASK then begin
|
||||||
rngend := len;
|
d := (len - sel.cpMin) div 2;
|
||||||
d := rngend - sel.cpMin;
|
sel.cpMax := sel.cpMin + d;
|
||||||
sel.cpMax := sel.cpMin + d div 2;
|
|
||||||
while d > 1 do begin
|
while d > 1 do begin
|
||||||
SendMessage(RichEditWnd, EM_EXSETSEL, 0, LPARAM(@sel));
|
SendMessage(RichEditWnd, EM_EXSETSEL, 0, LPARAM(@sel));
|
||||||
SendMessage(RichEditWnd, EM_GETCHARFORMAT, SCF_SELECTION, PtrInt(@fmt));
|
SendMessage(RichEditWnd, EM_GETCHARFORMAT, SCF_SELECTION, PtrInt(@fmt));
|
||||||
@ -208,10 +228,26 @@ begin
|
|||||||
else
|
else
|
||||||
sel.cpMax := sel.cpMax - d;
|
sel.cpMax := sel.cpMax - d;
|
||||||
end;
|
end;
|
||||||
end;
|
|
||||||
|
if (fmt.dwMask and ALL_MASK) = ALL_MASK then begin
|
||||||
|
repeat
|
||||||
|
inc(sel.cpMax);
|
||||||
|
SendMessage(RichEditWnd, EM_EXSETSEL, 0, LPARAM(@sel));
|
||||||
|
SendMessage(RichEditWnd, EM_GETCHARFORMAT, SCF_SELECTION, PtrInt(@fmt));
|
||||||
|
writeln(sel.cpMax, ' ', (fmt.dwMask and ALL_MASK) <> ALL_MASK);
|
||||||
|
until (sel.cpMax = len) or ((fmt.dwMask and ALL_MASK) <> ALL_MASK);
|
||||||
|
end else begin
|
||||||
|
repeat
|
||||||
|
dec(sel.cpMax);
|
||||||
|
SendMessage(RichEditWnd, EM_EXSETSEL, 0, LPARAM(@sel));
|
||||||
|
SendMessage(RichEditWnd, EM_GETCHARFORMAT, SCF_SELECTION, PtrInt(@fmt));
|
||||||
|
until (sel.cpMax <= sel.cpMin) or ((fmt.dwMask and ALL_MASK) = ALL_MASK);
|
||||||
|
end;
|
||||||
|
end;}
|
||||||
|
|
||||||
RangeStart := sel.cpMin;
|
RangeStart := sel.cpMin;
|
||||||
RangeLen := sel.cpMax - sel.cpMin;
|
RangeLen := last - sel.cpMin - 1;
|
||||||
|
writeln('Range Start = ', RangeStart, ' Len = ', RangeLen);
|
||||||
Result := true;
|
Result := true;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user