Add vertically-aligned text between two enumerate items












4















I'd like to get something like this:





MWE:



documentclass{article}

begin{document}
begin{enumerate}
item $Y^2 - 1 = 0$ quad (text)
item $Y^2 + 1 = 0$ quad (text)
end{enumerate}
end{document}









share|improve this question



























    4















    I'd like to get something like this:





    MWE:



    documentclass{article}

    begin{document}
    begin{enumerate}
    item $Y^2 - 1 = 0$ quad (text)
    item $Y^2 + 1 = 0$ quad (text)
    end{enumerate}
    end{document}









    share|improve this question

























      4












      4








      4








      I'd like to get something like this:





      MWE:



      documentclass{article}

      begin{document}
      begin{enumerate}
      item $Y^2 - 1 = 0$ quad (text)
      item $Y^2 + 1 = 0$ quad (text)
      end{enumerate}
      end{document}









      share|improve this question














      I'd like to get something like this:





      MWE:



      documentclass{article}

      begin{document}
      begin{enumerate}
      item $Y^2 - 1 = 0$ quad (text)
      item $Y^2 + 1 = 0$ quad (text)
      end{enumerate}
      end{document}






      spacing vertical-alignment enumerate enumitem vertical






      share|improve this question













      share|improve this question











      share|improve this question




      share|improve this question










      asked 16 hours ago









      Lele99_DDLele99_DD

      1147




      1147






















          2 Answers
          2






          active

          oldest

          votes


















          6














          How about a simple raisebox, wrapped in a macro taking into account itemsep and parsep values (thanks to circumscribe, I have change to glueexpr`, since all involved lengths are glues, not ordinary lengths!)



          enter image description here



          documentclass{article}

          usepackage{enumitem}

          newcommand{raisecontent}[1]{%
          raisebox{glueexprbaselineskip/2+parsep/2+itemsep/2+lineskip/2}[htstrutbox][htstrutbox]{#1}%
          }

          begin{document}
          begin{enumerate}
          item $Y^2 - 1 = 0$
          item $Y^2 + 1 = 0$ raisecontent{quad (text)}
          end{enumerate}

          begin{enumerate}[itemsep=40pt]
          item $Y^2 - 1 = 0$
          item $Y^2 + 1 = 0$ raisecontent{quad (text)}
          end{enumerate}

          end{document}





          share|improve this answer


























          • Working in progress...

            – Christian Hupfer
            15 hours ago











          • @Circumscribe: Thanks, I totally forgot about glueexpr....

            – Christian Hupfer
            15 hours ago











          • @Circumscribe: I changed and apparently the slight vertical shift is removed. Thanks again

            – Christian Hupfer
            15 hours ago













          • Let us continue this discussion in chat.

            – Circumscribe
            15 hours ago











          • @Circumscribe: Oh, I thought itemsep etc. would be normal length 'registers' and skip's'

            – Christian Hupfer
            13 hours ago





















          4














          Another solution, based on tabularx and listliketab, which emulates list environments within tables:



          documentclass{article}
          usepackage{tabularx, listliketab, multirow}

          begin{document}

          storestyleof{enumerate}
          begin{listliketab}
          newcounter{tabenum}setcounter{tabenum}{0}
          newcommand{tabitem}{addtocounter{tabenum}{1}thetabenum.}
          noindentbegin{tabularx}{linewidth}{@{}L l@{quad}X@{}}
          tabitem & $Y^2 - 1 = 0$ & multirow{2}{=}{(Text)}\
          tabitem & $Y^2 + 1 = 0$
          end{tabularx}
          end{listliketab}

          end{document}


          enter image description here






          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',
            autoActivateHeartbeat: false,
            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%2f474045%2fadd-vertically-aligned-text-between-two-enumerate-items%23new-answer', 'question_page');
            }
            );

            Post as a guest















            Required, but never shown

























            2 Answers
            2






            active

            oldest

            votes








            2 Answers
            2






            active

            oldest

            votes









            active

            oldest

            votes






            active

            oldest

            votes









            6














            How about a simple raisebox, wrapped in a macro taking into account itemsep and parsep values (thanks to circumscribe, I have change to glueexpr`, since all involved lengths are glues, not ordinary lengths!)



            enter image description here



            documentclass{article}

            usepackage{enumitem}

            newcommand{raisecontent}[1]{%
            raisebox{glueexprbaselineskip/2+parsep/2+itemsep/2+lineskip/2}[htstrutbox][htstrutbox]{#1}%
            }

            begin{document}
            begin{enumerate}
            item $Y^2 - 1 = 0$
            item $Y^2 + 1 = 0$ raisecontent{quad (text)}
            end{enumerate}

            begin{enumerate}[itemsep=40pt]
            item $Y^2 - 1 = 0$
            item $Y^2 + 1 = 0$ raisecontent{quad (text)}
            end{enumerate}

            end{document}





            share|improve this answer


























            • Working in progress...

              – Christian Hupfer
              15 hours ago











            • @Circumscribe: Thanks, I totally forgot about glueexpr....

              – Christian Hupfer
              15 hours ago











            • @Circumscribe: I changed and apparently the slight vertical shift is removed. Thanks again

              – Christian Hupfer
              15 hours ago













            • Let us continue this discussion in chat.

              – Circumscribe
              15 hours ago











            • @Circumscribe: Oh, I thought itemsep etc. would be normal length 'registers' and skip's'

              – Christian Hupfer
              13 hours ago


















            6














            How about a simple raisebox, wrapped in a macro taking into account itemsep and parsep values (thanks to circumscribe, I have change to glueexpr`, since all involved lengths are glues, not ordinary lengths!)



            enter image description here



            documentclass{article}

            usepackage{enumitem}

            newcommand{raisecontent}[1]{%
            raisebox{glueexprbaselineskip/2+parsep/2+itemsep/2+lineskip/2}[htstrutbox][htstrutbox]{#1}%
            }

            begin{document}
            begin{enumerate}
            item $Y^2 - 1 = 0$
            item $Y^2 + 1 = 0$ raisecontent{quad (text)}
            end{enumerate}

            begin{enumerate}[itemsep=40pt]
            item $Y^2 - 1 = 0$
            item $Y^2 + 1 = 0$ raisecontent{quad (text)}
            end{enumerate}

            end{document}





            share|improve this answer


























            • Working in progress...

              – Christian Hupfer
              15 hours ago











            • @Circumscribe: Thanks, I totally forgot about glueexpr....

              – Christian Hupfer
              15 hours ago











            • @Circumscribe: I changed and apparently the slight vertical shift is removed. Thanks again

              – Christian Hupfer
              15 hours ago













            • Let us continue this discussion in chat.

              – Circumscribe
              15 hours ago











            • @Circumscribe: Oh, I thought itemsep etc. would be normal length 'registers' and skip's'

              – Christian Hupfer
              13 hours ago
















            6












            6








            6







            How about a simple raisebox, wrapped in a macro taking into account itemsep and parsep values (thanks to circumscribe, I have change to glueexpr`, since all involved lengths are glues, not ordinary lengths!)



            enter image description here



            documentclass{article}

            usepackage{enumitem}

            newcommand{raisecontent}[1]{%
            raisebox{glueexprbaselineskip/2+parsep/2+itemsep/2+lineskip/2}[htstrutbox][htstrutbox]{#1}%
            }

            begin{document}
            begin{enumerate}
            item $Y^2 - 1 = 0$
            item $Y^2 + 1 = 0$ raisecontent{quad (text)}
            end{enumerate}

            begin{enumerate}[itemsep=40pt]
            item $Y^2 - 1 = 0$
            item $Y^2 + 1 = 0$ raisecontent{quad (text)}
            end{enumerate}

            end{document}





            share|improve this answer















            How about a simple raisebox, wrapped in a macro taking into account itemsep and parsep values (thanks to circumscribe, I have change to glueexpr`, since all involved lengths are glues, not ordinary lengths!)



            enter image description here



            documentclass{article}

            usepackage{enumitem}

            newcommand{raisecontent}[1]{%
            raisebox{glueexprbaselineskip/2+parsep/2+itemsep/2+lineskip/2}[htstrutbox][htstrutbox]{#1}%
            }

            begin{document}
            begin{enumerate}
            item $Y^2 - 1 = 0$
            item $Y^2 + 1 = 0$ raisecontent{quad (text)}
            end{enumerate}

            begin{enumerate}[itemsep=40pt]
            item $Y^2 - 1 = 0$
            item $Y^2 + 1 = 0$ raisecontent{quad (text)}
            end{enumerate}

            end{document}






            share|improve this answer














            share|improve this answer



            share|improve this answer








            edited 7 hours ago

























            answered 16 hours ago









            Christian HupferChristian Hupfer

            150k15198393




            150k15198393













            • Working in progress...

              – Christian Hupfer
              15 hours ago











            • @Circumscribe: Thanks, I totally forgot about glueexpr....

              – Christian Hupfer
              15 hours ago











            • @Circumscribe: I changed and apparently the slight vertical shift is removed. Thanks again

              – Christian Hupfer
              15 hours ago













            • Let us continue this discussion in chat.

              – Circumscribe
              15 hours ago











            • @Circumscribe: Oh, I thought itemsep etc. would be normal length 'registers' and skip's'

              – Christian Hupfer
              13 hours ago





















            • Working in progress...

              – Christian Hupfer
              15 hours ago











            • @Circumscribe: Thanks, I totally forgot about glueexpr....

              – Christian Hupfer
              15 hours ago











            • @Circumscribe: I changed and apparently the slight vertical shift is removed. Thanks again

              – Christian Hupfer
              15 hours ago













            • Let us continue this discussion in chat.

              – Circumscribe
              15 hours ago











            • @Circumscribe: Oh, I thought itemsep etc. would be normal length 'registers' and skip's'

              – Christian Hupfer
              13 hours ago



















            Working in progress...

            – Christian Hupfer
            15 hours ago





            Working in progress...

            – Christian Hupfer
            15 hours ago













            @Circumscribe: Thanks, I totally forgot about glueexpr....

            – Christian Hupfer
            15 hours ago





            @Circumscribe: Thanks, I totally forgot about glueexpr....

            – Christian Hupfer
            15 hours ago













            @Circumscribe: I changed and apparently the slight vertical shift is removed. Thanks again

            – Christian Hupfer
            15 hours ago







            @Circumscribe: I changed and apparently the slight vertical shift is removed. Thanks again

            – Christian Hupfer
            15 hours ago















            Let us continue this discussion in chat.

            – Circumscribe
            15 hours ago





            Let us continue this discussion in chat.

            – Circumscribe
            15 hours ago













            @Circumscribe: Oh, I thought itemsep etc. would be normal length 'registers' and skip's'

            – Christian Hupfer
            13 hours ago







            @Circumscribe: Oh, I thought itemsep etc. would be normal length 'registers' and skip's'

            – Christian Hupfer
            13 hours ago













            4














            Another solution, based on tabularx and listliketab, which emulates list environments within tables:



            documentclass{article}
            usepackage{tabularx, listliketab, multirow}

            begin{document}

            storestyleof{enumerate}
            begin{listliketab}
            newcounter{tabenum}setcounter{tabenum}{0}
            newcommand{tabitem}{addtocounter{tabenum}{1}thetabenum.}
            noindentbegin{tabularx}{linewidth}{@{}L l@{quad}X@{}}
            tabitem & $Y^2 - 1 = 0$ & multirow{2}{=}{(Text)}\
            tabitem & $Y^2 + 1 = 0$
            end{tabularx}
            end{listliketab}

            end{document}


            enter image description here






            share|improve this answer




























              4














              Another solution, based on tabularx and listliketab, which emulates list environments within tables:



              documentclass{article}
              usepackage{tabularx, listliketab, multirow}

              begin{document}

              storestyleof{enumerate}
              begin{listliketab}
              newcounter{tabenum}setcounter{tabenum}{0}
              newcommand{tabitem}{addtocounter{tabenum}{1}thetabenum.}
              noindentbegin{tabularx}{linewidth}{@{}L l@{quad}X@{}}
              tabitem & $Y^2 - 1 = 0$ & multirow{2}{=}{(Text)}\
              tabitem & $Y^2 + 1 = 0$
              end{tabularx}
              end{listliketab}

              end{document}


              enter image description here






              share|improve this answer


























                4












                4








                4







                Another solution, based on tabularx and listliketab, which emulates list environments within tables:



                documentclass{article}
                usepackage{tabularx, listliketab, multirow}

                begin{document}

                storestyleof{enumerate}
                begin{listliketab}
                newcounter{tabenum}setcounter{tabenum}{0}
                newcommand{tabitem}{addtocounter{tabenum}{1}thetabenum.}
                noindentbegin{tabularx}{linewidth}{@{}L l@{quad}X@{}}
                tabitem & $Y^2 - 1 = 0$ & multirow{2}{=}{(Text)}\
                tabitem & $Y^2 + 1 = 0$
                end{tabularx}
                end{listliketab}

                end{document}


                enter image description here






                share|improve this answer













                Another solution, based on tabularx and listliketab, which emulates list environments within tables:



                documentclass{article}
                usepackage{tabularx, listliketab, multirow}

                begin{document}

                storestyleof{enumerate}
                begin{listliketab}
                newcounter{tabenum}setcounter{tabenum}{0}
                newcommand{tabitem}{addtocounter{tabenum}{1}thetabenum.}
                noindentbegin{tabularx}{linewidth}{@{}L l@{quad}X@{}}
                tabitem & $Y^2 - 1 = 0$ & multirow{2}{=}{(Text)}\
                tabitem & $Y^2 + 1 = 0$
                end{tabularx}
                end{listliketab}

                end{document}


                enter image description here







                share|improve this answer












                share|improve this answer



                share|improve this answer










                answered 13 hours ago









                BernardBernard

                169k773198




                169k773198






























                    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.




                    draft saved


                    draft discarded














                    StackExchange.ready(
                    function () {
                    StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2ftex.stackexchange.com%2fquestions%2f474045%2fadd-vertically-aligned-text-between-two-enumerate-items%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

                    "Incorrect syntax near the keyword 'ON'. (on update cascade, on delete cascade,)

                    Alcedinidae

                    Origin of the phrase “under your belt”?