From 9229e71a46d038be8d501f0f261ce5771740e8b2 Mon Sep 17 00:00:00 2001 From: Mahmoud Gomaa Date: Mon, 20 Dec 2021 20:29:05 +0200 Subject: [PATCH] Add files via upload --- docs/Functions/Msg.cshtml | 11 +- docs/Functions/Path.cshtml | 8 + docs/Functions/Str.cshtml | 378 ++++++++++++++++++++----------------- docs/Functions/Sys.cshtml | 9 +- docs/Syntax/Dynamic.cshtml | 15 +- docs/Syntax/Index.cshtml | 10 + docs/Syntax/Static.cshtml | 8 +- docs/Syntax/default.cshtml | 42 +++++ docs/_DocsLayout.cshtml | 1 + 9 files changed, 301 insertions(+), 181 deletions(-) create mode 100644 docs/Syntax/default.cshtml diff --git a/docs/Functions/Msg.cshtml b/docs/Functions/Msg.cshtml index 52c0c70..572cff0 100644 --- a/docs/Functions/Msg.cshtml +++ b/docs/Functions/Msg.cshtml @@ -114,4 +114,13 @@ If the function succeeds, the return value is one of the following values:
Examples
msg("Hello, Warld!","NileSoft Shell", msg.info | msg.ok)
msg("Hello, Warld!","NileSoft Shell")
-msg("Hello, Warld!")
\ No newline at end of file +msg("Hello, Warld!") +

+
+
msg.beep(type)
+

Plays a waveform sound. The waveform sound for each sound type is identified by an entry in the registry.

+

Syntax

+ sys.beep
+ sys.beep(msg.error)
+ sys.beep(msg.warning) +
\ No newline at end of file diff --git a/docs/Functions/Path.cshtml b/docs/Functions/Path.cshtml index 74b4073..b5642c0 100644 --- a/docs/Functions/Path.cshtml +++ b/docs/Functions/Path.cshtml @@ -179,4 +179,12 @@ path.getknownfolder('{905e63b6-c1bf-494e-b29c-65b732d3d21a}') +
+
path.separator(path.sep)
+

Replacing the back slash with a forward slash or defining a spacer.

+

Syntax

+ path.separator('c:\windows\system32') return "c:/windows/system32"
+ path.separator('c:\windows\system32', '#') return "c:#windows#system32" +
+ diff --git a/docs/Functions/Str.cshtml b/docs/Functions/Str.cshtml index 049b282..27eaba1 100644 --- a/docs/Functions/Str.cshtml +++ b/docs/Functions/Str.cshtml @@ -1,176 +1,202 @@ -@page -@{ - ViewData["page-support"] = "Functions \\ STR"; -} -
STR
-
-
-
str.get (str.at)
-

Returns a character from a specific location in the string.

-

Syntax

- str.get("Hello World!", 7) -
-
-
str.set
-

Sets a character with a specific location in the string.

-

Syntax

- str.set("Hello World!", 6, '-') -
-
-
str.contains
-

Returns a value indicating whether a specified substring occurs within this string.

-

Syntax

- str.contains("Hello World!", 'World') -
-
-
str.empty (str.null)
-

Tests whether the string contains characters.

-

Syntax

- str.empty("") -
-
-
str.start
-

Checks whether the string starts with the specified prefix.

-

Syntax

- str.start("Hello World!", "World!") -
-
-
str.end
-

Checks whether the string ends with the specified suffix.

-

Syntax

- str.end("Hello World!", "World!") -
-
-
str.equals
-

Determines whether two String have the same value.

-

Syntax

- str.equals("Hello World!", "Hello World!") -
-
-
str.not
-

Determine if two strings do not have the same value.

-

Syntax

- str.not("Hello World!", "Hello-World!") -
-
-
str.length (str.len)
-

Gets the number of characters in the current string.

-

Syntax

- str.length("Hello World!") -
-
-
str.trim
-

Returns a new string in which all leading and trailing occurrences of a set of specified characters from the current string are removed.

-

Syntax

-

Removes all leading and trailing white-space characters from the current string.

- str.trim(" Hello World! ")

-

Removes all leading and trailing 'H!' characters from the current string.

- str.trim("Hello World!", "H!") -
-
-
str.trimstart
-

Returns a new string in which all leading occurrences of a set of specified characters from the current string are removed.

-

Syntax

