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

Re: [Patch] Nicer notebook tabs with GTK2

Expand Messages
  • Fran├žois Ingelrest
    Hi! ... I would not say it s useless in the sense that icons make notebook tabs a bit nicer to look at. I actually never liked notebook tabs in GVim because
    Message 1 of 12 , May 3 1:56 AM
    • 0 Attachment
      Hi!

      On Fri, May 2, 2008 at 10:23 PM, Bram Moolenaar <Bram@...> wrote:
      > > Here is a patch that improves a bit notebook tabs with GTK2. It:
      > > - Groups the creation of tab labels into one function (the code was
      > > duplicated at two places before)
      > > - Adds a file icon in front of the label
      > >
      > > Here are some screenshots:
      > >
      > > http://www.silent-blade.org/misc/gvim-notebook-before.png
      > > http://www.silent-blade.org/misc/gvim-notebook-after.png
      > >
      > > Comments are welcome :-)
      >
      > I also think that the space that the icon takes is too much. Most
      > people edit files of the same type (e.g., all Java files), the icon
      > isn't very helpful then. And when you have two windows in one Tab, what
      > icon are you going to show?

      I would not say it's useless in the sense that icons make notebook
      tabs a bit nicer to look at. I actually never liked notebook tabs in
      GVim because they are too narrow and that makes difficult to spot the
      one I need (the main reason I wrote this small patch). Also, in this
      perspective, the toolbar is useless as it takes too much space for
      commands that can already easily be typed. But it's there because it's
      the GUI version and that's the way GUIs generally look like. The same
      goes for icons in notebook tabs: Almost all the GUI applications I can
      think of display such an icon although the label would be sufficient.
      It's just a bit nicer to look at.

      Regarding multiple windows in one notebook tab: As Tony said, the
      active window should be used. Actually the active filetype should be
      used, and the icon should be updated as soon as it changes, be it
      because the active window has changed or because the user has :set it.

      Anyway, if you feel it's useless, I'm fine with that: I'm not going to
      spend time writing code that people don't want/need. That's also why I
      wanted your feedback :-)

      And thanks for taking the time to reply!

      --~--~---------~--~----~------------~-------~--~----~
      You received this message from the "vim_dev" maillist.
      For more information, visit http://www.vim.org/maillist.php
      -~----------~----~----~----~------~----~------~--~---
    • Nico Weber
      ... FWIW, I think this is a nice change. If I edit more than, say, 5 files, I can t use a tab for each file anyways. For just two to three tabs, the icons give
      Message 2 of 12 , May 3 2:30 AM
      • 0 Attachment
        > I would not say it's useless in the sense that icons make notebook
        > tabs a bit nicer to look at. I actually never liked notebook tabs in
        > GVim because they are too narrow and that makes difficult to spot the
        > one I need (the main reason I wrote this small patch). Also, in this
        > perspective, the toolbar is useless as it takes too much space for
        > commands that can already easily be typed. But it's there because it's
        > the GUI version and that's the way GUIs generally look like. The same
        > goes for icons in notebook tabs: Almost all the GUI applications I can
        > think of display such an icon although the label would be sufficient.
        > It's just a bit nicer to look at.

        FWIW, I think this is a nice change. If I edit more than, say, 5
        files, I can't use a tab for each file anyways. For just two to three
        tabs, the icons give the tabs a much nicer look (at least on GTK,
        where most tabs include file icons. In OS X, tabs usually don't have
        file icons, so I wouldn't want it in the OS X version).

        Nico

        --~--~---------~--~----~------------~-------~--~----~
        You received this message from the "vim_dev" maillist.
        For more information, visit http://www.vim.org/maillist.php
        -~----------~----~----~----~------~----~------~--~---
      • Antony Scriven
        ... More than just looking nicer, I think it can be a usability improvement, e.g. Firefox displays the shortcut icon in its tabs; I find this makes finding a
        Message 3 of 12 , May 6 8:43 AM
        • 0 Attachment
          Nico Weber <nicolasweber@...> wrote:

          > > [...]
          >
          > > the GUI version and that's the way GUIs generally look
          > > like. The same goes for icons in notebook tabs: Almost
          > > all the GUI applications I can think of display such an
          > > icon although the label would be sufficient. It's just
          > > a bit nicer to look at.
          >
          > FWIW, I think this is a nice change. If I edit more than,
          > say, 5 files, I can't use a tab for each file anyways.
          > For just two to three tabs, the icons give the tabs
          > a much nicer look (at least on GTK, where most tabs
          > include file icons. In OS X, tabs usually don't have file
          > icons, so I wouldn't want it in the OS X version).

          More than just looking nicer, I think it can be a usability
          improvement, e.g. Firefox displays the shortcut icon in its
          tabs; I find this makes finding a tab easier. But... Vim can
          detect ~500 different filetypes. Who's coming up with 500
          distinct and easily recognizable icons? --Antony

          --~--~---------~--~----~------------~-------~--~----~
          You received this message from the "vim_dev" maillist.
          For more information, visit http://www.vim.org/maillist.php
          -~----------~----~----~----~------~----~------~--~---
        • Antony Scriven
          ... Btw, I didn t mean for that to sound negative. I d be happy if you could come up with a good solution for that. --Antony
          Message 4 of 12 , May 6 8:53 AM
          • 0 Attachment
            2008/5/6 Antony Scriven <adscriven@...>:

            > [... about icons for filetypes in GUI tabs ...]
            > But... Vim can detect ~500 different filetypes. Who's
            > coming up with 500 distinct and easily recognizable
            > icons? --Antony

            Btw, I didn't mean for that to sound negative. I'd be happy
            if you could come up with a good solution for that. --Antony

            --~--~---------~--~----~------------~-------~--~----~
            You received this message from the "vim_dev" maillist.
            For more information, visit http://www.vim.org/maillist.php
            -~----------~----~----~----~------~----~------~--~---
          • Fran├žois Ingelrest
            ... GTK actually uses the system icons defined by the user s theme, i.e., you provide it the mime type and it provides you the icon associated to that mime
            Message 5 of 12 , May 6 9:02 AM
            • 0 Attachment
              On Tue, May 6, 2008 at 5:43 PM, Antony Scriven <adscriven@...> wrote:
              > Nico Weber <nicolasweber@...> wrote:
              > > > the GUI version and that's the way GUIs generally look
              > > > like. The same goes for icons in notebook tabs: Almost
              > > > all the GUI applications I can think of display such an
              > > > icon although the label would be sufficient. It's just
              > > > a bit nicer to look at.
              > >
              > > FWIW, I think this is a nice change. If I edit more than,
              > > say, 5 files, I can't use a tab for each file anyways.
              > > For just two to three tabs, the icons give the tabs
              > > a much nicer look (at least on GTK, where most tabs
              > > include file icons. In OS X, tabs usually don't have file
              > > icons, so I wouldn't want it in the OS X version).
              >
              > More than just looking nicer, I think it can be a usability
              > improvement, e.g. Firefox displays the shortcut icon in its
              > tabs; I find this makes finding a tab easier. But... Vim can
              > detect ~500 different filetypes. Who's coming up with 500
              > distinct and easily recognizable icons? --Antony

              GTK actually uses the system icons defined by the user's theme, i.e.,
              you provide it the mime type and it provides you the icon associated
              to that mime type in the current user's theme. Those icons are the
              ones that are used for instance in Nautilus. Almost the same goes for
              the toolbar: AFAIK, icons are taken from the user's theme and are
              directly provided by GTK.

              --~--~---------~--~----~------------~-------~--~----~
              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.