PRINTMODE: Difference between revisions
Jump to navigation
Jump to search
Navigation:
Main Page with Articles and Tutorials
Keyword Reference - Alphabetical
Keyword Reference - By usage
Report a broken link
(Created page with "{{DISPLAYTITLE:_PRINTMODE}} The _PRINTMODE statement sets the text or _FONT printing mode on a background image when using PRINT or _PRINTSTRING. {{PageSyntax}} : _PRINTMODE {''_KEEPBACKGROUND''|''_ONLYBACKGROUND''|''_FILLBACKGROUND''}[, {{Parameter|imageHandle&}}] {{Parameters}} * One of 3 mode keywords is mandatory when using this statement to deal with the text background. **''_KEEPBACKGROUND'' (mode 1): Text background transparent. Only the te...") |
No edit summary |
||
(3 intermediate revisions by 2 users not shown) | |||
Line 1: | Line 1: | ||
{{DISPLAYTITLE:_PRINTMODE}} | {{DISPLAYTITLE:_PRINTMODE}} | ||
The [[_PRINTMODE]] statement sets the text or [[_FONT]] printing mode on | The [[_PRINTMODE]] statement sets the text or [[_FONT]] printing mode on an image when using [[PRINT]] or [[_PRINTSTRING]]. | ||
Line 7: | Line 7: | ||
{{ | {{PageParameters}} | ||
* One of 3 mode keywords is mandatory when using this statement to deal with the text background. | * One of 3 mode keywords is mandatory when using this statement to deal with the text background. | ||
**''_KEEPBACKGROUND'' (mode 1): Text background transparent. Only the text is displayed over anything behind it. | **''_KEEPBACKGROUND'' (mode 1): Text background transparent. Only the text is displayed over anything behind it. | ||
**''_ONLYBACKGROUND'' (mode 2): Text background only is displayed. Text is transparent to anything behind it. | **''_ONLYBACKGROUND'' (mode 2): Text background only is displayed. Text is transparent to anything behind it. | ||
**''_FILLBACKGROUND'' (mode 3): Text and background block anything behind them like a normal [[PRINT]]. '''Default setting.''' | **''_FILLBACKGROUND'' (mode 3): Text and background block anything behind them like a normal [[PRINT]]. '''Default setting.''' | ||
* If the optional {{Parameter|imageHandle&}} is omitted or | * If the optional {{Parameter|imageHandle&}} is omitted or is 0 then the setting will be applied to the current [[_DEST|destination]] image. | ||
{{PageDescription}} | {{PageDescription}} | ||
* Use the [[_PRINTMODE (function)]] to find the current [[_PRINTMODE]] setting mode number. | * Use the [[_PRINTMODE (function)]] to find the current [[_PRINTMODE]] setting mode number for an image. | ||
* '''The _PRINTMODE statement and function can only be used | * '''The _PRINTMODE statement and function can only be used on graphic images, not text-based ones such as SCREEN 0''' | ||
{{PageExamples}} | {{PageExamples}} | ||
''Example:'' Using _PRINTMODE with [[PRINT]] in a graphic screen mode. The background used is CHR$(219) = █ | ''Example:'' Using _PRINTMODE with [[PRINT]] in a graphic screen mode. The background used is CHR$(219) = █ | ||
{{CodeStart}} | {{CodeStart}} | ||
{{Cl | {{Cl|SCREEN}} 12 | ||
{{Cl|COLOR}} 8: {{Cl|LOCATE}} 10, 10: {{Cl|PRINT}} {{Cl|STRING$}}(3, 219) 'background | {{Cl|COLOR}} 8: {{Cl|LOCATE}} 10, 10: {{Cl|PRINT}} {{Cl|STRING$}}(3, 219) 'background | ||
{{Cl|_PRINTMODE}} _KEEPBACKGROUND | {{Cl|_PRINTMODE}} _KEEPBACKGROUND | ||
{{Cl|COLOR}} 15: {{Cl|LOCATE}} 10, 10: {{Cl|PRINT}} {{Cl|_PRINTMODE}} | {{Cl|COLOR}} 15: {{Cl|LOCATE}} 10, 10: {{Cl|PRINT}} {{Cl|_PRINTMODE}} | ||
{{Cl|END}} | {{Cl|END}} | ||
{{CodeEnd}} | {{CodeEnd}} | ||
Latest revision as of 10:53, 26 January 2023
The _PRINTMODE statement sets the text or _FONT printing mode on an image when using PRINT or _PRINTSTRING.
Syntax
- _PRINTMODE {_KEEPBACKGROUND|_ONLYBACKGROUND|_FILLBACKGROUND}[, imageHandle&]
Parameters
- One of 3 mode keywords is mandatory when using this statement to deal with the text background.
- _KEEPBACKGROUND (mode 1): Text background transparent. Only the text is displayed over anything behind it.
- _ONLYBACKGROUND (mode 2): Text background only is displayed. Text is transparent to anything behind it.
- _FILLBACKGROUND (mode 3): Text and background block anything behind them like a normal PRINT. Default setting.
- If the optional imageHandle& is omitted or is 0 then the setting will be applied to the current destination image.
Description
- Use the _PRINTMODE (function) to find the current _PRINTMODE setting mode number for an image.
- The _PRINTMODE statement and function can only be used on graphic images, not text-based ones such as SCREEN 0
Examples
Example: Using _PRINTMODE with PRINT in a graphic screen mode. The background used is CHR$(219) = █
SCREEN 12 COLOR 8: LOCATE 10, 10: PRINT STRING$(3, 219) 'background _PRINTMODE _KEEPBACKGROUND COLOR 15: LOCATE 10, 10: PRINT _PRINTMODE END |
See also