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

New snapshot (r38) of MacVim

Expand Messages
  • björn
    I have uploaded a new snapshot of MacVim to: http://code.google.com/p/macvim/ Let me know if you have any problems with this snapshot. The major changes are:
    Message 1 of 16 , Jul 29, 2007
    • 0 Attachment
      I have uploaded a new snapshot of MacVim to:

      http://code.google.com/p/macvim/

      Let me know if you have any problems with this snapshot.  The major changes are:
      - based on vim 7.1.* instead of 7.0.*
      - no process leaks
      - less memory leaks (it might still leak some)
      - app should no longer hang when resizing window
      - warning is given when close button pressed
      - distributed objects used for interprocess communication
      - tab sizing changed (more tabs can fit at the same time)

      If MacVim ever hangs like Nico described when he resized the window, that means the "communication queues" between MacVim and Vim are clogging up.  Please let me know if you discover any such behaviour and I will most likely be able to fix it very easily.  Unfortunately this is timing related, so if you have a faster/slower machine than I do you might run into problems that I will never have.  I have gone through the code to eliminate all the problem areas I could find, so hopefully nobody will have any problems now.

      I will try to release a new snapshot weekly (on Sunday night central european time, most likely), and announce new snapshots on this list.


      /Björn


      P.S. If you dislike the status line, open terminal and type:
         defaults write org.vim.MacVim statuslineoff 1
      (It serves no major purpose anymore, so I might disable it permanently soon.)

      If you think the tabs are too small when many are open at the same time, type:
        defaults write org.vim.MacVim tabminwidth 80
      (where 80 represents the width in pixels)

      If you want the tabs to have a different size by default, type:
        defaults write org.vim.MacVim taboptimumwidth 164



      --~--~---------~--~----~------------~-------~--~----~
      You received this message from the "vim_mac" maillist.
      For more information, visit http://www.vim.org/maillist.php
      -~----------~----~----~----~------~----~------~--~---

    • Nico Weber
      Hi, ... Still happens for me (only if I hit the zoom button first, though). Zoom button behaviour is still broken (should toggle between best size (whatever
      Message 2 of 16 , Jul 30, 2007
      • 0 Attachment
        Hi,

        > - app should no longer hang when resizing window

        Still happens for me (only if I hit the zoom button first, though).
        Zoom button behaviour is still broken (should toggle between "best
        size" (whatever that means; for me a "vertical maximize" makes most
        sense with vim) and "user size" (usually the size the window had
        before you hit the zoom button the first time...check out the HIG for
        the exact wording. The default Cocoa handler for that does the Wrong
        Thing.)

        And the toolbar is still broken: As soon as I hit Cmd-t to open a new
        tab, a second star appears below the "chevron" (I believe that's the
        right term -- the thingie to click on to reveal the overflow toolbar
        buttons). I have columns=80, if you can't reproduce it I can send you
        a screenshot.

        And it's a bit weird that the window turns white during resizing. I
        guess this is an implementation artifact (you're talking to vim
        processes over some pipe)?

        > If MacVim ever hangs like Nico described when he resized the
        > window, that means the "communication queues" between MacVim and
        > Vim are clogging up. Please let me know if you discover any such
        > behaviour and I will most likely be able to fix it very easily.
        > Unfortunately this is timing related, so if you have a faster/
        > slower machine than I do you might run into problems that I will
        > never have. I have gone through the code to eliminate all the
        > problem areas I could find, so hopefully nobody will have any
        > problems now.

        Sorry ;-) I've got a 2.4 GHz Core 2 Duo.

        > I will try to release a new snapshot weekly (on Sunday night
        > central european time, most likely), and announce new snapshots on
        > this list.

        w00t.

        > (It serves no major purpose anymore, so I might disable it
        > permanently soon.)

        +1.

        Can you set gui.border_offset (or gui.border_width, whatever you use)
        to something more than 0? Having letters at the left edge of the
        window looks weird to me.

        Oh, I just tried to do some actual work with MacVim (I opened
        gui_mac.c), and after hitting zoom (first thing I do with the "old"
        vim), thinking "oh, damn, wrong", hitting zoom again (because that
        undoes zoom in every sane application) and thinking "damn, wrong
        _again_", the window was completely broken: Only the first 13.5
        toolbar icons were drawn (the right half of nr 14 ws missing) and
        there was no text visible at all, only patches of color. Hitting Ctrl-
        L didn't help.

        Looking forward to the next snapshot :-)

        Bye,
        Nico



        --~--~---------~--~----~------------~-------~--~----~
        You received this message from the "vim_mac" maillist.
        For more information, visit http://www.vim.org/maillist.php
        -~----------~----~----~----~------~----~------~--~---
      • björn
        ... Arghm! Ok, I will keep digging. I ve never managed to recreate this crash on my machine though, so I m not sure what gives. As for zoom button
        Message 3 of 16 , Jul 30, 2007
        • 0 Attachment
          > - app should no longer hang when resizing window

          Still happens for me (only if I hit the zoom button first, though).
          Zoom button behaviour is still broken (should toggle between "best
          size" (whatever that means; for me a "vertical maximize" makes most
          sense with vim) and "user size" (usually the size the window had
          before you hit the zoom button the first time...check out the HIG for
          the exact wording. The default Cocoa handler for that does the Wrong
          Thing.)

          Arghm!  Ok, I will keep digging.  I've never managed to recreate this crash on my machine though, so I'm not sure what gives.

          As for zoom button behaviour...hold down Cmd when you resize.  Presto!  I also think that height-only zoom should be the default, but for some reason I got the impression that Vim users preferred the zoom-to-all-i've-got style.  I will switch the role of the two with the next snapshot (I certainly _never_ zoom to fill the screen).

          And the toolbar is still broken: As soon as I hit Cmd-t to open a new
          tab, a second star appears below the "chevron" (I believe that's the
          right term -- the thingie to click on to reveal the overflow toolbar
          buttons). I have columns=80, if you can't reproduce it I can send you
          a screenshot.

          I've noticed some peculiarities with the toolbar as well...check out screenshot #3 (how nice that I managed to capture this on a screenshot :) ).  It's weird...I'm wondering if it is a bug in NSToolbar...I certainly have no control over it and it is not considered part of the "content view" of the window, so there should be no way to accidentally draw on top of it.  (And I don't even do any drawing myself...)

          And it's a bit weird that the window turns white during resizing. I
          guess this is an implementation artifact (you're talking to vim
          processes over some pipe)?

          On my TODO list.  Basically, every time you resize the NSTextStorage gets wiped (the content of which is what is actually drawn on screen), and stays that way until Vim has a chance to say "draw some text!" (and as you've noticed that takes a couple of milliseconds).

          Sorry ;-) I've got a 2.4 GHz Core 2 Duo.

          I'm the one who's sorry...I've got an iBook G4 :'(

          Can you set gui.border_offset (or gui.border_width, whatever you use)
          to something more than 0? Having letters at the left edge of the
          window looks weird to me.

          That is possible, although I have to figure out how to...I'll put it on my TODO.

          Oh, I just tried to do some actual work with MacVim (I opened
          gui_mac.c), and after hitting zoom (first thing I do with the "old"
          vim), thinking "oh, damn, wrong", hitting zoom again (because that
          undoes zoom in every sane application) and thinking "damn, wrong
          _again_", the window was completely broken: Only the first 13.5
          toolbar icons were drawn (the right half of nr 14 ws missing) and
          there was no text visible at all, only patches of color. Hitting Ctrl-
          L didn't help.

          Have you (or anybody else for that matter) managed to reproduce this?  I've terrorized the zoom button more than I care to admit and never experience any zooming problems.  Maybe I'll just disable window resizing. ;)


          /Björn

          --~--~---------~--~----~------------~-------~--~----~
          You received this message from the "vim_mac" maillist.
          For more information, visit http://www.vim.org/maillist.php
          -~----------~----~----~----~------~----~------~--~---

        • Robert Hicks
          ... intentional? ... What do you mean it serves no purpose? I have a custom config that shows various things about the file. Robert
          Message 4 of 16 , Jul 30, 2007
          • 0 Attachment
            björn wrote:
            > I have uploaded a new snapshot of MacVim to:
            >
            > http://code.google.com/p/macvim/
            >
            > Let me know if you have any problems with this snapshot. The major
            > changes are:
            > - based on vim 7.1.* instead of 7.0.*
            > - no process leaks
            > - less memory leaks (it might still leak some)
            > - app should no longer hang when resizing window
            > - warning is given when close button pressed
            > - distributed objects used for interprocess communication
            >

            :q on the last buffer closes the window and not the app? Is that
            intentional?

            >
            > P.S. If you dislike the status line, open terminal and type:
            > defaults write org.vim.MacVim statuslineoff 1
            > (It serves no major purpose anymore, so I might disable it permanently
            > soon.)

            What do you mean it serves no purpose? I have a custom config that shows
            various things about the file.

            Robert



            --~--~---------~--~----~------------~-------~--~----~
            You received this message from the "vim_mac" maillist.
            For more information, visit http://www.vim.org/maillist.php
            -~----------~----~----~----~------~----~------~--~---
          • Nico Weber
            Hi, ... It s more a hang than a crash. ... Much nicer. The problem with zoom without cmd is that it resizes the window to max height and about .75*max_width on
            Message 5 of 16 , Jul 30, 2007
            • 0 Attachment
              Hi,

              > Arghm! Ok, I will keep digging. I've never managed to recreate
              > this crash on my machine though, so I'm not sure what gives.

              It's more a hang than a crash.

              > As for zoom button behaviour...hold down Cmd when you resize.
              > Presto! I also think that height-only zoom should be the default,
              > but for some reason I got the impression that Vim users preferred
              > the zoom-to-all-i've-got style. I will switch the role of the two
              > with the next snapshot (I certainly _never_ zoom to fill the screen).

              Much nicer. The problem with zoom without cmd is that it resizes the
              window to max height and about .75*max_width on first click, max
              height and width on second click, and then toggles between these two
              states (instead of toggling between the original size and whatever
              the optimal size is). zoom-to-all-i've-got is completely useless with
              a decent (24'' or 30'') external monitor or a MBP with a good
              resolution imho :-P

              > I've noticed some peculiarities with the toolbar as well...check
              > out screenshot #3 (how nice that I managed to capture this on a
              > screenshot :) ). It's weird...I'm wondering if it is a bug in
              > NSToolbar...I certainly have no control over it and it is not
              > considered part of the "content view" of the window, so there
              > should be no way to accidentally draw on top of it. (And I don't
              > even do any drawing myself...)

              I doubt this is a bug in NSToolbar. It works in too many
              applications ;-) If it's not fixed by the weekend, I might see if I
              can fix this.

              > Oh, I just tried to do some actual work with MacVim (I opened
              > gui_mac.c), and after hitting zoom (first thing I do with the "old"
              > vim), thinking "oh, damn, wrong", hitting zoom again (because that
              > undoes zoom in every sane application) and thinking "damn, wrong
              > _again_", the window was completely broken: Only the first 13.5
              > toolbar icons were drawn (the right half of nr 14 ws missing) and
              > there was no text visible at all, only patches of color. Hitting Ctrl-
              > L didn't help.
              >
              > Have you (or anybody else for that matter) managed to reproduce
              > this? I've terrorized the zoom button more than I care to admit
              > and never experience any zooming problems. Maybe I'll just disable
              > window resizing. ;)

              Might be Intel-specific. It's quite easy to reproduce: Launch

              ~/Desktop nico$ MacVim-snapshot-r38/MacVim.app/Contents/MacOS/
              Vim -g ~/src/vim7/src/gui_mac.c

              , hit zoom (windows turns white, becomes somewhat large), zoom
              (window fills screen, still white), zoom (window is a bit smaller
              again, has some patches of color in it). Happens every time.

              Bye,
              Nico



              --~--~---------~--~----~------------~-------~--~----~
              You received this message from the "vim_mac" maillist.
              For more information, visit http://www.vim.org/maillist.php
              -~----------~----~----~----~------~----~------~--~---
            • Nico Weber
              ... I think he means the GUI status bar, not Vim s status bar. The GUI status bar doesn t do anything atm.
              Message 6 of 16 , Jul 30, 2007
              • 0 Attachment
                >> P.S. If you dislike the status line, open terminal and type:
                >> defaults write org.vim.MacVim statuslineoff 1
                >> (It serves no major purpose anymore, so I might disable it
                >> permanently
                >> soon.)
                >
                > What do you mean it serves no purpose? I have a custom config that
                > shows
                > various things about the file.

                I think he means the GUI status bar, not Vim's status bar. The GUI
                status bar doesn't do anything atm.


                --~--~---------~--~----~------------~-------~--~----~
                You received this message from the "vim_mac" maillist.
                For more information, visit http://www.vim.org/maillist.php
                -~----------~----~----~----~------~----~------~--~---
              • björn
                ... Exactly, I m talking about the GUI status line. All it does is say Hi, this is an annoying message when you start, it tells you the dimensions of the
                Message 7 of 16 , Jul 31, 2007
                • 0 Attachment
                  >> P.S. If you dislike the status line, open terminal and type:
                  >>    defaults write
                  org.vim.MacVim statuslineoff 1
                  >> (It serves no major purpose anymore, so I might disable it
                  >> permanently
                  >> soon.)
                  >
                  > What do you mean it serves no purpose? I have a custom config that
                  > shows
                  > various things about the file.

                  I think he means the GUI status bar, not Vim's status bar. The GUI
                  status bar doesn't do anything atm.

                  Exactly, I'm talking about the GUI status line.  All it does is say "Hi, this is an annoying message" when you start, it tells you the dimensions of the window when you drag to resize, and finally it gives a message when you use :browse.  Not overly useful.  To begin with I put it there so that the text view didn't go under the "resize triangle" in the bottom-right corner of the window, but now that scrollbars are supported this is no longer an issue (except if you :set go-=r, but if you do that I am guessing you want the text view to fill out as much of the window as possible).


                  /Björn

                  --~--~---------~--~----~------------~-------~--~----~
                  You received this message from the "vim_mac" maillist.
                  For more information, visit http://www.vim.org/maillist.php
                  -~----------~----~----~----~------~----~------~--~---

                • björn
                  ... That sounds like a familiar problem, which I thought I had fixed. I will experiment around with the zooming&resizing and ask you (and everybody else) to
                  Message 8 of 16 , Jul 31, 2007
                  • 0 Attachment
                    > As for zoom button behaviour...hold down Cmd when you resize.
                    > Presto!  I also think that height-only zoom should be the default,
                    > but for some reason I got the impression that Vim users preferred
                    > the zoom-to-all-i've-got style.  I will switch the role of the two
                    > with the next snapshot (I certainly _never_ zoom to fill the screen).

                    Much nicer. The problem with zoom without cmd is that it resizes the
                    window to max height and about .75*max_width on first click, max
                    height and width on second click, and then toggles between these two
                    states (instead of toggling between the original size and whatever
                    the optimal size is). zoom-to-all-i've-got is completely useless with
                    a decent (24'' or 30'') external monitor or a MBP with a good
                    resolution imho :-P

                    That sounds like a familiar problem, which I thought I had fixed.  I will experiment around with the zooming&resizing and ask you (and everybody else) to try it out.  I wish I could test it more properly myself, but it seems that it needs to be tested with different resolutions, etc.  It will be in the next snapshot.

                    > I've noticed some peculiarities with the toolbar as well...check
                    > out screenshot #3 (how nice that I managed to capture this on a
                    > screenshot :) ).  It's weird...I'm wondering if it is a bug in
                    > NSToolbar...I certainly have no control over it and it is not
                    > considered part of the "content view" of the window, so there
                    > should be no way to accidentally draw on top of it.  (And I don't
                    > even do any drawing myself...)

                    I doubt this is a bug in NSToolbar. It works in too many
                    applications ;-) If it's not fixed by the weekend, I might see if I
                    can fix this.

                    That would be greatly appreciated.

                    > Oh, I just tried to do some actual work with MacVim (I opened
                    > gui_mac.c), and after hitting zoom (first thing I do with the "old"
                    > vim), thinking "oh, damn, wrong", hitting zoom again (because that
                    > undoes zoom in every sane application) and thinking "damn, wrong
                    > _again_", the window was completely broken: Only the first 13.5
                    > toolbar icons were drawn (the right half of nr 14 ws missing) and
                    > there was no text visible at all, only patches of color. Hitting Ctrl-
                    > L didn't help.
                    >
                    > Have you (or anybody else for that matter) managed to reproduce
                    > this?  I've terrorized the zoom button more than I care to admit
                    > and never experience any zooming problems.  Maybe I'll just disable
                    > window resizing. ;)

                    Might be Intel-specific. It's quite easy to reproduce: Launch

                         ~/Desktop nico$ MacVim-snapshot-r38/MacVim.app/Contents/MacOS/
                    Vim -g ~/src/vim7/src/gui_mac.c

                    , hit zoom (windows turns white, becomes somewhat large), zoom
                    (window fills screen, still white), zoom (window is a bit smaller
                    again, has some patches of color in it). Happens every time.

                    Never happens for me.  It would be good if somebody else could confirm this bug (and note if it happens on an Intel or a PPC).


                    /Björn

                    --~--~---------~--~----~------------~-------~--~----~
                    You received this message from the "vim_mac" maillist.
                    For more information, visit http://www.vim.org/maillist.php
                    -~----------~----~----~----~------~----~------~--~---

                  • björn
                    ... This is expected (Apple) behaviour for apps with multiple windows (e.g. see what happens when you close the last window in Safari). The thing that is
                    Message 9 of 16 , Jul 31, 2007
                    • 0 Attachment
                      :q on the last buffer closes the window and not the app? Is that
                      intentional?

                      This is expected (Apple) behaviour for apps with multiple windows (e.g. see what happens when you close the last window in Safari).

                      The thing that is confusing is that the application you are running is MacVim (the GUI) and not Vim, which is just a process associated with one of MacVim's windows.  When you type :q, you are telling Vim to quit, but to MacVim this only means "close the window".  To me this is not so much of an issue, since I am used to hitting <D-q> to close apps on a Mac anyway, but if you are coming from another OS this might seem weird.


                      /Björn
                      --~--~---------~--~----~------------~-------~--~----~
                      You received this message from the "vim_mac" maillist.
                      For more information, visit http://www.vim.org/maillist.php
                      -~----------~----~----~----~------~----~------~--~---

                    • Robert Hicks
                      ... Yes, it seems wierd since the carbon gvim closes with :q the last window. Isn t that the expected vim behavior though? Is the object to Macify Vim on
                      Message 10 of 16 , Jul 31, 2007
                      • 0 Attachment
                        björn wrote:
                        > :q on the last buffer closes the window and not the app? Is that
                        > intentional?
                        >
                        >
                        > This is expected (Apple) behaviour for apps with multiple windows (e.g.
                        > see what happens when you close the last window in Safari).
                        >
                        > The thing that is confusing is that the application you are running is
                        > MacVim (the GUI) and not Vim, which is just a process associated with
                        > one of MacVim's windows. When you type :q, you are telling Vim to quit,
                        > but to MacVim this only means "close the window". To me this is not so
                        > much of an issue, since I am used to hitting <D-q> to close apps on a
                        > Mac anyway, but if you are coming from another OS this might seem weird.
                        >

                        Yes, it seems wierd since the carbon gvim closes with :q the last
                        window. Isn't that the "expected" vim behavior though? Is the object to
                        Macify Vim on OSX?

                        Robert


                        --~--~---------~--~----~------------~-------~--~----~
                        You received this message from the "vim_mac" maillist.
                        For more information, visit http://www.vim.org/maillist.php
                        -~----------~----~----~----~------~----~------~--~---
                      • björn
                        ... I must be misunderstanding your question, because to me it seems like I already answered it in my last post. In any case, let me try to answer it again.
                        Message 11 of 16 , Aug 1, 2007
                        • 0 Attachment
                          >     :q on the last buffer closes the window and not the app? Is that
                          >     intentional?
                          >
                          >
                          > This is expected (Apple) behaviour for apps with multiple windows (e.g.
                          > see what happens when you close the last window in Safari).
                          >
                          > The thing that is confusing is that the application you are running is
                          > MacVim (the GUI) and not Vim, which is just a process associated with
                          > one of MacVim's windows.  When you type :q, you are telling Vim to quit,
                          > but to MacVim this only means "close the window".  To me this is not so
                          > much of an issue, since I am used to hitting <D-q> to close apps on a
                          > Mac anyway, but if you are coming from another OS this might seem weird.
                          >

                          Yes, it seems wierd since the carbon gvim closes with :q the last
                          window. Isn't that the "expected" vim behavior though? Is the object to
                          Macify Vim on OSX?

                          I must be misunderstanding your question, because to me it seems like I already answered it in my last post.  In any case, let me try to answer it again.

                          Carbon Vim is one application running one Vim process.  MacVim is one application running multiple Vim processes.  I.e. Carbon Vim is an application with only one window and MacVim is an application with multiple windows.  It is standard (Apple) behaviour that apps with only one window should quit when the window closes, whereas apps with multiple windows should only quit when the user selects "Quit" on the application's menu.  Thus, MacVim should _not_ quit when you type ":q" even if you only had one Vim process ( i.e. one window) open at that time.

                          Of course, if many people object to this kind of behaviour in MacVim then I could change it.  But I would need a good reason to do so.  Saying that "Carbon Vim" behaves in this way is not enough of an argument to me.  I do appreciate the input though! :)


                          /Björn

                          --~--~---------~--~----~------------~-------~--~----~
                          You received this message from the "vim_mac" maillist.
                          For more information, visit http://www.vim.org/maillist.php
                          -~----------~----~----~----~------~----~------~--~---

                        • Robert Hicks
                          björn wrote: ... I understand. It isn t just a Carbon Vim thing though or maybe I am crazy. When I have vim open :q closes vim when there are no
                          Message 12 of 16 , Aug 1, 2007
                          • 0 Attachment
                            björn wrote:
                            <snip>
                            > Of course, if many people object to this kind of behaviour in MacVim
                            > then I could change it. But I would need a good reason to do so.
                            > Saying that "Carbon Vim" behaves in this way is not enough of an
                            > argument to me. I do appreciate the input though! :)
                            >
                            >
                            I understand. It isn't just a "Carbon Vim" thing though or maybe I am
                            crazy. When I have "vim" open :q closes vim when there are no other
                            buffers open. On Windows and HP/UX when I use GVim and I :q when there
                            are no other buffers open GVim exits entirely. It is only the MacVim one
                            that behaves differently. I am not saying that is good or bad. I just
                            wanted to make sure that it was the intended behavior since it is a
                            "snapshot" and you would have liked feedback on it. : )

                            Thanks for the answer and for the build. I do like it.

                            Robert


                            --~--~---------~--~----~------------~-------~--~----~
                            You received this message from the "vim_mac" maillist.
                            For more information, visit http://www.vim.org/maillist.php
                            -~----------~----~----~----~------~----~------~--~---
                          • björn
                            ... This is kind of funny...just after having written that long rant I sat down and did some work on MacVim only to realise the menus behave very oddly if
                            Message 13 of 16 , Aug 1, 2007
                            • 0 Attachment
                              > Of course, if many people object to this kind of behaviour in MacVim
                              > then I could change it.  But I would need a good reason to do so.
                              > Saying that "Carbon Vim" behaves in this way is not enough of an
                              > argument to me.  I do appreciate the input though! :)
                              >
                              >
                              I understand. It isn't just a "Carbon Vim" thing though or maybe I am
                              crazy. When I have "vim" open :q closes vim when there are no other
                              buffers open. On Windows and HP/UX when I use GVim and I :q when there
                              are no other buffers open GVim exits entirely. It is only the MacVim one
                              that behaves differently. I am not saying that is good or bad. I just
                              wanted to make sure that it was the intended behavior since it is a
                              "snapshot" and you would have liked feedback on it.  : )

                              Thanks for the answer and for the build. I do like it.

                              This is kind of funny...just after having written that long rant I sat down and did some work on MacVim only to realise the menus behave very oddly if there are no Vim windows open.  The best short-term solution was to...here it comes...make MacVim quit automatically when the last window closes.  :)

                              So lets see if anybody has any objections as to why MacVim _shouldn't_ quit when the last window closes.  Like Robert says, the good side to this solution is that this is more familiar to Vim users from other platforms;  the bad side is that it is not standard Apple behaviour.  Which one do people think is the lesser evil here?


                              /Björn

                              --~--~---------~--~----~------------~-------~--~----~
                              You received this message from the "vim_mac" maillist.
                              For more information, visit http://www.vim.org/maillist.php
                              -~----------~----~----~----~------~----~------~--~---

                            • Jeremy Conlin
                              ... IMHO, I think an app should close when its last window is close. I realize this isn t very Mac like, but this is a soft rule. There are many apps that
                              Message 14 of 16 , Aug 2, 2007
                              • 0 Attachment
                                On 8/2/07, björn <bjorn.winckler@...> wrote:
                                This is kind of funny...just after having written that long rant I sat down and did some work on MacVim only to realise the menus behave very oddly if there are no Vim windows open.  The best short-term solution was to...here it comes...make MacVim quit automatically when the last window closes.  :)

                                So lets see if anybody has any objections as to why MacVim _shouldn't_ quit when the last window closes.  Like Robert says, the good side to this solution is that this is more familiar to Vim users from other platforms;  the bad side is that it is not standard Apple behaviour.  Which one do people think is the lesser evil here?
                                 


                                IMHO, I think an app should close when its last window is close.  I realize this isn't very Mac like, but this is a soft rule.  There are many apps that quit when their last window is closed.  In short, I think its an old tradition that is dying.

                                Jeremy

                                --~--~---------~--~----~------------~-------~--~----~
                                You received this message from the "vim_mac" maillist.
                                For more information, visit http://www.vim.org/maillist.php
                                -~----------~----~----~----~------~----~------~--~---

                              • björn
                                ... Yes, don t get me wrong here...the intentions are to make MacVim follow the HIG as much as is judged sensible (by me and whoever voices an opinion on this
                                Message 15 of 16 , Aug 3, 2007
                                • 0 Attachment
                                  >
                                  > It should do what the HIG says; ie stay open. Disable the menus if there's
                                  > no window. That way, I can hit Cmd-N to open a new vim window, and opening
                                  > files is slightly faster because the app is already loaded (atm, this is not
                                  > really true because each window spawns its own process, but in the long run
                                  > it might be).
                                  >
                                  > Nico

                                  another vote for following the HIG. i was under the impression that
                                  this project was to make a more Mac-like vim. there could always be a
                                  preference to quit the app when closing the last window.

                                  Yes, don't get me wrong here...the intentions are to make MacVim follow the HIG as much as is judged sensible (by me and whoever voices an opinion on this group).  I only violated the "stay-open" rule because I ran into a minor problem, and thought I'd ask for everybody's opinion on this issue.

                                  I will add a user default which controls whether MacVim should quit when the last window closes, and the default will follow the HIG.


                                  /Björn

                                  --~--~---------~--~----~------------~-------~--~----~
                                  You received this message from the "vim_mac" maillist.
                                  For more information, visit http://www.vim.org/maillist.php
                                  -~----------~----~----~----~------~----~------~--~---

                                • Robert Hicks
                                  ... Maybe because I am used to doing :q on every other operating system? Make it play nice sure but lets not change expected behavior. Robert
                                  Message 16 of 16 , Aug 3, 2007
                                  • 0 Attachment
                                    Nico Weber wrote:
                                    >> Yes, don't get me wrong here...the intentions are to make MacVim
                                    >> follow the HIG as much as is judged sensible (by me and whoever
                                    >> voices an opinion on this group). I only violated the "stay-open"
                                    >> rule because I ran into a minor problem, and thought I'd ask for
                                    >> everybody's opinion on this issue.
                                    >
                                    > Don't let your app be dictated by small implementation problems ;-)
                                    >
                                    >> I will add a user default which controls whether MacVim should quit
                                    >> when the last window closes, and the default will follow the HIG.
                                    >
                                    > Why even have an option? Hitting cmd-q is even quicker than :q, all
                                    > people using a mac know cmd-q, only very few people will change this
                                    > preference and it makes the code a tiny bit more complex :-P
                                    >

                                    Maybe because I am used to doing :q on every other operating system?
                                    Make it play nice sure but lets not change expected behavior.

                                    Robert


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