I copied code from software developers into my company's user Documentation space to provide examples for users to modify. The code is bracketed within {code} macro markers. Some long lines of code extend beyond the right edge of the browser window and make the window difficult to read since it requires horizontal scrollling. The entire page is affected.

      I ask that the code macro make text wrap around the window edge or be configrable so that users, such as me, can make the text wrap around.

        1. Confluence_System_Info.pdf
          79 kB
          Ronald Schwarz
        2. win_IE6.PNG
          81 kB
          Ulrich Kuhnhardt [Atlassian]
        3. win+FF2.PNG
          148 kB
          Ulrich Kuhnhardt [Atlassian]
        4. win+ie7.PNG
          137 kB
          Ulrich Kuhnhardt [Atlassian]

            [CONFSERVER-10697] Code macro should wrap

            boardtc added a comment -

            Please, can we get this reopened?

            boardtc added a comment - Please, can we get this reopened?

            Neither it wraps in v5.9.5 

            Dixan Martinez added a comment - Neither it wraps in v5.9.5 

            boardtc added a comment -

            The code macro does not wrap in v5.9.6 when I tried it

            boardtc added a comment - The code macro does not wrap in v5.9.6 when I tried it

            RianA added a comment -

            For those who want to unwrap code macro.

            code { /* forces the code to unwrap */  
                white-space: nowrap !important;  
            }
            

            RianA added a comment - For those who want to unwrap code macro. code { /* forces the code to unwrap */ white-space: nowrap !important; }

            BillA added a comment -

            BillA added a comment - Implemented in 3.5. See release notes at: http://confluence.atlassian.com/display/DOC/Confluence+3.5+Release+Notes#Confluence3.5ReleaseNotes-EnhancedCodeMacro

            Hi All,
            Thank you for your patience with this issue. In our upcoming Confluence release (3.5) we are bundling the new code macro. This will include wrapping for code in code blocks.
            Sherif

            Sherif Mansour added a comment - Hi All, Thank you for your patience with this issue. In our upcoming Confluence release (3.5) we are bundling the new code macro. This will include wrapping for code in code blocks. Sherif

            Steve Goldberg added a comment - - edited

            I showed this problem to a developer on our dev team and he was able to solve the problem within 10 minutes with some CSS:

            .code-comment {
            white-space: pre-wrap;
            }
            

            If you put that into your Custom HTML / Stylesheet (depending on which one you are using to define styles). This causes it to wrap.

            Job done.

            Steve Goldberg added a comment - - edited I showed this problem to a developer on our dev team and he was able to solve the problem within 10 minutes with some CSS: .code-comment { white-space: pre-wrap; } If you put that into your Custom HTML / Stylesheet (depending on which one you are using to define styles). This causes it to wrap. Job done.

            Still happening on Confluence 3.2.x and IE 8 as well

            Gurleen Anand [Atlassian] added a comment - Still happening on Confluence 3.2.x and IE 8 as well

            Gary Bauer added a comment -

            Has this been implemented? Or dropped? It's key for us. I am having to do my documentation in Word & attach it to a confluence page. Using the code macro means every paragraph ends up being written on a single line and obviously I can expect my clients read that.

            Gary Bauer added a comment - Has this been implemented? Or dropped? It's key for us. I am having to do my documentation in Word & attach it to a confluence page. Using the code macro means every paragraph ends up being written on a single line and obviously I can expect my clients read that.

            SarahA added a comment -

            Voted! This issue has the support of the tech writing team

            SarahA added a comment - Voted! This issue has the support of the tech writing team

              jclark@atlassian.com Joe Clark
              521566194c51 Ronald Schwarz
              Affected customers:
              37 This affects my team
              Watchers:
              24 Start watching this issue

                Created:
                Updated:
                Resolved:

                  Estimated:
                  Original Estimate - 3h
                  3h
                  Remaining:
                  Remaining Estimate - 3h
                  3h
                  Logged:
                  Time Spent - Not Specified
                  Not Specified