Plugin:MirLua/Module/m icolib/de
Jump to navigation
Jump to search
Allows you to work with icons.
Inkludieren Sie folgendes Modul: local icolib = require('m_icolib')
AddIcon
Registriert ein Icon.
Parameter
Parametername | Benötigt | Typ | Beschreibung |
---|---|---|---|
name | Ja | string
|
Unique icon name. |
description | Ja | string
|
Description. |
section | Nein | string
|
Section name in Miranda icon settings. By default plugin name (MirLua) is used. |
path | Nein | string
|
Default icon file to use. By default path to executable file of Miranda NG is used. |
Ergebnis
Typ: light userdata
Returns icon handle if icon was registered successfully, otherwise nil
.
Beispiel
local hIcon = icolib.AddIcon('iconUniqueName', 'My super icon')
GetIcon
Returns icon handle.
Parameter
Parametername | Benötigt | Typ | Beschreibung |
---|---|---|---|
name | Ja | string
|
Unique icon name. |
Ergebnis
Typ: boolean
Returns icon handle if icon was found, otherwise nil
.
Beispiel
if icolib.GetIcon('iconUniqueName') then
print('Icon iconUniqueName exists')
end
GetIconHandle
RemoveIcon
Removes an icon.
Parameter
Parametername | Benötigt | Typ | Beschreibung |
---|---|---|---|
name | Ja | string
|
Unique icon name. |
Beispiel
icolib.RemoveIcon('iconUniqueName')