# `GSInstance`

*Class*

## Declaration

```swift
class GSInstance
```

```objc
@interface GSInstance : NSObject
```

```python
class GSInstance(NSObject)
```

## Topics

### Instance Properties

- [`GSInstance.axesValues`](/Core/GlyphsCore/GSInstance/axesValues) — The axis values of the instance.
- [`GSInstance.axesValuesList`](/Core/GlyphsCore/GSInstance/axesValuesList) — A list of the axis values.
- [`GSInstance.customParameters`](/Core/GlyphsCore/GSInstance/customParameters) — A list of custom parameter objects.
- [`GSInstance.exports`](/Core/GlyphsCore/GSInstance/exports) — Indicates if the instance should be exported.
- [`GSInstance.font`](/Core/GlyphsCore/GSInstance/font) — Reference to the containing font
- [`GSInstance.iconPresets`](/Core/GlyphsCore/GSInstance/iconPresets) — An array of icon presets.
- [`GSInstance.id`](/Core/GlyphsCore/GSInstance/id) — A unique identifier for the instance that does not change when other properties such as the same are changed.
- [`GSInstance.image`](/Core/GlyphsCore/GSInstance/image)
- [`GSInstance.instanceInterpolations`](/Core/GlyphsCore/GSInstance/instanceInterpolations) — A dictionary that contains the interpolation coefficients for each master. This is automatically updated if you change interpolationWeight, interpolationWidth, interpolationCustom. It contains FontMaster IDs as keys and coefficients for that master as values. Or, you can set it manually if you set manualInterpolation to true. There is no UI for this, so you need to do that with a script.
- [`GSInstance.isBold`](/Core/GlyphsCore/GSInstance/isBold) — The style linking bold bit.
- [`GSInstance.isItalic`](/Core/GlyphsCore/GSInstance/isItalic) — The style linking italic bit.
- [`GSInstance.visible`](/Core/GlyphsCore/GSInstance/visible) — Indicates if the instance is visible in Preview > Show All instances.
- [`GSInstance.linkStyle`](/Core/GlyphsCore/GSInstance/linkStyle) — The style to use as the regular for this style. If styleName is `Medium`, you could link to `Light`. So this instance becomes the Bold style for the Light.
- [`GSInstance.listFontColor`](/Core/GlyphsCore/GSInstance/listFontColor)
- [`GSInstance.manualInterpolation`](/Core/GlyphsCore/GSInstance/manualInterpolation) — Disables automatic calculation of instanceInterpolations This allows manually setting instanceInterpolations.
- [`GSInstance.name`](/Core/GlyphsCore/GSInstance/name) — The name of the instance. This is used as the style name.
- [`GSInstance.nameParticles`](/Core/GlyphsCore/GSInstance/nameParticles) — the name particle.
- [`GSInstance.properties`](/Core/GlyphsCore/GSInstance/properties) — A list of property objects.
- [`GSInstance.readBuffer`](/Core/GlyphsCore/GSInstance/readBuffer) — The read buffer dictionary.
- [`GSInstance.tempData`](/Core/GlyphsCore/GSInstance/tempData) — A dictionary that stores temporary data. It will not be written to disk.
- [`GSInstance.tooltip`](/Core/GlyphsCore/GSInstance/tooltip)
- [`GSInstance.type`](/Core/GlyphsCore/GSInstance/type) — The type of the instance.
- [`GSInstance.typeName`](/Core/GlyphsCore/GSInstance/typeName) — The name of the instance type.
- [`GSInstance.userData`](/Core/GlyphsCore/GSInstance/userData) — The user data dictionary.
- [`GSInstance.weightClassUI`](/Core/GlyphsCore/GSInstance/weightClassUI) — The weight class UI string (e.g. Regular or Bold).
- [`GSInstance.weightClassValue`](/Core/GlyphsCore/GSInstance/weightClassValue) — The actual weight class value as set by the weightClass or custom parameter “weightClass”.
- [`GSInstance.widthClassUI`](/Core/GlyphsCore/GSInstance/widthClassUI) — The width class UI string (e.g. Medium).
- [`GSInstance.widthClassValue`](/Core/GlyphsCore/GSInstance/widthClassValue) — The actual width class value as set by the widthClass.

### Instance Methods

