Sublime Forum

Can we get multiple selections by columns numbers?

#1

Hi, I put a question in StackOverflow, and I´d like to put it here too.
It’s about getting multiple selections based on column numbers.

Can we get multiple selections by columns numbers?

0 Likes

#2

How would you envision this working? Like, you hit a key, a panel opens where you enter column numbers separated by commas, and the selections are added? Would it only work if there’s already text selected, or once for each line that already has a cursor in it? What should happen if you specify a column and a line doesn’t go that far?

0 Likes

#3

This new functionallity could be in the “Selection” menu, I guess.
I think the most effective way could be something like the “Replace” funcionallity ( CTRL + H ), that has a complete interface with input fields, buttons for options and commands, and output messages in the status bar. I wonder how difficult it would be to replicate it and make the adjustments.
But the way you describe it would be useful already. I wonder if this could be more simple at first to implement. So I should select the lines, call a panel and input the list of numbers. The selections would be put considering the longest line, and the shortest line would need some extra blank spaces to get the same size column as the longest line ( like the plugin Align Tab does ) for having the selection in the same position.
Anyway, like I said I think I could find some plugin for that but I didn’t find.
I imagined this when I had to manipulate a data file that I got from mainframe and I knew the fixed lenght of all the fields, but there wasn’t separation or spaces. Even using Calc it were not so easy to handle.

0 Likes