Changeset 142 for trunk/src/helpers/textview.c
- Timestamp:
- Feb 21, 2002, 8:24:22 PM (23 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/helpers/textview.c
r137 r142 278 278 */ 279 279 280 VOID SetSubFont(HPS hps,281 PXFMTFONT pFont,282 ULONG ulPointSize,283 PSZ pszFaceName,284 ULONG flFormat)280 static VOID SetSubFont(HPS hps, 281 PXFMTFONT pFont, 282 ULONG ulPointSize, 283 PSZ pszFaceName, 284 ULONG flFormat) 285 285 { 286 286 CHAR ac[256]; … … 336 336 337 337 /* 338 *@@ txvSetFormatFont:338 *@@ SetFormatFont: 339 339 * creates logical fonts from the specified 340 340 * font information. … … 343 343 */ 344 344 345 VOID txvSetFormatFont(HPS hps, // in: HPS to select default font into346 PXFMTCHARACTER pxfmtc, // in/out: format data347 ULONG ulPointSize, // in: font point size (e.g. 12) or 0348 PSZ pszFaceName) // in: font face name (e.g. "Courier") or NULL345 static VOID SetFormatFont(HPS hps, // in: HPS to select default font into 346 PXFMTCHARACTER pxfmtc, // in/out: format data 347 ULONG ulPointSize, // in: font point size (e.g. 12) or 0 348 PSZ pszFaceName) // in: font face name (e.g. "Courier") or NULL 349 349 { 350 350 pxfmtc->lPointSize = ulPointSize; … … 385 385 */ 386 386 387 VOID AppendCharNoCheck(char **ppszNew,388 PULONG pcbNew,389 char **ppTarget,390 char c)387 static VOID AppendCharNoCheck(char **ppszNew, 388 PULONG pcbNew, 389 char **ppTarget, 390 char c) 391 391 { 392 392 ULONG cbSizeThis = *ppTarget - *ppszNew; … … 494 494 */ 495 495 496 PSZ strhFindEOL2(PSZ *ppszSearchIn, // in: where to search497 PULONG pulOffset) // out: offset (ptr can be NULL)496 static PSZ strhFindEOL2(PSZ *ppszSearchIn, // in: where to search 497 PULONG pulOffset) // out: offset (ptr can be NULL) 498 498 { 499 499 PSZ pThis = *ppszSearchIn, … … 554 554 *@@ FORMATLINEBUF: 555 555 * worker structure to store various data 556 * in txvFormatText in between txvCreateWord556 * in txvFormatText in between CreateWord 557 557 * calls. This has been created for speed 558 558 * so we don't have to pass all these on … … 590 590 591 591 /* 592 *@@ txvCreateWord:592 *@@ CreateWord: 593 593 * 594 594 * -- If the word ends with one or several spaces, … … 613 613 */ 614 614 615 PTXVWORD txvCreateWord(HPS hps,616 PSZ *ppStartOfWord,617 PFORMATLINEBUF pflbuf)615 static PTXVWORD CreateWord(HPS hps, 616 PSZ *ppStartOfWord, 617 PFORMATLINEBUF pflbuf) 618 618 { 619 619 PTXVWORD pWord = NULL; … … 745 745 */ 746 746 747 PTXVWORD ProcessEscapes(char **ppCurrent, // in/out: current position; initially points to esc char748 PXFORMATDATA pxfd, // in/out: formatting data749 PFORMATLINEBUF pflbuf, // in/out: formatting buffer750 BOOL fWordsProcessed) // FALSE during step 1 (words processing),751 // TRUE during step 2 (rectangles correlation)747 static PTXVWORD ProcessEscapes(char **ppCurrent, // in/out: current position; initially points to esc char 748 PXFORMATDATA pxfd, // in/out: formatting data 749 PFORMATLINEBUF pflbuf, // in/out: formatting buffer 750 BOOL fWordsProcessed) // FALSE during step 1 (words processing), 751 // TRUE during step 2 (rectangles correlation) 752 752 { 753 753 PTXVWORD pEscapeWord = NULL; … … 1155 1155 } 1156 1156 1157 if (pWord = txvCreateWord(hps,1158 1159 1157 if (pWord = CreateWord(hps, 1158 &pCurrent, // advanced to next word 1159 &flbuf)) 1160 1160 { 1161 1161 lstAppendItem(&pxfd->llWords, pWord); … … 1411 1411 */ 1412 1412 1413 VOID DrawListMarker(HPS hps,1414 PRECTL prclLine, // current line rectangle1415 PTXVWORD pWordThis, // current word1416 LONG lViewXOfs) // in: x offset to paint; 0 means rightmost1413 static VOID DrawListMarker(HPS hps, 1414 PRECTL prclLine, // current line rectangle 1415 PTXVWORD pWordThis, // current word 1416 LONG lViewXOfs) // in: x offset to paint; 0 means rightmost 1417 1417 { 1418 1418 POINTL ptl; … … 1865 1865 */ 1866 1866 1867 VOID UpdateTextViewPresData(HWND hwndTextView,1868 PTEXTVIEWWINDATA ptxvd)1867 static VOID UpdateTextViewPresData(HWND hwndTextView, 1868 PTEXTVIEWWINDATA ptxvd) 1869 1869 { 1870 1870 PSZ pszFont; … … 1887 1887 &pszFaceName)) 1888 1888 { 1889 txvSetFormatFont(ptxvd->hps,1889 SetFormatFont(ptxvd->hps, 1890 1890 &ptxvd->xfd.fmtcStandard, 1891 1891 ulSize, … … 1920 1920 */ 1921 1921 1922 VOID AdjustViewRects(HWND hwndTextView,1923 PTEXTVIEWWINDATA ptxvd)1922 static VOID AdjustViewRects(HWND hwndTextView, 1923 PTEXTVIEWWINDATA ptxvd) 1924 1924 { 1925 1925 ULONG ulScrollCX = WinQuerySysValue(HWND_DESKTOP, SV_CXVSCROLL), … … 1992 1992 */ 1993 1993 1994 VOID FormatText2Screen(HWND hwndTextView,1995 PTEXTVIEWWINDATA ptxvd,1996 BOOL fAlreadyRecursing, // in: set this to FALSE when calling1997 BOOL fFullRecalc)1994 static VOID FormatText2Screen(HWND hwndTextView, 1995 PTEXTVIEWWINDATA ptxvd, 1996 BOOL fAlreadyRecursing, // in: set this to FALSE when calling 1997 BOOL fFullRecalc) 1998 1998 { 1999 1999 ULONG ulWinCX, … … 2080 2080 */ 2081 2081 2082 VOID PaintViewText2Screen(PTEXTVIEWWINDATA ptxvd,2083 PRECTL prcl2Paint) // in: invalid rectangle, can be NULL == paint all2082 static VOID PaintViewText2Screen(PTEXTVIEWWINDATA ptxvd, 2083 PRECTL prcl2Paint) // in: invalid rectangle, can be NULL == paint all 2084 2084 { 2085 2085 ULONG ulLineIndex = 0; … … 2100 2100 */ 2101 2101 2102 VOID PaintViewFocus(HPS hps,2103 PTEXTVIEWWINDATA ptxvd,2104 BOOL fFocus)2102 static VOID PaintViewFocus(HPS hps, 2103 PTEXTVIEWWINDATA ptxvd, 2104 BOOL fFocus) 2105 2105 { 2106 2106 POINTL ptl; … … 2131 2131 */ 2132 2132 2133 VOID RepaintWord(PTEXTVIEWWINDATA ptxvd,2134 PTXVWORD pWordThis,2135 LONG lColor)2133 static VOID RepaintWord(PTEXTVIEWWINDATA ptxvd, 2134 PTXVWORD pWordThis, 2135 LONG lColor) 2136 2136 { 2137 2137 POINTL ptlStart; … … 2184 2184 */ 2185 2185 2186 VOID RepaintAnchor(PTEXTVIEWWINDATA ptxvd,2187 LONG lColor)2186 static VOID RepaintAnchor(PTEXTVIEWWINDATA ptxvd, 2187 LONG lColor) 2188 2188 { 2189 2189 PLISTNODE pNode = ptxvd->pWordNodeFirstInAnchor; … … 2255 2255 */ 2256 2256 2257 MRESULT EXPENTRY fnwpTextView(HWND hwndTextView, ULONG msg, MPARAM mp1, MPARAM mp2)2257 static MRESULT EXPENTRY fnwpTextView(HWND hwndTextView, ULONG msg, MPARAM mp1, MPARAM mp2) 2258 2258 { 2259 2259 MRESULT mrc = 0; … … 2365 2365 2366 2366 // set "code" format 2367 txvSetFormatFont(ptxvd->hps,2367 SetFormatFont(ptxvd->hps, 2368 2368 &ptxvd->xfd.fmtcCode, 2369 2369 6, … … 3206 3206 */ 3207 3207 3208 PRQINFO3* prthEnumQueues(PULONG pulReturned) // out: no. of queues found3208 static PRQINFO3* prthEnumQueues(PULONG pulReturned) // out: no. of queues found 3209 3209 { 3210 3210 SPLERR rc; … … 3248 3248 */ 3249 3249 3250 VOID prthFreeBuf(PVOID pprq3)3250 static VOID prthFreeBuf(PVOID pprq3) 3251 3251 { 3252 3252 if (pprq3) … … 3270 3270 */ 3271 3271 3272 HDC prthCreatePrinterDC(HAB hab,3273 PRQINFO3 *pprq3,3274 PLONG palRes) // out: 2 longs holding horizontal and vertical3275 // printer resolution in pels per inch3272 static HDC prthCreatePrinterDC(HAB hab, 3273 PRQINFO3 *pprq3, 3274 PLONG palRes) // out: 2 longs holding horizontal and vertical 3275 // printer resolution in pels per inch 3276 3276 { 3277 3277 HDC hdc = NULLHANDLE; … … 3316 3316 */ 3317 3317 3318 HCINFO* prthQueryForms(HDC hdc,3319 PULONG pulCount)3318 static HCINFO* prthQueryForms(HDC hdc, 3319 PULONG pulCount) 3320 3320 { 3321 3321 HCINFO *pahci = NULL; … … 3348 3348 */ 3349 3349 3350 HPS prthCreatePS(HAB hab, // in: anchor block3351 HDC hdc, // in: printer device context3352 ULONG ulUnits) // in: one of:3353 // -- PU_PELS3354 // -- PU_LOMETRIC3355 // -- PU_HIMETRIC3356 // -- PU_LOENGLISH3357 // -- PU_HIENGLISH3358 // -- PU_TWIPS3350 static HPS prthCreatePS(HAB hab, // in: anchor block 3351 HDC hdc, // in: printer device context 3352 ULONG ulUnits) // in: one of: 3353 // -- PU_PELS 3354 // -- PU_LOMETRIC 3355 // -- PU_HIMETRIC 3356 // -- PU_LOENGLISH 3357 // -- PU_HIENGLISH 3358 // -- PU_TWIPS 3359 3359 { 3360 3360 SIZEL sizel; … … 3378 3378 */ 3379 3379 3380 VOID prthStartDoc(HDC hdc,3381 PSZ pszDocTitle)3380 static VOID prthStartDoc(HDC hdc, 3381 PSZ pszDocTitle) 3382 3382 { 3383 3383 DevEscape(hdc, … … 3398 3398 */ 3399 3399 3400 VOID prthNextPage(HDC hdc)3400 static VOID prthNextPage(HDC hdc) 3401 3401 { 3402 3402 DevEscape(hdc, … … 3417 3417 */ 3418 3418 3419 VOID prthEndDoc(HDC hdc,3420 HPS hps)3419 static VOID prthEndDoc(HDC hdc, 3420 HPS hps) 3421 3421 { 3422 3422 DevEscape(hdc, DEVESC_ENDDOC, 0L, 0L, 0, NULL); … … 3474 3474 txvInitFormat(&xfd); 3475 3475 3476 /* txvSetFormatFont(hps,3476 /* SetFormatFont(hps, 3477 3477 &xfd, 3478 3478 ulSize,
Note:
See TracChangeset
for help on using the changeset viewer.