Thread: Indentation in Code::Blocks

  1. #1
    Registered User
    Join Date
    Nov 2004
    Location
    USA
    Posts
    516

    Indentation in Code::Blocks

    I recently switched from Dev-Cpp to Code::Blocks. I love the interface but there is this small problem that is bothering me. Whenever i save the file and the cursor is on a line with no text it goes to the start of the line, i have to press tab many times to get it to where it was so as to maintain indentation. Its irritating at times Is there any way to stop the cursor from going to the start of the line ?
    Code:
    >+++++++++[<++++++++>-]<.>+++++++[<++++>-]<+.+++++++..+++.[-]>++++++++[<++++>-] <.>+++++++++++[<++++++++>-]<-.--------.+++.------.--------.[-]>++++++++[<++++>- ]<+.[-]++++++++++.

  2. #2
    Ex scientia vera
    Join Date
    Sep 2007
    Posts
    477
    I just switched myself - due to Dev-C++'s lack of maintenance, Code::Blocks is a hundred times better, and I curse myself to ashes for not having installed it before.

    Anyway, I noticed the think you're talking about, too, but it doesn't really bother me. Try sending them a mail?

    Btw, erasing the newline and going on the line above, then pressing enter, should get you back to your preferred level of indentation.
    Last edited by IceDane; 03-16-2008 at 06:55 PM.

  3. #3
    pwns nooblars
    Join Date
    Oct 2005
    Location
    Portland, Or
    Posts
    1,094
    The tip IceDane suggests is what I do, what you may want to look for is the remove white space setting. I remember seeing it but I am not on a computer with it installed at the moment.

  4. #4
    Registered User
    Join Date
    Jan 2008
    Posts
    290
    Have any of you guys tried compiling Code::Blocks yourselves, or do you use the binary package?

    I had a hell of time trying to compile it myself, and I eventually just gave up. I'll give it another try some day.

    [edit] Good god that was horribly off topic. I'm sorry. [/edit]

  5. #5
    C++まいる!Cをこわせ!
    Join Date
    Oct 2007
    Location
    Inside my computer
    Posts
    24,654
    Eh, what's the need of compiling it yourself?
    Quote Originally Posted by Adak View Post
    io.h certainly IS included in some modern compilers. It is no longer part of the standard for C, but it is nevertheless, included in the very latest Pelles C versions.
    Quote Originally Posted by Salem View Post
    You mean it's included as a crutch to help ancient programmers limp along without them having to relearn too much.

    Outside of your DOS world, your header file is meaningless.

  6. #6
    pwns nooblars
    Join Date
    Oct 2005
    Location
    Portland, Or
    Posts
    1,094
    I gave it a shot before on a linux box, eventually got it to compile but took a lot of work. Now I just wait for releases for my OS.

  7. #7
    Malum in se abachler's Avatar
    Join Date
    Apr 2007
    Posts
    3,195
    Quote Originally Posted by Elysia View Post
    Eh, what's the need of compiling it yourself?
    Its a preface to porting it to a nonstandard architecture. It also proves the compiler is operating correctly. In order for a compiler to be complete, it has to compile itself in a multiple step process that results in an executable that compiles its own source to produce the exact executable that was used to compile it.

  8. #8
    C++ Witch laserlight's Avatar
    Join Date
    Oct 2003
    Location
    Singapore
    Posts
    28,413
    Its a preface to porting it to a nonstandard architecture. It also proves the compiler is operating correctly. In order for a compiler to be complete, it has to compile itself in a multiple step process that results in an executable that compiles its own source to produce the exact executable that was used to compile it.
    They are talking about compiling Code::Blocks, not the compiler.
    Quote Originally Posted by Bjarne Stroustrup (2000-10-14)
    I get maybe two dozen requests for help with some sort of programming or design problem every day. Most have more sense than to send me hundreds of lines of code. If they do, I ask them to find the smallest example that exhibits the problem and send me that. Mostly, they then find the error themselves. "Finding the smallest program that demonstrates the error" is a powerful debugging tool.
    Look up a C++ Reference and learn How To Ask Questions The Smart Way

  9. #9
    i dont know Vicious's Avatar
    Join Date
    May 2002
    Posts
    1,200
    Quote Originally Posted by abachler View Post
    In order for a compiler to be complete, it has to compile itself in a multiple step process that results in an executable that compiles its own source to produce the exact executable that was used to compile it.
    That may have missed the mark for this topic (IDE vs Compiler) but i felt it was quote worthy. Pending signature addition.
    What is C++?

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. library issues in CodeBlocks
    By everlearnin in forum C++ Programming
    Replies: 0
    Last Post: 06-02-2009, 08:44 PM
  2. Replies: 3
    Last Post: 05-23-2009, 06:20 PM
  3. Codeblocks crashes linux?
    By Shakti in forum Tech Board
    Replies: 1
    Last Post: 03-25-2009, 07:26 AM
  4. Code::Blocks doesn't like my enums and typedefs
    By muehl in forum C++ Programming
    Replies: 19
    Last Post: 02-12-2009, 10:48 AM
  5. Fixing the Indentation draft
    By Elysia in forum A Brief History of Cprogramming.com
    Replies: 47
    Last Post: 02-23-2008, 11:17 AM