Leaked source code of windows server 2003
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

54 lines
1.4 KiB

  1. #include "lsidefs.h"
  2. #include "plsrun.h"
  3. #include "pilsobj.h"
  4. #include "txtils.h"
  5. #include "txtobj.h"
  6. #include "txtln.h"
  7. // %%Function: EnumObjText
  8. // %%Contact: victork
  9. //
  10. LSERR WINAPI EnumObjText(PDOBJ pdobj, PLSRUN plsrun, PCLSCHP plschp, LSCP cpFirst, LSDCP dcp,
  11. LSTFLOW lstflow, BOOL fReverseOrder, BOOL fGeometryProvided,
  12. const POINT* pptStart, PCHEIGHTS pheightsPres, long dupRun)
  13. {
  14. TXTOBJ* ptxtobj;
  15. PLNOBJ plnobj;
  16. PILSOBJ pilsobj;
  17. long* pdup;
  18. BOOL fCharWidthsProvided;
  19. ptxtobj = (TXTOBJ*)pdobj;
  20. plnobj = ptxtobj->plnobj;
  21. pilsobj = plnobj->pilsobj;
  22. Unreferenced(plschp);
  23. if (ptxtobj->txtkind == txtkindTab)
  24. {
  25. return (*pilsobj->plscbk->pfnEnumTab)(pilsobj->pols, plsrun, cpFirst,
  26. &plnobj->pwch[ptxtobj->iwchFirst],
  27. ptxtobj->u.tab.wchTabLeader, lstflow,
  28. fReverseOrder, fGeometryProvided,
  29. pptStart, pheightsPres, dupRun);
  30. }
  31. if (ptxtobj->txtf & txtfGlyphBased)
  32. {
  33. fCharWidthsProvided = fFalse;
  34. pdup = NULL;
  35. }
  36. else
  37. {
  38. fCharWidthsProvided = fTrue;
  39. pdup = &plnobj->pdup[ptxtobj->iwchFirst];
  40. }
  41. return (*pilsobj->plscbk->pfnEnumText)(pilsobj->pols, plsrun, cpFirst, dcp,
  42. &plnobj->pwch[ptxtobj->iwchFirst],
  43. ptxtobj->iwchLim - ptxtobj->iwchFirst, lstflow,
  44. fReverseOrder, fGeometryProvided,
  45. pptStart, pheightsPres, dupRun,
  46. fCharWidthsProvided, pdup);
  47. }