- [`GSInstance addCustomParameter:`](/Core/GlyphsCore/GSInstance/addCustomParameter:) — Adds a custom parameter.
- [`GSInstance addIconPreset:`](/Core/GlyphsCore/GSInstance/addIconPreset:)
- [`GSInstance addNameParticle:forAxisId:`](/Core/GlyphsCore/GSInstance/addNameParticle:forAxisId:)
- [`GSInstance addProperty:`](/Core/GlyphsCore/GSInstance/addProperty:) — Adds a property object to the properties array.
- [`GSInstance axisExternalValueValueForId:`](/Core/GlyphsCore/GSInstance/axisExternalValueValueForId:) — Returns the external axis value for a specific ID.
- [`GSInstance axisInternalValueValueForId:`](/Core/GlyphsCore/GSInstance/axisInternalValueValueForId:) — Returns the internal axis value for a specific ID.
- [`GSInstance axisValueForId:`](/Core/GlyphsCore/GSInstance/axisValueForId:) — Returns the axis value for a specific ID.
- [`GSInstance axisValueValueForId:`](/Core/GlyphsCore/GSInstance/axisValueValueForId:) — Returns the axis value for a specific ID. (Deprecated)
- [`GSInstance coordinateForAxisIndex:`](/Core/GlyphsCore/GSInstance/coordinateForAxisIndex:) — Returns the coordinate for a specific axis index.
- [`GSInstance countOfCustomParameters`](/Core/GlyphsCore/GSInstance/countOfCustomParameters) — The count of customParameters
- [`GSInstance countOfProperties`](/Core/GlyphsCore/GSInstance/countOfProperties) — The number of properties
- [`GSInstance customBoolValueForKey:`](/Core/GlyphsCore/GSInstance/customBoolValueForKey:) — Returns the boolean value of the custom parameter for the specified key.
- [`GSInstance customBoolValueForKey:defaultValue:`](/Core/GlyphsCore/GSInstance/customBoolValueForKey:defaultValue:) — Returns the boolean value of the custom parameter for the specified key, or the default value if not found.
- [`GSInstance customColorValueForKey:`](/Core/GlyphsCore/GSInstance/customColorValueForKey:) — Returns the color value of the custom parameter for the specified key.
- [`GSInstance customParameterForKey:`](/Core/GlyphsCore/GSInstance/customParameterForKey:) — Returns the custom parameter object for the specified key.
- [`GSInstance customParameterActiveForKey:`](/Core/GlyphsCore/GSInstance/customParameterActiveForKey:) — Returns the active custom parameter object for the specified key.
- [`GSInstance customValueForKey:`](/Core/GlyphsCore/GSInstance/customValueForKey:) — Returns the value of the custom parameter for the specified key.
- [`GSInstance defaultPropertyForName:`](/Core/GlyphsCore/GSInstance/defaultPropertyForName:) — Returns the default property for the specified name.
- [`GSInstance fileName:error:`](/Core/GlyphsCore/GSInstance/fileName:error:) — Returns the file name with the specified format.
- [`GSInstance filteredMasters:error:`](/Core/GlyphsCore/GSInstance/filteredMasters:error:) — Returns the filtered masters for the specified font.
- [`GSInstance finalPath:error:`](/Core/GlyphsCore/GSInstance/finalPath:error:) — Returns the file name with the specified format. It includes the “Export Folder” part.
- [`GSInstance fontName:`](/Core/GlyphsCore/GSInstance/fontName:) — Returns the font name.
- [`GSInstance fullName:`](/Core/GlyphsCore/GSInstance/fullName:) — Returns the full name.
- [`GSInstance indexOfObjectInIconPresets:`](/Core/GlyphsCore/GSInstance/indexOfObjectInIconPresets:) — Returns the index of the specified icon preset in iconPresets.
- [`GSInstance indexOfObjectInProperties:`](/Core/GlyphsCore/GSInstance/indexOfObjectInProperties:) — Returns the index of the specified property in properties.
- [`GSInstance initWithDict:container:format:`](/Core/GlyphsCore/GSInstance/initWithDict:container:format:) — Initializes a new instance of the GSInstance class with a dictionary and format version.
- [`GSInstance initFast`](/Core/GlyphsCore/GSInstance/initFast)
- [`GSInstance initWithType:`](/Core/GlyphsCore/GSInstance/initWithType:) — Initializes a new instance of the GSInstance class with a type.
- [`GSInstance initWithTypeName:`](/Core/GlyphsCore/GSInstance/initWithTypeName:) — Initializes a new instance of the GSInstance class with a type name.
- [`GSInstance insertObject:inCustomParametersAtIndex:`](/Core/GlyphsCore/GSInstance/insertObject:inCustomParametersAtIndex:) — Inserts a custom parameter at the specified index.
- [`GSInstance insertObject:inPropertiesAtIndex:`](/Core/GlyphsCore/GSInstance/insertObject:inPropertiesAtIndex:) — Inserts a property object at the specified index in the properties array.
- [`GSInstance instanceInterpolationsWithUpdates:`](/Core/GlyphsCore/GSInstance/instanceInterpolationsWithUpdates:) — Returns the instance interpolations with updates.
- [`GSInstance instanceKey`](/Core/GlyphsCore/GSInstance/instanceKey) — Returns the instance key.
- [`GSInstance interpolatedFont:`](/Core/GlyphsCore/GSInstance/interpolatedFont:) — The interpolated font proxy.
- [`GSInstance invalidateCustomParameterCache`](/Core/GlyphsCore/GSInstance/invalidateCustomParameterCache) — Invalidates the custom parameter cache.
- [`GSInstance isEqualToInstance:`](/Core/GlyphsCore/GSInstance/isEqualToInstance:) — Checks if the instance is equal to another instance.
- [`GSInstance nameUI`](/Core/GlyphsCore/GSInstance/nameUI) — Returns the name for the UI.
- [`GSInstance objectInCustomParametersAtIndex:`](/Core/GlyphsCore/GSInstance/objectInCustomParametersAtIndex:) — Returns the custom parameter object at the specified index.
- [`GSInstance objectInPropertiesAtIndex:`](/Core/GlyphsCore/GSInstance/objectInPropertiesAtIndex:) — Returns the property object at the specified index.
- [`GSInstance outlineFormat`](/Core/GlyphsCore/GSInstance/outlineFormat) — Returns the outline format.
- [`GSInstance postRead:format:`](/Core/GlyphsCore/GSInstance/postRead:format:) — Performs post-read operations.
- [`GSInstance postScriptNamePrefix:`](/Core/GlyphsCore/GSInstance/postScriptNamePrefix:) — Returns the PostScript name prefix.
- [`GSInstance preferredFamilyNames:`](/Core/GlyphsCore/GSInstance/preferredFamilyNames:) — Returns the preferred family names.
- [`GSInstance preferredSubfamilyNames:`](/Core/GlyphsCore/GSInstance/preferredSubfamilyNames:) — Returns the preferred subfamily names.
- [`GSInstance propertyForName:`](/Core/GlyphsCore/GSInstance/propertyForName:) — Returns the property for the specified name.
- [`GSInstance propertyForName:languageTag:`](/Core/GlyphsCore/GSInstance/propertyForName:languageTag:) — Returns the property for the specified name and language tag.
- [`GSInstance propertyListValueFormat:error:`](/Core/GlyphsCore/GSInstance/propertyListValueFormat:error:) — Returns the content of the object to store it in pList.
- [`GSInstance removeNameParticle:forAxisId:`](/Core/GlyphsCore/GSInstance/removeNameParticle:forAxisId:)
- [`GSInstance removeObjectFromCustomParameters:`](/Core/GlyphsCore/GSInstance/removeObjectFromCustomParameters:) — Removes the specified custom parameter.
- [`GSInstance removeObjectFromProperties:`](/Core/GlyphsCore/GSInstance/removeObjectFromProperties:) — Removes a property object from the properties array.
- [`GSInstance removeObjectFromCustomParametersAtIndex:`](/Core/GlyphsCore/GSInstance/removeObjectFromCustomParametersAtIndex:) — Removes the custom parameter at the specified index.
- [`GSInstance removeObjectFromCustomParametersForKey:`](/Core/GlyphsCore/GSInstance/removeObjectFromCustomParametersForKey:) — Removes the first custom parameter with the specified key.
- [`GSInstance removeObjectFromPropertiesAtIndex:`](/Core/GlyphsCore/GSInstance/removeObjectFromPropertiesAtIndex:) — Removes the property object at the specified index from the properties array.
- [`GSInstance replaceObjectInCustomParametersAtIndex:withObject:`](/Core/GlyphsCore/GSInstance/replaceObjectInCustomParametersAtIndex:withObject:) — Replaces the custom parameter at the specified index with a new custom parameter.
- [`GSInstance saveToFile:format:context:error:`](/Core/GlyphsCore/GSInstance/saveToFile:format:context:error:) — Saves the instance to a file with the specified format version.
- [`GSInstance scaleBy:`](/Core/GlyphsCore/GSInstance/scaleBy:) — Scales the instance object.
- [`GSInstance setAxisExternalValueValue:forId:`](/Core/GlyphsCore/GSInstance/setAxisExternalValueValue:forId:) — Sets the external axis value for a specific ID.
- [`GSInstance setAxisInternalValueValue:forId:`](/Core/GlyphsCore/GSInstance/setAxisInternalValueValue:forId:) — Sets the internal axis value for a specific ID.
- [`GSInstance setAxisValue:forId:`](/Core/GlyphsCore/GSInstance/setAxisValue:forId:) — Sets the axis value for a specific ID.
- [`GSInstance setAxisValueFast:forId:`](/Core/GlyphsCore/GSInstance/setAxisValueFast:forId:) — Sets the axis value quickly without copying data for a specific ID.
- [`GSInstance setAxisValueValue:forId:`](/Core/GlyphsCore/GSInstance/setAxisValueValue:forId:) — Sets the axis value for a specific ID. (Deprecated)
- [`GSInstance setCustomValue:forKey:`](/Core/GlyphsCore/GSInstance/setCustomValue:forKey:) — Sets the value for the custom parameter with the specified key.
- [`GSInstance setDefaultProperty:value:`](/Core/GlyphsCore/GSInstance/setDefaultProperty:value:) — Sets the default property for the specified name.
- [`GSInstance setProperty:value:languageTag:`](/Core/GlyphsCore/GSInstance/setProperty:value:languageTag:) — Adds a new font info value to the array specified by `key` or updates an existing one.
- [`GSInstance setTempData:forKey:`](/Core/GlyphsCore/GSInstance/setTempData:forKey:) — Adds key/value to tempData. Pass nil as value to remove previously set data.
- [`GSInstance styleMapFamilyNames:`](/Core/GlyphsCore/GSInstance/styleMapFamilyNames:) — Returns the style map family names.
- [`GSInstance styleMapStyleNames:`](/Core/GlyphsCore/GSInstance/styleMapStyleNames:) — Returns the style map style names.
- [`GSInstance tempDataForKey:`](/Core/GlyphsCore/GSInstance/tempDataForKey:) — Returns the value for the specified key in tempData.
- [`GSInstance updateInterpolationValues`](/Core/GlyphsCore/GSInstance/updateInterpolationValues) — Call it if you have made changes to the instance to force an update of instanceInterpolations.

