maurges / vim-cpp-helper

A vim plugin to ease writing c++ code
GNU General Public License v2.0
5 stars 0 forks source link

Generate setter/getter #13

Open Shatur opened 4 years ago

Shatur commented 4 years ago

Could you add the ability to generate setter/getter? This is very often needed. For example, in QtCreator for the variable bool m_value will be generated bool value() / void setValue(bool value). But if variable is named without any prefix (just bool value, for example), the getter will become bool getValue().

maurges commented 4 years ago

I already have some similar functionality in :PropertyFill specifically for Q_PROPERTY here, so it shouldn't be hard to create a new filler. But to be honest, recently I've gone away from C++, so I'm not in the mood to work on this. So it will take me some time to get to it. And hey, isn't being homestuck a great possibility to find time to learn vimscript? (=

Shatur commented 4 years ago

Not a problem. Thank you for the tip, I will take a look :)