How does using makebox allow arbitrary placement of things on a page?











up vote
1
down vote

favorite












What is it about using makebox that makes it disregard text body borders / margins, where other boxes respect the margins / text width and friends?




  • Allowing images outside of margin
    Letting graphics overflow over page edge


  • Drawing lines across paper
    Horizontal line spanning the entire document in LaTeX


  • Aligning things in margin with paragraph start How can I top align AND left align a box flush with the top of a paragraph?



I ask this because it seems like a magic box that you can just throw anything into and do whatever (same with parbox, I suppose). In TikZ, you have to use the overlay option. Is it due to something implicit like that?










share|improve this question




















  • 1




    With makebox you can specify [<size>], [<alignment>], as well as {<content>}. When the size is specified, the content can spill out the sides, even as TeX thinks of the box as only be of the specified size. By throwing in clever use of left/center/right alignment, it provides a mechanism for typesetting stuff at distal locations to the "cursor location". Try fbox{makebox[0pt][r]{This appears to the left}}. The box shows where TeX imagines the <content> to be.
    – Steven B. Segletes
    Oct 25 at 11:02








  • 1




    Roughly equivalent to hbox to <width> {hss <contents> hss}. Core TeX hss is like hfill, only it can shrink.
    – John Kormylo
    Oct 25 at 13:28

















up vote
1
down vote

favorite












What is it about using makebox that makes it disregard text body borders / margins, where other boxes respect the margins / text width and friends?




  • Allowing images outside of margin
    Letting graphics overflow over page edge


  • Drawing lines across paper
    Horizontal line spanning the entire document in LaTeX


  • Aligning things in margin with paragraph start How can I top align AND left align a box flush with the top of a paragraph?



I ask this because it seems like a magic box that you can just throw anything into and do whatever (same with parbox, I suppose). In TikZ, you have to use the overlay option. Is it due to something implicit like that?










share|improve this question




















  • 1




    With makebox you can specify [<size>], [<alignment>], as well as {<content>}. When the size is specified, the content can spill out the sides, even as TeX thinks of the box as only be of the specified size. By throwing in clever use of left/center/right alignment, it provides a mechanism for typesetting stuff at distal locations to the "cursor location". Try fbox{makebox[0pt][r]{This appears to the left}}. The box shows where TeX imagines the <content> to be.
    – Steven B. Segletes
    Oct 25 at 11:02








  • 1




    Roughly equivalent to hbox to <width> {hss <contents> hss}. Core TeX hss is like hfill, only it can shrink.
    – John Kormylo
    Oct 25 at 13:28















up vote
1
down vote

favorite









up vote
1
down vote

favorite











What is it about using makebox that makes it disregard text body borders / margins, where other boxes respect the margins / text width and friends?




  • Allowing images outside of margin
    Letting graphics overflow over page edge


  • Drawing lines across paper
    Horizontal line spanning the entire document in LaTeX


  • Aligning things in margin with paragraph start How can I top align AND left align a box flush with the top of a paragraph?



I ask this because it seems like a magic box that you can just throw anything into and do whatever (same with parbox, I suppose). In TikZ, you have to use the overlay option. Is it due to something implicit like that?










share|improve this question















What is it about using makebox that makes it disregard text body borders / margins, where other boxes respect the margins / text width and friends?




  • Allowing images outside of margin
    Letting graphics overflow over page edge


  • Drawing lines across paper
    Horizontal line spanning the entire document in LaTeX


  • Aligning things in margin with paragraph start How can I top align AND left align a box flush with the top of a paragraph?



I ask this because it seems like a magic box that you can just throw anything into and do whatever (same with parbox, I suppose). In TikZ, you have to use the overlay option. Is it due to something implicit like that?







positioning margins boxes






share|improve this question















share|improve this question













share|improve this question




share|improve this question








edited 20 mins ago

























asked Oct 25 at 10:50









Jonathan Komar

6,45132977




