Page 1 of 1

[Module] Preview Module (all OS)

Posted: Sat Aug 24, 2019 7:47 pm
by Thorsten1867
PreView Gadget - Module (All OS / DPI / 64Bit)

For my qAES-Packer I needed a preview function and so this module was created.
  • Preview images, XML, JSON, and text
  • automatically adjust the gadget size if the content is smaller than the gadget
  • automatic window adjustment possible [#ResizeWindow]

Code: Select all

; PreView::Gadget()             - create gadget
; PreView::FileImage()          - load a image file and preview it
; PreView::FileJSON()           - load a json file and preview it
; PreView::FileText()           - load a text file and preview it
; PreView::FileXML()            - load a xml file and preview it
; PreView::Image()              - preview image
; PreView::JSON()               - preview JSON
; PreView::Text()               - preview text string
; PreView::XML()                - previev xml  
; PreView::SetAutoResizeFlags() - [#MoveX|#MoveY|#ResizeWidth|#ResizeHeight]
; PreView::SetColor()           - similar to 'SetGadgetColor()'
; PreView::SetFont()            - similar to 'SetFont()'
Download: PreViewModule.pbi

Re: [Module] Preview Module (all OS)

Posted: Sat Sep 07, 2019 9:00 am
by Lord
Just two observations with your example code:

1. If Window is resized so that the shown picture just disappears,
the window is starting to grow and grows without any control.

2. WindowBounds() has no effekt

Re: [Module] Preview Module (all OS)

Posted: Sun Sep 08, 2019 9:10 am
by Kwai chang caine
For me the picture not disappears if i resize, there are just a flickering of the picture
The right click have no effect
W10 X64 / v5.70 X86
Thanks for sharing

Re: [Module] Preview Module (all OS)

Posted: Sun Sep 08, 2019 9:57 am
by Lord
Hi KCC!
Kwai chang caine wrote:For me the picture not disappears if i resize, there are just a flickering of the picture
The right click have no effect
W10 X64 / v5.70 X86
Thanks for sharing
Try to resize the window small until the window is smaller as the left, top position of the picture.
Because WindowBounds() is not working here, you can resize the window to 0, 0. then the mentioned growing of the window starts.

Re: [Module] Preview Module (all OS)

Posted: Sun Sep 08, 2019 4:40 pm
by Kwai chang caine
then the mentioned growing of the window starts.
Yes you have right, i have the same effect :D

Re: [Module] Preview Module (all OS)

Posted: Sun Sep 08, 2019 7:49 pm
by Thorsten1867
Bugfixes

Re: [Module] Preview Module (all OS)

Posted: Mon Sep 09, 2019 2:05 pm
by Thorsten1867
more bugfixes