Page 1 of 1
Select All on viewer
Posted: Wed Jun 30, 2010 12:36 pm
by spighy1980
Hi,
I'm working with GdPicture version 6.7.0.0 licensed.
I would like to create a region that contains the entire file displayed on viewer ("select all" functionality). Is it possible?
Is it also possible to change background color of the selected region?
Thanks in advance,
G. S.
Re: Select All on viewer
Posted: Wed Jun 30, 2010 2:18 pm
by Loïc
Hi,
I would like to create a region that contains the entire file displayed on viewer ("select all" functionality). Is it possible?
Easy:
Code: Select all
regid = GdViewer1.AddRegionInches("MyRegion", 0, 0, GdViewer1.PageWidth / GdViewer1.HorizontalResolution, GdViewer1.PageHeight / GdViewer1.VerticalResolution, ForegroundMixMode.ForegroundMixModeMASKPEN, Color.Aqua)
GdViewer1.Redraw()
Is it also possible to change background color of the selected region?
Yes:
Code: Select all
GdViewer1.SetRegionColor(regid, Color.LightSalmon)
GdViewer1.Redraw()
Hope this helps,
Loïc
Re: Select All on viewer
Posted: Thu Jul 01, 2010 11:01 am
by spighy1980
Loïc wrote:Hi,
I would like to create a region that contains the entire file displayed on viewer ("select all" functionality). Is it possible?
Easy:
Code: Select all
regid = GdViewer1.AddRegionInches("MyRegion", 0, 0, GdViewer1.PageWidth / GdViewer1.HorizontalResolution, GdViewer1.PageHeight / GdViewer1.VerticalResolution, ForegroundMixMode.ForegroundMixModeMASKPEN, Color.Aqua)
GdViewer1.Redraw()
Is it also possible to change background color of the selected region?
Yes:
Code: Select all
GdViewer1.SetRegionColor(regid, Color.LightSalmon)
GdViewer1.Redraw()
Hope this helps,
Loïc
Hi Loïc,
It's work very well.
Thank's a lot.
G. S.