Alaska Software Inc. - FONT SIZE IN @,SAY, GET
Username: Password:
AuthorTopic: FONT SIZE IN @,SAY, GET
JAYARAM MYSOREFONT SIZE IN @,SAY, GET
on Fri, 01 Jan 2010 21:42:21 +0530
Wish you all Alaska Xbase++ useres a Very Happy and Prosperous NEW YEAR 
2010.

I am migrating from Clipper 87. I am using a lot of @ say get like this :
      INVOLIN1 = SPACE(30)
      INVOLIN2 = SPACE(30)
      INVOLIN3 = SPACE(30)
      @ 26, 43 SAY "Note in Invoice:"
      @ 27, 43 GET  INVOLIN1
      @ 28, 43 GET  INVOLIN2
      @ 29, 43 GET  INVOLIN3

      @ 27,76 SAY " Tran.Code:" GET MAINACC->TRANSCODE
      @ 28,76 SAY "Party Mark:" GET MAINACC->PARTY_MRK
      @ 29,76 SAY " City Code:" GET MAINACC->CITY_CODE
      @ 30,76 SAY "Payment by:" GET ORDPAY

      @ 31,24 SAY "Order Through:" GET LETTERM
      @ 31,55 SAY "Dt." GET LETTERDT
      @ 32,24 SAY "Agent :" GET TAGNAME
      @ 32,66 SAY "O.F.No:" GET OFNUM
     READ

Is there any way to increase the Font Size while entering keyboard input on 
the screen ?

Is there any other way to READ  inputs ?

Your help is appreciated.

Regards

Jayaram
James Loughner Re: FONT SIZE IN @,SAY, GET
on Fri, 01 Jan 2010 12:06:49 -0500
In pure GUI a XbpSLE object is used and all the objects can be
individually configured for FONT and size.

I don't think the default procedural methodology supports mixed fonts on
the screen. At least using @SAY/GET syntax

If you want to keep the @ SAY/GET syntax the best solution is a 3rd
party add on called Express++

There is also Topdown which uses a function oriented syntax

Personally I reproduce the screen in Form Designer (FD) and generate
Class code. I then use a Class I wrote to give XBPSLE's Clipper style
pictures and navigation keys. But you must be committed to learning
Class style programming to use this method.

Jim






