Whitespaces indenting insted of tabs

Post your questions and problem reports here

Moderator: kfury77

Forum rules
Please try to follow these guidelines. This will help to receive faster and more accurate response.
  • Check the Support section of the corresponding product first. Chances are you will find your answer there;
  • Do not create new topics for already reported problems. Add your comments to the existing topics instead;
  • Create separate topic for each problem request. Do NOT post a number of non-related problem reports in a single topic;
  • Give your topic a meaningful title. Titles such as "A question," "Bug report" and "Help!" provide others no clue what your message is about;
  • Include the version number of the software you are using;
  • This is not an official customer support helpdesk. If you need a prompt and official response, please contact our support team directly instead. It may take a while until you receive a reply in the forum;
Post Reply
chemist
Posts: 6
Joined: Fri Aug 29, 2008 11:10 pm

Whitespaces indenting insted of tabs

Post by chemist »

I think it is bug. It was allways and i'm afraid of this bug will not be improved in the next version of the editors.

So in the all editors (HTMLPad, Rapid PHP and WeBuilder) there are some features for helping coding. For example: you can press Ctrl+T for placing the table, or you can select few strings and press another shortcut for transforming the strings to list. Also you can use snippets. In all of this cases you get many whitespaces instead of tabs.

And the similar problem while editing css-files. When i type "{" and press Enter, i get opened brace on the first line, 4 whitespaces on the second line and closed brace on the third line.

Could you please improve this?
davenz

Re: Whitespaces indenting insted of tabs

Post by davenz »

While I am not exactly sure what you mean, I tried your examples as suggested and cannot reproduce this at all. I tried all the examples in WB, RapidCSS and HTMLPad all behave the same way, that is, no whitespace except that which, as far as I am aware, should be there. The example below is in WeBuilder 08 and shows exactly what happens in a CSS file when I have typed in one { - the rest is autocompleted and 1 space is added and indented ready for the selector.

Image

I must be doing something different than you, so perhaps you could clarify and perhaps post an image of what you are getting there?

Dave.
x3po
Posts: 139
Joined: Fri May 16, 2008 10:48 am

Re: Whitespaces indenting insted of tabs

Post by x3po »

I can approve that for WB, latest version:

Image

After inserting the opening brace, the cursor jumps into the next line and inserts 4 whitespaces instead of a tab.
davenz

Re: Whitespaces indenting insted of tabs

Post by davenz »

The only way I can replicate your symptoms is to alter the indent settings in the program options; if I set it to 4 I get the same 4 spaces as you get. I guess WeBuilder is doing exactly what we tell it to. It will be interesting to see what your settings are.

I have no idea what the default settings are - I don't recall changing mine but then again, my memory isn't what it used to be, as far as I can remember. My current settings are as follows:

Image

Cheers

Dave.
x3po
Posts: 139
Joined: Fri May 16, 2008 10:48 am

Re: Whitespaces indenting insted of tabs

Post by x3po »

davenz wrote: Image
No, that does not help.
I just get 1, instead of 4, whitespaces then.
User avatar
EvilBMP
Posts: 120
Joined: Thu Jan 04, 2007 1:57 am
Location: Germany

Re: Whitespaces indenting insted of tabs

Post by EvilBMP »

The indenting system of WeBuilder truly is buggy ... and I also commited this bug before ... see http://forums.blumentals.net/viewtopic.php?f=4&t=3316

That's why I went back to spaces for indenting, cause everything is working fine then, but often this is against coding guidelines :(
User avatar
Karlis
Site Admin
Posts: 3605
Joined: Mon Jul 15, 2002 5:24 pm
Location: Riga, Latvia, Europe
Contact:

Re: Whitespaces indenting insted of tabs

Post by Karlis »

1) I wonder WHY you have "Convert TABS to spaces" ON if you want to have TABS for indenting? You should NOT use "Convert TABS to spaces" IF you want to use TABS.

If you have Indent = 1, Tab width = 4 and "Convert tabs to spaces" on -> when single tab is about to be inserted, it is converted to 4 spaces, because you have specified that you want toabs to be converted to spaces and the tab width is 4 spaces as you have set up.

2) Not all features are tied to these settings. E.g. code snippets are static pieces of code and will be inserted as-is without any pre-processing.

3) Indeed there is a bug with CSS auto indent. There is no bug with PHP auto indent, however.
Karlis Blumentals
Blumentals Software
www.blumentals.net
chemist
Posts: 6
Joined: Fri Aug 29, 2008 11:10 pm

Re: Whitespaces indenting insted of tabs

Post by chemist »

Are this settings correct?
Image

In the begining there is one TAB
Image

Press Ctrl+T and insert the table with 1 row and 5 cells
Image

Returned to the one TAB and inserted the snippet "Horizontal Menu"
Image
User avatar
EvilBMP
Posts: 120
Joined: Thu Jan 04, 2007 1:57 am
Location: Germany

Re: Whitespaces indenting insted of tabs

Post by EvilBMP »

Imho, settings for tab indent
Image

fetch (callword for a selfmade snippet)
Imageins
after Ctrl+J -> the bar symbol is another bug, because within the snippet editor it's a c&p Tab
Image



Imho, settings for tab indent without automatic remove of whitespace
Image

again the fetch snippet
Image
after Ctrl+J -> same bar symbol occurs ... tab before snippet remains - strange :D
Image


In conclusion, thats why I have to use space indenting. Currently I use the first settings, but with convert tabs to spaces enabled too and with space chars within snippets instead of tabs - then everything works like a charme, but sadly only then...

Greets, Evil

PS: Just in addition ... some software projects have complex coding guidelines ... where for example the initial indent has to be done with tabs and indents within the code have to be done with spaces! To enable this behaviour in WeBuilder would be a dream ;) But I am realistic...
Image

Keep up the work, Evil
User avatar
Karlis
Site Admin
Posts: 3605
Joined: Mon Jul 15, 2002 5:24 pm
Location: Riga, Latvia, Europe
Contact:

Re: Whitespaces indenting insted of tabs

Post by Karlis »

* Insert HTML tag features are detached from indenting settings, so they use only spaces (e.g. Insert Table)
* Yes, there is a problem (already registered) with snippet insertion (the first line still is spaces although it is better than it was when all lines were indented with spaces)
Karlis Blumentals
Blumentals Software
www.blumentals.net
User avatar
Karlis
Site Admin
Posts: 3605
Joined: Mon Jul 15, 2002 5:24 pm
Location: Riga, Latvia, Europe
Contact:

Re: Whitespaces indenting insted of tabs

Post by Karlis »

Improvement is expected in version 2010 in this area.
Karlis Blumentals
Blumentals Software
www.blumentals.net
Post Reply