# cp.ui.SplitGroup

Split Group UI. A SplitGroup is a container that can be split into multiple sections. Each section is an Element, and they are divided by a Splitter, resulting in something like { Element, Splitter, Element }.


# API Overview

Functions - API calls offered directly by the extension

  • matches

Constructors - API calls which return an object, typically one that offers API methods

  • SplitGroup

Fields - Variables which can only be accessed from an object returned by a constructor

  • children
  • childrenUI
  • sections
  • splitters
  • splittersUI

# API Documentation

# Functions

# matches

Signature cp.ui.SplitGroup.matches(element) -> boolean
Type Function
Description Checks to see if an element matches what we think it should be.
Parameters
  • element - An axuielementObject to check.
Returns
  • true if matches otherwise false
Notes None
Examples None
Source src/extensions/cp/ui/SplitGroup.lua line 21

# Constructors

# SplitGroup

Signature cp.ui.SplitGroup(parent, uiFinder, childInits) -> cp.ui.SplitGroup
Type Constructor
Description Creates a new SplitGroup.
Parameters
  • parent - The parent object.
  • uiFinder - The function or cp.prop which returns an hs.axuielement for the SplitGroup, or nil.
  • childInits - A table of section-creating functions, in order, including the Splitters.
Returns
  • A new SplitGroup instance.
Notes
  • Many childInints values can be the actual Element value (eg: TextArea), since they only require the parent and uiFinder parameters.
  • The cp.fn.ax.init function can be useful for passing in Element types which require more than just the parent and uiFinder values.
  • Example: `SplitGroup(parent, uiFinder, { cp.fn.ax.init(ScrollArea, cp.ui.List), cp.fn.ax.init(ScrollArea, cp.ui.TextArea) })
Examples None
Source src/extensions/cp/ui/SplitGroup.lua line 32

# Fields

# children

Signature cp.ui.SplitGroup.children <table: cp.ui.Element, read-only>
Type Field
Description All children of the Split Group, based on the childInits passed to the constructor.
Notes None
Source src/extensions/cp/ui/SplitGroup.lua line 60

# childrenUI

Signature cp.ui.SplitGroup.childrenUI <cp.prop: table of axuielementObject, read-only>
Type Field
Description The list of axuielementObjects for the sections, sorted in top-down order.
Notes None
Source src/extensions/cp/ui/SplitGroup.lua line 53

# sections

Signature cp.ui.SplitGroup.sections <table: table of cp.ui.Element, read-only>
Type Field
Description The Sections of the SplitGroup. Each section will be a table of cp.ui.Elements.
Notes None
Source src/extensions/cp/ui/SplitGroup.lua line 80

# splitters

Signature cp.ui.SplitGroup.splitters <table: cp.ui.Splitter, read-only>
Type Field
Description The Splitters of the SplitGroup. There will be one less splitter than there are sections.
Notes None
Source src/extensions/cp/ui/SplitGroup.lua line 75

# splittersUI

Signature cp.ui.SplitGroup.splittersUI <cp.prop: table of axuielementObject, read-only>
Type Field
Description The list of axuielementObjects for the splitters.
Notes None
Source src/extensions/cp/ui/SplitGroup.lua line 68