On 01/01/2010 11:12 AM, JAYARAM MYSORE wrote:
> Wish you all Alaska Xbase++ useres a Very Happy and Prosperous NEW YEAR 
> 2010.
> 
> I am migrating from Clipper 87. I am using a lot of @ say get like this :
>       INVOLIN1 = SPACE(30)
>       INVOLIN2 = SPACE(30)
>       INVOLIN3 = SPACE(30)
>       @ 26, 43 SAY "Note in Invoice:"
>       @ 27, 43 GET  INVOLIN1
>       @ 28, 43 GET  INVOLIN2
>       @ 29, 43 GET  INVOLIN3
> 
>       @ 27,76 SAY " Tran.Code:" GET MAINACC->TRANSCODE
>       @ 28,76 SAY "Party Mark:" GET MAINACC->PARTY_MRK
>       @ 29,76 SAY " City Code:" GET MAINACC->CITY_CODE
>       @ 30,76 SAY "Payment by:" GET ORDPAY
> 
>       @ 31,24 SAY "Order Through:" GET LETTERM
>       @ 31,55 SAY "Dt." GET LETTERDT
>       @ 32,24 SAY "Agent :" GET TAGNAME
>       @ 32,66 SAY "O.F.No:" GET OFNUM
>      READ
> 
> Is there any way to increase the Font Size while entering keyboard input on 
> the screen ?
> 
> Is there any other way to READ  inputs ?
> 
> Your help is appreciated.
> 
> Regards
> 
> Jayaram
> 
> 
>
JAYARAM MYSORERe: FONT SIZE IN @,SAY, GET
on Sat, 02 Jan 2010 19:46:57 +0530
Dear Jim,
Thanks for your advice.
What is the best way to learn the basics of class methods.
I have read quite a bit in the help. But I am not able to get a grip of the 
things. Any help is welcomed.
Regards
Jayaram
"James Loughner" <jwrl@suddenlink.net> wrote in message 
news:4d408f4a$bf3e1d9$3407@news.alaska-software.com...
> In pure GUI a XbpSLE object is used and all the objects can be
> individually configured for FONT and size.
>
> I don't think the default procedural methodology supports mixed fonts on
> the screen. At least using @SAY/GET syntax
>
> If you want to keep the @ SAY/GET syntax the best solution is a 3rd
> party add on called Express++
>
> There is also Topdown which uses a function oriented syntax
>
> Personally I reproduce the screen in Form Designer (FD) and generate
> Class code. I then use a Class I wrote to give XBPSLE's Clipper style
> pictures and navigation keys. But you must be committed to learning
> Class style programming to use this method.
>
> Jim
>
>
>
>
>
>
> On 01/01/2010 11:12 AM, JAYARAM MYSORE wrote:
>> Wish you all Alaska Xbase++ useres a Very Happy and Prosperous NEW YEAR
>> 2010.
>>
>> I am migrating from Clipper 87. I am using a lot of @ say get like this :
>>       INVOLIN1 = SPACE(30)
>>       INVOLIN2 = SPACE(30)
>>       INVOLIN3 = SPACE(30)
>>       @ 26, 43 SAY "Note in Invoice:"
>>       @ 27, 43 GET  INVOLIN1
>>       @ 28, 43 GET  INVOLIN2
>>       @ 29, 43 GET  INVOLIN3
>>
>>       @ 27,76 SAY " Tran.Code:" GET MAINACC->TRANSCODE
>>       @ 28,76 SAY "Party Mark:" GET MAINACC->PARTY_MRK
>>       @ 29,76 SAY " City Code:" GET MAINACC->CITY_CODE
>>       @ 30,76 SAY "Payment by:" GET ORDPAY
>>
>>       @ 31,24 SAY "Order Through:" GET LETTERM
>>       @ 31,55 SAY "Dt." GET LETTERDT
>>       @ 32,24 SAY "Agent :" GET TAGNAME
>>       @ 32,66 SAY "O.F.No:" GET OFNUM
>>      READ
>>
>> Is there any way to increase the Font Size while entering keyboard input 
>> on
>> the screen ?
>>
>> Is there any other way to READ  inputs ?
>>
>> Your help is appreciated.
>>
>> Regards
>>
>> Jayaram
>>
>>
>>
>
James Loughner Re: FONT SIZE IN @,SAY, GET
on Sun, 03 Jan 2010 00:33:41 -0500
You might want to study the code here as examples.

http://gogalthorp.com/splash

feel free to ask any questions.

There are 2 things you must master Class encapsulation and events

A Class is data and methods (functions) encapsulated into a single unit
ie a class. A class is like a skeleton that defines this structure. You
can then use the class definition to instantiate class objects. For
example you could define a Vector class that would incorporate data
structures that define a vector along with the rules of adding
subtracting and  multiplying vectors as well as possibly displaying or
plotting the values of the object. These are the methods. There is an
example Vector class on the above web page.

You can inherit from Class structures in a New class. The New (Sub)
class will have all the data structures and methods of the super class.
You can then over load (ie replace) data structures and methods.

For windows and windows widgets (all things are windows in Windows)
Xbase++ uses some special Windows based classes. These are XBPs (Xbase++
Parts) These XBPs are built up from other classes that allow the objects
created with them to be registered with the Windows kernel. Window then
can detect events directed to that object and sends a message to the
registered object. It is then up to the object to react to the event the
why you want it to. The XBPs incorporate many standard Windows
behaviors. But you can over load them. Xbase++ provides two way to
effect events. One is to sub class the XBP and overload the method that
services the event. Or you can use codeblocks assigned to special
variable called callbacks. Code blocks don't overload normal behavior
but supplement it. The code in the codeblock is is run when the
associated event happens.

Events are transmitted to the XBP objects by the event loop to a method
that all XBps have. The :handleEvent() method. Which is basically a big
case statement. You can also overload event process in this method also.

