Wednesday, June 27, 2012

Re: where are those %F, %y, %f......

Bee wrote:
>
> On Jun 26, 2:51 pm, andy richer<andy.ric...@gmail.com> wrote:
>
>> On Fri, Jun 15, 2012 at 5:28 PM, Tony Mechelynck<
>>
>> antoine.mechely...@gmail.com> wrote:
>>
>>
>>> 'titlestring' is a 'statusline'-like option. If you want a specific
>>> (nondefaut) title, you set it. For instance, having
>>>
>>
>>> if has('title')
>>> set title titlestring=%F%y%m%r
>>> endif
>>>
>>
>>> Best regards,
>>> Tony.
>>> --
>>>
>>
>>> I tried to use :help %F, %y,... to find the definition above with no luck.
>>>
>> And by experiment I see %F shows ~/c/d/e.v, %f shows ./c/d/e.v if I
>> opened e.v inside a utility called SOS.
>> 1.
>> Would anyone please advise me where can I find all those %x definition in
>> gvim?
>> 2.
>> I modified above example to: set title titlestring=%{$PWD}/%f and it
>> works in titlebar.
>> The thing is that it shows "/a/b/c/d/e.v" where e.v is the file name.
>> How can I show "e.v /a/b/c/d" in titlebar?
>>
>> Best Regards,
>> Andy
>>
> :help titlestring
> When this option contains printf-style '%' items,
> they will be expanded according to the rules used for 'statusline'.
>
> :help statusline
>
>
Additionally, when one is perplexed about finding help for something in
Vim's help pages, use helpgrep. Applied to your question:

:helpgrep %F
:cope

would've pointed you in the right direction.

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

No comments: