wxPython的整体架构

首先从全局上把握,从整体上看wxPython的构架,然后再去学习wxPython的组成元素。

wxPython有五部分组成:

1、Windows:

The Windows module consists of various windows, that form an application. Panel, Dialog, Frame or Scrolled Window.

windows组件包含了各种窗口,Panel,Dialog,Frame,ScrolledWindow

 

2、Controls:--控制器
Controls module provides the common widgets found in graphical applications. For example a Button, a Toolbar, or a Notebook. Widgets are called controls under Windows OS

Controls组件主要包括像按钮这样的控制构件

 

3、Core
The Core module consists of elementary classes, that are used in development. These classes include the Object class, which is the mother of all classes, Sizers, which are used for widget layout, Events, basic geometry classses like Point and Rectangle

Core主要包括了对GUI的布局、事件以及GUI的坐标位置的确定,还有形状的控制等等

 

4、GDI
The Graphics Device Interface (GDI) is a set of classes used for drawing onto the widgets. This module contains classes for manipulation of Fonts, Colours, Brushes, Pens or Images.

这部分主要用于画图

 

5、Misc
The Misc module contains of various other classes and module functions. These classes are used for logging, application configuration, system settings, working with display or joystick

本部分主要用于日志,应用的配置信息以及系统的设定等工作。

 

从上面的描述可以总结出,Windows,Controls是专注于GUI的展示的,也就是专注于图形界面的组件创建;当有了组件,那么利用Core当中的布局等功能可以将界面美化,美化的同时给组件添加事件。GDI是专注于绘图的,而Misc则专注于系统的外围的配置信息。总之就目前来讲,我的理解是抛出GDI,利用Windows,Controls,Core,Misc可以做出除了绘图意外的其他GUI系统

你可能感兴趣的:(工作,windows,OS,wxPython)