### IFrameExtension

  IFrameWindow maintains objects of the IFrameExtension class to record information about each of its frame-extension windows. You add a frame extension to a frame window by calling IFrameWindow::addExtension. You do not need to create an IFrameExtension object yourself.

  IFrameWindow::extensions and IFrameWindow::setExtensions deal with collections of such frame extensions. Each collection is actually an object of the IFrameExtensions class, which is a list of the extensions currently added to the IFrameWindow object.

  Frame extensions have the following attributes:

  type
    Specifies the extension be one of three types having the following characteristics:
    - A fixed width or height.
    - A width or height that is a fraction of the frame control it occupies. See the location attribute.
    - A width or height determined by the minimum size of the extension window.
  size
    Specifies that the size is any of the following:
    - A specific width or height, for fixed-size extensions
    - A fraction, for relative-sized extensions
    - The minimum size of the associated control.
  location
    Specifies the portion of the frame the extension occupies. The enumeration IFrameWindow::Location provides the possible values.
  control
    Specifies a pointer to the control window that occupies the extension.

### IFrameExtension - Member Functions and Data by Group

### Constructors & Destructor

Use these functions to construct objects of the IFrameExtension class. You cannot copy or assign IFrameExtension objects because both the copy constructor and assignment operator are private functions. You can construct objects of this class by providing the same set of parameters as for IFrameWindow::addExtension.

~IFrameExtension

      public:
      ~IFrameExtension()

  Destructor for the class.

Supported Platforms

  Windows | OS/2 | AIX
  Yes | Yes | Yes

IFrameExtension

  Overload 1

      public:
      IFrameExtension( IWindow* window,
                       IFrameWindow::Location location,
                       double percentage,
                       IFrameWindow::SeparatorType separator )

  Create relative-type extensions using this constructor.

  You can construct objects of this class by providing the following set of parameters:

  window
    The frame extension window.
  location
    The relative location (left, right, top, or bottom) and frame window area (title bar area, menu bar area, client area) to be occupied by the frame extension. Use the enumeration IFrameWindow::Location to specify the location for the frame extension.
  percentage
    The portion of the frame window area allocated to the frame extension, in a floating point percentage (0 < x < 1.0).
  separator
    The separator type. Use the enumeration IFrameWindow::SeparatorType to specify the type of separator delimiting the frame extension.

Supported Platforms

  Windows | OS/2 | AIX
  Yes | Yes | Yes

  Overload 2

      public:
      IFrameExtension( IWindow* window,
                       IFrameWindow::Location location,
                       IFrameWindow::SeparatorType separator )

  Use this constructor to create frame extensions that are sized to the minimum size of the associated window.

  You can construct objects of this class by providing the same set of parameters as for IFrameWindow::addExtension.

  window
    The frame extension window.
  location
    The relative location (left, right, top, or bottom) and frame window area (title bar area, menu bar area, client area) to be occupied by the frame extension. Use the enumeration IFrameWindow::Location to specify the location for the frame extension.
  separator
    The separator type. Use the enumeration IFrameWindow::SeparatorType to specify the type of separator delimiting the frame extension.

Supported Platforms

  Windows | OS/2 | AIX
  Yes | Yes | Yes

  Overload 3

      public:
      IFrameExtension( IWindow* window,
                       IFrameWindow::Location location,
                       unsigned long widthOrHeight,
                       IFrameWindow::SeparatorType separator )

  Use this constructor for a fixed-type extension.

  You construct objects of this class by providing the following set of parameters.

  window
    The frame extension window.
  location
    The relative location (left, right, top, or bottom) and frame window area (title bar area, menu bar area, client area) to be occupied by the frame extension. Use the enumeration IFrameWindow::Location to specify the location for the frame extension.
  widthOrHeight
    The portion of the frame window area allocated to the frame extension, in a fixed width or height.
  separator
    The separator type. Use the enumeration IFrameWindow::SeparatorType to specify the type of separator delimiting the frame extension.

