Dgs-dxscrollbar: Difference between revisions

From Multi Theft Auto: Wiki
Jump to navigation Jump to search
No edit summary
Line 20: Line 20:
*'''arrowColorHover:''' An integer of the arrow color when the mouse's cursor is hovering on it, which can be converted by [[tocolor]].
*'''arrowColorHover:''' An integer of the arrow color when the mouse's cursor is hovering on it, which can be converted by [[tocolor]].
*'''arrowColorClick:''' An integer of the arrow color when the arrow gets clicked, which can be converted by [[tocolor]].
*'''arrowColorClick:''' An integer of the arrow color when the arrow gets clicked, which can be converted by [[tocolor]].


===cursorColor===
===cursorColor===

Revision as of 02:20, 2 September 2019

DGS Properties is always used to change the gui style and make it more fantastic.

This page shows the properties of dgs-dx3dtext that you could use.

Main Functions

Properties

arrowWidth

This property adjusts the width of arrow ( take vertical scroll bar as a standard ).

dgsSetProperty(scrollbar,"arrowWidth",{arrowWidth,relative})
  • arrowWidth: A number of the width of arrow, which is affected by relative.
  • relative: A bool of whether the width is relative or not. If this is true, then length must be between 0 and 1.

arrowColor

The arrow color of scroll bar, includes normal, hovering, click.

dgsSetProperty(scrollbar,"arrowColor",{arrowColorNormal,arrowColorHover,arrowColorClick})
  • arrowColorNormal: An integer of the arrow color, which can be converted by tocolor.
  • arrowColorHover: An integer of the arrow color when the mouse's cursor is hovering on it, which can be converted by tocolor.
  • arrowColorClick: An integer of the arrow color when the arrow gets clicked, which can be converted by tocolor.

cursorColor

The cursor color of scroll bar, includes normal, hovering, click.

dgsSetProperty(scrollbar,"cursorColor",{cursorColorNormal,cursorColorHover,cursorColorClick})
  • cursorColorNormal: An integer of the cursor color, which can be converted by tocolor.
  • cursorColorHover: An integer of the cursor color when the mouse's cursor is hovering on it, which can be converted by tocolor.
  • cursorColorClick: An integer of the cursor color when the cursor gets clicked, which can be converted by tocolor.

cursorWidth

This property adjusts the width of cursor ( take vertical scroll bar as a standard ).

dgsSetProperty(scrollbar,"cursorWidth",{cursorWidth,relative})
  • cursorWidth: A number of the width of arrow, which is affected by relative.
  • relative: A bool of whether the width is relative or not. If this is true, then length must be between 0 and 1.

grades

This property stores the grades of scroll bar. See dgsScrollBarSetGrades/dgsScrollBarGetGrades

dgsSetProperty(scrollbar,"grades",grades)
  • grades: A number of the grades of scroll bar.

currentGrade

This property stores the current grade of scroll bar if grades enabled.

dgsSetProperty(scrollbar,"currentGrade",currentGrade)
  • currentGrade: A number of the current grade, ranges from 0 to grades.


image

The image of scroll bar, includes arrow, cursor and trough.

dgsSetProperty(scrollbar,"image",{arrowImage,cursorImage,troughImage})
  • arrowImage: A texture of the image of arrow.
  • cursorImage: A texture of the image of cursor.
  • troughImage: A texture of the image of trough.

length

This property determines whether the length of the cursor of scroll bar.

dgsSetProperty(scrollbar,"length",{length,relative})
  • length: A number of the length of scroll bar, which is affected by relative.
  • relative: A bool of whether the length is relative or not. If this is true, then length must be between 0 and 1.

locked

This is equivalent to dgsScrollBarSetLocked/dgsScrollBarGetLocked.

dgsSetProperty(scrollbar,"locked",locked)
  • locked: A bool of whether the scroll bar get locked or not.

multiplier

This property determines whether how much a scroll bar will scroll when you click the arrow or use mouse wheel.

This property is difficult to understand. Before use this property, do an experiment first.

dgsSetProperty(scrollbar,"multiplier",{multiplier,relative})
  • multiplier: A number of the multiplier of scroll bar, which is affected by relative.
  • relative: A bool of whether the multiplier is relative or not. If this is true, then multiplier must be between 0 and 1.

position

This is equivalent to dgsScrollBarSetScrollPosition/dgsScrollBarGetScrollPosition.

dgsSetProperty(scrollbar,"position",position)
  • position: An integer of the scroll poisition of the scroll bar.

scrollArrow

This property indicates whether enable the scroll arrow or not. It is useful when making scroll bar act as slide or something else.

dgsSetProperty(scrollbar,"scrollArrow",scrollArrow)
  • scrollArrow: A bool of whether enable the scroll arrow or not.

troughWidth

This property adjusts the width of trough ( take vertical scroll bar as a standard ).

dgsSetProperty(scrollbar,"troughWidth",{troughWidth,relative})
  • troughWidth: A number of the width of arrow, which is affected by relative.
  • relative: A bool of whether the width is relative or not. If this is true, then length must be between 0 and 1.

troughColor

The trough color of scroll bar.

dgsSetProperty(scrollbar,"troughColor",troughColor)
  • troughColor: An integer of the trough color, which can be converted by tocolor.

voh

This property determines whether the scroll bar is horizontal or vertical.

dgsSetProperty(scrollbar,"voh",voh)
  • voh: Available values are as follows:
    • false: vertical
    • true: horizontal

See Also

General Properties

Unique Properties For DGS Core Elements

Extra Properties For DGS Plugins