WideStudio Application Builder User's Guide

| WideStudio Application Builder User's Guide | WideStudio Index Table of contents

> ## Select the base class for a new class

> ### Default base class

> By default, the window derivation is done: the class from the top window of the class application window becomes the base class for the new class. The application builder generates the following c++ source codes, where [classwin] is the name of the class application window.
> - "[classwin].h"
>   A public header file for the class. You can add new members to this.
> - "[classwin].cpp"
>   A public source file for the class. You can add new codes to this.
> - "[classwin]P.h"
>   A private header file for the class. DO NOT EDIT THIS FILE.
> - "[classwin]P.cpp"
>   A private source file for the class. DO NOT EDIT THIS FILE.

> [Definition of class application window]
> A sample class application window, called "class1", is shown in the figure below and is derived from the class of the WSCwork window, and becomes the C++ class "class1". The top window is used as the base class by default, but you can select a different base class using the [Attributes] section of the inspector.

> ### How to select a base class for a new class

> For example of the composite derivation, a part of the class application window, the form "cla_form000", is used as a base class here. By default, the top window is used as the base class, but if another instance of the class application window is selected, it becomes the base class.
> (NOTICE) You must re-generate the source code whenever you change the base class. If you have edited the files, save your work into a different file and add it back in after re-generation. To re-generate the sources, delete the following files, where [classwin] is the name of the class application window:
> - "[classwin].h"
> - "[classwin].cpp"

> [Selection of a base class]
> In this case, a new class "class1" is created from the instance "cla_form000" which is selected as the base class. So, the class "class1" inherits WSCform, along with any child instances on the form "cla_form000".

Document Release 3.70 for WideStudio ver 3.70, Feb 2004

WideStudio documents index | Table of contents

Copyright(C) T. Hirabayashi, 2000-2004 | Last modified: Feb 25, 2004