When you create an object you normally assign the returned value to a
variable. The variable then holds a pointer to the object. You can set
or get values form the class variables (ivars {Instance Variables}) or
run a method like this

VarHoldinfPointer:SomeIvar := 10
VarHoldinfPointer:SomeMethod()

In the Class code you must always refer to ivars  or methods of that
class by a special variable called self. Which is just a pointer to the
current object of that class. It is common to use a shorthand which is
::
So in the class code

::SomeIvar := 10
::SomeMethod()


Ok there is a starting point study some code 

Jim









On 01/02/2010 09:16 AM, JAYARAM MYSORE wrote:
> Dear Jim,
> Thanks for your advice.
> What is the best way to learn the basics of class methods.
> I have read quite a bit in the help. But I am not able to get a grip of the 
> things. Any help is welcomed.
> Regards
> Jayaram
> "James Loughner" <jwrl@suddenlink.net> wrote in message 
> news:4d408f4a$bf3e1d9$3407@news.alaska-software.com...
>> In pure GUI a XbpSLE object is used and all the objects can be
>> individually configured for FONT and size.
>>
>> I don't think the default procedural methodology supports mixed fonts on
>> the screen. At least using @SAY/GET syntax
>>
>> If you want to keep the @ SAY/GET syntax the best solution is a 3rd
>> party add on called Express++
>>
>> There is also Topdown which uses a function oriented syntax
>>
>> Personally I reproduce the screen in Form Designer (FD) and generate
>> Class code. I then use a Class I wrote to give XBPSLE's Clipper style
>> pictures and navigation keys. But you must be committed to learning
>> Class style programming to use this method.
>>
>> Jim
>>
>>
>>
>>
>>
>>
>> On 01/01/2010 11:12 AM, JAYARAM MYSORE wrote:
>>> Wish you all Alaska Xbase++ useres a Very Happy and Prosperous NEW YEAR
>>> 2010.
>>>
>>> I am migrating from Clipper 87. I am using a lot of @ say get like this :
>>>       INVOLIN1 = SPACE(30)
>>>       INVOLIN2 = SPACE(30)
>>>       INVOLIN3 = SPACE(30)
>>>       @ 26, 43 SAY "Note in Invoice:"
>>>       @ 27, 43 GET  INVOLIN1
>>>       @ 28, 43 GET  INVOLIN2
>>>       @ 29, 43 GET  INVOLIN3
>>>
>>>       @ 27,76 SAY " Tran.Code:" GET MAINACC->TRANSCODE
>>>       @ 28,76 SAY "Party Mark:" GET MAINACC->PARTY_MRK
>>>       @ 29,76 SAY " City Code:" GET MAINACC->CITY_CODE
>>>       @ 30,76 SAY "Payment by:" GET ORDPAY
>>>
>>>       @ 31,24 SAY "Order Through:" GET LETTERM
>>>       @ 31,55 SAY "Dt." GET LETTERDT
>>>       @ 32,24 SAY "Agent :" GET TAGNAME
>>>       @ 32,66 SAY "O.F.No:" GET OFNUM
>>>      READ
>>>
>>> Is there any way to increase the Font Size while entering keyboard input 
>>> on
>>> the screen ?
>>>
>>> Is there any other way to READ  inputs ?
>>>
>>> Your help is appreciated.
>>>
>>> Regards
>>>
>>> Jayaram
>>>
>>>
>>>
>>
> 
>
AUGE_OHRRe: FONT SIZE IN @,SAY, GET
on Sun, 03 Jan 2010 21:35:42 +0100
hi,

>I am migrating from Clipper 87
...
> What is the best way to learn the basics of class methods.

it is a long Way from S87 Syntax to Xbase++ Class Syntax,
so you might make one more Step in Cl*pper v5.x

did you use DbEdit() in S87 ? if yes have a look at TBrowse() Class

you will find Source, using DbEdit, in 
c:\ALASKA\XPPW32\Source\SYS\dbedit.prg
TBrowse Source are c:\ALASKA\XPPW32\Source\SYS\BrowSys.prg and BrowUtil.prg

