Skip to content

Commit 29b81b4

Browse files
authored
Merge pull request #892 from boriel-basic/docs
doc: add POINT documentation
2 parents 12789ec + 6e45c2b commit 29b81b4

5 files changed

Lines changed: 53 additions & 5 deletions

File tree

docs/identifier.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -127,7 +127,7 @@ You should also avoid defining (with a SUB or FUNCTION command) routines with th
127127
* **[GetKeyScanCode (Library Function)](library/keys/getkeyscancode.md)** **(function)**
128128
* **[LCase (Library Function)](library/string/lcase.md)** **(function)**
129129
* **[UCase (Library Function)](library/string/ucase.md)** **(function)**
130-
* **[POINT (Library Function)](library/string/point.md)** **(function)**
130+
* **[POINT (Library Function)](library/point.md)** **(function)**
131131
* **[POS (Library Function)](library/pos.md)** **(function)**
132132
* **[print42 (Library Subroutine)](library/print42.bas.md)** **(sub)**
133133
* **[printat42 (Library Subroutine)](library/print42.bas.md)** **(sub)**

docs/library/csrlin.md

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,5 +24,7 @@ CSRLIN is a library function to be included with the following command:
2424

2525
## See also
2626

27-
* [ POS](pos.md)
2827
* [ AT ](../at.md)
28+
* [ SCREEN ](screen.md)
29+
* [ POINT ](point.md)
30+
* [ POS](pos.md)

docs/library/point.md

Lines changed: 43 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,43 @@
1+
# POINT
2+
3+
## Syntax
4+
5+
6+
```
7+
POINT(x, y)
8+
```
9+
10+
## Description
11+
12+
Returns 1 if the pixel at coordinates (x, y) is set. 0 if it is not.
13+
14+
## Requirements
15+
16+
POINT is a library function to be included with the following command:
17+
18+
19+
```
20+
# include <point.bas>
21+
```
22+
23+
## Sample usage
24+
25+
```basic
26+
# include <point.bas>
27+
28+
PLOT 10, 10
29+
PRINT "Point at (10, 10) is "; POINT(10, 10): REM 1
30+
PRINT "Point at (15, 15) is "; POINT(15, 15): REM 0
31+
```
32+
33+
## Remarks
34+
35+
* This function extends the one in Sinclair BASIC (and it's compatible with it) since it also allows rows 22 and 23.
36+
* When using `--sinclair` cmd line parameter this function is already available (i.e. no `#include <point.bas>` sentence is needed)
37+
38+
## See also
39+
40+
* [ AT ](../at.md)
41+
* [ CSRLIN ](csrlin.md)
42+
* [ SCREEN ](screen.md)
43+
* [ POS](pos.md)

docs/library/pos.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,3 +18,5 @@ POS is a library function to be included with the following directive:
1818

1919
* [ AT ](../at.md)
2020
* [ CSRLIN](csrlin.md)
21+
* [ POINT ](point.md)
22+
* [ SCREEN ](screen.md)

docs/library/screen.md

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ SCREEN is a library function to be included with the following command:
2323

2424
## Sample usage
2525

26-
```
26+
```basic
2727
# include <screen.bas>
2828
2929
PRINT AT 9, 10; "A"
@@ -38,6 +38,7 @@ PRINT AT 0, 0; "The character at 9, 10 is "; c$
3838

3939
## See also
4040

41-
* [ CSRLIN ](csrlin_.md)
42-
* [ POS](pos_.md)
4341
* [ AT ](../at.md)
42+
* [ CSRLIN ](csrlin_.md)
43+
* [ POINT ](point.md)
44+
* [ POS](pos.md)

0 commit comments

Comments
 (0)