Table of Contents

Class CadToolPalette

Namespace
OpenCAD2D
Assembly
OpenCAD2D.Core.dll

A tool palette: a name and the tools in the order they are listed, and how they are listed (ViewStyle and IconSize). A palette of a set is made through CadToolPalettes.

public sealed class CadToolPalette
Inheritance
CadToolPalette
Inherited Members

Constructors

CadToolPalette(string)

Makes an empty palette.

Fields

DefaultIconSize

The icon size a palette starts with, in pixels.

MaxIconSize

The largest icon size, in pixels.

MinIconSize

The smallest icon size, in pixels.

Properties

IconSize

Gets or sets the size of the icons in pixels, from MinIconSize to MaxIconSize; 32 until set.

Name

Gets or sets the name shown on the palette's tab; the set it is in keeps them apart where it renames.

Tools

Gets the tools, in the order they are listed.

ViewStyle

Gets or sets how the tools are listed; icons alone until set.

Methods

Add(CadTool)

Puts a tool last.

Clone()

Gets a copy of the palette, tools and view included, each tool a copy.

Insert(int, CadTool)

Puts a tool at a place of the list.

Move(CadTool, int)

Moves a tool to another place of the list, as dragging it within the palette does.

Remove(CadTool)

Takes a tool out.