YaST2 Developers Documentation: yast2



functions
files
intro

yast2

modules/HTML.ycp
Generic HTML formatting
Note: Inline doc uses [tag]...[/tag] instead of ... to avoid confusing "ycpdoc".

Global Functions

global Para (string text) -> string

Make a HTML paragraph from a text, i.e. embed a text into [p]...[/p]

Parameters:
text plain text or HTML fragment
Return value:
HTML code

global Heading (string text) -> string

Make a HTML heading from a text, i.e. embed a text into [h3]...[/h3] Note: There is only one heading level here since we don't have any more fonts anyway.

Parameters:
text plain text or HTML fragment
Return value:
HTML code

global Link (string text, string link_id) -> string

Make a HTML link, i.e. [a href="..."]...[/a] You still need to embed that into a paragraph or heading etc.!

Parameters:
text (translated) text the user will see
link_id internal ID of that link returned by UserInput()
Return value:
HTML code

global ListStart () -> string

Start a HTML (unsorted) list, i.e. [ul] You might consider using HTML::list() instead which takes a list of items and does all the rest by itself.

Return value:
HTML code

global ListEnd () -> string

End a HTML (unsorted) list, i.e. [/ul] You might consider using HTML::list() instead which takes a list of items and does all the rest by itself.

Return value:
HTML code

global ListItem (string text) -> string

Make a HTML list item, i.e. embed a text into [li][p]...[/p][/li] You might consider using HTML::list() instead which takes a list of items and does all the rest by itself.

Parameters:
text plain text or HTML fragment
Return value:
HTML code

global List (list<string> items) -> string

Make a HTML (unsorted) list from a list of strings, i.e. [ul] [li]...[/li] [li]...[/li] ... [/ul]

Parameters:
items list of strings for items
Return value:
HTML code

global ColoredList (list<string> items, string color) -> string

Make a HTL (unsorted) colored list from a list of strings, i.e. [ul] [li][font color="..."]...[/font][/li] [li][font color="..."]...[/font][/li] ... [/ul]

Parameters:
items list of strings for items
color item color
Return value:
HTML code

global Colorize (string text, string color) -> string

Colorize a piece of HTML code, i.e. embed it into [font color="..."]...[/font] You still need to embed that into a paragraph or heading etc.!

Parameters:
text text to colorize
color item color
Return value:
HTML code

global Bold (string text) -> string

Make a piece of HTML code bold, i.e. embed it into [b]...[/b] You still need to embed that into a paragraph or heading etc.!

Parameters:
text text to make bold
Return value:
HTML code

global Newline () -> string

Make a forced HTML line break, i.e. [br]

Return value:
HTML code

global Newlines (integer count) -> string

Make a number of forced HTML line breaks, i.e. [br]

Parameters:
count how many of them
Return value:
HTML code

YaST2 Developers Documentation