Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
QWidget、QGraphicsView、QGraphicsItem などを実装するクラスを作成するとき...私は常に QtWidget、QGraphicsView などの代わりに QtGui を含めます...これは悪い習慣ですか? パフォーマンスコストはありますか?このため、ビルド時間が長くなりますか?
QtGuiヘッダーに他のすべてのヘッダーが含まれている場合、コンパイラーのプリプロセッサーがより多くのファイルを読み取る必要があり、コンパイラー自体が解析および追跡するクラス/構造体が増えるため、コンパイル時間が長くなります。ただし、リンク時間、さらに重要なことにランタイム は影響を受けません。
QtGui