# CrystalControl class

Namespace: [Grasshopper2.UI.Crystallography](https://developer.rhino3d.com/api/gh2/namespace/grasshopper2.ui.crystallography.md) · Assembly: [Grasshopper2](https://developer.rhino3d.com/api/gh2/assembly/grasshopper2.md)

```cs
public sealed class CrystalControl : FlexControl
```

Control for showing a single, rotateable crystal preview.

## Constructors

- [CrystalControl](https://developer.rhino3d.com/api/gh2/type/grasshopper2.ui.crystallography.crystalcontrol/ctor.md): (2 overloads) Create a new default crystal control.

## Properties

- [CrystalColour](https://developer.rhino3d.com/api/gh2/type/grasshopper2.ui.crystallography.crystalcontrol/crystalcolour.md): Gets or sets the crystal colour.
- [CrystalTransform](https://developer.rhino3d.com/api/gh2/type/grasshopper2.ui.crystallography.crystalcontrol/crystaltransform.md): Gets the current crystal transform.
- [Perspective](https://developer.rhino3d.com/api/gh2/type/grasshopper2.ui.crystallography.crystalcontrol/perspective.md): Gets or sets the perspective strength. Value outside the valid range will automatically be clipped. 0.0 = no perspective. 0.15 = subtle perspective. 0.3 = weak perspective. 0.6 = medium perspective. 1.0 = full perspective.
- [Shape](https://developer.rhino3d.com/api/gh2/type/grasshopper2.ui.crystallography.crystalcontrol/shape.md): Gets the crystal currently displayed in this control.
- [ShowCrystalButton](https://developer.rhino3d.com/api/gh2/type/grasshopper2.ui.crystallography.crystalcontrol/showcrystalbutton.md): Gets or sets whether to show the crystal selector button.
- [ShowCrystalGrid](https://developer.rhino3d.com/api/gh2/type/grasshopper2.ui.crystallography.crystalcontrol/showcrystalgrid.md): Gets or sets whether to draw the grid.

## Inherited Members

- From [FlexControl](https://developer.rhino3d.com/api/gh2/type/grasshopper2.ui.flex.flexcontrol.md): [AllowPan](https://developer.rhino3d.com/api/gh2/type/grasshopper2.ui.flex.flexcontrol/allowpan.md), [AllowScrollGesture](https://developer.rhino3d.com/api/gh2/type/grasshopper2.ui.flex.flexcontrol/allowscrollgesture.md), [AllowZoom](https://developer.rhino3d.com/api/gh2/type/grasshopper2.ui.flex.flexcontrol/allowzoom.md), [AutoWindowSelect](https://developer.rhino3d.com/api/gh2/type/grasshopper2.ui.flex.flexcontrol/autowindowselect.md), [Border](https://developer.rhino3d.com/api/gh2/type/grasshopper2.ui.flex.flexcontrol/border.md), [ContentBounds](https://developer.rhino3d.com/api/gh2/type/grasshopper2.ui.flex.flexcontrol/contentbounds.md), [ContentToControl](https://developer.rhino3d.com/api/gh2/type/grasshopper2.ui.flex.flexcontrol/contenttocontrol.md), [ControlToContent](https://developer.rhino3d.com/api/gh2/type/grasshopper2.ui.flex.flexcontrol/controltocontent.md), [CurrentWindowSelection](https://developer.rhino3d.com/api/gh2/type/grasshopper2.ui.flex.flexcontrol/currentwindowselection.md), [DrawContentBoundary](https://developer.rhino3d.com/api/gh2/type/grasshopper2.ui.flex.flexcontrol/drawcontentboundary.md), [DrawScrollbars](https://developer.rhino3d.com/api/gh2/type/grasshopper2.ui.flex.flexcontrol/drawscrollbars.md), [FloatingButtonRail](https://developer.rhino3d.com/api/gh2/type/grasshopper2.ui.flex.flexcontrol/floatingbuttonrail.md), [FloatingButtons](https://developer.rhino3d.com/api/gh2/type/grasshopper2.ui.flex.flexcontrol/floatingbuttons.md), [FocusObject](https://developer.rhino3d.com/api/gh2/type/grasshopper2.ui.flex.flexcontrol/focusobject.md), [InnerBounds](https://developer.rhino3d.com/api/gh2/type/grasshopper2.ui.flex.flexcontrol/innerbounds.md), [InnerScreenBounds](https://developer.rhino3d.com/api/gh2/type/grasshopper2.ui.flex.flexcontrol/innerscreenbounds.md), [IntegerOrigin](https://developer.rhino3d.com/api/gh2/type/grasshopper2.ui.flex.flexcontrol/integerorigin.md), [IsDragSource](https://developer.rhino3d.com/api/gh2/type/grasshopper2.ui.flex.flexcontrol/isdragsource.md), [IsDropTarget](https://developer.rhino3d.com/api/gh2/type/grasshopper2.ui.flex.flexcontrol/isdroptarget.md), [MaximumZoom](https://developer.rhino3d.com/api/gh2/type/grasshopper2.ui.flex.flexcontrol/maximumzoom.md), [MinimumZoom](https://developer.rhino3d.com/api/gh2/type/grasshopper2.ui.flex.flexcontrol/minimumzoom.md), [MouseDwellDelay](https://developer.rhino3d.com/api/gh2/type/grasshopper2.ui.flex.flexcontrol/mousedwelldelay.md), [OuterBounds](https://developer.rhino3d.com/api/gh2/type/grasshopper2.ui.flex.flexcontrol/outerbounds.md), [ParentControl](https://developer.rhino3d.com/api/gh2/type/grasshopper2.ui.flex.flexcontrol/parentcontrol.md), [Projection](https://developer.rhino3d.com/api/gh2/type/grasshopper2.ui.flex.flexcontrol/projection.md), [ResizeBehaviour](https://developer.rhino3d.com/api/gh2/type/grasshopper2.ui.flex.flexcontrol/resizebehaviour.md), [ResponsivesBackwards](https://developer.rhino3d.com/api/gh2/type/grasshopper2.ui.flex.flexcontrol/responsivesbackwards.md), [ResponsivesForwards](https://developer.rhino3d.com/api/gh2/type/grasshopper2.ui.flex.flexcontrol/responsivesforwards.md), [ScreenBounds](https://developer.rhino3d.com/api/gh2/type/grasshopper2.ui.flex.flexcontrol/screenbounds.md), [VisibleFrame](https://developer.rhino3d.com/api/gh2/type/grasshopper2.ui.flex.flexcontrol/visibleframe.md), [ZoomFeedbackLocation](https://developer.rhino3d.com/api/gh2/type/grasshopper2.ui.flex.flexcontrol/zoomfeedbacklocation.md), [Draw](https://developer.rhino3d.com/api/gh2/type/grasshopper2.ui.flex.flexcontrol/draw.md), [MouseDwell](https://developer.rhino3d.com/api/gh2/type/grasshopper2.ui.flex.flexcontrol/mousedwell.md), [PopulateContextMenu](https://developer.rhino3d.com/api/gh2/type/grasshopper2.ui.flex.flexcontrol/populatecontextmenu.md), [ProjectionChanged](https://developer.rhino3d.com/api/gh2/type/grasshopper2.ui.flex.flexcontrol/projectionchanged.md), [WindowSelection](https://developer.rhino3d.com/api/gh2/type/grasshopper2.ui.flex.flexcontrol/windowselection.md), [AddSparkle](https://developer.rhino3d.com/api/gh2/type/grasshopper2.ui.flex.flexcontrol/addsparkle.md), [Animate<T>](https://developer.rhino3d.com/api/gh2/type/grasshopper2.ui.flex.flexcontrol/animate.md), [AnimatedZoomFactor](https://developer.rhino3d.com/api/gh2/type/grasshopper2.ui.flex.flexcontrol/animatedzoomfactor.md), [BeginWindowSelect](https://developer.rhino3d.com/api/gh2/type/grasshopper2.ui.flex.flexcontrol/beginwindowselect.md), [ComputeWrappingBounds](https://developer.rhino3d.com/api/gh2/type/grasshopper2.ui.flex.flexcontrol/computewrappingbounds.md), [CreateFloatingButtons](https://developer.rhino3d.com/api/gh2/type/grasshopper2.ui.flex.flexcontrol/createfloatingbuttons.md), [DispatchRotation](https://developer.rhino3d.com/api/gh2/type/grasshopper2.ui.flex.flexcontrol/dispatchrotation.md), [DrawWindowSelectionEdge](https://developer.rhino3d.com/api/gh2/type/grasshopper2.ui.flex.flexcontrol/drawwindowselectionedge.md), [DrawWindowSelectionFill](https://developer.rhino3d.com/api/gh2/type/grasshopper2.ui.flex.flexcontrol/drawwindowselectionfill.md), [EndWindowSelect](https://developer.rhino3d.com/api/gh2/type/grasshopper2.ui.flex.flexcontrol/endwindowselect.md), [FloatingButtonTooltipOverride](https://developer.rhino3d.com/api/gh2/type/grasshopper2.ui.flex.flexcontrol/floatingbuttontooltipoverride.md), [LooksLikeSingleClick](https://developer.rhino3d.com/api/gh2/type/grasshopper2.ui.flex.flexcontrol/lookslikesingleclick.md), [Map](https://developer.rhino3d.com/api/gh2/type/grasshopper2.ui.flex.flexcontrol/map.md), [Navigate](https://developer.rhino3d.com/api/gh2/type/grasshopper2.ui.flex.flexcontrol/navigate.md), [OnKeyDown](https://developer.rhino3d.com/api/gh2/type/grasshopper2.ui.flex.flexcontrol/onkeydown.md), [OnKeyUp](https://developer.rhino3d.com/api/gh2/type/grasshopper2.ui.flex.flexcontrol/onkeyup.md), [OnLoad](https://developer.rhino3d.com/api/gh2/type/grasshopper2.ui.flex.flexcontrol/onload.md), [OnLoadComplete](https://developer.rhino3d.com/api/gh2/type/grasshopper2.ui.flex.flexcontrol/onloadcomplete.md), [OnMouseDoubleClick](https://developer.rhino3d.com/api/gh2/type/grasshopper2.ui.flex.flexcontrol/onmousedoubleclick.md), [OnMouseDown](https://developer.rhino3d.com/api/gh2/type/grasshopper2.ui.flex.flexcontrol/onmousedown.md), [OnMouseLeave](https://developer.rhino3d.com/api/gh2/type/grasshopper2.ui.flex.flexcontrol/onmouseleave.md), [OnMouseMove](https://developer.rhino3d.com/api/gh2/type/grasshopper2.ui.flex.flexcontrol/onmousemove.md), [OnMouseUp](https://developer.rhino3d.com/api/gh2/type/grasshopper2.ui.flex.flexcontrol/onmouseup.md), [OnMouseWheel](https://developer.rhino3d.com/api/gh2/type/grasshopper2.ui.flex.flexcontrol/onmousewheel.md), [OnPaint](https://developer.rhino3d.com/api/gh2/type/grasshopper2.ui.flex.flexcontrol/onpaint.md), [OnPinchGesture](https://developer.rhino3d.com/api/gh2/type/grasshopper2.ui.flex.flexcontrol/onpinchgesture.md), [OnPopulateContextMenu](https://developer.rhino3d.com/api/gh2/type/grasshopper2.ui.flex.flexcontrol/onpopulatecontextmenu.md), [OnScrollGesture](https://developer.rhino3d.com/api/gh2/type/grasshopper2.ui.flex.flexcontrol/onscrollgesture.md), [OnSizeChanged](https://developer.rhino3d.com/api/gh2/type/grasshopper2.ui.flex.flexcontrol/onsizechanged.md), [OnTextInput](https://developer.rhino3d.com/api/gh2/type/grasshopper2.ui.flex.flexcontrol/ontextinput.md), [PopFocus](https://developer.rhino3d.com/api/gh2/type/grasshopper2.ui.flex.flexcontrol/popfocus.md), [PushFocus](https://developer.rhino3d.com/api/gh2/type/grasshopper2.ui.flex.flexcontrol/pushfocus.md), [RegisterIResponsive](https://developer.rhino3d.com/api/gh2/type/grasshopper2.ui.flex.flexcontrol/registeriresponsive.md), [ScheduleRedraw](https://developer.rhino3d.com/api/gh2/type/grasshopper2.ui.flex.flexcontrol/scheduleredraw.md), [UnregisterIResponsive](https://developer.rhino3d.com/api/gh2/type/grasshopper2.ui.flex.flexcontrol/unregisteriresponsive.md), [UpdateMapping](https://developer.rhino3d.com/api/gh2/type/grasshopper2.ui.flex.flexcontrol/updatemapping.md)
