# `GSLayer axisRuleString:rule:`

*Type Method*

A display string for an axis rule.

## Declaration

```swift
class func axisRuleString(_ axis: GSAxis, rule: [String : NSNumber]) -> String?
```

```objc
+ (NSString *) axisRuleString:(GSAxis *) axis rule:(NSDictionary<NSString *,NSNumber *> *) rule;
```

```python
axisRuleString_rule_(axis: GSAxis, rule: dict[str, NSNumber]) -> str
```

## Parameters

- `axis` — The axis described by the rule.
- `rule` — Inclusive `min` and `max` bounds in internal axis values.

## Return Value

A compact rule description, or `nil` when the rule has no bounds.

## See Also

### Alternative Layers

- [`GSLayer.axisRules`](/Core/GlyphsCore/GSLayer/axisRules) — Alternative-layer axis rules keyed by axis ID.
- [`GSLayer descriptionForAttributeAxisRules`](/Core/GlyphsCore/GSLayer/descriptionForAttributeAxisRules) — A display description of the Alternative-layer axis rules.

