Dgs-dxwindow: Difference between revisions

From Multi Theft Auto: Wiki
Jump to navigation Jump to search
No edit summary
Line 18: Line 18:
*'''color:''' An integer of the color of the background of the window.
*'''color:''' An integer of the color of the background of the window.


===titnamecolor===
===textColor===
The color which can be translated by [[tocolor]] of the title text of the window.
The color which can be translated by [[tocolor]] of the title text of the window.
<syntaxhighlight lang="lua">dgsSetProperty(window,"titnamecolor",titnamecolor)</syntaxhighlight>
<syntaxhighlight lang="lua">dgsSetProperty(window,"textColor",textColor)</syntaxhighlight>
*'''titnamecolor:''' An integer of the color of the title text of the window.
*'''textColor:''' An integer of the color of the title text of the window.


===titcolor===
===titleColor===
The color which can be translated by [[tocolor]] of the title of the window.
The color which can be translated by [[tocolor]] of the title of the window.
<syntaxhighlight lang="lua">dgsSetProperty(window,"titcolor",titcolor)</syntaxhighlight>
<syntaxhighlight lang="lua">dgsSetProperty(window,"titleColor",titleColor)</syntaxhighlight>
*'''titcolor:''' An integer of the color of the title of the window.
*'''titleColor:''' An integer of the color of the title of the window.
 
===titleImage===
The texture element(texture/render target/screen source/shader etc) of the title background of the window.
<syntaxhighlight lang="lua">dgsSetProperty(window,"titleImage",titleImage)</syntaxhighlight>
*'''titleImage:''' A texture element of the title background of the window.


===text===
===text===
Line 33: Line 38:
*'''text:''' A string of the title text of the window.
*'''text:''' A string of the title text of the window.


===textcolor===
===textColor===
The color which can be translated by [[tocolor]] of the text of the window.
The color which can be translated by [[tocolor]] of the text of the window.
<syntaxhighlight lang="lua">dgsSetProperty(window,"textcolor",textcolor)</syntaxhighlight>
<syntaxhighlight lang="lua">dgsSetProperty(window,"textColor",textColor)</syntaxhighlight>
*'''textcolor:''' An integer of the color of the title text of the window.
*'''textColor:''' An integer of the color of the title text of the window.


===textsize===
===textSize===
The scale of the text of the window. ''Learn More [[dxDrawText]]''
The scale of the text of the window. ''Learn More [[dxDrawText]]''
<syntaxhighlight lang="lua">dgsSetProperty(window,"textsize",{scaleX,scaleY})</syntaxhighlight>
<syntaxhighlight lang="lua">dgsSetProperty(window,"textSize",{scaleX,scaleY})</syntaxhighlight>
*'''scaleX:''' A float of the 2D X scale of the title text of the window.
*'''scaleX:''' A float of the 2D X scale of the title text of the window.
*'''scaleY:''' A float of the 2D Y scale of the title text of the window.
*'''scaleY:''' A float of the 2D Y scale of the title text of the window.
Line 83: Line 88:
*'''maxHeight:''' An integer of the maximum height of the window.
*'''maxHeight:''' An integer of the maximum height of the window.


===sidesize===
===borderSize===
This property determines the border size in pixels which is used to resize the window.
This property determines the border size in pixels which is used to resize the window.
<syntaxhighlight lang="lua">dgsSetProperty(window,"sidesize",sidesize)</syntaxhighlight>
<syntaxhighlight lang="lua">dgsSetProperty(window,"borderSize",borderSize)</syntaxhighlight>
*'''sidesize:''' An integer of the size of the border of the window in pixels.
*'''borderSize:''' An integer of the size of the border of the window in pixels.


===titlesize===
===titleHeight===
This property determines the title size in pixels which is also used to move the window.
This property determines the title size in pixels which is also used to move the window.
<syntaxhighlight lang="lua">dgsSetProperty(window,"titlesize",titlesize)</syntaxhighlight>
<syntaxhighlight lang="lua">dgsSetProperty(window,"titleHeight",titleHeight)</syntaxhighlight>
*'''titlesize:''' An integer of the size of the title of the window in pixels.
*'''titleHeight:''' An integer of the size of the title of the window in pixels.


