![](/ubb/images/icons/default/book.gif) Re: enhancement request
|
Joined: Apr 2004
Posts: 203 NYC, USA
Member
|
Member
Joined: Apr 2004
Posts: 203 NYC, USA |
PlSQLDev Version 8.0.4 Oracle 11gR2
|
|
|
![](/ubb/images/icons/default/book.gif) Re: enhancement request
|
Joined: Feb 2005
Posts: 59 Latvia
Member
|
Member
Joined: Feb 2005
Posts: 59 Latvia |
Tabs, by the way, are better than spaces... Tabs in PLSQLDEV can be shown as any amount of *spaces*, so you control look of the code, idents and stuff, but if you use space, well, space is space, one symbol, that's it... less flexible... I like them...
regards Kirurgs
|
|
|
![](/ubb/images/icons/default/book.gif) Re: enhancement request
|
Joined: Sep 2003
Posts: 387 London, UK
Member
|
Member
Joined: Sep 2003
Posts: 387 London, UK |
I've always liked tabs, but I'm having to give them up for SQL and PL/SQL because no editor currently supports them for these languages. (I guess Vim could do so if I could learn its indentation macro language and submit a language pack, but life's too short.) It would be nice if PL/SQL Developer could do so, but if that is (as it seems) not possible then I agree it would be useful to have features for (1) highlighting them using symbols or colours, and (2) intelligently replacing them (though the regexp replace already works pretty well).
|
|
|
![](/ubb/images/icons/default/book.gif) Re: enhancement request
|
Joined: Apr 2003
Posts: 517 Portland, OR, USA
Member
|
Member
Joined: Apr 2003
Posts: 517 Portland, OR, USA |
That's an interesting discussion about tabs. Tabs have been shunned where I work, because everyone had a different setting for how much space a tab took. It would look great on one person's computer and be all messed up on another. With spaces, it looks the same for everybody. I guess we all have preferences.
I was wondering what the regular expressions are. So far, I only know \t is tabs because of this forum. I looked in the manual and I can't find them. It just says to check the box and I can use regular expressions. Did I miss it?
Thanks,
Mike
|
|
|
![](/ubb/images/icons/default/book.gif) Re: enhancement request
|
Joined: Sep 2003
Posts: 387 London, UK
Member
|
Member
Joined: Sep 2003
Posts: 387 London, UK |
> Tabs have been shunned where I work, because everyone had a different setting for how much space a tab took. It would look great on one person's computer and be all messed up on another.
No! Used correctly they do not break alignment. Unfortunately without a language-aware editor that supports tabs it takes a certain amount of discipline.
Obviously you would not use a tab after any character other than another tab or a newline, and ideally an editor would make it hard to do so by accident.
An editor that supported tabs would also switch from tabs to spaces at the right point in the line (i.e. directly under the start of an SQL statement) rather than blindly adding tabs up to the start of the text.
This is not a problem for procedural code such as (for example) shell script or indeed procedural sections within PL/SQL. It's SQL that needs blank-padding with odd amounts of spaces (not tabs), and AFAIK no editor exists that supports this.
|
|
|
![](/ubb/images/icons/default/book.gif) Re: enhancement request
|
Joined: Dec 2002
Posts: 491 Wellington, NZ
Member
|
Member
Joined: Dec 2002
Posts: 491 Wellington, NZ |
so, what happens when you use a proportional font? tabs look all screwed up for me.
i agree with RobertK, "death to the tab button!!"
... suck in your lips and frown like a werewolf ...
|
|
|
![](/ubb/images/icons/default/book.gif) Re: enhancement request
|
Joined: Jul 2004
Posts: 281 The Netherlands
Member
|
Member
Joined: Jul 2004
Posts: 281 The Netherlands |
Comming from a Fortran77 background I've spent hours trying to figure out why some piece of code could not compile, finally figuring out that it was caused by the tabs I used instead of spaces.
Ever since then 'spaces + non-proportional font' has been the thing for me.
Then again, I don't like apple pie, whereas some others do :-)
Been there, done that, Got the T-Shirt
|
|
|
![](/ubb/images/icons/default/book.gif) Re: enhancement request
|
Joined: Dec 2001
Posts: 73 Cedar Hills, UT
Member
|
Member
Joined: Dec 2001
Posts: 73 Cedar Hills, UT |
While editing PL/SQL code, there are only a few things I still have to use my favorite editor (UltraEdit) for:
Removing CR/LF characters from a list to "flatten" it into a single comma-delimited string.
Trim trailing spaces.
Convert tabs to spaces.
Powerful column-mode editing.
Quickly copying the full path and filename of the current file to my clipboard (which I now do from within xplorer2 from zabkat). This is used when running SQL scripts from the Command window or from SQL*Plus.
And powerful, regexp search/replace in files that can recurse through subdirectories to change all code for a given project.
If PL/SQL Dev could include these functions, I could kiss my text editor goodbye.
bc
|
|
|
![](/ubb/images/icons/default/book.gif) Re: enhancement request
|
Joined: Sep 2003
Posts: 387 London, UK
Member
|
Member
Joined: Sep 2003
Posts: 387 London, UK |
> so, what happens when you use a proportional font? tabs look all screwed up for me.Now you've lost me. What does a proportional font have to do with tab alignment? Say the start of a block of code is 3 tab stops in from the margin. That will come to whatever width 3 tabs stops are displayed as in your editor, regardless of the font. It will still be vertically aligned with anything else indented by 3 tab stops. But when would you look at code in a proportional font anyway? A proportional font screws up your alignment on its own, regardless of tabs. For example, SELECT col1
, col2
FROM sometable I need col2 to be aligned under col1, which a proportional font would not do.
|
|
|
![](/ubb/images/icons/default/book.gif) Re: enhancement request
|
Joined: Dec 2005
Posts: 2,004 Roima Denmark
Member
|
Member
Joined: Dec 2005
Posts: 2,004 Roima Denmark |
To Marco. bcoulam said: [quote]Trim trailing spaces. Convert tabs to spaces.[/quote]When will this be implemented? I use an editor like EditPlus for these special tasks, and I assume that the developers of PL/SQL Developer do not want to throw us all in the arms of other editors? A lot of our older code is edited in Wordpad (sigh!) and tabs are used extensively. The tab size must somehow be stated before conversion, editors like Notepad use a tab stop of 8 whereas for instance Wordpad uses 6. This must be configurable. Please note: replacing tabs with spaces is not just a simple matter of search and replace. In an editor with a tab stop of 8, a line of code that is 11 characters long followed by a tab and more code would have the result that the rest of the code begins at column 16 (always a multiplum of 8) and not just 8 columns to the right of the current position. This is important to remember so tabbed code look the same after conversion. I will look forward to this enhancement ![cool cool](/ubb/images/graemlins/default/cool.gif)
|
|
|
|
|