<div dir="ltr"><div class="gmail_quote">On Fri, Apr 22, 2011 at 5:35 PM, Martin <span dir="ltr"><<a href="mailto:lazarus@mfriebe.de">lazarus@mfriebe.de</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;">
<div class="im"><br>
<blockquote class="gmail_quote" style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;">
<br>
<a href="http://bugs.freepascal.org/view.php?id=19215" target="_blank">http://bugs.freepascal.org/view.php?id=19215</a><br>
<br>
Please check this lines in SynTextDrawer<br>
<br>
procedure TheFontStock.SetStyle(Value: TFontStyles);<br>
<br>
// ASSERT(idx <= High(TheStockFontPatterns)); //Check this line<br>
<br>
<br>
SY<br>
Zaher Dirkey<br>
<br>
</blockquote>
<br>
<br></div>
I will look at it in due course.<br>
<br>
In case... your clean up may be so you can add features later; and seeing you gone for TextDrawer first.<br>
<br>
If you want to add features around drawing, here are a few of my ideas (all without any idea when..., just distant ideas)<br></blockquote><div><br>The real reason to choose TextDrawer it is simple to start, and i have problem with my highlighter printing the text, my bug not catches yet.<br>
 <br></div><blockquote class="gmail_quote" style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;">
<br>
1) Introduction of a TSynCanvas<br>
  - More or less to wrap the TSynEdit.Handle<br>
  - The class could be known by other classes in SynEdit (without circle references) and would be used for any Invalidate, invalidateLines, invalidateRect request.<br>
  - Maybe also for painting, so painting is in an event, and the handle is passed in by the caller.<br>
    Also painting is done from other classes, more below<br>
<br>
2) Introduction of a TSynViewPort (or TsynEditViewPort)<br>
  represents the textarea (as opposed to gutter).<br>
  SynEdit takes care of the layout (eg Gutter AlLeft, ViewPort alClient...), and the classes are responsible for the painting, (using TsynCanvas, and the arguments to the paint event)<br>
<br>
  TSynViewPort will also be responsible to store TopLine, LeftChar, LinesInWindow, CharsInWindow<br>
  TSynViewPort would still use TextDrawer, but some stuff may move...<br>
<br>
----<br>
Ideally this would even allow to have none LCL versions, like fpgui, msegui, or delphi... => but that is a long way<br>
<br>
You are af course invited to bring up your ideas too.<div><div></div><div class="h5"><br></div></div></blockquote><div><br>It is need more understand the SynEdit and more discusses, I also have some feature like to have it in the SynEdit.<br>
<br>Thanks<br> </div>-- <br></div>Zaher Dirkey<br>
</div>