plugin Cuda-Ext Align

Plugins for SynWrite and CudaText...
LuNik700
Posts: 18
Joined: 21.08.2021 14:56

plugin Cuda-Ext Align

Post by LuNik700 »

Hello,
I quite new to CudaText but it seems to be a great editor for my needs. I would like to switch from VS Code cause CudaText is much more light weighted, offers great functionality and in my eyes has a better UI with an old-style toolbar.
I use it mainly for coding SQL and PL/SQL.

There is functionality I miss in the plugin Cuda-Ext respectively it does not work and doesn't offer enough flexibilty for aligning.

What I want is
1: align text for positions of carets in multiple lines
2: align text for selected text according to a flexible separator

I think the first functionality is absend at the moment!?!
"Cuda-Ext| Align |Align comma separated columns in selected lines" seens to work solely for a "," as a separator not for ";" or "|" ...
For the second request there is given functionality in the plugin Cuda-Ext ( Cuda-Ext| Align | Align in lines by separator ) but this sometimes behaves strange and works (if it works) only for the first occurance of the separator in a line ...

For example:
123; 2345; 234
23456;7868;2
45;frsf;afaf

results with ";" as separator in:
123 ; 2345; 234
23456;7868;2
45;frsf;afaf
(with the text being aligned in the first 2 lines at ";", but nothing more ...)

Another example with "X" as the chosen separator:
123 X 2345 234
23456X78682
45Xfrsfafaf

results in:
123 X 2345 234
23456X78682
45Xfrsfafaf
(with the text being aligned in the first 2 lines at "X" but not in the 3rd line)

Can somebody help? Do I use the plugin in a wrong way??? is there an alternative?

Best regards
Ludger
uvviewsoft
Posts: 392
Joined: 01.12.2020 13:46

Post by uvviewsoft »

Thanks for report about CudaExt. Author is @kvichans but maybe I will try to fix that.

ps. Please use code-blocks of PHPBB forum.
uvviewsoft
Posts: 392
Joined: 01.12.2020 13:46

Post by uvviewsoft »

About command "Align in lines by separator". It works ok. I checked it. Maybe you didn't select n lines before the command?

Before the command:
Screenshot from 2021-08-21 20-53-26.png
Call the command, enter ';', it gives
Screenshot from 2021-08-21 20-53-33.png
It works for FIRST separator in line.
LuNik700
Posts: 18
Joined: 21.08.2021 14:56

Post by LuNik700 »

Hi,
thanks for your quick reply! I did select the lines I wanted to apply that alignment to ...

Your example works with me as well! That's the strange thing ... in some (perhaps the most) cases ist works but sometimes it shows really strange behavior.

But just as example for the unexpected behavior ... if you mark the whole text and then align using ";" as the separator character then the last line ist skipped ...

Code: Select all

ddd,dddd,dddd
ddd;dddd;dddd
ddddddd;dddd;dddd
ddd;ddddddddd;dddd
dd;dddd;ddddddd
dddddddd;dddd

Code: Select all

ddd,dddd,dddd
ddd    ;dddd;dddd
ddddddd;dddd;dddd
ddd    ;ddddddddd;dddd
dd     ;dddd;ddddddd
dddddddd;dddd
Sorry I'm looking for a way to insert the corresponding screenshots, but I can't find a way to do that ([img] is off) ... Sorry, I'm not familiar with this forum software.

Best regards
Ludger
LuNik700
Posts: 18
Joined: 21.08.2021 14:56

Post by LuNik700 »

... and I forget to mention that if you select from the end to the beginning of the text (the opposite way you normally do) then the alignment doesn't work at all. Perhaps that is not common but sometimes I do it that way round ...

Have a nice weekend
Ludger
uvviewsoft
Posts: 392
Joined: 01.12.2020 13:46

Post by uvviewsoft »

>if you mark the whole text and then align using ";" as the separator character then the last line ist skipped ...

Well, I didn't repeat it. I got -
Screenshot from 2021-08-21 23-24-42.png
Attach images by clicking 'Full editor' button in forum's reply. it has "Upload attachement" tab on bottom.
uvviewsoft
Posts: 392
Joined: 01.12.2020 13:46

Post by uvviewsoft »

(Maybe post the video here? which shows your steps.)

About custom separator for the "Align comma-separated columns"- it will be implemented soon.
LuNik700
Posts: 18
Joined: 21.08.2021 14:56

Post by LuNik700 »

Attach images by clicking 'Full editor' button in forum's reply. it has "Upload attachement" tab on bottom.
I think I should get myself new glasses ... Got it!
About custom separator for the "Align comma-separated columns"- it will be implemented soon.
That is great news!!! Thanks in advance!!!

Here are the corresponding screenshots:
Selection.JPG
Separator.JPG
Alignment.JPG
Best regards and thx
Ludger

PS. If you need a video for further clarification please let me know. I will then look for a way to record one ...
uvviewsoft
Posts: 392
Joined: 01.12.2020 13:46

Post by uvviewsoft »

I confirm it, when last line don't have a EOL mark. To-fix.
uvviewsoft
Posts: 392
Joined: 01.12.2020 13:46

Post by uvviewsoft »

Posted
issue https://github.com/kvichans/cuda_ext/issues/182
and issue https://github.com/kvichans/cuda_ext/issues/183

Pls wait because @kvichans is busy for some days.
Post Reply