Recent

Author Topic: Windows Mobile 6.5 and FullScreen ?  (Read 13332 times)

swierzbicki

  • Full Member
  • ***
  • Posts: 177
Windows Mobile 6.5 and FullScreen ?
« on: June 26, 2013, 10:06:14 am »
Hello,

I'm really lost ! I can't find a way to make my application Fullscreen !
Yes, I have read the Wiki and yes I've search arroun dthe web (google wasn't my friend).

I'm using an Motorola MC3190 Device, has anyone been able to switch to full screen ?

Thank you in advance
Lazarus 1.6.2
fpc 3.0.0
wince/win32/win64
delphi berlin

zariq

  • Full Member
  • ***
  • Posts: 109

swierzbicki

  • Full Member
  • ***
  • Posts: 177
Re: Windows Mobile 6.5 and FullScreen ?
« Reply #2 on: June 27, 2013, 07:43:28 pm »
Yes ! The menubar is still displayed... It's really a showstopper forme me (ans m'y usées).
Lazarus 1.6.2
fpc 3.0.0
wince/win32/win64
delphi berlin

zariq

  • Full Member
  • ***
  • Posts: 109
Re: Windows Mobile 6.5 and FullScreen ?
« Reply #3 on: June 27, 2013, 10:08:36 pm »
I tried it a few years ago and didn't get it to work either. Around that time I gave up on windows mobile and decided to wait for android. You could report it as a bug and see if anything happens.

swierzbicki

  • Full Member
  • ***
  • Posts: 177
Re: Windows Mobile 6.5 and FullScreen ?
« Reply #4 on: July 02, 2013, 11:42:00 am »
Too bad for the bottom menubar but I'll live with it.
I'm almost done with my fullscreen issue : have a look at the two attached screenshoots :

The first picture display my form with it's top taskbar.
The second picture is the same form but with the taskbar disabled (see code bellow).

Code: [Select]
procedure TfrmPrincipale.RemoveTaskbar(AFullScreen: Boolean);
const
  MENU_HEIGHT = 20;
var
  rc: TRect;
begin
  if AFullScreen then
  begin
    GetWindowRect(Handle, @rc);

    SHFullScreen(Handle, SHFS_HIDETASKBAR);

    MoveWindow(Handle,
    rc.left,
    rc.top-MENU_HEIGHT,
    rc.right,
    rc.bottom+MENU_HEIGHT,
    TRUE);
  end
  else
  begin
    GetWindowRect(Handle, @rc);
    SHFullScreen(Handle, SHFS_SHOWTASKBAR);
    MoveWindow(Handle,
         rc.left,
         rc.top+MENU_HEIGHT,
         rc.right,
         rc.bottom-MENU_HEIGHT,
         TRUE);
  end;
end;

GetWindowRect(Handle, @rc) retreive this informations :

rc.left : 0
rc.top : 20
rc.right : 240
rc.bottom : 240

« Last Edit: July 26, 2013, 01:45:58 pm by swierzbicki »
Lazarus 1.6.2
fpc 3.0.0
wince/win32/win64
delphi berlin

nightrider

  • Full Member
  • ***
  • Posts: 139
Re: Windows Mobile 6.5 and FullScreen ?
« Reply #5 on: July 18, 2013, 11:36:39 pm »
Hi!

I have an application that runs in full screen under windows 6 and  6.x. It was developed and compiled under Lazarus 0.9.30. It is stable and reliable. It uses SQLite.

When I try to migrate it to Lazarus 1.0.6 I was informed by mr. Felipe Monteiro that someone made a mistake in one version between 0.9.30 and 1.0.6 that doesn't allow use fully full screen. There is a bug report in the list of errors that report this. I don't know how to find it. I confess. But I already saw it.

If you want to try with Lazarus 0.9.30 only to see if it solves your problem I can send you a copy of mine.

Unfortunately, I don't have the knowledge need to debug these specific bug...

Cheers

Greetings from São Paulo - Brasil

Ricardo

swierzbicki

  • Full Member
  • ***
  • Posts: 177