Cl*pper v5x and Xbase++ can use TBrowse Class with same (Classy) Syntax as 
XbParts do,

so look at those Source and "play" with its Class Methode (Function) and 
Class Property (VARs)
to get a Idee how to use a "Class" and its Syntax

greetings by OHR
Jimmy
Zupan Miran Re: FONT SIZE IN @,SAY, GET
on Fri, 01 Jan 2010 20:20:13 +0100
JAYARAM MYSORE pravi:
> Is there any way to increase the Font Size while entering keyboard input on 
> the screen ?

No, only way is define font before whwn you open XbpCrt window (hybrid mode)

//*** Open xbpcrt window ***
oCrt:= Open_Crt(cTitle,nRows, nCols,"Lucida Console",9,14)

SetColor( BARVA_CRT )
  @  2, 1 say " Zaporedna stevilka " color "gr+/b"
  @  2,30 say " Stev. izdajnice " color "gr+/b"
  @  2,79 say " z dne " color "gr+/b"

...
...
SetColor(BARVA_GET)
SetCursor( SC_SPECIAL1 )
  @  2,21 say a1 picture "!99999" color "r/w*"
  @  2,47 get a2 picture "@!"
  @  2,86 get a3
  @  4,21 get a4 picture "@SK" valid ctrl_part(@a4,4,32,3,@a12,novi)
...
...

//**************************************************************************

#include "Common.ch"   //*** inportan because of DEFAULT statement

FUNCTION Open_crt( cTitle, nRows, nCols, cFont, nFontSize, nFontHeight, yCrtPom, xCrtPom )

LOCAL oCrt, oPs
DEFAULT cTitle  TO "Pregled podatkov"      //***  cFont TO "Lucida Console", "Fixedsys", "Courier"
DEFAULT cFont   TO "Lucida Console"
DEFAULT yCrtPom TO 0, xCrtPom TO 0

DO CASE
    CASE xres=1
         //*** for resolution 800*600
         DEFAULT nFontSize TO 7, nFontHeight TO 12

    CASE xres=2
         //*** for resolution 1024*768
         DEFAULT nFontSize TO 8, nFontHeight TO 14      //***10,14  / 9,13  / 8,13

   CASE xres=3 .or. xres=4
        //*** for resolution>1024*768
        DEFAULT nFontSize TO 8, nFontHeight TO 14      //***10,14  / 9,13  / 8,13

ENDCASE

oAppWindow := SetAppWindow()
oCrt := XbpCrt():new(AppDeskTop(),oAppWindow,;
      CenterPos( { nCols*nFontSize,nRows*nFontHeight },AppDesktop():currentSize(),yCrtPom,xCrtPom ),;
      nRows, nCols, cTitle )

oCrt:ClipChildren := .T.
oCrt:minmax       := .F.
oCrt:sysmenu      := .T.
oCrt:closeable    := .T.
oCrt:asyncFlush   := .T.
oCrt:autoMark     := .T.
oCrt:FontName     := cFont
oCrt:FontHeight   := nFontHeight
oCrt:FontWidth    := nFontSize
oCrt:border       := XBPDLG_RAISEDBORDERTHICK_FIXED
//*** oCrt:icon         := 101
//*** oCrt:useVisualStyle:=.T.
oCrt:close        := {|mp1,mp2,obj| oCrt:destroy() }
oCrt:create()

//*** Presentation Space ***
//*** oCrt:PresSpace()
oPS:=oCrt:presSpace()
SetAppWindow ( oCrt )

//*** pobrisi ozadje v oCrt ***
SetColor( "W/W" )
CLS
GraSetColor( oPS, GraMakeRGBColor( {222,222,222} ) )
GraBox(oPS, {0,0}, oCrt:currentSize(), GRA_FILL)

SetMouse ( .T. )

//*** set focus ***
SetAppFocus( oCrt )

RETURN oCrt

Something like that

Best regards
Miran Zupan

