Thanks it returns cCommentL when I am into a comment and returns nothing when I am into code lines. Very Powerful
Thanks :) On 24 nov, 01:51, pansz <[email protected]> wrote: > epanda 写道: > > > Hi, > > I would like to know if a found line of my search is in a comment > > block . > > /* > > > Func() > > > */ > > :echo synIDattr(synID(line("."), col("."), 1), "name") > > this gives you the highlight group of the current line/column, you can > see it is comment. --~--~---------~--~----~------------~-------~--~----~ You received this message from the "vim_use" maillist. For more information, visit http://www.vim.org/maillist.php -~----------~----~----~----~------~----~------~--~---
