Hi Roger
How can I center a screen at the end of the desktop?
How can I center a screen at the end of the desktop?
How can I center a screen at the end of the desktop?
Nolberto Paulino
Regards
Regards
Re: How can I center a screen at the end of the desktop?
I don't understand the question.
What do you mean by the "end of the desktop" ?
Do you want a dialog centered vertically but aligned to the right?
Do you want a dialog centered horizontally but aligned to the bottom?
Or am I on the wrong track here?
What do you mean by the "end of the desktop" ?
Do you want a dialog centered vertically but aligned to the right?
Do you want a dialog centered horizontally but aligned to the bottom?
Or am I on the wrong track here?
The eXpress train is coming - and it has more cars.
Re: How can I center a screen at the end of the desktop?
I'm sending you a photo as I want it to fit on any pc screen.
It's for use on a pc touch tablet.
I'm sending you a photo as I want it to fit on any pc screen
It's for use on a pc touch tablet.
I'm sending you a photo as I want it to fit on any pc screen
rdonnay wrote:I don't understand the question.
What do you mean by the "end of the desktop" ?
Do you want a dialog centered vertically but aligned to the right?
Do you want a dialog centered horizontally but aligned to the bottom?
Or am I on the wrong track here?
- Attachments
-
- Sin título.jpg (316.78 KiB) Viewed 9632 times
Nolberto Paulino
Regards
Regards
Re: How can I center a screen at the end of the desktop?
Here is a sample test program:
Code: Select all
#INCLUDE "dcdialog.CH"
FUNCTION Main()
LOCAL GetList[0]
FOR i := 1 TO 10
@ i,1 DCSAY 'This is line ' + Alltrim(Str(i)) SAYSIZE 100
NEXT
DCREAD GUI FIT EVAL {|o|AlignWindow(o)}
RETURN nil
* ---------
FUNCTION AlignWindow( oDlg )
LOCAL aCoords := DC_GetWorkArea(), nBottom, nLeft
nBottom := AppDeskTop():currentSize()[2] - aCoords[4]
nLeft := AppDeskTop():currentSize()[1]/2 - oDlg:currentSize()[1]/2
oDlg:setPos({nLeft,nBottom})
RETURN nil
* ---------
PROC appsys
The eXpress train is coming - and it has more cars.
Re: How can I center a screen at the end of the desktop?
Thank you
rdonnay wrote:Here is a sample test program:Code: Select all
#INCLUDE "dcdialog.CH" FUNCTION Main() LOCAL GetList[0] FOR i := 1 TO 10 @ i,1 DCSAY 'This is line ' + Alltrim(Str(i)) SAYSIZE 100 NEXT DCREAD GUI FIT EVAL {|o|AlignWindow(o)} RETURN nil * --------- FUNCTION AlignWindow( oDlg ) LOCAL aCoords := DC_GetWorkArea(), nBottom, nLeft nBottom := AppDeskTop():currentSize()[2] - aCoords[4] nLeft := AppDeskTop():currentSize()[1]/2 - oDlg:currentSize()[1]/2 oDlg:setPos({nLeft,nBottom}) RETURN nil * --------- PROC appsys
Nolberto Paulino
Regards
Regards
Re: How can I center a screen at the end of the desktop?
Thank you
digitsoft wrote:Thank you
rdonnay wrote:Here is a sample test program:Code: Select all
#INCLUDE "dcdialog.CH" FUNCTION Main() LOCAL GetList[0] FOR i := 1 TO 10 @ i,1 DCSAY 'This is line ' + Alltrim(Str(i)) SAYSIZE 100 NEXT DCREAD GUI FIT EVAL {|o|AlignWindow(o)} RETURN nil * --------- FUNCTION AlignWindow( oDlg ) LOCAL aCoords := DC_GetWorkArea(), nBottom, nLeft nBottom := AppDeskTop():currentSize()[2] - aCoords[4] nLeft := AppDeskTop():currentSize()[1]/2 - oDlg:currentSize()[1]/2 oDlg:setPos({nLeft,nBottom}) RETURN nil * --------- PROC appsys
Nolberto Paulino
Regards
Regards