* * *

Author Topic: ATSynEdit: cooking feature  (Read 1639 times)

Alextp

  • Sr. Member
  • ****
  • Posts: 412
    • UVViewSoft
ATSynEdit: cooking feature
« on: December 22, 2016, 06:56:50 pm »
The Brackets app has such feature, inline editors -
https://www.andrewmunsell.com/wp-content/uploads/2015/06/04.png

Cannot do it now, but made step to it. this is feature in ATSynEdit, gaps.
Picture in attach.
The doc about gaps is here, describes some details about it -
http://wiki.freepascal.org/ATSynEdit#Gaps_object

The code in trunk has it (at GH)
I want to use it, to preview pictures in my app, as small reduced pic.

Alextp

  • Sr. Member
  • ****
  • Posts: 412
    • UVViewSoft
Re: ATSynEdit: cooking feature
« Reply #1 on: January 31, 2017, 07:28:46 pm »
Update.

Finder class (for ATSynEdit) now extended -

- supports option InSelection (do the find/replace only in selection)
- and now this InSelection opt extended. It now supports several selections - for carets,
which have selections. This supported for Count-all, Mark-all, Replace-all.

- for Find its not  needed to support InSelection, coz FindNext does selection of found text;
so smaller selection made, so InSelection cannot work
« Last Edit: January 31, 2017, 07:30:20 pm by Alextp »

Alextp

  • Sr. Member
  • ****
  • Posts: 412
    • UVViewSoft
Re: ATSynEdit: cooking feature
« Reply #2 on: February 16, 2017, 04:40:04 pm »
Update

now mouse clicks are configurable via array of actions.
Click, Shift-click, Ctrl-click, Ctrl+Shift-click, middle click, right click.

In code config filled in InitMouseActions() like this--

Code: Pascal  [Select]
  1.   Add(cMouseActionClickSimple, [ssLeft]);
  2.   Add(cMouseActionClickSimple, [ssLeft, ssAlt]);
  3.   Add(cMouseActionClickSimple, [ssLeft, ssAltGr]);
  4.   Add(cMouseActionClickRight, [ssRight]);
  5.   Add(cMouseActionClickAndSelBlock, [ssLeft, ssShift]);
  6.   Add(cMouseActionMakeCaret, [ssLeft, ssXControl]);
  7.   Add(cMouseActionMakeCaretsColumn, [ssLeft, ssXControl, ssShift]);
  8.   Add(cMouseActionNiceScrolling, [ssMiddle]);
  9. end;
  10.  


Alextp

  • Sr. Member
  • ****
  • Posts: 412
    • UVViewSoft
Re: ATSynEdit: cooking feature
« Reply #3 on: March 16, 2017, 09:41:25 pm »
Update

2 new properties added
- OptMouseDragDropCopying - allow to copy with dragdrop with Ctrl key
- OptMouseDragDropCopyingWithState - key which does copy, e.g. ssCtrl/ssAlt

Alextp

  • Sr. Member
  • ****
  • Posts: 412
    • UVViewSoft
Re: ATSynEdit: cooking feature
« Reply #4 on: May 25, 2017, 11:40:28 am »
Update.

Finder class very much optimized. Now mass-find and mass-replace do 2 stages:

1) DoCollect methods collect all matches to list. they can also show replace-confirm for mass-replace.
2) Operation takes resulting list. Mass-replace reads list from end to begin and does mass-replace in one go. w/o updating buffers.

So mass-replace works 3 seconds instead of 70 seconds before (on big test file).
« Last Edit: May 25, 2017, 11:42:50 am by Alextp »

Alextp

  • Sr. Member
  • ****
  • Posts: 412
    • UVViewSoft
Re: ATSynEdit: cooking feature
« Reply #5 on: June 19, 2017, 04:51:19 pm »
Update

Added OptBorder*** props, and removed not needed OptBorderVisible.
now control has border of any size [0: hidden, 1+: shown]

Property can  set new border size of focused control.
And color exists for border of focused control.
So if control focused [eg, input in Find dialogs] it can be with blue 3pixel border. Like PyCharm.

Picture of  test



Alextp

  • Sr. Member
  • ****
  • Posts: 412
    • UVViewSoft
Re: ATSynEdit: cooking feature
« Reply #6 on: July 06, 2017, 12:36:33 pm »
Added option:
OptMouseColumnSelectionWithoutKey

and 2 commands:
"column select without key modifier: on/ off"

when option is on, usual mouse dragging makes column selection (vertical).
when off [default], normal stream selection.

Alextp

  • Sr. Member
  • ****
  • Posts: 412
    • UVViewSoft
Re: ATSynEdit: cooking feature
« Reply #7 on: July 11, 2017, 07:52:49 pm »
Improved option above:
when it is on, also Shift+arrows, Shift+home/end/pageup/pagedown, work in other way- they do column selection (usually they make stream selection).
This is like programs do:
-SynWrite
-PSPad
-ConTEXT
-RJ TextEd

Alextp

  • Sr. Member
  • ****
  • Posts: 412
    • UVViewSoft
Re: ATSynEdit: cooking feature
« Reply #8 on: July 11, 2017, 08:00:06 pm »
Some days ago:
reworked function (it's very big and complex) which calculates color fragments.
Wrote text (long) about it:
http://wiki.freepascal.org/ATSynEdit#Details_about_highlighting_rendering
« Last Edit: July 11, 2017, 08:02:24 pm by Alextp »

timofonic

  • Newbie
  • Posts: 4
Re: ATSynEdit: cooking feature
« Reply #9 on: July 18, 2017, 03:13:24 am »
I wonder if this can be used by Lazarus IDE itself or already provides a functionally equivalent implementation...

Alextp

  • Sr. Member
  • ****
  • Posts: 412
    • UVViewSoft
Re: ATSynEdit: cooking feature
« Reply #10 on: July 18, 2017, 09:55:29 am »
What can be used? ATSynEdit in Lazarus IDE cannot be used. IDE cannot use another editor component.

JD

  • Hero Member
  • *****
  • Posts: 1573
Re: ATSynEdit: cooking feature
« Reply #11 on: July 18, 2017, 11:45:29 am »
I wonder if this can be used by Lazarus IDE itself or already provides a functionally equivalent implementation...

AFAIK this component is already in use in Alextp's CudaText application http://uvviewsoft.com/cudatext/
Windows (10, 7) - Lazarus 1.6.4/FPC 3.0.2 (also Delphi occasionally)
Linux Mint Cinnamon  - Lazarus 1.4/FPC 2.6.4
Indy 10.6 series; Zeos 7.2.1; SQLite, Firebird, PostgreSQL & MariaDB

 

Recent

Get Lazarus at SourceForge.net. Fast, secure and Free Open Source software downloads Open Hub project report for Lazarus