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

8977Re: some new fuoptions?

Expand Messages
  • björn
    Aug 31, 2008
    • 0 Attachment
      2008/8/31 Pavel <pavel.stranak@...>:
      > you are right, it is all there, but I have no idea, how to switch it
      > all on/off with switching to/from fullscreen mode. That is why I asked
      > for the fuoptions. But maybe there is another way.

      I was afraid you'd ask for that since I'm not sure myself how best to
      accomplish this. Anyway, I came up with one way that seems to work
      ok. Add the lines below to your ~/.gvimrc and you'll be able to still
      use Cmd-Shift-F or the Window menu to toggle full-screen.


      p.s. I don't know of any way to have "non-GUI scrollbars" so I hide
      them instead.

      " Function to call when toggling full-screen
      fu! ToggleFu()
      if &fu
      " In full-screen
      set go+=e " show gui tabs
      set go+=r " show right-hand scrollbar
      set lines=33 columns=80 " set lines&columns to normal values
      set nofu " leave full-screen
      " In windowed mode
      set go-=e " hide gui tabs
      set go-=r " hide right-hand scrollbar
      set lines=50 columns=120 " set lines&columns to something big
      set fu " enter full-screen

      " Clear 'fuopt' so that it doesn't change 'lines' and 'columns'
      set fuopt=

      " Make the 'Toggle Full Screen Mode' menu item call ToggleFu()
      aunmenu Window.Toggle\ Full\ Screen\ Mode
      an <silent> 9900.320 Window.Toggle\ Full\ Screen\ Mode :cal ToggleFu()<CR>

      " Rebind the 'Toggle Full Screen Mode' menu item to Cmd-Shift-F
      macm Window.Toggle\ Full\ Screen\ Mode key=<D-F>

      You received this message from the "vim_mac" maillist.
      For more information, visit http://www.vim.org/maillist.php
    • Show all 6 messages in this topic