TftPrintBdfText(ByRef dwFlashAddress As Dword, swX_Pos As SWord, swY_Pos As SWord, wEndOfLine As Word, wEndOfPage As Word, pBreakLine As Byte, wForeColor As Word, wBackColor As Word, pTransparent As Bit, bPrintMode As Byte)
|
Parameter |
Description |
|
dwFlashAddress |
The address in flash memory to start reading from. |
|
swX_Pos |
The absolute X-position for the upper-left corner of the virtual print box. |
|
swY_Pos |
The absolute Y-position for the upper-left corner of the virtual print box. |
|
wEndOfLine |
The absolute X-position for the lower-right corner of the virtual print box. |
|
wEndOfPage |
The absolute Y-position for the lower-right corner of the virtual print box. |
|
pBreakLine |
Defines how to break long words into new lines. The last character of the current line will not be split. |
|
wForeColor |
The 16-bit RGB565 color for the character's active pixels (used to form the glyph). |
|
wBackColor |
The 16-bit RGB565 color for the background (used for empty pixels forming the character box). |
|
pTransparent |
Use transparency: |
|
bPrintMode |
Determines how the text is displayed when it doesn't fit on the screen. |
Draws a text from a Flash table with BDF font in virtual rectangle box top to bottom.
|
TftPrintBdfText(myText, 20, 220, 300, 20, 1, RED, BLACK, 1, 104) '... Dim myText As Flash8 = "One thing I know is that I know nothing. This is the source of my wisdom. - Socrates", 0 |
The background color (wBackColor) will be ignored if transparency is used. Only the glyph's pixels will be printed, which is slower than using the background color.
bPrintMode controls how the text from the flash table is printed:
For different delay coefficients for options 61 to 100 and 101 to 160, open BDF.inc in the folder TftLib\Fonts\BDF.
Look for the procedure TftPrintDelay(bPrintMode As Byte) at the bottom, where you can adjust the delay in milliseconds.
pBreakLine determines how words are broken across lines:
In both cases, the last character of the current line will not be split. It will either be fully displayed or carried over to the next line.
|
Include "TftLib\Fonts\SND\F5_BDF_Sail-Regular-25.inc" '.... TftSetUp(0, 0) TftSetBdfFont(5) TftResetScreen(BLUE) TftRectangleSNTC(20,220, 300,20, BLACK) TftPrintBdfText(myText, 20, 190, 300, 20, 0, YELLOW, BLACK, 1, 0) Dim myText As Flash8 = "The positron or antielectron is the particle ",_ "with an electric charge of +1e, a spin of 1/2 (the same as the electron), ",_ "and the same mass as an electron. It is the antiparticle (antimatter ",_ "counterpart) of the electron. When a positron collides with an electron, ",_ "annihilation occurs. If this collision occurs at low energies, it results ",_ "in the production of two or more photons.", 0 |
|
|
Include "TftLib\Fonts\SND\F5_BDF_Sail-Regular-25.inc" '.... TftSetUp(0, 0) TftSetBdfFont(5) TftResetScreen(BLUE) TftRectangleSNTC(20,220, 300,20, BLACK) TftPrintBdfText(myText, 20, 190, 300, 20, 1, YELLOW, BLACK, 1, 0) Dim myText As Flash8 = "The positron or antielectron is the particle ",_ "with an electric charge of +1e, a spin of 1/2 (the same as the electron), ",_ "and the same mass as an electron. It is the antiparticle (antimatter ",_ "counterpart) of the electron. When a positron collides with an electron, ",_ "annihilation occurs. If this collision occurs at low energies, it results ",_ "in the production of two or more photons.", 0 |
|
|
Include "TftLib\Fonts\SND\F5_BDF_Sail-Regular-25.inc" '.... TftSetUp(0, 0) TftSetBdfFont(5) TftResetScreen(BLUE) TftRectangleSNTC(20,220, 300,20, BLACK) TftPrintBdfText(myText, 20, 190, 300, 20, 1, YELLOW, BLACK, 1, 5) Dim myText As Flash8 = "The positron or antielectron is the particle ",_ "with an electric charge of +1e, a spin of 1/2 (the same as the electron), ",_ "and the same mass as an electron. It is the antiparticle (antimatter ",_ "counterpart) of the electron. When a positron collides with an electron, ",_ "annihilation occurs. If this collision occurs at low energies, it results ",_ "in the production of two or more photons.", 0 |
|
|
Include "TftLib\Fonts\SND\F5_BDF_Sail-Regular-25.inc" '.... TftSetUp(0, 0) TftSetBdfFont(5) TftResetScreen(BLUE) TftRectangleSNTC(20,220, 300,20, BLACK) TftPrintBdfText(myText, 20, 190, 300, 20, 0, YELLOW, BLACK, 1, 80) Dim myText As Flash8 = "The positron or antielectron is the particle ",_ "with an electric charge of +1e, a spin of 1/2 (the same as the electron), ",_ "and the same mass as an electron. It is the antiparticle (antimatter ",_ "counterpart) of the electron. When a positron collides with an electron, ",_ "annihilation occurs. If this collision occurs at low energies, it results ",_ "in the production of two or more photons.", 0 |
|
|
Include "TftLib\Fonts\SND\F5_BDF_Sail-Regular-25.inc" '.... TftSetUp(0, 0) TftSetBdfFont(5) TftResetScreen(BLUE) TftRectangleSNTC(20,220, 300,20, BLACK) TftPrintBdfText(myText, 20, 190, 300, 20, 1, YELLOW, BLACK, 1, 80) Dim myText As Flash8 = "The positron or antielectron is the particle ",_ "with an electric charge of +1e, a spin of 1/2 (the same as the electron), ",_ "and the same mass as an electron. It is the antiparticle (antimatter ",_ "counterpart) of the electron. When a positron collides with an electron, ",_ "annihilation occurs. If this collision occurs at low energies, it results ",_ "in the production of two or more photons.", 0 |
|
|
Include "TftLib\Fonts\SND\F5_BDF_Sail-Regular-25.inc" '.... TftSetUp(0, 0) TftSetBdfFont(5) TftResetScreen(BLUE) TftRectangleSNTC(20,220, 300,20, BLACK) TftPrintBdfText(myText, 20, 190, 300, 20, 1, YELLOW, BLACK, 1, 112) Dim myText As Flash8 = "The positron or antielectron is the particle ",_ "with an electric charge of +1e, a spin of 1/2 (the same as the electron), ",_ "and the same mass as an electron. It is the antiparticle (antimatter ",_ "counterpart) of the electron. When a positron collides with an electron, ",_ "annihilation occurs. If this collision occurs at low energies, it results ",_ "in the production of two or more photons.", 0 |
|
Created with the Personal Edition of HelpNDoc: Maximize Your Productivity with HelpNDoc's CHM Help File Creation Features