-

Removes all leading white-space characters from the current string.

- str.trimstart(" Hello World!")
- -

Removes all leading 'H' characters from the current string.

- str.trimstart("Hello World!", "H") -
-
-
str.trimend
-

Returns a new string in which all trailing occurrences of a set of specified characters from the current string are removed.

-

Syntax

-

Removes all trailing white-space characters from the current string.

- str.trimend("Hello World! ")
- -

Removes all trailing '!' characters from the current string.

- str.trimend("Hello World!", "!") -
-
-
str.find
-

Searches a string in a forward direction for the first occurrence of a substring that matches a specified sequence of characters.

-

Syntax

- str.find("Hello World!", "lo") -
-
-
str.findlast
-

Searches a string in a backward direction for the first occurrence of a substring that matches a specified sequence of characters.

-

Syntax

- str.findlast("Hello World!", "Wor") -
-
-
str.lower
-

Returns a copy of this string converted to lowercase.

-

Syntax

- str.lower("Hello World!") -
-
-
str.upper
-

Returns a copy of this string converted to uppercase.

-

Syntax

- str.upper("Hello World!") -
-
-
str.left
-

Extracts the left part of a string.

-

Syntax

- str.left("Hello World!", 5) -
-
-
str.right
-

Extracts the right part of a string.

-

Syntax

- str.right("Hello World!", 5) -
-
-
str.sub
-

Copies a substring of at most some number of characters from a string beginning from a specified position.

-

Syntax

- str.sub("Hello World!", 5)
- str.sub("Hello World!", 0, 5) -
-
-
str.remove
-

Removes an element or a range of elements in a string from a specified position.

-

Syntax

- str.remove("Hello World!", " ")
str.remove("Hello World!", 5)
- str.remove("Hello World!", 5, 1) -
-
-
str.replace
-

Replace elements in a string at a specified position with specific characters or characters copied from other ranges or strings.

-

Syntax

- str.replace("Hello World!", "World", "User")
str.replace("Hello World!", "world", "user", true) -
-
-
str.padleft
-

Returns a new string of a specified length in which the beginning of the current string is padded with spaces or with a specified character.

-

Syntax

- str.padleft("Hello World!", "*")
str.padleft("Hello World!", "*", 3) -
-
-
str.padright
-

Returns a new string of a specified length in which the end of the current string is padded with spaces or with a specified character.

-

Syntax

- str.padright("Hello World!", "*")
str.padright("Hello World!", "*", 3) -
-
-
str.padding
-

Returns a new string of a specified length in which the start and end of the current string is padded with spaces or with a specified character.

-

Syntax

- str.padding("Hello World!", "*")
str.padding("Hello World!", "*", 3) -
- -@*
-
str.format
-

Formats the string as sprintf does.

-

Syntax

- str.format("Hello %s!", "World")
str.format("Hello World!", "*", 3) -
*@ +@page +@{ + ViewData["page-support"] = "Functions \\ STR"; +} +
STR
+
+
+
str.get (str.at)
+

Returns a character from a specific location in the string.

+

Syntax

+ str.get("Hello World!", 7) +
+
+
str.set
+

Sets a character with a specific location in the string.

+

Syntax

+ str.set("Hello World!", 6, '-') +
+
+
str.contains
+

Returns a value indicating whether a specified substring occurs within this string.

+

Syntax

+ str.contains("Hello World!", 'World') +
+
+
str.empty (str.null)
+

Tests whether the string contains characters.

+

Syntax

+ str.empty("") +
+
+
str.start
+

Checks whether the string starts with the specified prefix.

+

Syntax

+ str.start("Hello World!", "World!") +
+
+
str.end
+

Checks whether the string ends with the specified suffix.

+

Syntax

+ str.end("Hello World!", "World!") +
+
+
str.equals
+

Determines whether two String have the same value.

+

Syntax

+ str.equals("Hello World!", "Hello World!") +
+
+
str.not
+

Determine if two strings do not have the same value.

+

Syntax

+ str.not("Hello World!", "Hello-World!") +
+
+
str.length (str.len)
+

Gets the number of characters in the current string.

+

Syntax

+ str.length("Hello World!") +
+
+
str.trim
+

Returns a new string in which all leading and trailing occurrences of a set of specified characters from the current string are removed.

+

Syntax

+

Removes all leading and trailing white-space characters from the current string.

