From dce948f1812ea079e571d922c16c41dd46a6779e Mon Sep 17 00:00:00 2001
From: Mahmoud Gomaa The namespace of the application contains file paths, version and some details.
+ APP
-
-app.about
-app.cfg
-app.directory(dir)
-app.dll
-app.exe
-app.is64
-app.name
-app.reload
-app.unload
-app.version(var)
-
\ No newline at end of file
+
+
+app.directory (app.dir)
+ Returns the path of Shell directory.
+
+
+
+
+
+
+
+
+
+
Color namespace contains predefined colors
+color.default color.accent diff --git a/docs/Functions/IO.cshtml b/docs/Functions/IO.cshtml index ba8d620..30d4e39 100644 --- a/docs/Functions/IO.cshtml +++ b/docs/Functions/IO.cshtml @@ -3,11 +3,11 @@ ViewData["page-support"] = "Functions \\ IO"; }+IO
-- Documentation under construction. ---io.attribute.archive ++ +
++ io.attribute enumerations.
+Syntax
++io.attribute.virtualio.attribute.archive io.attribute.compressed io.attribute.device io.attribute.directory @@ -20,21 +20,115 @@ io.attribute.readonly io.attribute.sparsefile io.attribute.system io.attribute.temporary -io.attribute.virtual -io.attributes -io.copy -io.delete -io.directory -io.dir.make -io.file.append -io.file.create -io.file.make -io.file.read -io.file.size -io.file.write -io.move -io.rename -+ +io.attributes
+Retrieves file system attributes for a specified path.
+Syntax
+io.attributes(path)
+attribute verification
++// check if path is hidden +io.attribute.hidden(path) + +// check if path is directory +io.attribute.directory(path) + +var { atrr = io.attributes(path) } + +// check if attr is hidden +io.attribute.hidden(atrr) + +// check if attr is directory +io.attribute.directory(atrr)+ +io.copy
+Copies an existing file to a new file.
+Syntax
+io.copy(pathFrom, pathTo)++ +io.move
+Moves an existing file or a directory, including its children..
+Syntax
+io.move(oldPath, newPath)++ +io.rename
+Rename a file or directory.
+Syntax
+io.rename(oldName, newName)++ +io.delete
+Deletes an existing path.
+Syntax
+io.delete(path)++ +io.directory.create (io.dir.create)
+Create new directory.
+Syntax
+io.directory.create(path)++ +io.directory.exists (io.dir.exists)
+Check if one or more directories exists.
+Syntax
+io.directory.exists(path)+
+io.directory.exists(path1, path2, path3, ...)++ +io.directory.empty (io.dir.empty)
+Check if one or more directory is empty.
+Syntax
+io.directory.empty(path)+
+io.directory.empty(path1, path2, path3, ...)+File functions.
++ +io.file.size
+Retrieves the size of the specified file, in bytes.
+Syntax
+io.file.size(path)++ +io.file.exists
+Check if one or more files exists.
+Syntax
+io.file.exists(path)+
+io.file.exists(path1, path2, path3, ...)++ +io.file.read
+Read file contents as text with character count option.
+Syntax
+io.file.read(path)
+io.file.read(path, 12)++ +io.file.create
+Create new file with content option.
+Syntax
+io.file.create(path)
+io.file.create(path, "Hello World!")++ +io.file.write
+Writing to a file with new content.
+Syntax
+io.file.write(path, "Hello World!")++ -@*If the help function is passed without an argument, then the interactive help utility starts up on the console. -The help function has the following syntax:*@ \ No newline at end of file diff --git a/docs/Functions/Image.cshtml b/docs/Functions/Image.cshtml index 2ac8c96..5925f3f 100644 --- a/docs/Functions/Image.cshtml +++ b/docs/Functions/Image.cshtml @@ -1,20 +1,49 @@ @page @{ - ViewData["page-support"] = "Functions \\ APP"; + ViewData["title"] = "Functions"; + ViewData["page-support"] = "Functions \\ Image"; } -io.file.append
+Appends text to an existing file, or to a new file if the specified file does not exist.
+Syntax
+io.file.append(path, "Hello ")+
+io.file.append(path, "World!")+APP
-- Documentation under construction. -+IMAGE (DRAW)
+The image namespace contains functions that return an icon and are only assigned to the
+imageproperty+ +image.glyph
+Return font icon with color and size option.
+Syntax
+image.glyph(0xE00B)
+image.glyph("\uE00B")
+image.glyph("\xE00B")
+
+image.glyph(0xE00B, #0000ff)
+image.glyph(0xE00B, #0000ff, 10)
+image.glyph(0xE00B, #0000ff, 12, "Segoe MDL2 Assets")
++ +image.icon
+Returns an icon through a path or through resources.
+Syntax
+image.icon(path)
+image.icon(path, index)
+image.icon(path, -id)
+
+image(path)
+image(path, index)
+image(path, -id)
++ + +@*image.rect
+Returns a colored rectangle icon of an optional size.
+Syntax
+image.rect(#0000ff)
+image.rect(#0000ff, 10)
+-app.about -app.cfg -app.directory(dir) -app.dll -app.exe -app.is64 -app.name -app.reload -app.unload -app.version(ver) +image.res +image.str +image.symbol +draw.str +draw.symbol +draw.circle+*@ \ No newline at end of file diff --git a/docs/Functions/Index.cshtml b/docs/Functions/Index.cshtml index 71ece41..62a3921 100644 --- a/docs/Functions/Index.cshtml +++ b/docs/Functions/Index.cshtml @@ -1,45 +1,137 @@ @page @{ + ViewData["title"] = "Functions"; ViewData["page-support"] = "Functions"; }Functions
-- Documentation under construction. -The functions and variables have unique titles described by fully qualified names that indicate a logical hierarchy.
Shell has a number of functions and variables built into it that are always available. They are listed here in alphabetical order.
-
Conditionally executes another statement.
+Syntax
+if(condition-expression)if(condition-expression, true-expression)if(condition-expression, true-expression, false-expression)
+Returns a null value.
+Syntax
+null(expression)Returns text with a double quotation mark.
+Syntax
+quote(expression)
+Returns the value of the numeric parameter to a character.
+Syntax
+char(numeric-expression)
+Returns the value of the passed variable
+Syntax
+var(expression)
+Converting the value of the passed numeric expression to hexadecimal string.
+Syntax
+tohex(numeric-expression)
+Returns true if the parameters passed are equal.
Syntax
+equal(expression-1, expression-2)
+Returns true if the parameters passed are not equal.
Syntax
+not(expression-1, expression-2)
+Returns true if the first parameter is greater than the second parameter.
Syntax
+greater(expression-1, expression-2)
+Returns true if the first parameter is less than the second parameter.
Syntax
+less(expression-1, expression-2)
+bitwise left shift.
+Syntax
+shl(shift-expression, additive-expression)
+bitwise right shift.
+Syntax
+shr(shift-expression, additive-expression)
+The flags that specify how an application is to be displayed when it is opened.
+cmd.hidden
+cmd.show
+cmd.visible
+cmd.normal
+cmd.maximized
+cmd.minimized
+Syntax
+mode.none
+mode.single
+mode.multiple
+mode.multiunique
+mode.multisingle
+mode.multi
+
+Syntax
+type.desktop
+type.directory(dir)
+type.drive
+type.dvd
+type.file
+type.fixed
+type.namespace
+type.remote
+type.unknown
+type.usb
+type.vhd
+null
+bool
+true
+false
+auto
+none
+default
+
+@*
-if for foreach -equal -greater -less -shl -shr -char -not -print -quote -tohex -null -var- -
break continue @@ -51,6 +143,8 @@ auto none inherit parent +before +after both top bottom @@ -60,52 +154,9 @@ show visible minimized maximized -vis.disable -vis.hidden - -mode.none -mode.single -mode.multiple -mode.multiunique -mode.multisingle -mode.multi - -type.desktop -type.directory(dir) -type.drive -type.dvd -type.file -type.fixed -type.namespace -type.remote -type.unknown -type.usb -type.vhd - -cmd -cmd.hidden -cmd.show -cmd.visible -cmd.normal -cmd.maximized -cmd.minimized - -draw -draw.rect -draw.str -draw.glyph -draw.symbol -draw.circle - -icon -glyph -image -image.icon -image.res -image.str -image.glyph -image.symbol -image.rect -+*@ + + diff --git a/docs/Functions/Key.cshtml b/docs/Functions/Key.cshtml index 5edc73e..36e14f4 100644 --- a/docs/Functions/Key.cshtml +++ b/docs/Functions/Key.cshtml @@ -3,12 +3,10 @@ ViewData["page-support"] = "Functions \\ KEY"; }
-key -key.alt ++ + +Keyboard functions
++ keys enumerations
++key.winkey.alt key.apps key.back key.cancel @@ -61,6 +59,28 @@ key.snapshot key.space key.tab key.up -key.win -
Syntax
+
+// check if SHIFT key is pressed
+key(key.shift)
+
+// or
+key == key.shift
+
+// or
+key.shift()
+
+// check if tow keys (SHIFT+CTRL+X) is pressed
+key(key.shift, key.control)
+
+// check if keys (SHIFT+CTRL+X) is pressed
+key(key.shift, key.control, 87)
+
+Displays a modal dialog box that contains a system icon, a set of buttons, and a brief application-specific message, such as status or error information. The message box returns an integer value that indicates which button the user clicked.
-path.absolute -path.combine -path.currentdirectory(curdir) -path.directory(dir) -path.directory.box -path.directory.make -path.directory.name -path.directory.title -path.empty -path.exists -path.file -path.file.box -path.file.ext -path.file.name -path.file.title -path.full -path.getknownfolder -path.isabsolute -path.isclsid -path.isdirectory -path.isdrive -path.isexe -path.isfile -path.isnamespace -path.isrelative -path.isroot -path.join -path.lnk -path.lnktarget -path.name -path.parent -path.parent.name -path.relative -path.removeextension -path.root -path.short -path.title -path.type -+
Combines an array of strings into a path.
+Syntax
+path.combine(path1, path2)path.combine("C:", "Windows", "Explorer.exe")
+Retrieves the current directory for the current process.
+Syntax
+path.currentdirectory
+Return the directory name from the path.
+Syntax
+path.directory.name('c:\windows\system32') // returns: system32
+Shows the directory selection box and returns the path of the specified directory.
+Syntax
+path.directory.box
+Check if one or more path is empty.
+Syntax
+path.empty(path)path.empty(path1, path2, ...)
+Check if one or more path exists..
+Syntax
+path.exists(path)path.exists(path1, path2, ...)
+Returns the absolute path for the specified path string.
+Syntax
+path.full(path)
+Retrieves the short path form of the specified path.
+Syntax
+path.short(path)
+Return the name from the path.
+Syntax
+path.name(path)
+Return the path of the parent
+Syntax
+path.location(path)
+Return the name from the parent
+Syntax
+path.location.name(path)
+Return the drive path
+Syntax
+path.root(path)
+Return the title from the path
+Syntax
+path.title(path)
+Return the type of path
+Syntax
+path.type(path) == type.file
+Return the name of path
+Syntax
+path.file.name(path)
+Return the name of path without extension
+Syntax
+path.file.title(path)
+Return the extension of path
+Syntax
+path.file.ext(path)
+Shows the file selection box and returns the path of the specified file.
+Syntax
+path.file.boxpath.file.box('All|*.*|Text|*.txt')path.file.box('exe|*.exe', 'c:\windows')path.file.box('exe|*.exe', 'c:\windows', 'explorer.exe')
+Syntax
+path.isabsolute(path)
+Syntax
+path.isrelative(path)
+Syntax
+path.isfile(path)
+Syntax
+path.isdirectory(path)
+Syntax
+path.isdrive(path)
+Syntax
+path.isclsid(path)
+Syntax
+path.isexe(path)
+Remove the extension from the passed parameter.
+Syntax
+path.removeextension
+Return a path from the shortcut
+Syntax
+path.lnktarget
+Retrieves the full path of a known folder identified.
+Syntax
+path.getknownfolder('{905e63b6-c1bf-494e-b29c-65b732d3d21a}')
+-reg(...) -reg.cr -reg.cu -reg.lm -reg.u -reg.cc -reg.none -reg.sz -reg.expand -reg.binary -reg.multi -reg.dword -reg.qword -\ No newline at end of file +
Registary functions
+Syntax
+reg.cr // HKEY_CLASSES_ROOT
+reg.cu // HKEY_CURRENT_USER
+reg.lm // HKEY_LOCAL_MACHINE
+reg.u // HKEY_USERS
+reg.cc // HKEY_CURRENT_CONFIG
+Syntax
+reg.none // No data type
+reg.sz // REG_SZ
+reg.expand // REG_EXPAND_SZ
+reg.binary // REG_BINARY
+reg.multi // REG_MULTI_SZ
+reg.dword // REG_DWORD
+reg.qword // REG_QWORD
+Syntax
+reg(reg.lm, 'SOFTWARE\Microsoft\Windows NT\CurrentVersion','ProductName')reg(reg.cr, 'txtfile\DefaultIcon')
+Has many functions to handle selected file system objects.
@* has the following syntax:*@ -
false, separator=' ')
0)
diff --git a/docs/Functions/Str.cshtml b/docs/Functions/Str.cshtml index c9cc1e7..049b282 100644 --- a/docs/Functions/Str.cshtml +++ b/docs/Functions/Str.cshtml @@ -1,35 +1,176 @@ -@page -@{ - ViewData["page-support"] = "Functions \\ STR"; -} -
-str.at -str.char -str.contains -str.empty -str.end -str.equals -str.find -str.findlast -str.format -str.left -str.length -str.lower -str.not -str.null -str.padleft -str.padright -str.remove -str.replace -str.right -str.start -str.sub -str.trim -str.trimend -str.trimstart -str.upper -\ No newline at end of file +@page +@{ + ViewData["page-support"] = "Functions \\ STR"; +} +
Returns a character from a specific location in the string.
+Syntax
+str.get("Hello World!", 7)
+Sets a character with a specific location in the string.
+Syntax
+str.set("Hello World!", 6, '-')
+Returns a value indicating whether a specified substring occurs within this string.
+Syntax
+str.contains("Hello World!", 'World')
+Tests whether the string contains characters.
+Syntax
+str.empty("")
+Checks whether the string starts with the specified prefix.
+Syntax
+str.start("Hello World!", "World!")
+Checks whether the string ends with the specified suffix.
+Syntax
+str.end("Hello World!", "World!")
+Determines whether two String have the same value.
+Syntax
+str.equals("Hello World!", "Hello World!")
+Determine if two strings do not have the same value.
+Syntax
+str.not("Hello World!", "Hello-World!")
+Gets the number of characters in the current string.
+Syntax
+str.length("Hello World!")
+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!")
+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")
+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!", "!")
+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")
+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")
+Returns a copy of this string converted to lowercase.
+Syntax
+str.lower("Hello World!")
+Returns a copy of this string converted to uppercase.
+Syntax
+str.upper("Hello World!")
+Extracts the left part of a string.
+Syntax
+str.left("Hello World!", 5)
+Extracts the right part of a string.
+Syntax
+str.right("Hello World!", 5)
+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)
+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, 1)
+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")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!", "*")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!", "*")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!", "*")Formats the string as sprintf does.
+Syntax
+str.format("Hello %s!", "World")-sys.appdata -sys.beep -sys.bin -sys.bin32 -sys.bin64 -sys.copy -sys.dark -sys.datetime +diff --git a/docs/Functions/User.cshtml b/docs/Functions/User.cshtml index 4180820..025fc28 100644 --- a/docs/Functions/User.cshtml +++ b/docs/Functions/User.cshtml @@ -3,15 +3,22 @@ ViewData["page-support"] = "Functions \\ USER"; }+ +sys.name
+Returns Windows name.
+Syntax
+sys.name++ +sys.name
+Returns Windows name.
+Syntax
+sys.name++ +sys.type
+Returns system architecture.
+Syntax
+sys.type++ +sys.type
+Returns system architecture.
+Syntax
+sys.type == 64
+sys.type == 32++ +sys.is64
+Returns if system architecture is x64.
+Syntax
+sys.is64++ +sys.dark
+Check if dark mode is enabled.
+Syntax
+sys.dark++ +sys.var
+Retrieves the value of an environment variable.
+Syntax
+sys.var('WINDIR')++ +sys.version (sys.ver)
+Windows version.
+Syntax
++sys.version +sys.version.build +sys.version.major +sys.version.minor +sys.version.name +sys.version.type+ +sys.datetime
+Date and time format
+Syntax
++sys.datetime sys.datetime.date sys.datetime.date_day sys.datetime.date_dayofweek @@ -30,11 +77,15 @@ sys.datetime.time_min sys.datetime.time_minute sys.datetime.time_ms sys.datetime.time_pm -sys.datetime.time_second -sys.directory(dir) -sys.extended -sys.is64 -sys.name +sys.datetime.time_second+ + +Windows paths
++sys.appdata +sys.bin +sys.bin32 +sys.bin64 +sys.directory (sys.dir) sys.path sys.prog sys.prog32 @@ -44,17 +95,12 @@ sys.refresh sys.root sys.temp sys.templates +sys.users +sys.wow- +sys.beep@*sys.copy +sys.extended*@ sys.toggleext sys.togglehidden -sys.type -sys.users -sys.var -sys.version(ver) -sys.version.build -sys.version.major -sys.version.minor -sys.version.name -sys.version.type -sys.wow -
-user.home ++ +
++ + +user.name
+Returns the current username.
+Syntax
+user.name++ Functions to return the path of user directories
+Syntax
+\ No newline at end of file +user.videos +user.home user.appdata user.contacts user.desktop -user.directory(dir) +user.directory (user.dir) user.documents user.documentslibrary user.downloads @@ -19,7 +26,6 @@ user.favorites user.libraries user.localappdata user.music -user.name user.personal user.pictures user.profile @@ -28,5 +34,7 @@ user.sendto user.startmenu user.temp user.templates -user.videos -