===ignoreTitleSize===
===ignoreTitleSize===

Revision as of 12:11, 14 August 2018

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

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

Main Functions

Properties

image

The texture element(texture/render target/screen source/shader etc) of the background of the window.

dgsSetProperty(window,"image",image)
  • image: A texture element of the background of the window.

color

The color which can be translated by tocolor of the background of the window.

dgsSetProperty(window,"color",color)
  • color: An integer of the color of the background of the window.

textColor

The color which can be translated by tocolor of the title text of the window.

dgsSetProperty(window,"textColor",textColor)
  • textColor: An integer of the color of the title text of the window.

titleColor

The color which can be translated by tocolor of the title of the window.

dgsSetProperty(window,"titleColor",titleColor)
  • titleColor: An integer of the color of the title of the window.

titleImage

The texture element(texture/render target/screen source/shader etc) of the title background of the window.

dgsSetProperty(window,"titleImage",titleImage)
  • titleImage: A texture element of the title background of the window.

text

This is equivalent to dgsSetText/dgsGetText.

dgsSetProperty(window,"text",text)
  • text: A string of the title text of the window.

textColor

The color which can be translated by tocolor of the text of the window.

dgsSetProperty(window,"textColor",textColor)
  • textColor: An integer of the color of the title text of the window.

textSize

The scale of the text of the window. Learn More dxDrawText

dgsSetProperty(window,"textSize",{scaleX,scaleY})
  • scaleX: A float of the 2D X scale of the title text of the window.
  • scaleY: A float of the 2D Y scale of the title text of the window.

font

This is equivalent to dgsSetFont/dgsGetFont. Learn More dxDrawText

dgsSetProperty(window,"font",font)

colorcoded

Whether the color code in the title text is enabled or not. Learn More dxDrawText

dgsSetProperty(window,"colorcoded",colorcoded)
  • colorcoded: Set to true to enable embedded #FFFFFF color codes.

movetyp

This property determines the moving type of the window.

dgsSetProperty(window,"movetyp",movetyp)
  • movetyp: A boolean value indicating the state of the moving type.
    • true: User can move the window by clicking anywhere of the window.
    • false: User can move the window by only clicking the title of the window.

movable

This is equivalent to dgsWindowSetMovable, which allows you to specify whether or not a user can move a DGS window.

dgsSetProperty(window,"movable",movable)
  • movable: A boolean value indicating whether user can move the window or not.

sizable

This is equivalent to dgsWindowSetSizable, which allows you to specify whether or not a user can resize a DGS window.

dgsSetProperty(window,"sizable",sizable)
  • movable: A boolean value indicating whether user can resize the window or not.

minSize

This property determines the minimum width and height of the window that users can resize to.

dgsSetProperty(window,"minSize",{minWidth,minHeight})
  • minWidth: An integer of the minimum width of the window.
  • minHeight: An integer of the minimum height of the window.

maxSize

This property determines the maximum width and height of the window that users can resize to.

dgsSetProperty(window,"maxSize",{maxWidth,maxHeight})
  • maxWidth: An integer of the maximum width of the window.
  • maxHeight: An integer of the maximum height of the window.

borderSize

This property determines the border size in pixels which is used to resize the window.

dgsSetProperty(window,"borderSize",borderSize)
  • borderSize: An integer of the size of the border of the window in pixels.

titleHeight

This property determines the title size in pixels which is also used to move the window.

dgsSetProperty(window,"titleHeight",titleHeight)
  • titleHeight: An integer of the size of the title of the window in pixels.

ignoreTitleSize

This property determines whether to ignore the window title when calculating window's child elements (useful for gui to dgs).

dgsSetProperty(window,"ignoreTitleSize",ignoreTitleSize)
  • ignoreTitleSize: A bool of the state of whether to ignore the window title.

See Also

General Properties

Unique Properties For DGS Core Elements

Extra Properties For DGS Plugins