From 2c08e9a0890f3ea1918a880c997a3949a9b82a11 Mon Sep 17 00:00:00 2001 From: Doug Coleman Date: Sat, 27 Jun 2015 19:18:22 -0700 Subject: [PATCH] vim: Add tabbed window option. --- basis/editors/macvim/macvim.factor | 4 ++-- basis/editors/vim/vim.factor | 7 +++++-- 2 files changed, 7 insertions(+), 4 deletions(-) diff --git a/basis/editors/macvim/macvim.factor b/basis/editors/macvim/macvim.factor index 6278833076..ba3726b6aa 100644 --- a/basis/editors/macvim/macvim.factor +++ b/basis/editors/macvim/macvim.factor @@ -1,5 +1,5 @@ -USING: core-foundation.launch-services editors editors.vim -io.pathnames io.standard-paths kernel namespaces ; +USING: editors editors.vim io.pathnames io.standard-paths kernel +namespaces ; IN: editors.macvim TUPLE: macvim < vim ; diff --git a/basis/editors/vim/vim.factor b/basis/editors/vim/vim.factor index 7aa46499d7..3040980baf 100644 --- a/basis/editors/vim/vim.factor +++ b/basis/editors/vim/vim.factor @@ -11,6 +11,8 @@ HOOK: find-vim-path editor-class ( -- path ) HOOK: vim-ui? editor-class ( -- ? ) +SYMBOL: vim-tabs? + M: vim vim-ui? f ; M: vim find-vim-path "vim" ?find-in-path ; @@ -22,8 +24,9 @@ M: vim editor-command ( file line -- command ) [ actual-vim-path dup string? [ , ] [ % ] if vim-ui? [ "-g" , ] when - [ , ] [ number>string "+" prepend , ] bi* + vim-tabs? get [ "--remote-tab-silent" , ] when + number>string "+" prepend , + , ] { } make ; M: vim editor-detached? f ; -