How usable is Qt without its preprocessing step?

后端 未结 12 913
自闭症患者
自闭症患者 2021-02-02 05:21

I think it\'s unreasonable for a library to require preprocessing of my source code with a special tool. That said, several people have recommended the Qt library to me for cros

12条回答
  •  [愿得一人]
    2021-02-02 06:04

    Qt doesn't require the use of moc just to use it, it requires that usage if you create a subclass of QObject, and to declare signals and slots in your custom classes.

    It's not unreasonable, moc provides features that C++ doesn't have, signals/slots, introspection, etc.

    So, to do something minimally advanced, you WILL have to use the moc preprocessor. You either love it, or hate it.

提交回复
热议问题