Hi.
About a month ago, I started to factor out a framework part from MacVim:
I now can build a MacVim app which consists of two parts: a Vim framework (with vim+runtime and supporting classes like MMVimView) and an app which uses that framework. There are two new targets:
- MacVimFramework: This is the framework.
- MacVimWithFramework: This is a copy of the MacVim target which uses the above framework.
The binary can be found here:
It's compiled on 10.8 and I hope that it works on other machines, too. (It works on my machine, ;-)
There are yet many rough edges though, for example:
- You cannot call the framework a real framework yet: it's just a collection of classes that can be compiled in a separate framework target.
- Sometimes I just blindly refactored, not really having carefully read the whole code or having thought about whether it's a sensible separation of code. Well, just get it done first and then refactor again, I'd say...
- The framework uses PSMTabBarControl, ie it expects the client-app to include it.
- Things can be in a broken state, eg all new windows have a fixed hard-coded size...
However, I think/hope that it can serve as a base for a real MacVim-framework. I'll try to consolidate the code base further and start to think about how to make it a real and easy to use framework.
Best,
Tae
PS. I'm sorry that I ignored the usual formatting of the code.
PPS. I started to migrate the code to ARC; well, at least for two small files.