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

Re: New tab visualization

Expand Messages
  • Kip Coul
    Hello Andy, Good suggestion. I ll look into the internals of listchars to implement this. I ll keep you posted. Cheers, Kip ... -- You received this message
    Message 1 of 8 , Dec 31, 2012
    • 0 Attachment
      Hello Andy,

      Good suggestion.

      I'll look into the internals of listchars to implement this.

      I'll keep you posted.

      Cheers,
      Kip

      On 31 déc. 2012, at 11:47, Andy Spencer <andy753421@...> wrote:

      > On 2012-12-31 10:22, Kip Coul wrote:
      >> Currently, the visualization of a tab is represented as a first
      >> character followed by as many repetitions of a second character needed
      >> to fill the width (lcs_tab1 and lcs_tab2 in the code, if I'm not
      >> mistaken).
      >>
      >> I'd like to do the opposite, through an option: the first character
      >> repeated plus the second character at the end. That would enable using
      >> arrows ('--->' for 4-space wide tabs).
      >>
      >> What do you think about this? I could add an option such as 'tabview'
      >> which could take two values.
      >
      > I've wanted this before as well.
      >
      > Maybe instead of adding another option you could modify how listchars
      > works? You could use tab:xyz for the left character, the repeated middle
      > character, and the (optional) right character. Then to get an arrow you
      > could use:
      >
      > :set listchars=tab:-->
      >
      > Any existing configurations that use the two character format `tab:xy'
      > would just be a special case and would be equivalent to tab:xyy.
      >
      > --
      > You received this message from the "vim_dev" 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 from the "vim_dev" 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
    • Ingo Karkat
      ... This has been proposed before, but not been accepted yet. http://groups.google.com/group/vim_dev/browse_thread/thread/6eaf6fc82626ec25 Have a look at the
      Message 2 of 8 , Dec 31, 2012
      • 0 Attachment
        On 31-Dec-12 20:12:13 +0900, Kip Coul wrote:

        > Hello Andy,
        >
        > Good suggestion.
        >
        > I'll look into the internals of listchars to implement this.
        >
        > I'll keep you posted.
        >
        > Cheers,
        > Kip
        >
        > On 31 déc. 2012, at 11:47, Andy Spencer <andy753421@...> wrote:
        >
        >> On 2012-12-31 10:22, Kip Coul wrote:
        >>> Currently, the visualization of a tab is represented as a first
        >>> character followed by as many repetitions of a second character needed
        >>> to fill the width (lcs_tab1 and lcs_tab2 in the code, if I'm not
        >>> mistaken).
        >>>
        >>> I'd like to do the opposite, through an option: the first character
        >>> repeated plus the second character at the end. That would enable using
        >>> arrows ('--->' for 4-space wide tabs).
        >>>
        >>> What do you think about this? I could add an option such as 'tabview'
        >>> which could take two values.
        >>
        >> I've wanted this before as well.
        >>
        >> Maybe instead of adding another option you could modify how listchars
        >> works? You could use tab:xyz for the left character, the repeated middle
        >> character, and the (optional) right character. Then to get an arrow you
        >> could use:
        >>
        >> :set listchars=tab:-->
        >>
        >> Any existing configurations that use the two character format `tab:xy'
        >> would just be a special case and would be equivalent to tab:xyy.

        This has been proposed before, but not been accepted yet.

        http://groups.google.com/group/vim_dev/browse_thread/thread/6eaf6fc82626ec25

        Have a look at the patch, check whether it still works, try to improve it (tests
        would be especially nice; Bram rightly wants better test coverage now), and
        resubmit for consideration here.

        -- regards, ingo

        PS: Please don't top-post to this list.

        --
        You received this message from the "vim_dev" 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
      • Bram Moolenaar
        ... Instead of changing the meaning of tab: it s probably easier to add another item, e.g. rtab:. Or bat: (although most users will miss the hint of a reverse
        Message 3 of 8 , Jan 2, 2013
        • 0 Attachment
          Andy Spencer wrote:

          > On 2012-12-31 10:22, Kip Coul wrote:
          > > Currently, the visualization of a tab is represented as a first
          > > character followed by as many repetitions of a second character needed
          > > to fill the width (lcs_tab1 and lcs_tab2 in the code, if I'm not
          > > mistaken).
          > >
          > > I'd like to do the opposite, through an option: the first character
          > > repeated plus the second character at the end. That would enable using
          > > arrows ('--->' for 4-space wide tabs).
          > >
          > > What do you think about this? I could add an option such as 'tabview'
          > > which could take two values.
          >
          > I've wanted this before as well.
          >
          > Maybe instead of adding another option you could modify how listchars
          > works? You could use tab:xyz for the left character, the repeated middle
          > character, and the (optional) right character. Then to get an arrow you
          > could use:
          >
          > :set listchars=tab:-->
          >
          > Any existing configurations that use the two character format `tab:xy'
          > would just be a special case and would be equivalent to tab:xyy.

          Instead of changing the meaning of tab: it's probably easier to add
          another item, e.g. rtab:. Or bat: (although most users will miss the
          hint of a reverse tab...).

          --
          hundred-and-one symptoms of being an internet addict:
          227. You sleep next to your monitor. Or on top of it.

          /// Bram Moolenaar -- Bram@... -- http://www.Moolenaar.net \\\
          /// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
          \\\ an exciting new programming language -- http://www.Zimbu.org ///
          \\\ help me help AIDS victims -- http://ICCF-Holland.org ///

          --
          You received this message from the "vim_dev" 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
        • Pragm B
          Hello everyone, I have been wanting this feature as well, so I made a patch. The way it works is as follows: - an option, called ntab (for new tab , or end
          Message 4 of 8 , Oct 13, 2013
          • 0 Attachment
            Hello everyone,

            I have been wanting this feature as well, so I made a patch.
            The way it works is as follows:
            - an option, called "ntab" (for "new tab", or "end tab") is introduced within "listchars". It can be set like this: "ntab:1" or "ntab:y" or "ntab:Y" and unset with "ntab:0" or "ntab:n" or "ntab:N".
            - when "ntab" is off [default], things behave as they currently do
            - when "ntab" is on, the first character of "tab" is repeated, and the last character is mandatorily put.
            This means that "tab:->,ntab:1" will show a tab that takes four spaces as "--->" and a tab that taks 1 space as ">".

            I attach the patch with this e-mail.

            Thanks!

            Nathaniel


            On Wednesday, January 2, 2013 5:50:23 PM UTC+1, Bram Moolenaar wrote:
            > Andy Spencer wrote:
            >
            >
            >
            > > On 2012-12-31 10:22, Kip Coul wrote:
            >
            > > > Currently, the visualization of a tab is represented as a first
            >
            > > > character followed by as many repetitions of a second character needed
            >
            > > > to fill the width (lcs_tab1 and lcs_tab2 in the code, if I'm not
            >
            > > > mistaken).
            >
            > > >
            >
            > > > I'd like to do the opposite, through an option: the first character
            >
            > > > repeated plus the second character at the end. That would enable using
            >
            > > > arrows ('--->' for 4-space wide tabs).
            >
            > > >
            >
            > > > What do you think about this? I could add an option such as 'tabview'
            >
            > > > which could take two values.
            >
            > >
            >
            > > I've wanted this before as well.
            >
            > >
            >
            > > Maybe instead of adding another option you could modify how listchars
            >
            > > works? You could use tab:xyz for the left character, the repeated middle
            >
            > > character, and the (optional) right character. Then to get an arrow you
            >
            > > could use:
            >
            > >
            >
            > > :set listchars=tab:-->
            >
            > >
            >
            > > Any existing configurations that use the two character format `tab:xy'
            >
            > > would just be a special case and would be equivalent to tab:xyy.
            >
            >
            >
            > Instead of changing the meaning of tab: it's probably easier to add
            >
            > another item, e.g. rtab:. Or bat: (although most users will miss the
            >
            > hint of a reverse tab...).
            >
            >
            >
            > --
            >
            > hundred-and-one symptoms of being an internet addict:
            >
            > 227. You sleep next to your monitor. Or on top of it.
            >
            >
            >
            > /// Bram Moolenaar -- XXXXXXXXXXX -- http://www.Moolenaar.net \\\
            >
            > /// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
            >
            > \\\ an exciting new programming language -- http://www.Zimbu.org ///
            >
            > \\\ help me help AIDS victims -- http://ICCF-Holland.org ///

            --
            --
            You received this message from the "vim_dev" 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_dev" group.
            To unsubscribe from this group and stop receiving emails from it, send an email to vim_dev+unsubscribe@....
            For more options, visit https://groups.google.com/groups/opt_out.
          • Bram Moolenaar
            ... Thanks, I ll add it in the todo list. Is Pragm B. your full name? -- DENNIS: Listen -- strange women lying in ponds distributing swords is no basis for a
            Message 5 of 8 , Oct 13, 2013
            • 0 Attachment
              Pragm B. wrote:

              > Hello everyone,
              >
              > I have been wanting this feature as well, so I made a patch.
              > The way it works is as follows:
              > - an option, called "ntab" (for "new tab", or "end tab") is introduced within "listchars". It can be set like this: "ntab:1" or "ntab:y" or "ntab:Y" and unset with "ntab:0" or "ntab:n" or "ntab:N".
              > - when "ntab" is off [default], things behave as they currently do
              > - when "ntab" is on, the first character of "tab" is repeated, and the last character is mandatorily put.
              > This means that "tab:->,ntab:1" will show a tab that takes four spaces as "--->" and a tab that taks 1 space as ">".
              >
              > I attach the patch with this e-mail.

              Thanks, I'll add it in the todo list.

              Is Pragm B. your full name?

              --
              DENNIS: Listen -- strange women lying in ponds distributing swords is no
              basis for a system of government. Supreme executive power derives
              from a mandate from the masses, not from some farcical aquatic
              ceremony.
              The Quest for the Holy Grail (Monty Python)

              /// Bram Moolenaar -- Bram@... -- http://www.Moolenaar.net \\\
              /// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
              \\\ an exciting new programming language -- http://www.Zimbu.org ///
              \\\ help me help AIDS victims -- http://ICCF-Holland.org ///

              --
              --
              You received this message from the "vim_dev" 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_dev" group.
              To unsubscribe from this group and stop receiving emails from it, send an email to vim_dev+unsubscribe@....
              For more options, visit https://groups.google.com/groups/opt_out.
            • Pragm B
              Hello, No, that s just a nickname :) My name is Nathaniel Braun. Thanks for integrating the patch! ... -- -- You received this message from the vim_dev
              Message 6 of 8 , Oct 13, 2013
              • 0 Attachment
                Hello,

                No, that's just a nickname :)

                My name is Nathaniel Braun.

                Thanks for integrating the patch!


                On Sun, Oct 13, 2013 at 11:07 PM, Bram Moolenaar <Bram@...> wrote:

                Pragm B. wrote:

                > Hello everyone,
                >
                > I have been wanting this feature as well, so I made a patch.
                > The way it works is as follows:
                >    - an option, called "ntab" (for "new tab", or "end tab") is introduced within "listchars". It can be set like this: "ntab:1" or "ntab:y" or "ntab:Y" and unset with "ntab:0" or "ntab:n" or "ntab:N".
                >    - when "ntab" is off [default], things behave as they currently do
                >    - when "ntab" is on, the first character of "tab" is repeated, and the last character is mandatorily put.
                > This means that "tab:->,ntab:1" will show a tab that takes four spaces as "--->" and a tab that taks 1 space as ">".
                >
                > I attach the patch with this e-mail.

                Thanks, I'll add it in the todo list.

                Is Pragm B. your full name?

                --
                DENNIS:  Listen -- strange women lying in ponds distributing swords is no
                         basis for a system of government.  Supreme executive power derives
                         from a mandate from the masses, not from some farcical aquatic
                         ceremony.
                                                  The Quest for the Holy Grail (Monty Python)

                 /// Bram Moolenaar -- Bram@... -- http://www.Moolenaar.net   \\\
                ///        sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
                \\\  an exciting new programming language -- http://www.Zimbu.org        ///
                 \\\            help me help AIDS victims -- http://ICCF-Holland.org    ///

                --
                --
                You received this message from the "vim_dev" 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 a topic in the Google Groups "vim_dev" group.
                To unsubscribe from this topic, visit https://groups.google.com/d/topic/vim_dev/AZQWFbgnMIo/unsubscribe.
                To unsubscribe from this group and all its topics, send an email to vim_dev+unsubscribe@....
                For more options, visit https://groups.google.com/groups/opt_out.

                --
                --
                You received this message from the "vim_dev" 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_dev" group.
                To unsubscribe from this group and stop receiving emails from it, send an email to vim_dev+unsubscribe@....
                For more options, visit https://groups.google.com/groups/opt_out.
              Your message has been successfully submitted and would be delivered to recipients shortly.