EpdPrintSndString()

Library Description ›› EPD ›› Bufferless ›› Fonts ››
… visits
Parent Previous Next

Syntax

EpdPrintSndString(sString As sTftString, bFontSize As Byte, wX_Pos As Word, wY_Pos As Word, pPosition As Bit, bForeColor As Byte, bBackColor As Byte)

Parameters

Parameter

Description

sString

Null-terminated string to print, up to 72 characters

bFontSize

Font size: 1 = nominal size; 2, 3, 4... are integer multiples of the nominal size

wX_Pos

X-position of the character's lower-left corner

wY_Pos

Y-position of the character's lower-left corner

pPosition

How wX_Pos/wY_Pos are interpreted:
0 = Absolute — actual pixel position on the EPD screen (e.g. wX_Pos = 152, wY_Pos = 86)
1 = Relative — relative to the screen's virtual division into columns/rows by FontSpace (e.g. wX_Pos = 5, wY_Pos = 2 with FontSpace = 8 means actual position x = 5×8 = 40, y = 2×8 = 16)

bForeColor

Color of the pixels forming the character itself

bBackColor

Color of the character cell's background pixels (the space around the glyph within its own cell, sized according to bFontSize)

Overview

Prints a string using the standard (SND) font.

Example

EpdPrintSndString

("SSD1680 BWR", 1, 1, 2, 1, BLACK, WHITE)

Note: When pPosition = 0 (absolute), wX_Pos is rounded to the nearest multiple of 8 — not truncated down — via wX_Pos = ((wX_Pos + 4) >> 3) << 3. For example, 150 rounds up to 152; 148 also rounds up to 152 (exactly halfway, rounds up). This follows directly from the byte-oriented GRAM constraint covered earlier: text in bufferless mode is built and written a full byte at a time, so the horizontal starting position can only ever land on an 8-pixel boundary.

Created with the Personal Edition of HelpNDoc: Experience a User-Friendly Interface with HelpNDoc's Documentation Tool