layoutManager : Create layouts from tabs, templates and windows and control them.
| script karma
Downloaded by 859
Comments, bugs, improvements
script versions (upload new version)
|See latest version on github: https://github.com/viaa/VimPlugins
" LayoutManager plugin
" Version 1.0.2
" LayoutManager.vim allows to create layouts composed named of tabs and windows and do operations on these tabs and windows. The main idea is that tabs and windows are given names, for example, a window named "menu" could contain a menu file, another window called "code" could contain the code file, another one named "output" could contain the compiler's output text etc. The goal was to have a multiple windows environment similar to an IDE environment like visual studio for examples with windows and tabs with names that do different things, and were content may be "sent" to specific windows using commands, links (utl), mappings and especially from other script files and project files etc.
" In the zip file, I put in the example of a project file (.vim) I am currently doing that will be using the layoutManager.vim plugin. It is not finished but you are free to look at it to see how to use the plugin.
" I tried to use an object programming style in vimscript because I thought it was suitable for this type of application.
" Here is an example of utilisation of layoutManager.vim:
" " Create a new layout
" let myLayout1 = g:lmLayout.New('MyLayout1')
" " Add tabs to the layout
" call myLayout1.Tabs.Add(g:lmTab.New('MyTab1', 'MyTemplate1'))
" call myLayout1.Tabs.Add(g:lmTab.New('MyTab2', 'MyTemplate2'))
" " Send commands to some of the windows of MyTab1
" call myLayout1.Tabs.MyTab1.Windows.code.Execute('e ' . $VIM . '/vimrc') " Show the vimrc file in the code window
" call myLayout1.Tabs.MyTab1.Windows.output.Write("this is the output window 1!", 3) " Write text in the output window
" call myLayout1.Tabs.MyTab1.Windows.files.ExecuteShell('dir c:') " List a directory in the files window
" call myLayout1.Tabs.MyTab1.Windows.code.SetFocus()
" " Send commands to some of the windows of MyTab2
" call myLayout1.Tabs.MyTab2.Windows.menu.Write("this is the menu!", 3) " Write text in the menu window
" call myLayout1.Tabs.MyTab2.Windows.code2.Execute('e ' . $VIM . '/vimrc') " Show the vimrc file in the code2 window
" let myLayout2 = s:layout.New('MyLayout2')
" " Set focus to MyTab1
" call myLayout1.Tabs.MyTab1.SetFocus()
" Note that I didn't finish the examples or the documentation, but the plugin is working fine with these initial features. Feel free to propose any features or to send comments.
" See sample project file included in the zip file
" Remove tabs and windows from the containers, at the same time from the editor
" Ajouter une fonction pour aller directement a une fenetre style gt 1 gt 5 pour les tabs mais pour une fenetre
|Copy the file layoutManager.vim to your vim plugin directory.|
Click on the package to download.
ip used for rating: 22.214.171.124