Re: Windows Mobile 6.5 and FullScreen ?
« Reply #6 on: July 26, 2013, 01:43:53 pm »
After playing a lot (better saying hitting my head on walls  >:( ), I have found to make my application cohabitate with the Windows CE Top menu (where time, wifi signal... are located) and Bottom menus (where the windows button and the (OK) or (X) button are located).

- set font to Tahoma 8 : you can get Exception - TWinControl.WMSize loop detected, the widgetset does not like the LCL bounds or sends unneeded wmsize messages - if controls are resized due to high font size (look OK at design time but will hurts at runtime)

- Don't make your controls wider or larger than your native pda screen resolution or you will get  Exception - TWinControl.WMSize loop detected ... - too

- On the OnPaint :
I'm calling SHOWTASKBAR to overlap my form menu bar (which is displayed when the PDA is coming back to life after a standby)
Code: [Select]
SHFullScreen(TForm(Sender).Handle, SHFS_SHOWTASKBAR);

- On the OnCreate Event :
Windows Top menu is 20 pixel height. Windows Bottom menu is 34 pixel height. Remove them from you form Height
I'm using the combinaison BorderStyle:=bsDialog and WindowState:=wsMaximized to not display the (OK) or (X) button.

Code: [Select]
  TForm(Sender).BorderStyle:=bsDialog;
  TForm(Sender).Top := 20;
  TForm(Sender).Left := 0;
  TForm(Sender).Width := 240;
  TForm(Sender).Height := 186;
  TForm(Sender).WindowState:=wsMaximized; 


This is not really smart but I can get my application to use all the screen workarea (minus bottom and top menu bar).
If someone has a better way of doing this.... you are welcome !

B.R.
« Last Edit: July 26, 2013, 01:50:12 pm by swierzbicki »
Lazarus 1.6.2
fpc 3.0.0
wince/win32/win64
delphi berlin

BigChimp

  • Hero Member
  • *****
  • Posts: 5740
  • Add to the wiki - it's free ;)
    • FPCUp, PaperTiger scanning and other open source projects
Re: Windows Mobile 6.5 and FullScreen ?
« Reply #7 on: July 26, 2013, 02:28:01 pm »
@swierzbicki, please post at least your Lazarus version - it really matters with Windows CE development because some bugs have been introduced in certain versions.
Want quicker answers to your questions? Read http://wiki.lazarus.freepascal.org/Lazarus_Faq#What_is_the_correct_way_to_ask_questions_in_the_forum.3F

Open source including papertiger OCR/PDF scanning:
https://bitbucket.org/reiniero

Lazarus trunk+FPC trunk x86, Windows x64 unless otherwise specified

swierzbicki

  • Full Member
  • ***
  • Posts: 177
Re: Windows Mobile 6.5 and FullScreen ?
« Reply #8 on: July 26, 2013, 03:12:43 pm »
Hi BigChimp,

Lazarus 1.0.10 r41613 FPC 2.6.2 i386-win32-win32/win64
Lazarus 1.6.2
fpc 3.0.0
wince/win32/win64
delphi berlin

BigChimp

  • Hero Member
  • *****
  • Posts: 5740
  • Add to the wiki - it's free ;)
    • FPCUp, PaperTiger scanning and other open source projects
Re: Windows Mobile 6.5 and FullScreen ?
« Reply #9 on: July 26, 2013, 03:34:35 pm »
Ok, thanks. There might be some wince fixes in trunk/development version, but I really don't know - you'd have to go through the changelog.
Want quicker answers to your questions? Read http://wiki.lazarus.freepascal.org/Lazarus_Faq#What_is_the_correct_way_to_ask_questions_in_the_forum.3F

Open source including papertiger OCR/PDF scanning:
https://bitbucket.org/reiniero

Lazarus trunk+FPC trunk x86, Windows x64 unless otherwise specified

swierzbicki

  • Full Member
  • ***
  • Posts: 177
Re: Windows Mobile 6.5 and FullScreen ?
« Reply #10 on: July 26, 2013, 04:28:02 pm »
I will tempted to download the latest nighty build : Lazarus 1.0.11 + FPC 2.7.1, but I don't find the corresponding Cross compiler installer (only available for FPC 2.6.2 or 2.6.3)
Lazarus 1.6.2
fpc 3.0.0
wince/win32/win64
delphi berlin

 

TinyPortal © 2005-2018