+ str.trim(" Hello World! ")

+

Removes all leading and trailing 'H!' characters from the current string.

+ str.trim("Hello World!", "H!") +
+
+
str.trimstart
+

Returns a new string in which all leading occurrences of a set of specified characters from the current string are removed.

+

Syntax

+

Removes all leading white-space characters from the current string.

+ str.trimstart(" Hello World!")
+ +

Removes all leading 'H' characters from the current string.

+ str.trimstart("Hello World!", "H") +
+
+
str.trimend
+

Returns a new string in which all trailing occurrences of a set of specified characters from the current string are removed.

+

Syntax

+

Removes all trailing white-space characters from the current string.

+ str.trimend("Hello World! ")
+ +

Removes all trailing '!' characters from the current string.

+ str.trimend("Hello World!", "!") +
+
+
str.find
+

Searches a string in a forward direction for the first occurrence of a substring that matches a specified sequence of characters.

+

Syntax

+ str.find("Hello World!", "lo") +
+
+
str.findlast
+

Searches a string in a backward direction for the first occurrence of a substring that matches a specified sequence of characters.

+

Syntax

+ str.findlast("Hello World!", "Wor") +
+
+
str.lower
+

Returns a copy of this string converted to lowercase.

+

Syntax

+ str.lower("Hello World!") +
+
+
str.upper
+

Returns a copy of this string converted to uppercase.

+

Syntax

+ str.upper("Hello World!") +
+
+
str.left
+

Extracts the left part of a string.

+

Syntax

+ str.left("Hello World!", 5) +
+
+
str.right
+

Extracts the right part of a string.

+

Syntax

+ str.right("Hello World!", 5) +
+
+
str.sub
+

Copies a substring of at most some number of characters from a string beginning from a specified position.

+

Syntax

+ str.sub("Hello World!", 5)
+ str.sub("Hello World!", 0, 5) +
+
+
str.remove
+

Removes an element or a range of elements in a string from a specified position.

+

Syntax

+ str.replace("Hello World!", " ")
+ str.remove("Hello World!", 5)
+ str.remove("Hello World!", 5, 1) +
+
+
str.replace
+

Replace elements in a string at a specified position with specific characters or characters copied from other ranges or strings.

+

Syntax

+ str.replace("Hello World!", "World", "User")
+ str.replace("Hello World!", "world", "user", true) +
+
+
str.padleft
+

Returns a new string of a specified length in which the beginning of the current string is padded with spaces or with a specified character.

+

Syntax

+ str.padleft("Hello World!", "*")
+ str.padleft("Hello World!", "*", 3) +
+
+
str.padright
+

Returns a new string of a specified length in which the end of the current string is padded with spaces or with a specified character.

+

Syntax

+ str.padright("Hello World!", "*")
+ str.padright("Hello World!", "*", 3) +
+
+
str.padding
+

Returns a new string of a specified length in which the start and end of the current string is padded with spaces or with a specified character.

+

Syntax

+ str.padding("Hello World!", "*")
+ str.padding("Hello World!", "*", 3) +
+ +
+
str.guid
+

Returns a new guid string

+

Syntax

+ str.guid return 00000000000000000000000000000000
+ str.guid(1) return 00000000-0000-0000-0000-000000000000
+ str.guid(2) return {00000000-0000-0000-0000-000000000000}
+ str.guid(3) return (00000000-0000-0000-0000-000000000000)
+
+ +
+
str.capitalize
+

Returns a new capitalize string

+

Syntax

+ str.capitalize('hello world') return "Hello World"
+
+ +
+
str.res
+

Returns a string resource from the executable file. "shell32.dll" is the default file.

+

Syntax

+ str.res(-4640) return "Runs the selected command with elevation" from "shell32.dll"
+ str.res('explorer.dll', -22000) return "Desktop"
+
+ +@* +
+
str.format
+

Formats the string as sprintf does.

+

Syntax

+ str.format("Hello %s!", "World")
str.format("Hello World!", "*", 3) +
*@ diff --git a/docs/Functions/Sys.cshtml b/docs/Functions/Sys.cshtml index f35e0ae..d3db617 100644 --- a/docs/Functions/Sys.cshtml +++ b/docs/Functions/Sys.cshtml @@ -99,8 +99,15 @@ sys.users sys.wow +
+
sys.beep(milliseconds)
+