6,45132977








  • 1




    With makebox you can specify [<size>], [<alignment>], as well as {<content>}. When the size is specified, the content can spill out the sides, even as TeX thinks of the box as only be of the specified size. By throwing in clever use of left/center/right alignment, it provides a mechanism for typesetting stuff at distal locations to the "cursor location". Try fbox{makebox[0pt][r]{This appears to the left}}. The box shows where TeX imagines the <content> to be.
    – Steven B. Segletes
    Oct 25 at 11:02








  • 1




    Roughly equivalent to hbox to <width> {hss <contents> hss}. Core TeX hss is like hfill, only it can shrink.
    – John Kormylo
    Oct 25 at 13:28
















  • 1




    With makebox you can specify [<size>], [<alignment>], as well as {<content>}. When the size is specified, the content can spill out the sides, even as TeX thinks of the box as only be of the specified size. By throwing in clever use of left/center/right alignment, it provides a mechanism for typesetting stuff at distal locations to the "cursor location". Try fbox{makebox[0pt][r]{This appears to the left}}. The box shows where TeX imagines the <content> to be.
    – Steven B. Segletes
    Oct 25 at 11:02








  • 1




    Roughly equivalent to hbox to <width> {hss <contents> hss}. Core TeX hss is like hfill, only it can shrink.
    – John Kormylo
    Oct 25 at 13:28










1




1




With makebox you can specify [<size>], [<alignment>], as well as {<content>}. When the size is specified, the content can spill out the sides, even as TeX thinks of the box as only be of the specified size. By throwing in clever use of left/center/right alignment, it provides a mechanism for typesetting stuff at distal locations to the "cursor location". Try fbox{makebox[0pt][r]{This appears to the left}}. The box shows where TeX imagines the <content> to be.
– Steven B. Segletes
Oct 25 at 11:02






With makebox you can specify [<size>], [<alignment>], as well as {<content>}. When the size is specified, the content can spill out the sides, even as TeX thinks of the box as only be of the specified size. By throwing in clever use of left/center/right alignment, it provides a mechanism for typesetting stuff at distal locations to the "cursor location". Try fbox{makebox[0pt][r]{This appears to the left}}. The box shows where TeX imagines the <content> to be.
– Steven B. Segletes
Oct 25 at 11:02






1




1




Roughly equivalent to hbox to <width> {hss <contents> hss}. Core TeX hss is like hfill, only it can shrink.
– John Kormylo
Oct 25 at 13:28






Roughly equivalent to hbox to <width> {hss <contents> hss}. Core TeX hss is like hfill, only it can shrink.
– John Kormylo
Oct 25 at 13:28












1 Answer
1






active

oldest

votes

















up vote
1
down vote



accepted










There is nothing special about makebox. If you go



parbox{1cm}{...}


then if ... is wider than 1in you will get an overfull box, but it is possible to make the text visually wider without being wider to tex, eg



parbox{1cm}{XXXXXXXXXXXhspace{-10cm}X}



is not overfull, despite the fact that the X will extend past the 1cm boundary of the box.



makebox is just a box with (if you use the length option) a specified width but glue added either side that can stretch or shrink an arbitrary amount so that the contents are always exactly the width of the box, even if they appear to extend past it.