Supported Platforms

  Windows | OS/2 | AIX
  Yes | Yes | Yes

### Extension Location

When adding a frame extension, you specify where the frame extension is attached. See IFrameWindow::Location for details on locations. You can attach the frame extension relative to the client area, the menu bar, or the title bar. You can query the location of the extension as well as the ID of the frame control to which the extension is attached.

attachedToId

      public:
      virtual unsigned long attachedToId() const

  Returns the ID of the frame control this extension is attached to.

Supported Platforms

  Windows | OS/2 | AIX
  Yes | Yes | Yes

location

      public:
      IFrameWindow::Location location() const

  Returns the frame extension's location.

Supported Platforms

  Windows | OS/2 | AIX
  Yes | Yes | Yes

### Extension Sizing

Using the frame-extension sizing members, you can query and set the size of the frame extension.

You can query the width and height of relative- and fixed-type extensions. See the Extension Type group for information on types of extensions.

You can reset the size of an extension or indicate that the extension is to be sized to the minimum size of the window it contains. The size of a separator, if requested, is not included in the size of the extension.

Various sizing calculations are provided. You can calculate a total rectangle based on a specified rectangle plus the frame extension's size. This total also includes the separator width. The opposite calculation function is also provided. You specify a base rectangle and the rectangle size is returned minus the frame extension's size and separator width.

attachTo

      public:
      virtual ISWP attachTo(ISWP& baseSWP)

  Returns the SWP structure which contains information about how the frame extension is sized when attached to the control. The SWP structure is updated to account for the space this extension occupies.

Supported Platforms

  Windows | OS/2 | AIX
  Yes | Yes | Ignored

baseRectFor

      public:
      virtual IRectangle
        baseRectFor( const IRectangle& totalRect ) const

  Calculates and returns a rectangle representing the client rectangle without its frame extension. Both the rectangle you specify and the returned rectangle are in the orientation of the native windowing system. You can use the class ICoordinateSystem to determine the native orientation.

Supported Platforms

  Windows | OS/2 | AIX
  Yes | Yes | Yes

AIX Considerations

  This function always returns a default IRectangle.

fixedSize

      public:
      virtual unsigned long fixedSize() const

  Returns the fixed width or height in window coordinates. If the extension is of type relative, 0 is returned.

Supported Platforms

  Windows | OS/2 | AIX
  Yes | Yes | Yes

relativeSize

      public:
      virtual double relativeSize() const

  Returns the relative width or height as a percentage. If the extension is of type fixed, 0.0 is returned.

Supported Platforms

  Windows | OS/2 | AIX
  Yes | Yes | Yes

setSize

  Resets the size of the extension.

  Overload 1

      public:
      virtual IFrameExtension&
        setSize( unsigned long widthOrHeight )

  Use this setSize function to set the size of a fixed-type extension.

  widthOrHeight
    The portion of the frame window area (title bar area, menu bar area, or client area) allocated to the frame extension, in a fixed width or height (unsigned long).

Supported Platforms

  Windows | OS/2 | AIX
  Yes | Yes | Yes

  Overload 2

      public:
      virtual IFrameExtension& setSize(int widthOrHeight)

  Use this setSize function to set the size of a fixed-type extension.

  widthOrHeight
    The portion of the frame window area (title bar area, menu bar area, or client area) allocated to the frame extension, in a fixed width or height (int).

Supported Platforms

  Windows | OS/2 | AIX
  Yes | Yes | Yes

  Overload 3

      public:
      virtual IFrameExtension& setSize(double widthOrHeight)

  Use this setSize function to set the size of a relative-type extension.

  widthOrHeight
    The portion of the frame window area (title bar area, menu bar area, or client area) allocated to the frame extension, in a floating point percentage (double, 0 < x < 1.0).

Supported Platforms

  Windows | OS/2 | AIX
  Yes | Yes | Yes

