Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
Synchronet
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Container registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Main
Synchronet
Commits
7e9a4f86
Commit
7e9a4f86
authored
1 year ago
by
Rob Swindell
Browse files
Options
Downloads
Patches
Plain Diff
Add some detials to JSDOCS for global methods: log, word_wrap, lfexpand
parent
4a0d83d7
No related branches found
No related tags found
No related merge requests found
Pipeline
#5065
passed
1 year ago
Stage: build
Changes
2
Pipelines
1
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
src/sbbs3/js_global.c
+3
-2
3 additions, 2 deletions
src/sbbs3/js_global.c
src/sbbs3/main.cpp
+3
-3
3 additions, 3 deletions
src/sbbs3/main.cpp
with
6 additions
and
5 deletions
src/sbbs3/js_global.c
+
3
−
2
View file @
7e9a4f86
...
@@ -4925,7 +4925,7 @@ static jsSyncMethodSpec js_global_functions[] = {
...
@@ -4925,7 +4925,7 @@ static jsSyncMethodSpec js_global_functions[] = {
,
310
,
310
},
},
{
"lfexpand"
,
js_lfexpand
,
1
,
JSTYPE_STRING
,
JSDOCSTR
(
"text"
)
{
"lfexpand"
,
js_lfexpand
,
1
,
JSTYPE_STRING
,
JSDOCSTR
(
"text"
)
,
JSDOCSTR
(
"Expand line-feeds (LF) to carriage-return/line-feeds (CRLF), returns modified string"
)
,
JSDOCSTR
(
"Expand
sole
line-feeds (LF) to carriage-return/line-feed
sequence
s (CRLF), returns modified string"
)
,
310
,
310
},
},
{
"wildmatch"
,
js_wildmatch
,
2
,
JSTYPE_BOOLEAN
,
JSDOCSTR
(
"[<i>bool</i> case_sensitive=false,] filename [,pattern='*'] [,path=false]"
)
{
"wildmatch"
,
js_wildmatch
,
2
,
JSTYPE_BOOLEAN
,
JSDOCSTR
(
"[<i>bool</i> case_sensitive=false,] filename [,pattern='*'] [,path=false]"
)
...
@@ -5126,7 +5126,8 @@ static jsSyncMethodSpec js_global_functions[] = {
...
@@ -5126,7 +5126,8 @@ static jsSyncMethodSpec js_global_functions[] = {
{
"word_wrap"
,
js_word_wrap
,
1
,
JSTYPE_STRING
,
JSDOCSTR
(
"text [,line_length=79 [,orig_line_length=79 [,<i>bool</i> handle_quotes=true [,<i>bool</i> is_utf8=false]]]]"
)
{
"word_wrap"
,
js_word_wrap
,
1
,
JSTYPE_STRING
,
JSDOCSTR
(
"text [,line_length=79 [,orig_line_length=79 [,<i>bool</i> handle_quotes=true [,<i>bool</i> is_utf8=false]]]]"
)
,
JSDOCSTR
(
"Return a word-wrapped version of the <i>text</i> string argument optionally handing quotes magically, "
,
JSDOCSTR
(
"Return a word-wrapped version of the <i>text</i> string argument optionally handing quotes magically, "
"<i>line_length</i> defaults to <i>79</i>, <i>orig_line_length</i> defaults to <tt>79</tt>, "
"<i>line_length</i> defaults to <i>79</i>, <i>orig_line_length</i> defaults to <tt>79</tt>, "
"<i>handle_quotes</i> defaults to <tt>true</tt>, and <i>is_utf8</i> defaults to <tt>false</tt>"
)
"<i>handle_quotes</i> defaults to <tt>true</tt>, and <i>is_utf8</i> defaults to <tt>false</tt>"
"<p>Note: if the original text does not contain any carriage-return (CR) characters, lines are wrapped with sole line-feed (LF) characters."
)
,
311
,
311
},
},
{
"quote_msg"
,
js_quote_msg
,
1
,
JSTYPE_STRING
,
JSDOCSTR
(
"text [,line_length=79] [,prefix=
\"
>
\"
]"
)
{
"quote_msg"
,
js_quote_msg
,
1
,
JSTYPE_STRING
,
JSDOCSTR
(
"text [,line_length=79] [,prefix=
\"
>
\"
]"
)
...
...
This diff is collapsed.
Click to expand it.
src/sbbs3/main.cpp
+
3
−
3
View file @
7e9a4f86
...
@@ -1217,8 +1217,8 @@ js_prompt(JSContext *cx, uintN argc, jsval *arglist)
...
@@ -1217,8 +1217,8 @@ js_prompt(JSContext *cx, uintN argc, jsval *arglist)
static
jsSyncMethodSpec
js_global_functions
[]
=
{
static
jsSyncMethodSpec
js_global_functions
[]
=
{
{
"log"
,
js_log
,
1
,
JSTYPE_STRING
,
JSDOCSTR
(
"[<i>number</i> level=LOG_INFO,] value [,value]"
)
{
"log"
,
js_log
,
1
,
JSTYPE_STRING
,
JSDOCSTR
(
"[<i>number</i> level=LOG_INFO,] value [,value]"
)
,
JSDOCSTR
(
"Add a line of text to the server and/or system log
,
"
,
JSDOCSTR
(
"Add a line of text to the server and/or system log
.<br>
"
"<i>values</i> are typically string constants or variables
,
"
"<i>values</i> are typically string constants or variables
(each logged as a separate log message),<br>
"
"<i>level</i> is the severity of the message to be logged, one of the globally-defined values, in decreasing severity:<br>"
"<i>level</i> is the severity of the message to be logged, one of the globally-defined values, in decreasing severity:<br>"
"<tt>LOG_EMERG, LOG_ALERT, LOG_CRIT, LOG_ERR, LOG_WARNING, LOG_NOTICE, LOG_INFO, and LOG_DEBUG</tt> (default: <tt>LOG_INFO</tt>)"
)
"<tt>LOG_EMERG, LOG_ALERT, LOG_CRIT, LOG_ERR, LOG_WARNING, LOG_NOTICE, LOG_INFO, and LOG_DEBUG</tt> (default: <tt>LOG_INFO</tt>)"
)
,
311
,
311
...
@@ -1246,7 +1246,7 @@ static jsSyncMethodSpec js_global_functions[] = {
...
@@ -1246,7 +1246,7 @@ static jsSyncMethodSpec js_global_functions[] = {
,
311
,
311
},
},
{
"printf"
,
js_printf
,
1
,
JSTYPE_STRING
,
JSDOCSTR
(
"<i>string</i> format [,value][,value]"
)
{
"printf"
,
js_printf
,
1
,
JSTYPE_STRING
,
JSDOCSTR
(
"<i>string</i> format [,value][,value]"
)
,
JSDOCSTR
(
"Send a C-style formatted string of text to the output stream"
)
,
JSDOCSTR
(
"Send a C-style formatted string of text to the output stream
. See also the <tt>format()</tt> function.
"
)
,
310
,
310
},
},
{
"alert"
,
js_alert
,
1
,
JSTYPE_VOID
,
JSDOCSTR
(
"value"
)
{
"alert"
,
js_alert
,
1
,
JSTYPE_VOID
,
JSDOCSTR
(
"value"
)
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment