Author Topic: MasmBasic  (Read 2770 times)

Mike Lobanovsky

  • Full Member
  • ***
  • Posts: 161
    • View Profile
    • Freestyle BASIC Script Language
Re: MasmBasic
« Reply #15 on: 09. November 2016, 03:35:02 »
Jochen,

I'm greatful for the invitation and also for choosing my avatar for your experimentation (I wish I could do the same in return on the FBSL forum) but I won't run your exe pack on my machines for the reasons I've stated earlier regarding the validity of executable file names and the uncertainty of the outcome of such experimentation from the file system integrity perspective.

I am sorry but that's the point I'm going to stand by, paranoia or schizophrenia, whatever. :)
Mike
____________________________________________________________________________________________
(3.6GHz i5-3470, 16GB RAM / 2 x nVidia GTX 650Ti SLI-bridged, 2GB VRAM / x64 Win 7, x86 elementaryOS Luna)

jj2007

  • Full Member
  • ***
  • Posts: 120
  • MasmBasic rocks
    • View Profile
    • MasmBasic - faster than C
Re: MasmBasic
« Reply #16 on: 09. November 2016, 11:17:58 »
validity of executable file names and the uncertainty of the outcome of such experimentation from the file system integrity perspective.

Mike,

These are absolutely valid Unicode file names. Microsoft takes pride in that, and if a Billion Chinese users had the same fear as you, it would be bad for their business.

At least on my Italian OS, none of these exes had any problems *)

You might check your views on locales. Afaik Windows Explorer doesn't care for locales, it just uses Unicode under the hood, even if it can't display the font. Do you see them in Explorer, actually? I see all file names properly, and I doubt that all these fonts are installed by default.

It is a problem, though, for non-Unicode file managers like my old FreeCommander version. When I double-click the ? ? ? ? ? ? ? ?.exe, nothing happens. However, even then, file integrity problems should be a phenomenon of the very very early days of Windows.

P.S.: I've had a look at MSDN, who confirm what I wrote on the use of Unicode above. There is one notable exception: The use of the Yen symbol in applications that work on FAT filesystems:
Quote
For security reasons, your applications should not typically allow the character U+00A5 in a Unicode string that might be converted for use as a FAT file name.

*) I just tested the PlayingWithUnicode.zip attached above also on a FAT32 USB stick. Everything works like a charm, including saving rotated images in Hindi, Chinese, Russian etc; I did a scandisk afterwards, no problems found.
« Last Edit: 09. November 2016, 13:23:51 by jj2007 »

Mike Lobanovsky

  • Full Member
  • ***
  • Posts: 161
    • View Profile
    • Freestyle BASIC Script Language
Re: MasmBasic
« Reply #17 on: 09. November 2016, 22:03:40 »
This is a "clean" (of all localization packs; LCID=1033) installation of Win 7 Pro Sp1 I'm using for C/C++ development:
Mike
____________________________________________________________________________________________
(3.6GHz i5-3470, 16GB RAM / 2 x nVidia GTX 650Ti SLI-bridged, 2GB VRAM / x64 Win 7, x86 elementaryOS Luna)

jj2007

  • Full Member
  • ***
  • Posts: 120
  • MasmBasic rocks
    • View Profile
    • MasmBasic - faster than C
Re: MasmBasic
« Reply #18 on: 10. November 2016, 02:44:43 »
This is a "clean" (of all localization packs; LCID=1033) installation of Win 7 Pro Sp1 I'm using for C/C++ development:

Thanks, Mike. Weird that Explorer can handle Unicode filenames (the images are loaded etc) but can't display them, while the message boxes have a bad caption but Chinese text is displayed properly. Mysteries of Windows 8)

Mike Lobanovsky

  • Full Member
  • ***
  • Posts: 161
    • View Profile
    • Freestyle BASIC Script Language
Re: MasmBasic
« Reply #19 on: 10. November 2016, 08:42:42 »
Mysteries of Windows 8)

Yeah, there's also absolutely no problem with net browsing either. Prolly all major browsers have their own locale support utils to cover most if not all of the browser page text requests. I wish I knew how to handle those to be able to use them too on the installations that don't support those CPs and fonts officially. ;)
Mike
____________________________________________________________________________________________
(3.6GHz i5-3470, 16GB RAM / 2 x nVidia GTX 650Ti SLI-bridged, 2GB VRAM / x64 Win 7, x86 elementaryOS Luna)

jj2007

  • Full Member
  • ***
  • Posts: 120
  • MasmBasic rocks
    • View Profile
    • MasmBasic - faster than C
Displaying animated GIF images
« Reply #20 on: 26. November 2016, 10:43:56 »
Download update 26 Nov 16:

Inter alia, GuiImage handles now animated GIFs automatically; search \Masm32\MasmBasic\MbGuide.rtf for .MbGui

Example (a complete Windows GUI application with a sizeable window):
Code: [Select]
include \masm32\MasmBasic\Res\MbGui.asm
Event Paint
  GuiImage "http://retrogamecoding.org/board/index.php?action=dlattach;attach=1045;type=avatar", fit
GuiEnd

The more elaborate attached demo displays (provided MasmBasic is installed)
- a static background car.jpg
- an avatar (members only, sorry :biggrin:)
- a smiley (the car needed a little decoration)
- and an animated GIF from the resources

jj2007

  • Full Member
  • ***
  • Posts: 120
  • MasmBasic rocks
    • View Profile
    • MasmBasic - faster than C
Re: MasmBasic
« Reply #21 on: 02. December 2016, 10:14:24 »
MasmBasic update 2 December got several new features (see here for some examples), inter alia the StringToArray function can now be fed with files from disk, from the internet, and with a text file embedded in the resouce section:

include \masm32\MasmBasic\MasmBasic.inc Init
  StringToArray 123, my$()            ; 123 is the resource ID
  For_ ct=0 To Min(39, eax)            ; loop max 40 times
      PrintLine Str$("Line %i\t", ct), my$(ct)
  Next
  Inkey "--- hit any key ---"
EndOfCode

Rsrc            ; when hitting F6, RichMasm exports this section to [filename].rc
123 RCDATA "\\Masm32\\MasmBasic\\MasmBasic.inc"
Rsrc

jj2007

  • Full Member
  • ***
  • Posts: 120
  • MasmBasic rocks
    • View Profile
    • MasmBasic - faster than C
Re: MasmBasic
« Reply #22 on: 27. January 2017, 01:29:42 »
MasmBasic updated, see here for reasons.