sizeTo

      public:
      virtual ISize sizeTo(const ISize& baseSize) const

  Calculates and returns the size this extension would be if attached to a control of the specified size.

Supported Platforms

  Windows | OS/2 | AIX
  Yes | Yes | Yes

AIX Considerations

  AIX does not support this function. The function always returns the specified baseSize value.

totalRectFor

      public:
      virtual IRectangle
        totalRectFor( const IRectangle& baseRect ) const

  Calculates and returns a new rectangle value. This value is baseRect plus the frame extension's size and position. Both the rectangle you specify and the returned rectangle are in the orientation of the native windowing system. You can use the class ICoordinateSystem to determine the native orientation.

Supported Platforms

  Windows | OS/2 | AIX
  Yes | Yes | Yes

AIX Considerations

  This function always returns a default IRectangle.

useMinimumSize

      public:
      virtual IFrameExtension& useMinimumSize()

  Specifies that the width or height of the extension is assigned from the minimum size of the window it contains.

Supported Platforms

  Windows | OS/2 | AIX
  Yes | Yes | Ignored

### Extension Type

When adding a frame extension, you specify the type of extension using one of the Type enumerations: fixed, relative, or minimumSize.

A fixed extension remains a specific size.

When adding a relative extension, you specify the percentage of the frame control that the extension will occupy. The extension is sized when the frame control is resized.

You can specify that the extension be sized according to its associated control's minimum size.

The type of extension you choose depends on the desired layout of your controls.

type

      public:
      Type type() const

  Returns the extension type for this frame extension object. The returned value is an enumerator provided by Type.

Supported Platforms

  Windows | OS/2 | AIX
  Yes | Yes | Yes

### Extension Window

Use these members to query the window that is associated with the extension. This control is the control specified when the extension was added to the frame.

control

      public:
      IWindow* control() const

  Returns a pointer to the window that occupies this frame extension.

Supported Platforms

  Windows | OS/2 | AIX
  Yes | Yes | Yes

### Separator

A separator is a visual delineator between an extension and the window to which it is attached. You specify whether you want a separator when adding a frame extension by using IFrameWindow::addExtension. You can specify no separator, a thin separator line, or a thick separator line. The separator types are defined in the enumeration IFrameWindow::SeparatorType. You can query the width of the separator line. The separator width is not included in the size of the frame extensions. See the Extension Sizing members for more details.

#### AIX Considerations

  In the Motif environment, the separator consists of a XmSeparator widget. You can query and set the handle of the separator using setSeparatorHandle and separatorHandle. You can query the IFrameWindow::separatorType of the separator with the separatorType function.

drawSeparator

      public:
      virtual void drawSeparator(const IPresSpaceHandle& psh)

  Draws the separator line between a frame extension and the adjacent control (or extension) it is attached to.

Supported Platforms

  Windows | OS/2 | AIX
  Yes | Yes | Ignored

separatorWidth

      public:
      virtual unsigned long separatorWidth() const

  Returns the width of the separator line between this frame extension and either of the following:

  - The control it is attached to
  - The extension it is adjacent to

Supported Platforms

  Windows | OS/2 | AIX
  Yes | Yes | Yes

### IFrameExtension - Enumerations

Type

      enum Type { fixed,
                  relative,
                  minimumSize }

  Use these enumerators to specify how the frame extension is sized:

  fixed
    Specifies a fixed width or height.
  relative
    Specifies a relative width or height based on how much of the attached-to frame control the extension occupies.
  minimumSize
    Specifies that the extension should be sized according to the minimum size of the frame extension's window.

Supported Platforms

  Windows | OS/2 | AIX
  Yes | Yes | Yes

### IFrameExtension - Inherited Member Functions and Data

#### Inherited Public Functions

  - None

#### Inherited Public Data

  - None

#### Inherited Protected Functions

  - None

#### Inherited Protected Data

  - None