--------------------------------
SPC Zupan Miran s.p.
Tomanova pot 9, 1251 Moravce, Slovenia
TEL: (xx386)  59 / 045 - 909
GSM: 041/ 620 - 753

E-mail: spczupan@spc-zupan.si
Web site:    www.spc-zupan.si
--------------------------------
Jack DuijfRe: FONT SIZE IN @,SAY, GET
on Mon, 04 Jan 2010 23:24:29 +0100
Hello,

There is a way to convert your Clipper5 apps to GUI app.
Personaly i use Express++ from Roger Donnay, this works me (and many others)
See sample code below.

Note: oDb = database object, but for you the DCSAY .. GET is interesting.

PROCEDURE Edit_BtwCode(oDesk,cLevel)

LOCAL GetList        := {}
LOCAL cTitle         := "Btwcode"
LOCAL oDb            := Db_BtwCode():New()
LOCAL lEdit          := FALSE
LOCAL oNew           := {}
LOCAL oFirst         := {}
LOCAL aBtn           := {}
LOCAL nLine          := 2
if oDb:AllOk
   oDb:Refresh := {||Data_Refresh(GetList,oDb)}
   oDb:Update  := {||Data_Update(oDesk,GetList,oDb,,EDIT_NOCONFIRMCHANGE)}
   oDb:Delete  := {||Data_Delete(oDesk,oDb)}

   Aadd(aBtn,{"Print",{||Lijst_BtwCode()},{||!lEdit},BITMAP_E_PRINT,BITMAP_D_PRINT,xbeK_ALT_P,"Afdrukken 
(Alt-P)","P"})
   Kmov_Buttons(GetList,oDb,@lEdit,,@oNew,@oFirst,cLevel,aBtn)

   @ nLine++   , 2 DCSAY "Btw code"          GET oDb:code 
SAYRIGHT WHEN {||lEdit .and. oDb:New} PICTURE "@!" GETOBJECT oNew SAYFONT 
"10.Arial"
   @ nLine++   , 2 DCSAY "Omschrijving"      GET oDb:omschrijving 
SAYRIGHT WHEN {||lEdit} GETOBJECT oFirst VALID 
{||Valid_Leverwijze_Naam(oDb:omschrijving)} SAYFONT "10.Verdana"
   @ nLine     , 2 DCSAY "Percentage"        GET oDb:btwperc 
SAYRIGHT WHEN {||lEdit} PICTURE "99.99"
   @ nLine++   ,28 DCSAY "%"
   nLine++
   DC_READ(oDesk,GetList,cTitle)
endif
oDb:Destroy()
return


Regards,
Jack Duijf


"JAYARAM MYSORE" schreef in bericht 
news:354ebff2$64d04817$35a0@news.alaska-software.com...
> Wish you all Alaska Xbase++ useres a Very Happy and Prosperous NEW YEAR 
> 2010.
>
> I am migrating from Clipper 87. I am using a lot of @ say get like this :
>      INVOLIN1 = SPACE(30)
>      INVOLIN2 = SPACE(30)
>      INVOLIN3 = SPACE(30)
>      @ 26, 43 SAY "Note in Invoice:"
>      @ 27, 43 GET  INVOLIN1
>      @ 28, 43 GET  INVOLIN2
>      @ 29, 43 GET  INVOLIN3
>
>      @ 27,76 SAY " Tran.Code:" GET MAINACC->TRANSCODE
>      @ 28,76 SAY "Party Mark:" GET MAINACC->PARTY_MRK
>      @ 29,76 SAY " City Code:" GET MAINACC->CITY_CODE
>      @ 30,76 SAY "Payment by:" GET ORDPAY
>
>      @ 31,24 SAY "Order Through:" GET LETTERM
>      @ 31,55 SAY "Dt." GET LETTERDT
>      @ 32,24 SAY "Agent :" GET TAGNAME
>      @ 32,66 SAY "O.F.No:" GET OFNUM
>     READ
>
> Is there any way to increase the Font Size while entering keyboard input 
> on the screen ?
>
> Is there any other way to READ  inputs ?
>
> Your help is appreciated.
>
> Regards
>
> Jayaram
>
>
>