share|improve this answer





















    Your Answer








    StackExchange.ready(function() {
    var channelOptions = {
    tags: "".split(" "),
    id: "85"
    };
    initTagRenderer("".split(" "), "".split(" "), channelOptions);

    StackExchange.using("externalEditor", function() {
    // Have to fire editor after snippets, if snippets enabled
    if (StackExchange.settings.snippets.snippetsEnabled) {
    StackExchange.using("snippets", function() {
    createEditor();
    });
    }
    else {
    createEditor();
    }
    });

    function createEditor() {
    StackExchange.prepareEditor({
    heartbeatType: 'answer',
    convertImagesToLinks: false,
    noModals: true,
    showLowRepImageUploadWarning: true,
    reputationToPostImages: null,
    bindNavPrevention: true,
    postfix: "",
    imageUploader: {
    brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
    contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
    allowUrls: true
    },
    onDemand: true,
    discardSelector: ".discard-answer"
    ,immediatelyShowMarkdownHelp:true
    });


    }
    });














    draft saved

    draft discarded


















    StackExchange.ready(
    function () {
    StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2ftex.stackexchange.com%2fquestions%2f456709%2fhow-does-using-makebox-allow-arbitrary-placement-of-things-on-a-page%23new-answer', 'question_page');
    }
    );

    Post as a guest















    Required, but never shown

























    1 Answer
    1






    active

    oldest

    votes








    1 Answer
    1






    active

    oldest

    votes









    active

    oldest

    votes






    active

    oldest

    votes








    up vote
    1
    down vote



    accepted










    There is nothing special about makebox. If you go



    parbox{1cm}{...}


    then if ... is wider than 1in you will get an overfull box, but it is possible to make the text visually wider without being wider to tex, eg



    parbox{1cm}{XXXXXXXXXXXhspace{-10cm}X}



    is not overfull, despite the fact that the X will extend past the 1cm boundary of the box.



    makebox is just a box with (if you use the length option) a specified width but glue added either side that can stretch or shrink an arbitrary amount so that the contents are always exactly the width of the box, even if they appear to extend past it.






    share|improve this answer

























      up vote
      1
      down vote



      accepted










      There is nothing special about makebox. If you go



      parbox{1cm}{...}


      then if ... is wider than 1in you will get an overfull box, but it is possible to make the text visually wider without being wider to tex, eg



      parbox{1cm}{XXXXXXXXXXXhspace{-10cm}X}



      is not overfull, despite the fact that the X will extend past the 1cm boundary of the box.



      makebox is just a box with (if you use the length option) a specified width but glue added either side that can stretch or shrink an arbitrary amount so that the contents are always exactly the width of the box, even if they appear to extend past it.






      share|improve this answer























        up vote
        1
        down vote



        accepted







        up vote
        1
        down vote



        accepted






        There is nothing special about makebox. If you go



        parbox{1cm}{...}


        then if ... is wider than 1in you will get an overfull box, but it is possible to make the text visually wider without being wider to tex, eg



        parbox{1cm}{XXXXXXXXXXXhspace{-10cm}X}



        is not overfull, despite the fact that the X will extend past the 1cm boundary of the box.



        makebox is just a box with (if you use the length option) a specified width but glue added either side that can stretch or shrink an arbitrary amount so that the contents are always exactly the width of the box, even if they appear to extend past it.






        share|improve this answer












        There is nothing special about makebox. If you go



        parbox{1cm}{...}


        then if ... is wider than 1in you will get an overfull box, but it is possible to make the text visually wider without being wider to tex, eg



        parbox{1cm}{XXXXXXXXXXXhspace{-10cm}X}



        is not overfull, despite the fact that the X will extend past the 1cm boundary of the box.



        makebox is just a box with (if you use the length option) a specified width but glue added either side that can stretch or shrink an arbitrary amount so that the contents are always exactly the width of the box, even if they appear to extend past it.







        share|improve this answer












        share|improve this answer



        share|improve this answer










        answered Oct 25 at 14:03









        David Carlisle

        479k3811121847




        479k3811121847






























            draft saved

            draft discarded




















































            Thanks for contributing an answer to TeX - LaTeX Stack Exchange!


            • Please be sure to answer the question. Provide details and share your research!

            But avoid



            • Asking for help, clarification, or responding to other answers.

            • Making statements based on opinion; back them up with references or personal experience.


            To learn more, see our tips on writing great answers.





            Some of your past answers have not been well-received, and you're in danger of being blocked from answering.


            Please pay close attention to the following guidance:


            • Please be sure to answer the question. Provide details and share your research!

            But avoid



            • Asking for help, clarification, or responding to other answers.

            • Making statements based on opinion; back them up with references or personal experience.


            To learn more, see our tips on writing great answers.




            draft saved


            draft discarded














            StackExchange.ready(
            function () {
            StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2ftex.stackexchange.com%2fquestions%2f456709%2fhow-does-using-makebox-allow-arbitrary-placement-of-things-on-a-page%23new-answer', 'question_page');
            }
            );

            Post as a guest















            Required, but never shown





















































            Required, but never shown














            Required, but never shown












            Required, but never shown







            Required, but never shown

































            Required, but never shown














            Required, but never shown












            Required, but never shown







            Required, but never shown







            Popular posts from this blog

            サソリ

            広島県道265号伴広島線

            Accessing regular linux commands in Huawei's Dopra Linux