Suspends the execution of the current thread until the time-out interval elapses.

+

Syntax

+ sys.sleep(1000) +
+
@*sys.copy
 sys.extended*@
 sys.toggleext
 sys.togglehidden
-sys.beep
+ diff --git a/docs/Syntax/Dynamic.cshtml b/docs/Syntax/Dynamic.cshtml index 63282f3..0b04acf 100644 --- a/docs/Syntax/Dynamic.cshtml +++ b/docs/Syntax/Dynamic.cshtml @@ -32,10 +32,16 @@ + + Where + Allow menu item to be passed if a true value is returned
+ Default = true + + Title Sets a value indicating the caption of the menuitem.
-

This property must be included with menu and item, not required for separator.

+

This property must be included with menu and item if image propery is not defined, not required for separator.

Default = null

Required for menu, item.

@@ -377,7 +383,12 @@

Required for item.

+ + Column(col) +

Create a new column.

+ Default = true +

Required for item, menu.

+ -

The title property must include at least the following types of (menu or item).

diff --git a/docs/Syntax/Index.cshtml b/docs/Syntax/Index.cshtml index 112ff2d..d763d0b 100644 --- a/docs/Syntax/Index.cshtml +++ b/docs/Syntax/Index.cshtml @@ -10,6 +10,8 @@
  • Syntax are not case sensitive.
  • Spaces around the equal (=) sign are optional and are ignored.
  • The properties of static and dynamic items are separated by blank spaces or on a separate line and must be placed in parentheses ( ).
  • +
  • variable are optional.
  • +
  • default are optional.
  • Static items are optional.
  • Static items have one type: item.
  • Dynamic items are optional.
  • @@ -32,6 +34,14 @@ varabiles can be placed in the var, or in the dynamic body section of an menu, o ... } + default + { + // defaults content + default-name = default-value + default-name = [default-value, default-value, ...] + ... + } + // static items static { diff --git a/docs/Syntax/Static.cshtml b/docs/Syntax/Static.cshtml index 3a8346d..12a0be5 100644 --- a/docs/Syntax/Static.cshtml +++ b/docs/Syntax/Static.cshtml @@ -27,10 +27,16 @@ ViewData["title"] = "Static Items"; + + Where + Allow menu item to be passed if a true value is returned
    + Default = true + + Find Accept menuitem when the specific menuitem title is contains or equal to the current find property.
    Use this delimiter | to separate patterns. -

    This property must be included with another property at least.

    +

    This property must be included with another property at least if where property is not defined.

    Default = null diff --git a/docs/Syntax/default.cshtml b/docs/Syntax/default.cshtml new file mode 100644 index 0000000..04795a5 --- /dev/null +++ b/docs/Syntax/default.cshtml @@ -0,0 +1,42 @@ +@page +@{ + ViewData["title"] = "Default"; + ViewData["page-support"] = "Default"; +} +

    Default

    +

    +

    Default are containers for storing default values.

    + +
    shell 
    +{
    +    default
    +    {
    +        // view = auto, compact, small, medium, large, wide
    +        view = view.compact
    +        
    +        // theme = auto, dark, light, white, black
    +        theme = theme.black
    +        
    +        // text = [normal, hover, disabled]
    +        text = [#ffffff, default, #808080]
    +        
    +        // block = [normal, hover, radius]
    +        block = [#000, #444, 5]
    +
    +        // separator = [color, size]
    +        separator = [#ff00ff, 1]
    +        
    +        // frame = [border color, border size]
    +        frame = [#000, 3]
    +        
    +        // font = [size, font name]
    +        font = [12, 'Brush Script']
    +       
    +        // Chevron, Check Mark, Radio Bullet
    +        symbol = #ff0000
    +       
    +        // Enable/Disable drop shadow
    +        shadow = false
    +    }
    +}
    + diff --git a/docs/_DocsLayout.cshtml b/docs/_DocsLayout.cshtml index f90ab33..3551d08 100644 --- a/docs/_DocsLayout.cshtml +++ b/docs/_DocsLayout.cshtml @@ -21,6 +21,7 @@ Items = new TreeListItem[] { new TreeListItem { Title = "Variables", Link= "variables" }, + new TreeListItem { Title = "default", Link = "default" }, new TreeListItem { Title = "Static", Link = "static" }, new TreeListItem { Title = "Dynamic", Link = "dynamic" } }