Loading ...
Sorry, an error occurred while loading the content.

Problem with latex template

Expand Messages
  • Alain Bertrand
    Hello all, I am moving after years with ***** to vim, mostly for latex. I have installed latex-suite. I encounter a strange problem with templates : My
    Message 1 of 7 , Apr 14 10:01 AM
    • 0 Attachment
      Hello all,


      I am moving after years with ***** to vim, mostly for latex.
      I have installed latex-suite.

      I encounter a strange problem with templates :

      My template is the template_patron.tex file.
      After inserted it in a new file with :TTemplate it becomes like the test.tex file:

      first line is supressed and indentation becomes strange.

      In order to get the first line not removed, I have inserted a blank line at the top of the file. (short_tem.tex) then after inserting the template the file is completly spoilt.

      What I am doing wrong here ?

      Thanks for your help,

      Alain

      --
      --
      You received this message from the "vim_use" maillist.
      Do not top-post! Type your reply below the text you are replying to.
      For more information, visit http://www.vim.org/maillist.php

      ---
      You received this message because you are subscribed to the Google Groups "vim_use" group.
      To unsubscribe from this group and stop receiving emails from it, send an email to vim_use+unsubscribe@....
      For more options, visit https://groups.google.com/d/optout.
    • netraken
      Hello all, I am transitioning from the other well known editor, mostly for latex. I have a latex template. When I open it in vim, everything is fine. When I
      Message 2 of 7 , Apr 14 1:22 PM
      • 0 Attachment
        Hello all,

        I am transitioning from the other well known editor, mostly for latex.

        I have a latex template. When I open it in vim, everything is fine.
        When I create a file, then insert the template in the file with
        :TTemplate, the tex file is inserted but the first line is cut away and
        formatting is funky.

        If a leave a blank line on the top of the file to get the first line
        (\documentclass[11pt]{article}
        the contents of the files are completely screwed up like that :


        <++>\<++>d<++>o<++>c<++>u<++>m<++>e<++>n<++>t<++>c<++>l<++>a<++>s<++>s<++>[<++>1<++>0<++>p<++>t<++>]<++>{<++>a<++>r<++>t<++>i<++>c<++>l<++>e<++>}<++>
        (a <++> is inserted between each letter !)

        What is happening ?

        I am on linux mint 16, all files in utf8.

        Thanks for your help,

        Alain

        --
        --
        You received this message from the "vim_use" maillist.
        Do not top-post! Type your reply below the text you are replying to.
        For more information, visit http://www.vim.org/maillist.php

        ---
        You received this message because you are subscribed to the Google Groups "vim_use" group.
        To unsubscribe from this group and stop receiving emails from it, send an email to vim_use+unsubscribe@....
        For more options, visit https://groups.google.com/d/optout.
      • Alain Bertrand
        Sorry for the double entry. The mailing list server seems quite slow to publish new threads. Alain -- -- You received this message from the vim_use maillist.
        Message 3 of 7 , Apr 15 12:15 AM
        • 0 Attachment
          Sorry for the double entry.
          The mailing list server seems quite slow to publish new threads.

          Alain

          --
          --
          You received this message from the "vim_use" maillist.
          Do not top-post! Type your reply below the text you are replying to.
          For more information, visit http://www.vim.org/maillist.php

          ---
          You received this message because you are subscribed to the Google Groups "vim_use" group.
          To unsubscribe from this group and stop receiving emails from it, send an email to vim_use+unsubscribe@....
          For more options, visit https://groups.google.com/d/optout.
        • John Beckett
          ... It s fast. The problem comes from the fact that the first post of each new member has to be moderated (approved by a manager). Sometimes that s fast, but
          Message 4 of 7 , Apr 15 3:19 AM
          • 0 Attachment
            Alain Bertrand wrote:
            > The mailing list server seems quite slow to publish new threads.

            It's fast. The problem comes from the fact that the first post
            of each new member has to be moderated (approved by a manager).
            Sometimes that's fast, but it may take several hours.

            Also, sometimes Google decides that a message from an existing
            member might be spam. Such messages also have to be moderated.

            Unfortunately such moderation is required to avoid spam. I'm
            sending this to the list as a periodic reminder.

            John


            --
            --
            You received this message from the "vim_use" maillist.
            Do not top-post! Type your reply below the text you are replying to.
            For more information, visit http://www.vim.org/maillist.php

            ---
            You received this message because you are subscribed to the Google Groups "vim_use" group.
            To unsubscribe from this group and stop receiving emails from it, send an email to vim_use+unsubscribe@....
            For more options, visit https://groups.google.com/d/optout.
          • netraken
            ... Up. I really need your help. Alain -- -- You received this message from the vim_use maillist. Do not top-post! Type your reply below the text you are
            Message 5 of 7 , Apr 15 11:12 PM
            • 0 Attachment
              On 14/04/2014 19:01, Alain Bertrand wrote:
              > Hello all,
              >
              >
              > I am moving after years with ***** to vim, mostly for latex.
              > I have installed latex-suite.
              >
              > I encounter a strange problem with templates :
              >
              > My template is the template_patron.tex file.
              > After inserted it in a new file with :TTemplate it becomes like the test.tex file:
              >
              > first line is supressed and indentation becomes strange.
              >
              > In order to get the first line not removed, I have inserted a blank line at the top of the file. (short_tem.tex) then after inserting the template the file is completly spoilt.
              >
              > What I am doing wrong here ?
              >
              > Thanks for your help,
              >
              > Alain
              >
              Up.
              I really need your help.

              Alain

              --
              --
              You received this message from the "vim_use" maillist.
              Do not top-post! Type your reply below the text you are replying to.
              For more information, visit http://www.vim.org/maillist.php

              ---
              You received this message because you are subscribed to the Google Groups "vim_use" group.
              To unsubscribe from this group and stop receiving emails from it, send an email to vim_use+unsubscribe@....
              For more options, visit https://groups.google.com/d/optout.
            • Ben Fritz
              I don t really know what your strange.tex attachment was for, but it looks like some sort of templating plugin placeholder got inserted all over the place.
              Message 6 of 7 , Apr 17 8:54 AM
              • 0 Attachment
                I don't really know what your "strange.tex" attachment was for, but it looks like some sort of templating plugin placeholder got inserted all over the place.

                For your "test.tex" file, it looks like your problem is a "stairstep" indent when you inserted a LaTeX template.

                I don't use TeX or LaTeX, but I did find a couple pages which seem to describe a similar problem with the automatic indenting of LaTeX documents.

                This one ( http://stackoverflow.com/questions/12693687/vim-automatic-indent-of-latex-files-bad ) suggests:
                let g:tex_flavor='latex'

                This one ( http://superuser.com/questions/494115/vim-indent-in-latex-align-goes-crazy ) suggests:
                let g:tex_indent_brace=0

                Both assume you have either "filetype indent on" or "filetype plugin indent on" in your .vimrc.

                Neither really has a very definite resolution.

                The other thing I can think of which might help (depending on how template insertion works) is setting the 'paste' option prior to inserting the template.

                Good luck! Please post back if you find a solution. Hopefully somebody who actually uses Vim's LaTeX features can step in here.

                --
                --
                You received this message from the "vim_use" maillist.
                Do not top-post! Type your reply below the text you are replying to.
                For more information, visit http://www.vim.org/maillist.php

                ---
                You received this message because you are subscribed to the Google Groups "vim_use" group.
                To unsubscribe from this group and stop receiving emails from it, send an email to vim_use+unsubscribe@....
                For more options, visit https://groups.google.com/d/optout.
              • netraken
                Hello, Thanks for your answer. ... the strange.tex is the result of using my template with an empty line above the documentclass line. All this garbage is
                Message 7 of 7 , Apr 17 10:24 PM
                • 0 Attachment
                  Hello,

                  Thanks for your answer.
                  On 17/04/2014 17:54, Ben Fritz wrote:
                  > I don't really know what your "strange.tex" attachment was for, but it looks like some sort of templating plugin placeholder got inserted all over the place.

                  the strange.tex is the result of using my template with an empty line
                  above the \documentclass line. All this garbage is inserted by vim ! I
                  have also other templates that are truncated for almost half the file,
                  so it is a problem more serious than only formatting.
                  >
                  > For your "test.tex" file, it looks like your problem is a "stairstep" indent when you inserted a LaTeX template.

                  >
                  > I don't use TeX or LaTeX, but I did find a couple pages which seem to describe a similar problem with the automatic indenting of LaTeX documents.
                  >
                  > This one ( http://stackoverflow.com/questions/12693687/vim-automatic-indent-of-latex-files-bad ) suggests:
                  > let g:tex_flavor='latex'
                  Already done.
                  >
                  > This one ( http://superuser.com/questions/494115/vim-indent-in-latex-align-goes-crazy ) suggests:
                  > let g:tex_indent_brace=0

                  Tried but no success.

                  I have quite a few options in my .vimrc and tex.vim. I'll remove all of
                  them and reinstall them step by step. That the only thing I can think of.


                  Alain

                  --
                  --
                  You received this message from the "vim_use" maillist.
                  Do not top-post! Type your reply below the text you are replying to.
                  For more information, visit http://www.vim.org/maillist.php

                  ---
                  You received this message because you are subscribed to the Google Groups "vim_use" group.
                  To unsubscribe from this group and stop receiving emails from it, send an email to vim_use+unsubscribe@....
                  For more options, visit https://groups.google.com/d/optout.
                Your message has been successfully submitted and would be delivered to recipients shortly.