Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.clipper.visual-objects > #8217

Re: create fixedtext control

From JohnMartens <martens@tennishulp.info>
Newsgroups comp.lang.clipper.visual-objects
Subject Re: create fixedtext control
Date 2015-06-16 18:59 +0200
Organization A noiseless patient Spider
Message-ID <mlpkia$3lr$1@dont-email.me> (permalink)
References <d0fb6f7f-6210-4307-82bb-9e3791f03e1e@googlegroups.com>

Show all headers | View raw


Does this help ?
John


METHOD DrawText(oPoint, cText, oFont, cColor) CLASS DataWindow
	*
	* method by Geoff S 10/12/2007

     LOCAL iOldMode, iNewMode AS INT
     LOCAL hDC AS PTR
     LOCAL oSelf AS OBJECT
     LOCAL oOldPen AS Pen
     LOCAL oOldFont AS Font

     *
     * getting the surface
     oSelf := SELF:oSurface

     IF !IsNil(cColor)
         oOldPen := oSelf:Pen
         oSelf:Pen := Pen{cColor, LINESOLID, 1}
     ENDIF
     IF !IsNil(oFont)
         oOldFont := oSelf:Font
         oSelf:Font := oFont
     ENDIF

     hDC := oSelf:__GetDC()
     iNewMode := TRANSPARENT
     iOldMode := SetBkMode(hDC, PTR(_CAST, iNewMode))
     SetTextAlign(hDC, _OR(TA_LEFT,TA_BOTTOM))
     TextOut(hDC, oPoint:X, oPoint:Y, Cast2Psz(cText), INT(_CAST, 
SLen(cText)))
     SetBkMode(hDC, PTR(_CAST, iOldMode))

     IF !IsNil(OPEN)
         oSelf:Pen := oOldPen
     ENDIF
     IF !IsNil(oFont)
         oSelf:Font := oOldFont
     ENDIF

RETURN SELF


moshe attia schreef op 16-6-2015 om 17:15:
> hi all
>
> i need to create (on run time ) matrix of fixedtext control on form
> and arrange it like matrix with same size
>
>
> moshe attia
>
>

Back to comp.lang.clipper.visual-objects | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread


Thread

create fixedtext  control moshe attia <attiamx@gmail.com> - 2015-06-16 08:15 -0700
  Re: create fixedtext  control JohnMartens <martens@tennishulp.info> - 2015-06-16 18:59 +0200
  Re: create fixedtext  control Karl Faller <mail_withoutthat_@_drei-f_andthat_.de> - 2015-06-16 19:45 +0200
  Re: create fixedtext  control moshe attia <attiamx@gmail.com> - 2015-06-16 12:34 -0700

csiph-web