Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. The Lounge
  3. A moment of silence please...

A moment of silence please...

Scheduled Pinned Locked Moved The Lounge
csharpc++visual-studio
33 Posts 14 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • G Gary Wheeler

    ... for the last vestiges of the old Republic have been swept away. My legacy C++ code was written in K&R brace style, as the gods intended. I write my C# using the vertical brace Allman[^] style, thereby appeasing those gods. The last week or so I've been doing significant work in the legacy code, and I can't stand it anymore. I've written a VS macro(*) to reformat K&R to vertical braces Allman form. (*) Yes, I know that VS can reformat code for you. The built-in stuff in VS2008 is pretty lame.

    Software Zen: delete this;

    RaviBeeR Offline
    RaviBeeR Offline
    RaviBee
    wrote on last edited by
    #22

    Gary, I'm sorry but we can't be friends any more. :( /ravi

    My new year resolution: 2048 x 1536 Home | Articles | My .NET bits | Freeware ravib(at)ravib(dot)com

    G 1 Reply Last reply
    0
    • RaviBeeR RaviBee

      Gary, I'm sorry but we can't be friends any more. :( /ravi

      My new year resolution: 2048 x 1536 Home | Articles | My .NET bits | Freeware ravib(at)ravib(dot)com

      G Offline
      G Offline
      Gary Wheeler
      wrote on last edited by
      #23

      :((

      Software Zen: delete this;

      RaviBeeR 1 Reply Last reply
      0
      • G Gary Wheeler

        :((

        Software Zen: delete this;

        RaviBeeR Offline
        RaviBeeR Offline
        RaviBee
        wrote on last edited by
        #24

        I'm hoping you'll see the beauty in the K&R format and return to your roots.  Besides, IL generated from C# code written in the K&R format has been known to run faster. :) /ravi

        My new year resolution: 2048 x 1536 Home | Articles | My .NET bits | Freeware ravib(at)ravib(dot)com

        G 1 Reply Last reply
        0
        • RaviBeeR RaviBee

          I'm hoping you'll see the beauty in the K&R format and return to your roots.  Besides, IL generated from C# code written in the K&R format has been known to run faster. :) /ravi

          My new year resolution: 2048 x 1536 Home | Articles | My .NET bits | Freeware ravib(at)ravib(dot)com

          G Offline
          G Offline
          Gary Wheeler
          wrote on last edited by
          #25

          Ah, 'tis me leg you be pullin' there laddie. We all be knowin' that the only way to make managed code go faster be to whip the horse harder.

          Software Zen: delete this;

          1 Reply Last reply
          0
          • G Gary Wheeler

            Tabs originally, now spaces. The group couldn't agree on a tab size :rolleyes: .

            Software Zen: delete this;

            P Offline
            P Offline
            PIEBALDconsult
            wrote on last edited by
            #26

            The problem is that when indent size is measured in "characters" then it depends on font size -- the smaller the font (I use an 8-point font) then the more characters are required to make an effective indent.

            1 Reply Last reply
            0
            • D Dave Kreskowiak

              My code will probably drive you nuts as I use Allman style. Always have, always will.

              A guide to posting questions on CodeProject

              Click this: Asking questions is a skill. Seriously, do it.
              Dave Kreskowiak

              P Offline
              P Offline
              PIEBALDconsult
              wrote on last edited by
              #27

              Yes, Allman is best.

              1 Reply Last reply
              0
              • G Gary Wheeler

                On rare occasions I will still print a page or two of code when I'm refactoring C++. That's never necessary in C#, because the refactoring tools are so much better.

                Software Zen: delete this;

                D Offline
                D Offline
                Dan Neely
                wrote on last edited by
                #28

                I've done it on rare occasions with C#; but only with 500-1000 line function monstrosities never should've been written in the first place.

                Did you ever see history portrayed as an old man with a wise brow and pulseless heart, waging all things in the balance of reason? Is not rather the genius of history like an eternal, imploring maiden, full of fire, with a burning heart and flaming soul, humanly warm and humanly beautiful? --Zachris Topelius Training a telescope on one’s own belly button will only reveal lint. You like that? You go right on staring at it. I prefer looking at galaxies. -- Sarah Hoyt

                1 Reply Last reply
                0
                • Richard DeemingR Richard Deeming

                  You should vote for this suggestion[^]. :)


                  "These people looked deep within my soul and assigned me a number based on the order in which I joined." - Homer

                  P Offline
                  P Offline
                  PIEBALDconsult
                  wrote on last edited by
                  #29

                  But that would only affect Visual Studio? What rubbish. I still want some way of having comments somewhat separated from the code so you can hide or show them as desired. And maybe store the code in XML.

                  1 Reply Last reply
                  0
                  • G Gary Wheeler

                    Tabs originally, now spaces. The group couldn't agree on a tab size :rolleyes: .

                    Software Zen: delete this;

                    L Offline
                    L Offline
                    Lost User
                    wrote on last edited by
                    #30

                    shirley with Tabs each individual can decide n the tab size for their preference?

                    PooperPig - Coming Soon

                    J G 2 Replies Last reply
                    0
                    • L Lost User

                      shirley with Tabs each individual can decide n the tab size for their preference?

                      PooperPig - Coming Soon

                      J Offline
                      J Offline
                      Jorgen Andersson
                      wrote on last edited by
                      #31

                      Since when is religion and pragmatism working together?

                      Wrong is evil and must be defeated. - Jeff Ello

                      1 Reply Last reply
                      0
                      • L Lost User

                        shirley with Tabs each individual can decide n the tab size for their preference?

                        PooperPig - Coming Soon

                        G Offline
                        G Offline
                        Gary Wheeler
                        wrote on last edited by
                        #32

                        On user likes tabs of 4, another likes tabs of 3. No version of Visual Studio since Visual C++ 6 has handled mixing spaces and tabs properly. The result is Visual Chaos™.

                        Software Zen: delete this;

                        L 1 Reply Last reply
                        0
                        • G Gary Wheeler

                          On user likes tabs of 4, another likes tabs of 3. No version of Visual Studio since Visual C++ 6 has handled mixing spaces and tabs properly. The result is Visual Chaos™.

                          Software Zen: delete this;

                          L Offline
                          L Offline
                          Lost User
                          wrote on last edited by
                          #33

                          I can't recall if it. Is vs or an add on, but there is an option to ta if or detabify If everyone always uses tabs, then one user an set. The tab spacing to 3 and the other to 4, then that's how they will be displayed for that user - with no changes to the file.

                          PooperPig - Coming Soon

                          1 Reply Last reply
                          0
                          Reply
                          • Reply as topic
                          Log in to reply
                          • Oldest to Newest
                          • Newest to Oldest
                          • Most Votes


                          • Login

                          • Don't have an account? Register

                          • Login or register to search.
                          • First post
                            Last post
                          0
                          • Categories
                          • Recent
                          • Tags
                          • Popular
                          • World
                          • Users
                          • Groups