how to format wide terminal output?

Comments

6 comments

  • Avatar
    Nils Bier

    Hi Robert,

    did you already had a look at the following page in our documentation: https://www.k15t.com/display/PDF/How+Can+I+Deal+with+Wide+Tables

    Does that help?

    Cheers,
    Nils

    0
    Comment actions Permalink
  • Avatar
    Robert Lauriston

    No, this isn't a table. It's plain text, the output of a command-line utility. For example:

    ============ SERVER 192.168.1.12:5701 =======================================================================================
    = Name                                      Version                                 Free Mem            CPU%      Uptime    =
    = ------------------------------------------------------------------------------------------------------------------------- =
    = 192.168.1.12:5701                         1.0.0-SNAPSHOT (13a78a9357)             840Mb               .         01:15:14  =

     

    0
    Comment actions Permalink
  • Avatar
    Robert Lauriston

    I tried adding inline CSS to the <pre> tag in the XHTML source, that changes the size in Confluence but it has no effect on the PDF output.

    I only want to use this format in a few places. I don't want to make all preformatted text smaller.

    0
    Comment actions Permalink
  • Avatar
    Nils Bier

    Hi Robert,

    have you tried creating a user-macro and wrap the text in this usermacro?

    E.g. you could create a new user-macro called "command" like in the attached screenshot.

    Then add the following CSS to the Content Formatting section in your PDF template:

    p.command {
        font-size: x-small;
    }

    This will output all text wrapped in the macro in font-size "x-small".

    Does this help?

    Cheers,
    Nils

     




    Screen Shot 2014-07-16 at 09.42.10.png
    0
    Comment actions Permalink
  • Avatar
    Robert Lauriston

    I used this macro:

    <pre class="pre-small">$body</pre>

    And this in Content Formatting:

    pre.pre-small {
    font-size: smaller
    }

    0
    Comment actions Permalink
  • Avatar
    Robert Lauriston

    Shouldn't this prevent page breaks within the block?

    pre.pre-small {
    font-size: smaller;
    page-break-inside: avoid !important;
    }

    0
    Comment actions Permalink

Please sign in to leave a comment.

Powered by Zendesk