Version 21 of PocketPC

Updated 2003-06-19 17:13:41

Marketing name used by Microsoft since about 2000 for Windows/CE, which runs on little handheld computers (PDAs) with small screens, e.g. iPAQ or Yakumo Alpha.

To port a Tk app to a PocketPC, consider that the screen is only 240x320 pixels, of which the top menu bar and at least the bottom right corner are not at the app's disposition.

As an example for porting, here is code with which MPJ adapted the code in Chess in Tcl to a HP Jornada:

 ###  Code to look better on a PocketPC
  wm geometry . 240x268+0+1
  . config -menu [menu .m]
  .m add casc -label Game -menu [menu .m.game -tearoff 0]
  .m.game add comm -label Undo -comm {game undo;  game drawSetup .c}
  .m.game add comm -label Reset -comm  {game reset; game drawSetup .c}
  .m.game add comm -label Flip -comm {game flipSides .c}
  .m.game add separator
  .m.game add comm -label Exit -comm exit
  game drawBoard .c -color {blue tan3}

http://mini.net/files/ChessOnJornada.jpg


Quick question: As an aside, how do people produce the PocketPC screenshots I see around the Wiki? - RS uses Magic SS [L1 ] which is only 8K executable, but produces 276KB .bmp output (so best delete soon) - associated with a hardware button, its operation is pretty nice. I then typically load the mirrored copy (docked) of the .bmp into an image editor and convert it to JPEG there.

MNO Thanks for the suggestion - it works very well for me too. Now I have a further question: I notice that the above code and the code for iFile 1.1 (and probably tkcon 2.3 but I haven't checked) include menus and the screenshot above clearly shows the menu appearing in the bottom left. This, for some reason, is not working for me. I am using the 8.3.4 binaries as posted on the Windows/CE page and iFile 1.1 from its page (as well as tkcon 2.3 downloaded elsewhere). I ran a quick test in tkcon, doing

 package require Tk
 . config -menu [menu .m]
 .m.game add comm -label Exit -comm exit

but I still don't see a menu anywhere even when activating (i.e. bringing to the front) the . window.

Is anybody else using the 8.3.4 binaries but seeing the menus? (i.e. have I messed up something in my installation or is this behaviour common to everybody?)

Ahh - I just re-read the README in that distribution, which has "Menus don't work correctly" as one of the TO-DO items. Any idea when/if menus will be fixed in the 8.3.4 distro?



PDA | Arts and crafts of Tcl-Tk programming