L A Walsh wrote:
> This is likely only pertinent to a GUI version of vim,
> like gvim running over X.
>
>
> More than once I've wanted to be able to tear off a tab
> and have gvim open the tab in a new window and
> have the new window function like a "tab"
> (or a "split") -- except the other "view" (in case of
> a split), be in a physically separate window.
>
> Just the other day, I had two files open in tabs
> (.cc and .h: a C++ source & header). Instead of
> window switching, I wanted to change my visual
> layout for 1 pair of files to see them side-by-side
> (and when I was done, close the 2nd display leaving
> the 2nd file as a 2nd tab in the 1st window.
>
> If I could tear off & merge tabs it would easily allow
> such operations.
>
> Is that something that might be doable?
>
>
See if http://www.drchip.org/astronaut/vim/index.html#DETACH 's
detach.vim will do what you want.
Regards,
Chip Campbell
--
--
You received this message from the "vim_use" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php
---
You received this message because you are subscribed to the Google Groups "vim_use" group.
To unsubscribe from this group and stop receiving emails from it, send an email to vim_use+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Wednesday, March 29, 2017
Re: cpp and golang code fold problem
YZ Xie wrote:
> Hi everyone,
>
> my .vimrc was
> set foldmethod=syntax
> filetype plugin indent on " Automatically detect file types.
> syntax enable
> syntax on
>
> but it cannot fold code if file was named like *.cpp, but it can work
> well if file was name *.c or *.cc. golang code failed too.
>
> my vim was installed by source code from github,runtime director
> is /usr/share/vim/vim80.
>
> I have export VIMRUNTIMEDIR= /usr/share/vim/vim80 in /etc/profile and
> source it.
>
> vim version was 8.0.439.
>
Hello:
I just opened a *.cpp file with fdm=syntax, and it folded just fine
using your .vimrc (plus using set nocp). Got any example source you
care to share that won't fold?
Also,syntax-enabled folding is something that the syntax highlighting
maintainers specify in ther syntax highlighting files. I suggest you
make some examples that won't fold and send them along with an
explanation to the syntax files' maintainers.
Regards,
Chip Campbell
--
--
You received this message from the "vim_use" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php
---
You received this message because you are subscribed to the Google Groups "vim_use" group.
To unsubscribe from this group and stop receiving emails from it, send an email to vim_use+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
> Hi everyone,
>
> my .vimrc was
> set foldmethod=syntax
> filetype plugin indent on " Automatically detect file types.
> syntax enable
> syntax on
>
> but it cannot fold code if file was named like *.cpp, but it can work
> well if file was name *.c or *.cc. golang code failed too.
>
> my vim was installed by source code from github,runtime director
> is /usr/share/vim/vim80.
>
> I have export VIMRUNTIMEDIR= /usr/share/vim/vim80 in /etc/profile and
> source it.
>
> vim version was 8.0.439.
>
Hello:
I just opened a *.cpp file with fdm=syntax, and it folded just fine
using your .vimrc (plus using set nocp). Got any example source you
care to share that won't fold?
Also,syntax-enabled folding is something that the syntax highlighting
maintainers specify in ther syntax highlighting files. I suggest you
make some examples that won't fold and send them along with an
explanation to the syntax files' maintainers.
Regards,
Chip Campbell
--
--
You received this message from the "vim_use" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php
---
You received this message because you are subscribed to the Google Groups "vim_use" group.
To unsubscribe from this group and stop receiving emails from it, send an email to vim_use+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Re: RFE: enable gvim to open a buffer or tab in a new window
On Tuesday, 28 March, 2017 at 13:08:03 BST, L A Walsh wrote:
>Just the other day, I had two files open in tabs (.cc and .h: a C++ source &
>header). Instead of window switching, I wanted to change my visual layout for
>1 pair of files to see them side-by-side (and when I was done, close the 2nd
>display leaving the 2nd file as a 2nd tab in the 1st window.
Why not just :vsplit the other file into the current tab, and :quit it when done?
--
--
You received this message from the "vim_use" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php
---
You received this message because you are subscribed to the Google Groups "vim_use" group.
To unsubscribe from this group and stop receiving emails from it, send an email to vim_use+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
>Just the other day, I had two files open in tabs (.cc and .h: a C++ source &
>header). Instead of window switching, I wanted to change my visual layout for
>1 pair of files to see them side-by-side (and when I was done, close the 2nd
>display leaving the 2nd file as a 2nd tab in the 1st window.
Why not just :vsplit the other file into the current tab, and :quit it when done?
--
--
You received this message from the "vim_use" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php
---
You received this message because you are subscribed to the Google Groups "vim_use" group.
To unsubscribe from this group and stop receiving emails from it, send an email to vim_use+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Re: Security Risk: (was vim 'less.sh' script probs w/folds)
Christian Brabandt wrote:
> Hi L.!
>
> On Di, 28 Mär 2017, L. A. Walsh wrote:
>
>
>> Here is the problem -- I am not using "less.vim"...
>>
>> I type in (at the command prompt):
>> less.sh <filename>
>>
>
> Here is the problem: Why do you type less.sh and not less or more or
> most. And why is this in your path?
>
----
I wanted syntax highlighting in less, so
I copied 'less.sh' into ~/bin/vless for testing. If it
was a suitable (compatible) pager, I might want it to
replace less as a default when I'm doing SW development.
At the very least, if it was 'less'-feature
compatible, highlighting could be invoked as a special
call out from 'less'.
Note: my first attempt to get this functionality was
to use the convert-to-HTML feature, and setup 'less'
to display the syntax-colorized version of the file
via 'lynx'. unfortunately 'lynx' doesn't implement
text coloring, and the alternate, 'w3m' gave even
worse looking output.
So..why did I use less.sh? Because I followed the
vim instructions to get 'vim' to be usable like "less" or
"more". Neither of those utils hide blocks of text based on
settings in the file. If I want smarter text display,
I'd bring up the file in a text editor, like vim! ;-)
Text files are supposed to be "dumb". From there, you
can add on specific features. In this case, highlighting
was supposed to be added to a 'less/more' like interface.
That excludes automatic visual formatting of the
text to look different than it does in the file.
In the same way, I wouldn't expect vim to automatically
justify text on output when trying to be a simple
replacement for 'less/more' pagers, but w/syntax.
I.e. the defaults should be the simple case as displayed in
'less/more'. Having options to add in hidden text or
word-break line-folding are fine options -- just not
for the default case where it's suppose to be like
a dumb-text pager (except for HLing feature).
"If you use the less or more program to view a file, you
don't get syntax highlighting. Thus you would like to
use Vim instead. You can do this by using the shell script
"$VIMRUNTIME/macros/less.sh".
So if I use less, and don't see syntax highlighting but
want to, then I'd expect vim to do that (only because it is
documented to do so in the help).
>
>> In regards to the 2nd sentence... it is also, not
>> quite accurate: when I saw the folds, the
>> first thing I tried was 'zR' (which didn't work).
>>
>
> You can still use :set nofoldenable
>
---
It's not about all the different things that might
work -- it's about the default inability to display the
file as it is on disk (without folds or text processing
markup).
Do you use 'less' or try to display syntax HLing using
'less.sh'?
What's the use case or reason for insisting that
the script shouldn't function like 'more' or 'less' by
default (as the documentation seems to indicate)?
*curious*,
Linda
--
--
You received this message from the "vim_use" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php
---
You received this message because you are subscribed to the Google Groups "vim_use" group.
To unsubscribe from this group and stop receiving emails from it, send an email to vim_use+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
> Hi L.!
>
> On Di, 28 Mär 2017, L. A. Walsh wrote:
>
>
>> Here is the problem -- I am not using "less.vim"...
>>
>> I type in (at the command prompt):
>> less.sh <filename>
>>
>
> Here is the problem: Why do you type less.sh and not less or more or
> most. And why is this in your path?
>
----
I wanted syntax highlighting in less, so
I copied 'less.sh' into ~/bin/vless for testing. If it
was a suitable (compatible) pager, I might want it to
replace less as a default when I'm doing SW development.
At the very least, if it was 'less'-feature
compatible, highlighting could be invoked as a special
call out from 'less'.
Note: my first attempt to get this functionality was
to use the convert-to-HTML feature, and setup 'less'
to display the syntax-colorized version of the file
via 'lynx'. unfortunately 'lynx' doesn't implement
text coloring, and the alternate, 'w3m' gave even
worse looking output.
So..why did I use less.sh? Because I followed the
vim instructions to get 'vim' to be usable like "less" or
"more". Neither of those utils hide blocks of text based on
settings in the file. If I want smarter text display,
I'd bring up the file in a text editor, like vim! ;-)
Text files are supposed to be "dumb". From there, you
can add on specific features. In this case, highlighting
was supposed to be added to a 'less/more' like interface.
That excludes automatic visual formatting of the
text to look different than it does in the file.
In the same way, I wouldn't expect vim to automatically
justify text on output when trying to be a simple
replacement for 'less/more' pagers, but w/syntax.
I.e. the defaults should be the simple case as displayed in
'less/more'. Having options to add in hidden text or
word-break line-folding are fine options -- just not
for the default case where it's suppose to be like
a dumb-text pager (except for HLing feature).
"If you use the less or more program to view a file, you
don't get syntax highlighting. Thus you would like to
use Vim instead. You can do this by using the shell script
"$VIMRUNTIME/macros/less.sh".
So if I use less, and don't see syntax highlighting but
want to, then I'd expect vim to do that (only because it is
documented to do so in the help).
>
>> In regards to the 2nd sentence... it is also, not
>> quite accurate: when I saw the folds, the
>> first thing I tried was 'zR' (which didn't work).
>>
>
> You can still use :set nofoldenable
>
---
It's not about all the different things that might
work -- it's about the default inability to display the
file as it is on disk (without folds or text processing
markup).
Do you use 'less' or try to display syntax HLing using
'less.sh'?
What's the use case or reason for insisting that
the script shouldn't function like 'more' or 'less' by
default (as the documentation seems to indicate)?
*curious*,
Linda
--
--
You received this message from the "vim_use" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php
---
You received this message because you are subscribed to the Google Groups "vim_use" group.
To unsubscribe from this group and stop receiving emails from it, send an email to vim_use+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Tuesday, March 28, 2017
vim cannot fold cpp and golang code
vim cannot fold test.cpp, vim prompts E490 no fold found, but rename this file to test.c or test.cc, vim can use zc to fold this same code.
I have set configure in .vimrc foldmethod=syntax set foldlevel=0 set foldnestmax=2 VIMRUNTIME=/usr/share/vim/vim80
in /usr/share/vim/vim80/ftplugin, there exits a cpp.vim file.
why vim cannot fold *.cpp and *.go, any problem?
--
You received this message from the "vim_use" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php
---
You received this message because you are subscribed to the Google Groups "vim_use" group.
To unsubscribe from this group and stop receiving emails from it, send an email to vim_use+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Re: cpp and golang code fold problem
在 2017年3月29日星期三 UTC+8下午1:16:40,YZ Xie写道:
> Hi everyone,
>
>
> my .vimrc was
> set foldmethod=syntax
> filetype plugin indent on " Automatically detect file types.
> syntax enable
> syntax on
>
> but it cannot fold code if file was named like *.cpp, but it can work well if file was name *.c or *.cc. golang code failed too.
>
>
> my vim was installed by source code from github,runtime director is /usr/share/vim/vim80.
>
>
> I have export VIMRUNTIMEDIR= /usr/share/vim/vim80 in /etc/profile and source it.
>
>
> vim version was 8.0.439.
>
>
> how can I fix this problem?
> thanks
when zc it show E490 no fold found, but rename source file from *.cpp to *.c or *.cc, it works well
--
--
You received this message from the "vim_use" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php
---
You received this message because you are subscribed to the Google Groups "vim_use" group.
To unsubscribe from this group and stop receiving emails from it, send an email to vim_use+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
> Hi everyone,
>
>
> my .vimrc was
> set foldmethod=syntax
> filetype plugin indent on " Automatically detect file types.
> syntax enable
> syntax on
>
> but it cannot fold code if file was named like *.cpp, but it can work well if file was name *.c or *.cc. golang code failed too.
>
>
> my vim was installed by source code from github,runtime director is /usr/share/vim/vim80.
>
>
> I have export VIMRUNTIMEDIR= /usr/share/vim/vim80 in /etc/profile and source it.
>
>
> vim version was 8.0.439.
>
>
> how can I fix this problem?
> thanks
when zc it show E490 no fold found, but rename source file from *.cpp to *.c or *.cc, it works well
--
--
You received this message from the "vim_use" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php
---
You received this message because you are subscribed to the Google Groups "vim_use" group.
To unsubscribe from this group and stop receiving emails from it, send an email to vim_use+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Re: Security Risk: (was vim 'less.sh' script probs w/folds)
Hi L.!
On Di, 28 Mär 2017, L. A. Walsh wrote:
> Here is the problem -- I am not using "less.vim"...
>
> I type in (at the command prompt):
> less.sh <filename>
Here is the problem: Why do you type less.sh and not less or more or
most. And why is this in your path?
> In regards to the 2nd sentence... it is also, not
> quite accurate: when I saw the folds, the
> first thing I tried was 'zR' (which didn't work).
You can still use :set nofoldenable
Best,
Christian
--
Probstei:
Körperteil eines Geistlichen, das wegen des Zölibats Pfarrerflucht
auslösen kann
--
--
You received this message from the "vim_use" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php
---
You received this message because you are subscribed to the Google Groups "vim_use" group.
To unsubscribe from this group and stop receiving emails from it, send an email to vim_use+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
On Di, 28 Mär 2017, L. A. Walsh wrote:
> Here is the problem -- I am not using "less.vim"...
>
> I type in (at the command prompt):
> less.sh <filename>
Here is the problem: Why do you type less.sh and not less or more or
most. And why is this in your path?
> In regards to the 2nd sentence... it is also, not
> quite accurate: when I saw the folds, the
> first thing I tried was 'zR' (which didn't work).
You can still use :set nofoldenable
Best,
Christian
--
Probstei:
Körperteil eines Geistlichen, das wegen des Zölibats Pfarrerflucht
auslösen kann
--
--
You received this message from the "vim_use" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php
---
You received this message because you are subscribed to the Google Groups "vim_use" group.
To unsubscribe from this group and stop receiving emails from it, send an email to vim_use+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Subscribe to:
Posts (Atom)