Quantcast

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

classic Classic list List threaded Threaded
7 messages Options
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate
star

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

andy richer-2
On Fri, Jun 15, 2012 at 5:28 PM, Tony Mechelynck <[hidden email]> 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

--
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
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate
star

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

Bee-16


On Jun 26, 2:51 pm, andy richer <[hidden email]> wrote:

> On Fri, Jun 15, 2012 at 5:28 PM, Tony Mechelynck <
>
> [hidden email]> 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

--
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
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate
star

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

Charles Campbell
Bee wrote:

>
> On Jun 26, 2:51 pm, andy richer<[hidden email]>  wrote:
>    
>> On Fri, Jun 15, 2012 at 5:28 PM, Tony Mechelynck<
>>
>> [hidden email]>  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
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate
star

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

Tony Mechelynck
On 27/06/12 16:55, Charles Campbell wrote:

> Bee wrote:
>>
>> On Jun 26, 2:51 pm, andy richer<[hidden email]>  wrote:
>>> On Fri, Jun 15, 2012 at 5:28 PM, Tony Mechelynck<
>>>
>>> [hidden email]>  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
>
In this case, the only uses of %F in the help are in an example under
'titlestring' and in a TODO item.

Bee's reply, and the line where I said earlier that 'titlestring' is a
'statusline'-like option, should have pointed Andy the help for
'statusline', where it is explained first that there can be printf-style
% items in the value of that option, and lower down (about one page down
with my 'guifont' in a maximized gvim) there is a list of possible
items. For %F, the relevant line is:

        F S   Full path to the file in the buffer.

and its meaning is explained in the help text that comes above it.


Best regards,
Tony.
--
My brother-in-law has found a way to make ends meet.  He goes around
with his head stuck up his ass.

--
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
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate
star

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

Charles Campbell
Tony Mechelynck wrote:

> On 27/06/12 16:55, Charles Campbell wrote:
>> Bee wrote:
>>>
>>> On Jun 26, 2:51 pm, andy richer<[hidden email]>  wrote:
>>>> On Fri, Jun 15, 2012 at 5:28 PM, Tony Mechelynck<
>>>>
>>>> [hidden email]>  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
>>
> In this case, the only uses of %F in the help are in an example under
> 'titlestring' and in a TODO item.
>
> Bee's reply, and the line where I said earlier that 'titlestring' is a
> 'statusline'-like option, should have pointed Andy the help for
> 'statusline', where it is explained first that there can be
> printf-style % items in the value of that option, and lower down
> (about one page down with my 'guifont' in a maximized gvim) there is a
> list of possible items. For %F, the relevant line is:
>
>     F S   Full path to the file in the buffer.
>
> and its meaning is explained in the help text that comes above it.
Tony -- have you heard the phrase, "Give a man a fish and you feed him
for a day. Teach a man to fish and you feed him for a lifetime"?

I was attempting to "teach the man to fish".

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
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate
star

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

Tony Mechelynck
On 28/06/12 15:37, Charles Campbell wrote:

> Tony Mechelynck wrote:
>> On 27/06/12 16:55, Charles Campbell wrote:
>>> Bee wrote:
>>>>
>>>> On Jun 26, 2:51 pm, andy richer<[hidden email]>  wrote:
>>>>> On Fri, Jun 15, 2012 at 5:28 PM, Tony Mechelynck<
>>>>>
>>>>> [hidden email]>  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
>>>
>> In this case, the only uses of %F in the help are in an example under
>> 'titlestring' and in a TODO item.
>>
>> Bee's reply, and the line where I said earlier that 'titlestring' is a
>> 'statusline'-like option, should have pointed Andy the help for
>> 'statusline', where it is explained first that there can be
>> printf-style % items in the value of that option, and lower down
>> (about one page down with my 'guifont' in a maximized gvim) there is a
>> list of possible items. For %F, the relevant line is:
>>
>>     F S   Full path to the file in the buffer.
>>
>> and its meaning is explained in the help text that comes above it.
> Tony -- have you heard the phrase, "Give a man a fish and you feed him
> for a day. Teach a man to fish and you feed him for a lifetime"?
>
> I was attempting to "teach the man to fish".
>
> Regards,
> Chip Campbell
>

Aha. And what do you do when no fish bites on the kind of fishline you
taught him to use?


Best regards,
Tony.
--
Good day to let down old friends who need help.

--
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
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate
star

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

Tony Mechelynck
On 30/06/12 15:39, Tony Mechelynck wrote:

> On 28/06/12 15:37, Charles Campbell wrote:
>> Tony Mechelynck wrote:
>>> On 27/06/12 16:55, Charles Campbell wrote:
>>>> Bee wrote:
>>>>>
>>>>> On Jun 26, 2:51 pm, andy richer<[hidden email]>  wrote:
>>>>>> On Fri, Jun 15, 2012 at 5:28 PM, Tony Mechelynck<
>>>>>>
>>>>>> [hidden email]>  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
>>>>
>>> In this case, the only uses of %F in the help are in an example under
>>> 'titlestring' and in a TODO item.
>>>
>>> Bee's reply, and the line where I said earlier that 'titlestring' is a
>>> 'statusline'-like option, should have pointed Andy the help for
>>> 'statusline', where it is explained first that there can be
>>> printf-style % items in the value of that option, and lower down
>>> (about one page down with my 'guifont' in a maximized gvim) there is a
>>> list of possible items. For %F, the relevant line is:
>>>
>>>     F S   Full path to the file in the buffer.
>>>
>>> and its meaning is explained in the help text that comes above it.
>> Tony -- have you heard the phrase, "Give a man a fish and you feed him
>> for a day. Teach a man to fish and you feed him for a lifetime"?
>>
>> I was attempting to "teach the man to fish".
>>
>> Regards,
>> Chip Campbell
>>
>
> Aha. And what do you do when no fish bites on the kind of fishline you
> taught him to use?
>
>
> Best regards,
> Tony.

P.S. I was also trying to "teach him to fish", namely, by paying
attention to what he's been told. Let's hope he will, in the future.


Best regards,
Tony.
--
"You can't survive by sucking the juice from a wet mitten."
                -- Charles Schulz, "Things I've Had to Learn Over and
                   Over and Over"

--
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
Loading...