Skip to content

Commit

Permalink
Merge pull request #8 from fakoua/coding-style
Browse files Browse the repository at this point in the history
Improved jdoc
  • Loading branch information
fakoua authored Dec 23, 2023
2 parents 1374f26 + b4aea40 commit 49bff1e
Showing 1 changed file with 9 additions and 7 deletions.
16 changes: 9 additions & 7 deletions mod.ts
Original file line number Diff line number Diff line change
Expand Up @@ -83,21 +83,21 @@ export async function unmute(): Promise<number> {
* import * as swissKnife from "https://deno.land/x/swissKnife/mod.ts"
* await swissKnife.screenshot("c:\\myfolder\\myfile.png")
* ```
*
*
* @example
* ```ts
* //take a screenshot of both screens
* import * as swissKnife from "https://deno.land/x/swissKnife/mod.ts"
* let res = await swissKnife.screenshot("c:\\myfolder\\myfile.png", "Dual")
* ```
*
*
* @example
* ```ts
* //Also you can specify the current active window
* import * as swissKnife from "https://deno.land/x/swissKnife/mod.ts"
* let res = await swissKnife.screenshot("c:\\myfolder\\myfile.png", "Window")
* ```
*
*
* @example
* ```ts
* //The third parameter allows you to specify the coordinates, width and height of the area
Expand Down Expand Up @@ -259,6 +259,7 @@ export async function notification(title: string, text: string, icon = 77, timeo
return exitCode
}


/**
* Window Actions
* @example
Expand All @@ -267,10 +268,11 @@ export async function notification(title: string, text: string, icon = 77, timeo
* //flash any window with title containing 'untit'
* await swissKnife.winAction("Untit", "Contains", "Flash")
* ```
* @param winTitle Window title to control (example: notepad, calc ...)
* @param find Find mode for window title (Equals, Contains, StartsWith, EndsWith)
* @param action Close, Hide, Flash, Max, Min ...
* @returns the process exit code
* @async
* @param {string} winTitle Window title to control (example: notepad, calc ...)
* @param {Find} find Find mode for window title (Equals, Contains, StartsWith, EndsWith)
* @param {WinActions} action Close, Hide, Flash, Max, Min ...
* @returns {Promise<number>}
*/
export async function winAction(winTitle: string, find: Find, action: WinActions): Promise<number> {
let findStr = ""
Expand Down

0 comments on commit 49bff1e

Please sign in to comment.