### Type Methods

- [`GSInstance allowedPropertyKeys`](/Core/GlyphsCore/GSInstance/allowedPropertyKeys) — Returns an array of allowed property keys.
- [`GSInstance drawImageSingleLayer:size:color:`](/Core/GlyphsCore/GSInstance/drawImageSingleLayer:size:color:)

## Relationships

### Inherits From

- `NSObject`

### Conforms To

- [`GSContainerProtocol`](/Core/GlyphsCore/GSContainerProtocol)
- [`GSParametersAndPropertiesProtocol`](/Core/GlyphsCore/GSParametersAndPropertiesProtocol)
- [`GSUserDataProtocol`](/Core/GlyphsCore/GSUserDataProtocol)
- `NSCoding`
- `NSCopying`

## See Also

### Essentials

- [`GSFont`](/Core/GlyphsCore/GSFont) — The top-level model object of a Glyphs document.
- [`GSGlyph`](/Core/GlyphsCore/GSGlyph) — A named glyph and its layer collection in a font.
- [`GSLayer`](/Core/GlyphsCore/GSLayer) — The drawing and editing representation of a glyph.
- [`GSAxis`](/Core/GlyphsCore/GSAxis) — `GSAxis` represents an axis in a `GSFont` object.
- [`GSFontMaster`](/Core/GlyphsCore/GSFontMaster)

