HScaleRef

public struct HScaleRef : HScaleProtocol, GWeakCapturing

The GtkHScale widget is used to allow the user to select a value using a horizontal slider. To create one, use gtk_hscale_new_with_range().

The position to show the current value, and the number of decimal places shown can be set using the parent GtkScale class’s functions.

GtkHScale has been deprecated, use GtkScale instead.

The HScaleRef type acts as a lightweight Swift reference to an underlying GtkHScale instance. It exposes methods that can operate on this data type through HScaleProtocol conformance. Use HScaleRef only as an unowned reference to an existing GtkHScale instance.

  • ptr
    Untyped pointer to the underlying `GtkHScale` instance.
    

    For type-safe access, use the generated, typed pointer hscale_ptr property instead.

    Declaration

    Swift

    public let ptr: UnsafeMutableRawPointer!

HScale Class

  • Designated initialiser from the underlying C data type

    Declaration

    Swift

    @inlinable
    init(_ p: UnsafeMutablePointer<GtkHScale>)
  • Designated initialiser from a constant pointer to the underlying C data type

    Declaration

    Swift

    @inlinable
    init(_ p: UnsafePointer<GtkHScale>)
  • Conditional initialiser from an optional pointer to the underlying C data type

    Declaration

    Swift

    @inlinable
    init!(_ maybePointer: UnsafeMutablePointer<GtkHScale>?)
  • Conditional initialiser from an optional, non-mutable pointer to the underlying C data type

    Declaration

    Swift

    @inlinable
    init!(_ maybePointer: UnsafePointer<GtkHScale>?)
  • Conditional initialiser from an optional gpointer

    Declaration

    Swift

    @inlinable
    init!(gpointer g: gpointer?)
  • Conditional initialiser from an optional, non-mutable gconstpointer

    Declaration

    Swift

    @inlinable
    init!(gconstpointer g: gconstpointer?)
  • Reference intialiser for a related type that implements HScaleProtocol

    Declaration

    Swift

    @inlinable
    init<T>(_ other: T) where T : HScaleProtocol
  • This factory is syntactic sugar for setting weak pointers wrapped in GWeak<T>

    Declaration

    Swift

    @inlinable
    static func unowned<T>(_ other: T) -> HScaleRef where T : HScaleProtocol
  • Unsafe typed initialiser. Do not use unless you know the underlying data type the pointer points to conforms to HScaleProtocol.

    Declaration

    Swift

    @inlinable
    init<T>(cPointer: UnsafeMutablePointer<T>)
  • Unsafe typed initialiser. Do not use unless you know the underlying data type the pointer points to conforms to HScaleProtocol.

    Declaration

    Swift

    @inlinable
    init<T>(constPointer: UnsafePointer<T>)
  • Unsafe untyped initialiser. Do not use unless you know the underlying data type the pointer points to conforms to HScaleProtocol.

    Declaration

    Swift

    @inlinable
    init(mutating raw: UnsafeRawPointer)
  • Unsafe untyped initialiser. Do not use unless you know the underlying data type the pointer points to conforms to HScaleProtocol.

    Declaration

    Swift

    @inlinable
    init(raw: UnsafeMutableRawPointer)
  • Unsafe untyped initialiser. Do not use unless you know the underlying data type the pointer points to conforms to HScaleProtocol.

    Declaration

    Swift

    @inlinable
    init(opaquePointer: OpaquePointer)
  • Creates a new `GtkHScale`.
    

    new is deprecated: Use gtk_scale_new() with %GTK_ORIENTATION_HORIZONTAL instead

    Declaration

    Swift

    @available(*, deprecated)
    @inlinable
    init<AdjustmentT>(adjustment: AdjustmentT?) where AdjustmentT : AdjustmentProtocol
  • Creates a new horizontal scale widget that lets the user input a number between min and max (including min and max) with the increment step. step must be nonzero; it’s the distance the slider moves when using the arrow keys to adjust the scale value.

    Note that the way in which the precision is derived works best if step is a power of ten. If the resulting precision is not suitable for your needs, use gtk_scale_set_digits() to correct it.

    new_with_range is deprecated: Use gtk_scale_new_with_range() with %GTK_ORIENTATION_HORIZONTAL instead

    Declaration

    Swift

    @available(*, deprecated)
    @inlinable
    init(range min: Double, max: Double, step: Double)
  • Creates a new horizontal scale widget that lets the user input a number between min and max (including min and max) with the increment step. step must be nonzero; it’s the distance the slider moves when using the arrow keys to adjust the scale value.

    Note that the way in which the precision is derived works best if step is a power of ten. If the resulting precision is not suitable for your needs, use gtk_scale_set_digits() to correct it.

    new_with_range is deprecated: Use gtk_scale_new_with_range() with %GTK_ORIENTATION_HORIZONTAL instead

    Declaration

    Swift

    @available(*, deprecated)
    @inlinable
    static func hscaleNewWith(range min: Double, max: Double, step: Double) -> WidgetRef!