Resizeable screen formats

Re: Resizeable screen formats

Postby Antonio Linares » Wed Jun 01, 2016 10:36 pm

it is the way they are designed in Windows GUI

A text has a different height from a checkbox or a combobox, etc.

Of course you can simulate text coordinates, using different fonts, etc. but then your dialogs will not look like a standard Windows app

Pritpal Bedi implemented a GT driver to do that. FWH uses a different approach to create true Windows looking apps
regards, saludos

Antonio Linares
www.fivetechsoft.com
User avatar
Antonio Linares
Site Admin
 
Posts: 42203
Joined: Thu Oct 06, 2005 5:47 pm
Location: Spain

Re: Resizeable screen formats

Postby TimStone » Wed Jun 01, 2016 10:49 pm

That is interesting. When creating a resource, I use the same sizes for Static and Edit controls ( Say and Get equivalents ). Then I can place them on the exact same lines. ( I edit the .rc manually, and thus I'm pixel accurate for all placements horizontally and vertically ).

The fonts are inherited from Windows settings. It works quite cleanly. However, it can be a bit more work.

I asked about this because all of the samples define using @ SAY and @ GET and some of the feature alignments depend on those rather than defined dialogs in an .rc.

Tim
Tim Stone
http://www.MasterLinkSoftware.com
http://www.autoshopwriter.com
timstone@masterlinksoftware.com
Using: FWH 23.10 with Harbour 3.2.0 / Microsoft Visual Studio Community 2022-24 32/64 bit
User avatar
TimStone
 
Posts: 2950
Joined: Fri Oct 07, 2005 1:45 pm
Location: Trabuco Canyon, CA USA

Re: Resizeable screen formats

Postby James Bott » Fri Jun 03, 2016 12:59 am

Tim,

I did some testing and I wonder about doing any dialog resizing. I modified TDialog to automatically resize a dialog (from an RC file) and all the controls based on the screen size. The top left dialog in the attached image is the standard size. The bottom left one was resized to occupy the proportionally same width and height of the screen as the small dialog would if it was on a standard 800x600 pixel screen. My screen is 1366 x 768. The dialog on the right is a standard dialog that is part of the Windows 10 OS. Obviously Windows is not resizing it's own dialogs.

So the original FW dialog looks similar to the Windows 10 OS dialog. The resized dialog looks strange. It would look stranger still had I resized the font also. My eyes are not all that good anymore but I can still see the small font OK.

So, I wonder why you want to resize the dialogs? Maybe you could show us a sample dialog that you want to resize?

Image
FWH 18.05/xHarbour 1.2.3/BCC7/Windows 10
User avatar
James Bott
 
Posts: 4840
Joined: Fri Nov 18, 2005 4:52 pm
Location: San Diego, California, USA

Re: Resizeable screen formats

Postby TimStone » Fri Jun 03, 2016 1:12 am

James,

Actually I do not want to resize the dialogs, but I've had a few clients think that would be a great idea. I really needed to get some input, do some tests, and then I can respond intelligently.

We will have some interesting issues with future Windows 10 displays. I have a Surface Book with a high resolution monitor. However, Windows likes to adjust the image automatically. I have two display sizes the user can select. The widescreen mode is 1920 x 1080. It looks great on a regular hi-res monitor. However, on the Surface Book, it has major display issues. You can turn off that display resizing on an application, but then it just doesn't fit well to the monitor because the fonts become tiny. So I set the program to the 1024 x 768 size. The problem with that is the data fields are very compressed and for my clients who have "older eyes", they complain it is not as easy to see. It works on the Surface Book, but still, it's all those fields pressed together. The issue is the amount of data that needs to be displayed, and I only have the top half of the screen, because in most cases the lower half is a browse control for the full database.

Pleasing clients is the challenge ... but I try. They are the ones who pay for the support and updates so solutions need to be found.
Tim Stone
http://www.MasterLinkSoftware.com
http://www.autoshopwriter.com
timstone@masterlinksoftware.com
Using: FWH 23.10 with Harbour 3.2.0 / Microsoft Visual Studio Community 2022-24 32/64 bit
User avatar
TimStone
 
Posts: 2950
Joined: Fri Oct 07, 2005 1:45 pm
Location: Trabuco Canyon, CA USA

Re: Resizeable screen formats

Postby Bayron » Fri Jun 03, 2016 2:42 am

I came up with my own solution to screen resolution...
It was involved with some old fashion math calculations from screen resolution...

So I control the size of every control

Code: Select all  Expand view  RUN
nPorcentaje := 50;  //Taken from a user defined configuration file

        nX1 := ( ( ( oDIALOG:nWidth - ( oDIALOG:nWidth * nPorcentaje )  ) / 2 ) / 2 )
        nX2 := ( ( oDIALOG:nWidth / 2 )- nX1 )
        nY1 := ( ( ( oDIALOG:nHeight - ( oDIALOG:nHeight * nPorcentaje ) ) / 2 ) / 2 )
        nY2 := ( ( oDIALOG:nHeight / 2 ) - nY1 )
       
        aAdd( Cuadro1 , { nY1 , nX1 , nY1 + ( INT( ( nY2 - nY1 ) * .46 ) ) , ;
              nX1 + ( INT( ( nX2 - nX1 ) * .40 ) ) } )
        aAdd( Cuadro2 , { nY1 + 5 , nX1 + ( INT( ( nX2 - nX1 ) * .40 ) + 4 ) , ;
              nY1 + ( INT( ( nY2 - nY1 ) * .57 ) - 2 ) , nX1 + ( INT( ( nX2 - nX1 ) )- 1 ) } )
        aAdd( Cuadro3 , { nY1 + ( INT( ( nY2 - nY1 ) * .46 ) ) , nX1 , ;
              nY1 + ( INT( ( nY2 - nY1 ) ) ) , nX1 + ( INT( ( nX2 - nX1 ) * .40 )  ) } )
        aAdd( Cuadro4 , { nY1 + 5 + ( INT( ( nY2 - nY1 ) * .57 ) ) , ;
              nX1 + 5 + ( INT( ( nX2 - nX1 ) * .40 ) ) , nY1 + ( INT( ( nY2 - nY1 ) - 5 ) ) , ;
              nX1 + ( INT( ( nX2 - nX1 ) * .60 ) ) } )
        aAdd( Cuadro5 , { nY1 + ( INT( ( nY2 - nY1 ) * .57 ) ) , ;
              nX1 + ( INT( ( nX2 - nX1 ) * .60) ) , nY1 + ( INT( ( nY2 - nY1 ) - 1 ) ) , ;
              nX1 + ( INT( ( nX2 - nX1 ) ) - 1 ) } )
       

DEFINE FONT oFont1 NAME 'Verdana' ;
            SIZE 0 , ( 22 * ( Min ( oDIALOG:nWidth / 1680 , oDIALOG:nHeight / 1050 ) ) ) * nPorcentaje ; //To compensate for wide screen and standard resolutions...
            BOLD


@ ( Cuadro1[1][1] + ( Btn1Height * 1 ) + 9 ) , ( Cuadro1[1][2] + ( Btn1Width * 0 ) +  8 ) ;
            BTNBMP oBtnF[ 1] OF oDIALOG ;
            SIZE ( Btn1Width - 4 ) , ( Btn1Height - 4 ) ;
            CENTER PIXEL ADJUST NOBORDER ;
            FONT oFont1 ;
            PROMPT "BOTON1"




100% of screen size

Image

50% of screen size

Image
=====>

Bayron Landaverry
(215)2226600 Philadelphia,PA, USA
+(502)46727275 Guatemala
MayaBuilders@gMail.com

FWH12.04||Harbour 3.2.0 (18754)||BCC6.5||UEstudio 10.10||
Windows 7 Ultimate

FiveWin, One line of code and it's done...
User avatar
Bayron
 
Posts: 815
Joined: Thu Dec 24, 2009 12:46 am
Location: Philadelphia, PA

Re: Resizeable screen formats

Postby dutch » Fri Jun 03, 2016 7:16 am

How about EasyDialog of Timm?
Is it apart of EasyReport?
If so, Is it possible to include into Fivewin?

With Respectation.
Regards,
Dutch

FWH 19.01 / xHarbour Simplex 1.2.3 / BCC73 / Pelles C / UEStudio
FWPPC 10.02 / Harbour for PPC (FTDN)
ADS V.9 / MySql / MariaDB
R&R 12 Infinity / Crystal Report XI R2
(Thailand)
User avatar
dutch
 
Posts: 1554
Joined: Fri Oct 07, 2005 5:56 pm
Location: Thailand

Re: Resizeable screen formats

Postby Antonio Linares » Fri Jun 03, 2016 7:30 am

regards, saludos

Antonio Linares
www.fivetechsoft.com
User avatar
Antonio Linares
Site Admin
 
Posts: 42203
Joined: Thu Oct 06, 2005 5:47 pm
Location: Spain

Re: Resizeable screen formats

Postby Silvio.Falconi » Fri Jun 03, 2016 9:22 am

Antonio,
it is compiled but when I run the example it want a dbf file, wher eI can found it ?
Since from 1991/1992 ( fw for clipper Rel. 14.4 - Momos)
I use : FiveWin for Harbour November 2023 - January 2024 - Harbour 3.2.0dev (harbour_bcc770_32_20240309) - Bcc7.70 - xMate ver. 1.15.3 - PellesC - mail: silvio[dot]falconi[at]gmail[dot]com
User avatar
Silvio.Falconi
 
Posts: 7090
Joined: Thu Oct 18, 2012 7:17 pm

Re: Resizeable screen formats

Postby Antonio Linares » Fri Jun 03, 2016 9:23 am

I have not used it so I can't tell you
regards, saludos

Antonio Linares
www.fivetechsoft.com
User avatar
Antonio Linares
Site Admin
 
Posts: 42203
Joined: Thu Oct 06, 2005 5:47 pm
Location: Spain

Re: Resizeable screen formats

Postby James Bott » Fri Jun 03, 2016 1:59 pm

Tim,

Surface Book


Ah, yes, that was the reason Microsoft came up with the whole new "Modern" interface design.

Can we see a screenshot of the entire screen from the Surface Book showing the issue?

Of course, you would need to also resize the font which I didn't do in my test.

Also, don't you have to put up the on-screen keyboard? Doesn't that take up half the screen? It would seem that you really need a whole new interface design for the Surface Book (and other tablets).

Regards
FWH 18.05/xHarbour 1.2.3/BCC7/Windows 10
User avatar
James Bott
 
Posts: 4840
Joined: Fri Nov 18, 2005 4:52 pm
Location: San Diego, California, USA

Re: Resizeable screen formats

Postby TimStone » Fri Jun 03, 2016 6:47 pm

James,

The Surface Book is actually a notebook computer. Yeah, you can detach the screen and use it as a tablet, but I wouldn't do that with this application. Also, with the pen, you can use handwriting for input and that takes up very little screen space.

The issue is Microsoft's resizing feature and those algorithms are changing as they receive input. Time will tell how it resolves, and how it ends up applying to other Win 10 devices, especially desktops.

Screen shots are difficult, but perhaps lunch soon.

Tim
Tim Stone
http://www.MasterLinkSoftware.com
http://www.autoshopwriter.com
timstone@masterlinksoftware.com
Using: FWH 23.10 with Harbour 3.2.0 / Microsoft Visual Studio Community 2022-24 32/64 bit
User avatar
TimStone
 
Posts: 2950
Joined: Fri Oct 07, 2005 1:45 pm
Location: Trabuco Canyon, CA USA

Previous

Return to FiveWin for Harbour/xHarbour

Who is online

Users browsing this forum: Google [Bot] and 9 guests

cron