Show and scroll with Meta-file
-
- Posts: 1102
- Joined: Mon Oct 17, 2005 5:41 am
- Location: Belgium
- Contact:
Show and scroll with Meta-file
Hi,
I'm creating drawings in meta-files, and show them in a window.
Sometimes the drawings ar larges than the screen, and want to move around like Adobe-reader.
How can I do this?
I'm creating drawings in meta-files, and show them in a window.
Sometimes the drawings ar larges than the screen, and want to move around like Adobe-reader.
How can I do this?
Regards,
Marc
FWH32+xHarbour | FWH64+Harbour | BCC | DBF | ADO+MySQL | ADO+MariaDB | ADO+SQLite
Marc
FWH32+xHarbour | FWH64+Harbour | BCC | DBF | ADO+MySQL | ADO+MariaDB | ADO+SQLite
- nageswaragunupudi
- Posts: 8017
- Joined: Sun Nov 19, 2006 5:22 am
- Location: India
- Contact:
Re: Show and scroll with Meta-file
can you please send me a sample metafile by email?
nageswaragunupudi [at] gmail [dot] com
nageswaragunupudi [at] gmail [dot] com
Regards
G. N. Rao.
Hyderabad, India
G. N. Rao.
Hyderabad, India
- nageswaragunupudi
- Posts: 8017
- Joined: Sun Nov 19, 2006 5:22 am
- Location: India
- Contact:
Re: Show and scroll with Meta-file
First please try this.
We will make some more improvements.
You can zoom and unzoom with mouse scroll and pan the image by dragging with mouse.
Btw, you can also use fingers on a touch screen to zoom/unzoom and pan the image on a touch screen.
We will make some more improvements.
Code: Select all
local oDlg, oImage
local cFile := "NW1151L.emf"
DEFINE DIALOG oDlg SIZE 900,600 PIXEL TRUEPIXEL
@ 20,20 XIMAGE oImage SOURCE cFile SIZE -20,-20 OF oDlg
ACTIVATE DIALOG oDlg CENTERED
Btw, you can also use fingers on a touch screen to zoom/unzoom and pan the image on a touch screen.
Regards
G. N. Rao.
Hyderabad, India
G. N. Rao.
Hyderabad, India
-
- Posts: 1102
- Joined: Mon Oct 17, 2005 5:41 am
- Location: Belgium
- Contact:
Re: Show and scroll with Meta-file
Thank you, that is what I wanted
Regards,
Marc
FWH32+xHarbour | FWH64+Harbour | BCC | DBF | ADO+MySQL | ADO+MariaDB | ADO+SQLite
Marc
FWH32+xHarbour | FWH64+Harbour | BCC | DBF | ADO+MySQL | ADO+MariaDB | ADO+SQLite
Re: Show and scroll with Meta-file
Marc,
by default :lBmpTransparent := .T.
Using non transparent images like Your drawing
maybe You need
@ 20,20 XIMAGE oImage SOURCE cFile SIZE -20,-20 OF oDlg
oImage:lBmpTransparent := .F.
otherwise it could show something like ( format JPG )
is showing transparent areas on the left upper corner
I tested the mousewheel but there I noticed problems with zoom / unzoom
( it works only sometimes )
moving the image works.
regards
Uwe
by default :lBmpTransparent := .T.
Using non transparent images like Your drawing
maybe You need
@ 20,20 XIMAGE oImage SOURCE cFile SIZE -20,-20 OF oDlg
oImage:lBmpTransparent := .F.
otherwise it could show something like ( format JPG )
is showing transparent areas on the left upper corner
I tested the mousewheel but there I noticed problems with zoom / unzoom
( it works only sometimes )
moving the image works.
regards
Uwe
Last edited by ukoenig on Sat Jul 20, 2019 8:59 am, edited 3 times in total.
Since 1995 ( the first release of FW 1.9 )
i work with FW.
If you have any questions about special functions, maybe i can help.
i work with FW.
If you have any questions about special functions, maybe i can help.
-
- Posts: 1102
- Joined: Mon Oct 17, 2005 5:41 am
- Location: Belgium
- Contact:
Re: Show and scroll with Meta-file
Thank you for the info Uwe.
Regards,
Marc
FWH32+xHarbour | FWH64+Harbour | BCC | DBF | ADO+MySQL | ADO+MariaDB | ADO+SQLite
Marc
FWH32+xHarbour | FWH64+Harbour | BCC | DBF | ADO+MySQL | ADO+MariaDB | ADO+SQLite
- nageswaragunupudi
- Posts: 8017
- Joined: Sun Nov 19, 2006 5:22 am
- Location: India
- Contact:
Re: Show and scroll with Meta-file
Please test again.I tested the mousewheel but there I noticed problems with zoom / unzoom
( it works only sometimes )
It works always.
Make sure the mouse pointer is inside the actual image area.
Regards
G. N. Rao.
Hyderabad, India
G. N. Rao.
Hyderabad, India
-
- Posts: 1102
- Joined: Mon Oct 17, 2005 5:41 am
- Location: Belgium
- Contact:
Re: Show and scroll with Meta-file
For me it seems to work always.
Regards,
Marc
FWH32+xHarbour | FWH64+Harbour | BCC | DBF | ADO+MySQL | ADO+MariaDB | ADO+SQLite
Marc
FWH32+xHarbour | FWH64+Harbour | BCC | DBF | ADO+MySQL | ADO+MariaDB | ADO+SQLite
- nageswaragunupudi
- Posts: 8017
- Joined: Sun Nov 19, 2006 5:22 am
- Location: India
- Contact:
Re: Show and scroll with Meta-file
Yes, it does.Marc Vanzegbroeck wrote:For me it seems to work always.
Regards
G. N. Rao.
Hyderabad, India
G. N. Rao.
Hyderabad, India
Re: Show and scroll with Meta-file
It is working now.
There was a hardware-problem, I didn't noticed before.
After changing the mouse it was ok.
regards
Uwe
There was a hardware-problem, I didn't noticed before.
After changing the mouse it was ok.
regards
Uwe
Since 1995 ( the first release of FW 1.9 )
i work with FW.
If you have any questions about special functions, maybe i can help.
i work with FW.
If you have any questions about special functions, maybe i can help.
- nageswaragunupudi
- Posts: 8017
- Joined: Sun Nov 19, 2006 5:22 am
- Location: India
- Contact:
Re: Show and scroll with Meta-file
This is not relevant for EMF files.Using non transparent images like Your drawing
maybe You need
@ 20,20 XIMAGE oImage SOURCE cFile SIZE -20,-20 OF oDlg
oImage:lBmpTransparent := .F.
otherwise it could show something like ( format JPG )
is showing transparent areas on the left upper corner
Using transparency, please see this variation:
Code: Select all
local oDlg, oImage, oBrush
local cFile := "NW1151L.emf"
DEFINE BRUSH oBrush FILE "c:\fwh\bitmaps\backgrnd\stone.bmp"
DEFINE DIALOG oDlg SIZE 900,600 PIXEL TRUEPIXEL
@ 20,20 XIMAGE oImage SOURCE cFile SIZE -20,-20 OF oDlg
oImage:SetBrush( oBrush )
ACTIVATE DIALOG oDlg CENTERED
RELEASE BRUSH oBrush
Regards
G. N. Rao.
Hyderabad, India
G. N. Rao.
Hyderabad, India
-
- Posts: 1102
- Joined: Mon Oct 17, 2005 5:41 am
- Location: Belgium
- Contact:
Re: Show and scroll with Meta-file
Is it also possible to know the location when you do a doubleclick?
Since when you swipe or zoom, the locations are different. Mayme a hyperlink would me nice
Since when you swipe or zoom, the locations are different. Mayme a hyperlink would me nice
Regards,
Marc
FWH32+xHarbour | FWH64+Harbour | BCC | DBF | ADO+MySQL | ADO+MariaDB | ADO+SQLite
Marc
FWH32+xHarbour | FWH64+Harbour | BCC | DBF | ADO+MySQL | ADO+MariaDB | ADO+SQLite
- nageswaragunupudi
- Posts: 8017
- Joined: Sun Nov 19, 2006 5:22 am
- Location: India
- Contact:
Re: Show and scroll with Meta-file
Ok.
Please keep testing and ask all your requirements. We will try to provide them.
Please keep testing and ask all your requirements. We will try to provide them.
Regards
G. N. Rao.
Hyderabad, India
G. N. Rao.
Hyderabad, India