You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Trying to use a vim function (located inside my .xvimrc)
Function Constr(cs)
if a:cs == "cx"
return "centerXAnchor"
"etc. etc.
endif
endfunction
Operation
So I hate typing up constraints. It kills me every single day.
So lets say I have two characters that represent "centerXAnchor" with "cx"
in EX mode, I do this ":s/ .\+ /=Constr(submatch(0))/g"
Note: Constr(cs) is a vimscript function (inside .xvimrc) that takes two character strings, goes through if-else statements to return the appropriate NSLayoutConstraint variable. So "ta" return "topAnchor"
Expected behaviour
Nothing happens when I run this. Ex command goes blank, and the text isn't changed.
Environments
Xcode Version [ 8.3.2 ]
XVim branch and revision [ developer i think? ]
Keyboard Language [ QWERTY ]
Input source language [ what... ]
Is it possible to add this functionality?
The text was updated successfully, but these errors were encountered:
Description
Trying to use a vim function (located inside my .xvimrc)
Function Constr(cs)
if a:cs == "cx"
return "centerXAnchor"
"etc. etc.
endif
endfunction
Operation
So I hate typing up constraints. It kills me every single day.
Note: Constr(cs) is a vimscript function (inside .xvimrc) that takes two character strings, goes through if-else statements to return the appropriate NSLayoutConstraint variable. So "ta" return "topAnchor"
Expected behaviour
Nothing happens when I run this. Ex command goes blank, and the text isn't changed.
Environments
Is it possible to add this functionality?
The text was updated successfully, but these errors were encountered: