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

Re: 7.2a: No color in xterm?

Expand Messages
  • Corinna Vinschen
    ... xterm has color capabilities for ages and the terminfo xterm entry contains this information. Of course, when linking against libtermcap instead of
    Message 1 of 9 , Jul 1, 2008
    • 0 Attachment
      On Jul 1 16:37, Marc Haisenko wrote:
      > On Tuesday 01 July 2008, Corinna Vinschen wrote:
      > > Hi,
      > >
      > > When running 7.2a in an xterm under Cygwin, the color capabilities
      > > of the xterm are not used. Rather, vim uses only standard terminal
      > > capabilities like underline, bold, etc.
      > >
      > > This doesn't happen with vim 7.1. Running vim 7.1 in an xterm under
      > > Cygwin shows all colors the xterm is capable of.
      > > in the syntax color settings.
      >
      > Well, "xterm" really has no color support. It was monochrome. You need to set
      > the TERM variable to either "xterm-color" or even "xterm-256color".

      xterm has color capabilities for ages and the terminfo xterm entry
      contains this information. Of course, when linking against libtermcap
      instead of ncurses... ;)


      Corinna

      --
      Corinna Vinschen
      Cygwin Project Co-Leader
      Red Hat

      --~--~---------~--~----~------------~-------~--~----~
      You received this message from the "vim_dev" maillist.
      For more information, visit http://www.vim.org/maillist.php
      -~----------~----~----~----~------~----~------~--~---
    • Marc Haisenko
      ... Yes, but in a lot of places it is still assumed that xterm means monochrome. For example, try OpenSolaris: if TERM=xterm you ll get a monochrome vim.
      Message 2 of 9 , Jul 1, 2008
      • 0 Attachment
        On Tuesday 01 July 2008, Corinna Vinschen wrote:
        > xterm has color capabilities for ages and the terminfo xterm entry
        > contains this information.

        Yes, but in a lot of places it is still assumed that "xterm" means monochrome.
        For example, try OpenSolaris: if TERM=xterm you'll get a monochrome vim.
        Setting it to "xterm-color" or "xterm-256color" fixes that. I ran into this
        when I installed OpenSolaris a few weeks back :-)

        Code that outputs color escape sequences for "xterm" is, in a very strict
        sense, wrong. Of course there's always the "correct-according-to-the-specs"
        vs. "Do-What-I-Mean" conflict :-)

        > Of course, when linking against libtermcap instead of ncurses... ;)
        >
        > Corinna

        Hehe :-)

        Marc


        --
        Marc Haisenko

        Comdasys AG
        Rüdesheimer Str. 7
        80686 München
        Germany

        Tel.: +49 (0)89 548 433 321

        --~--~---------~--~----~------------~-------~--~----~
        You received this message from the "vim_dev" maillist.
        For more information, visit http://www.vim.org/maillist.php
        -~----------~----~----~----~------~----~------~--~---
      • Gary Johnson
        ... The terminfo description for xterm that is distributed with xterm itself, which I would think would make it definitive, says it supports 8 colors.
        Message 3 of 9 , Jul 1, 2008
        • 0 Attachment
          On 2008-07-01, Marc Haisenko <haisenko@...> wrote:
          > On Tuesday 01 July 2008, Corinna Vinschen wrote:
          > > xterm has color capabilities for ages and the terminfo xterm entry
          > > contains this information.
          >
          > Yes, but in a lot of places it is still assumed that "xterm" means monochrome.
          > For example, try OpenSolaris: if TERM=xterm you'll get a monochrome vim.
          > Setting it to "xterm-color" or "xterm-256color" fixes that. I ran into this
          > when I installed OpenSolaris a few weeks back :-)
          >
          > Code that outputs color escape sequences for "xterm" is, in a very strict
          > sense, wrong. Of course there's always the "correct-according-to-the-specs"
          > vs. "Do-What-I-Mean" conflict :-)

          The terminfo description for "xterm" that is distributed with xterm
          itself, which I would think would make it definitive, says it
          supports 8 colors.

          Regards,
          Gary


          --~--~---------~--~----~------------~-------~--~----~
          You received this message from the "vim_dev" maillist.
          For more information, visit http://www.vim.org/maillist.php
          -~----------~----~----~----~------~----~------~--~---
        • Marc Haisenko
          ... (from XFree86/X.org) ... ...which ALSO is wrong because it supports 256 colors as you verify yourself with the attached script. As you can see, the UNIX
          Message 4 of 9 , Jul 1, 2008
          • 0 Attachment
            On Tuesday 01 July 2008, Gary Johnson wrote:
            > On 2008-07-01, Marc Haisenko <haisenko@...> wrote:
            > > On Tuesday 01 July 2008, Corinna Vinschen wrote:
            > > > xterm has color capabilities for ages and the terminfo xterm entry
            > > > contains this information.
            > >
            > > Yes, but in a lot of places it is still assumed that "xterm" means
            > > monochrome. For example, try OpenSolaris: if TERM=xterm you'll get a
            > > monochrome vim. Setting it to "xterm-color" or "xterm-256color" fixes
            > > that. I ran into this when I installed OpenSolaris a few weeks back :-)
            > >
            > > Code that outputs color escape sequences for "xterm" is, in a very strict
            > > sense, wrong. Of course there's always the
            > > "correct-according-to-the-specs" vs. "Do-What-I-Mean" conflict :-)
            >
            > The terminfo description for "xterm" that is distributed with xterm
            (from XFree86/X.org)
            > itself, which I would think would make it definitive, says it
            > supports 8 colors.
            >
            > Regards,
            > Gary

            ...which ALSO is wrong because it supports 256 colors as you verify yourself
            with the attached script.

            As you can see, the UNIX way of handling output is severely broken and always
            has been because there's just no way that the terminal can tell the system
            and/or application what it CAN support. We only have some files saying what
            the system THINKS a given terminal can support. It doesn't know for sure and
            just hopes for the best.

            Also, see the ncurses FAQ entry about the issue:
            http://invisible-island.net/ncurses/ncurses.faq.html#no_xterm_color

            Sorry for the off-topic line noise, will keep my mouth shut now :-)

            Marc

            --
            Marc Haisenko

            Comdasys AG
            Rüdesheimer Str. 7
            80686 München
            Germany

            Tel.: +49 (0)89 548 433 321

            --~--~---------~--~----~------------~-------~--~----~
            You received this message from the "vim_dev" maillist.
            For more information, visit http://www.vim.org/maillist.php
            -~----------~----~----~----~------~----~------~--~---
          Your message has been successfully submitted and would be delivered to recipients shortly.