Recent Posts

Pages: 1 ... 7 8 [9] 10
81
EZGUI 5 support forum / Re: EZ_GetImageSize
« Last post by Chris Boss on May 29, 2022, 08:57:18 pm »
EZGUI can not load image files other than Bitmaps (and icons, cursors).

The code you are referring to was based on code posted by Dan Ginzel which uses GDI+ API's to load JPG, PNG, etc and then return an EZGUI Picture string.

The code was on the forum, but I lost all the forum posts when upgrading the forum and have yet been bale to restore any of the old posts.

82
EZGUI 5 support forum / Re: EZ_GetImageSize
« Last post by Brian Reynolds on May 29, 2022, 06:21:32 pm »
That's odd. I got the following clip from your website a fair while ago but its not the complete info that was on the site. I can't find the complete info now. It was for loading files other than .BMP, such as .JPG, .PNG, etc. I used it a lot:

EZ_GetImageSize F$, W&, H&
Reads an image file and returns the size (width and height) in pixels, without loading.
F$ is the filename (full path) of any Image file windows supports (ie. JPeg, PNG,
GIF)
W& is a long variable to return the width in pixels
H& is a long variable to return the height in pixels
P$ = EZ_LoadImage (F$, W&, H&, QFlag&)
Loads an image file.
F$ is the filename (full path) of any Image file windows supports (ie. JPeg, PNG,
GIF)
W& is the requested width of the image (in pixels)
H& is the requested height of the image (in pixels)
QFlag& if set to non-zero (1) requests best quality possible
If W& and H& are set to -1 (or even zero) then the routine will use the actual size of
the image on file.
The return value (P$) is a valid EZGUI Picture string similiar to the return value of
EZ_LoadPicture.
83
EZGUI 5 support forum / Re: EZ_GetImageSize
« Last post by Chris Boss on May 29, 2022, 05:58:31 pm »
No such command in EZGUI.

Likely you may have used a function wrapper for other commands which you found on the forum.

Often when i write such a wrapper function I name it with the EZ_ prefix.

The command you need is:

 EZ_GetBitmapInfo hBmp&, W&, H&, PixelBits&, DIBPtr&

This will require calling the EZ_ImageHandle function to get an actual Bitmap handle from an EZGUI Picture name string (ie. EZ_LoadImage returns an internal name EZGUI uses to track a bitmap).

84
EZGUI 5 support forum / EZ_GetImageSize
« Last post by Brian Reynolds on May 29, 2022, 12:17:31 am »
I have had to reinstall EZGUI50pro and I can't find any details on the use of EZ_GetImageSize.
This may be an update after I bought EZGUI50pro.
Help required.
85
EZGUI 5 support forum / Re: Strange event
« Last post by Chris Boss on May 26, 2022, 08:57:16 pm »
That is not normal and surely not a problem with EZGUI.

Maybe a problem with the PB IDE, possibly some system corruption (ie. memory).

I would reboot your PC and try again. If it is temporary because of some kind of memory corrupt that should fix it.

86
EZGUI 5 support forum / Strange event
« Last post by Brian Reynolds on May 26, 2022, 07:22:42 pm »
I have come across something very weird when compiling code.
When I click on the compile button it takes a fair while to actually do anything and when it does it goes to the PowerBasic Home Page.
This even happens when I try to compile one of your Codeclips.
I've never had this happen before and I can't figure out why it happens.
Can you offer a suggestioon to fix it?
87
EZGUI 5 support forum / Re: Printing Unicode characters
« Last post by Chris Boss on April 06, 2022, 10:07:49 pm »
If the character set you require fits in 256 characters then EZGUI's ascii based fonts are   fine.

I would suggest though using the Windows utility "Character Map" to browse the fonts and their character sets.
Very useful tool.

You will find it on the Windows menu under "Windows Accessories"

88
EZGUI 5 support forum / Re: Printing Unicode characters
« Last post by Brian Reynolds on April 05, 2022, 08:16:37 pm »
Chris,
I was using the Arial that came with my Windows 10.
However, I have just managed to overcome the problem, using the following:

EZ_DefFont 50, "Broadway", 11, "BV[48#]"

and Printing a capital "I"

Thank you for your trouble

Brian Reynolds.
 
89
EZGUI 5 support forum / Re: Printing Unicode characters
« Last post by Chris Boss on April 05, 2022, 03:35:15 pm »
When you say printing do you mean to a printer or simply to the screen ?

Unicode characters require a unicode capable font and must be drawn using an API which supports unicode.

EZGUI is ASCI only.

That said, I current have two projects I am working on (one finished) which needs to display text in languages like Japanese which require Unicode and it was not that difficult to implement using the WIN32 API and integrate into an EZGUI app.

First I had to create my fonts using the CreateFontW API function.

Then I was able to draw the text using either the TextOutW or DrawtextW API functions.

The same API's can be used either the screen or a printer. You simply select the font handle into the DC you are drawing into and then select the previous one back in when done.

Both when drawing to the screen or printer EZGUI provides you with the DC handle (device context).
90
EZGUI 5 support forum / Printing Unicode characters
« Last post by Brian Reynolds on April 04, 2022, 09:50:17 pm »
Can anyone help me with printing very high HEX or UNICODE characters?

Using Windows Character Map, I select Arial and scroll down to about four-fifths of the depth and there's a "Full Block" (black block of character with and depth).

It shows at the bottom what I assume to be a Hex num,ber "U+2588"

I normally print these codes (255 and below) by converting them to a ASCII number but I can't figure how I can do this one.

Can anyone help? 
Pages: 1 ... 7 8 [9] 10