DgsDetachFromTranslation

From Multi Theft Auto: Wiki

This function detaches dgs element from translation table.

Syntax

bool dgsDetachFromTranslation ( element dgsElement )

Required Arguments

  • dgsElement: The dgs element you want to detach.

Returns

Returns a string if succeed, false otherwise.

Example

DGS = exports.dgs
TranslationTable = {
	Test="Text %rep% %rep%"
}
DGS:dgsSetTranslationTable("EN",TranslationTable)
local button = DGS:dgsCreateButton(200,200,200,100,"Login",false)
DGS:dgsAttachToTranslation(button,"EN")  --Attach
DGS:dgsSetText(button,{"Test","Test","DGS"})  --Change text with table to use translation table
DGS:dgsDetachToTranslation(button) --Detach

setTimer(function()
	TranslationTable2 = {
		Test="L %rep% O %rep% L"
	}
	DGS:dgsSetTranslationTable("EN",TranslationTable2) --Change Translation Table and nothing happen
end,1000,1)

See Also

Multi Language Supports

Animation

3D Interface

3D Text

Arrow List

Browser

Button

Check Box

Combo Box

Edit

Ellipse Detect Area

Detect Area

Grid List

Image

Memo

Label

Progress Bar

Radio Button

Scroll Bar

Scroll Pane

Switch Button

Tab Panel

Window

Plugin

Media Browser

Rounded Rectangle

Color Picker

Blur Box

Effect 3D