Page 1 of 1

FAR3: Macro "Align Block Special" for Editor

Posted: Tue 07 May, 2013 09:56
by farman
So here's another version of an "Align Block" macro for Editor, dedicated to the masters of Macros SimSU, Aidar and Shmuel. Most of the code is stolen from them. A big thanx to you, guys.

This is a specialized version. Mostly doing the same things than the other "Align Block" addons. There are some special additions:
- Autoindent paragraphs with bullets or numbers
- Some special CleanUp and Format functions

The big advantages are, that this macro is well commented (in English :-)) and you can easily fix it to your needs .
The macro seems to work well. If you discover any critical error please let me know.

Have fun.


Re: FAR3: Macro "Align Block Special" for Editor

Posted: Tue 07 May, 2013 10:24
by Shmuel
farman
Thank you for sharing. I'll give it a try later.
-- It seems when the size of code exceeds ~100 lines, attaching the zipped file to the message (along with posting the code) may be good idea.
-- The "DisableOutput" flag does not exist anymore and can be safely deleted.

-- Are you aware that in the lines like the following only 1-st variable is local?
  1. local id_RightMargin=2  id_UseAutoIndent=4  id_IndentFirstLine=5  id_IndentLeft=7

Re: FAR3: Macro "Align Block Special" for Editor

Posted: Wed 08 May, 2013 06:29
by farman
Well, some things in lua seems to be very special...
Thanx, Shmuel.
I've fixed fixed that.

Re: FAR3: Macro "Align Block Special" for Editor

Posted: Wed 08 May, 2013 06:58
by Shmuel
farman wrote:Well, some things in lua seems to be very special...
Usually, it looks like this in Lua:
  1. local a,b,c,d = 2,4,5,7