Author Topic: A problem about source code formation  (Read 4962 times)

Offline mousefire

  • Single posting newcomer
  • *
  • Posts: 3
A problem about source code formation
« on: March 20, 2008, 09:23:02 am »
after I type:
if(test>num)
and then the key "enter"
the editor can't auto indent to such formation:

if(test>num)
  code.....

I know After using the plugin "Astyle" the code can be changed to the formation I want, but how can I make it just as I like when I ented in the codes?

Offline Ceniza

  • Developer
  • Lives here!
  • *****
  • Posts: 1441
    • CenizaSOFT
Re: A problem about source code formation
« Reply #1 on: March 20, 2008, 09:45:50 am »
Code::Blocks only 'smart indents' when you add a { and press enter. It also 'smart unindents' when you add a }. Just another way to do it is with abbreviations (check Settings->Editor [Abbreviations]).

Offline mousefire

  • Single posting newcomer
  • *
  • Posts: 3
Re: A problem about source code formation
« Reply #2 on: March 20, 2008, 09:52:36 am »
Code::Blocks only 'smart indents' when you add a { and press enter. It also 'smart unindents' when you add a }. Just another way to do it is with abbreviations (check Settings->Editor [Abbreviations]).
Eh....Maybe I will always add a '{' after the key world if(),while(),for(;;)........
and,will the following editons of code::blocks solve it?

Offline Ceniza

  • Developer
  • Lives here!
  • *****
  • Posts: 1441
    • CenizaSOFT
Re: A problem about source code formation
« Reply #3 on: March 20, 2008, 10:01:49 am »
will the following editons of code::blocks solve it?

I don't know, but you can add a Feature request if you want here. You can also provide the patch here. (You must have a BerliOS account to do that)

Offline mousefire

  • Single posting newcomer
  • *
  • Posts: 3
Re: A problem about source code formation
« Reply #4 on: March 20, 2008, 10:10:07 am »
will the following editons of code::blocks solve it?

I don't know, but you can add a Feature request if you want here. You can also provide the patch here. (You must have a BerliOS account to do that)

Ok, thank you. I will add a Feature request.