------------------NOTICE-------------------------------* Software ID: gcanvas.ew Version: 0.10.5 04/December/2006 Copyright: (c) 2006 Gary Shingles All rights reserved. Licence: This software is provided 'as-is', without any express or implied warranty. In no event will the authors be held liable for any damages arising from the use of this software.Permission is granted to anyone to use this software for any purpose, including commercial applications, and to alter it and redistribute it freely, subject to the following restrictictions: 1. The origin of this software must not be misrepresented; you must not claim that you wrote the original software. 2. If you use this software in a product, acknowedgement in the product's documenation and binary are required. 3. Altered source versions, and works substantially derived from the it, must... a) be plainly be marked as such, b) not be misrepresented as the original software, c) include this notice, unaltered. ------------------End of NOTICE------------------------*
Topic | Description |
Index | Alphabetical list of all items. |
Canvas | A managed viewport into a larger graphex. This system is built on top of the 'graphex' system. |
Events | Getting events from the canvas |
FUBAR | Not so well thought out stuff, or TODO stuff |
Grid | Controls automatic grid drawing on the canvas |
Internal | Information for developers |
Objects | Everything drawn on the canvas is an 'object' |
Properties | Rudimentary ways to attach info to a canvas or object |
ScrollBars | Controlling and accessing Scroll Bars |
TODO | Things to Come |
Utils | Routines to help manipulate the canvas |
const
] My standard way of maintaining consistency in reasonably complex sequencesvar
] sequence. Maintains a list to of Canvas objectsfunc
] returns the index into the canvas_list of the canvas with ID canvasID orconst
] unfortunately named like Euphoria's C_* constants, so might changevar
] controls whether a BrightRed box is drawn around the extents of all rendered objectsproc
] Draw the canvas using the current view port offsetproc
] internally set event handler for both types of scroll barconst
] and GC_VSCROLLconst
] Rather unfriendlily named constants of the automatically added scroll bar width and heightsfunc
] Return the canvas's auto scroll behaviourfunc
] Get a 'handle' on the underlying graphex object used by the canvas.proc
] Get the grid data from the canvas, see GR_* for the meanings.func
] Get the maximum value of the horizontal scroll bar given the dimensions of the view port and the OSBfunc
] Get the data from an object that has previously been added to the canvasfunc
] Get the current view port offsetfunc
] Return the Euphoria object associated with the canvas by setGfxCanvasPropertyfunc
] Get the win32lib id of the button created at the conjunction of both scroll barsfunc
] Get the property set by getGfxCanvasShapePropertyfunc
] Get the maximum value of the vertical scroll bar given the dimensions of the view port and the OSBproc
] Cause a horizontal scroll bar to be displayed on the canvasfunc
] Add a graphex style object to the canvas.proc
] Cause both scroll bars and the button to be added to the canvasproc
] Adds the little button that is so natural with two scroll bars presentproc
] Cause a Vertical scroll bar to be displayed on the canvasproc
] Mechanism to attach an event to the canvas.proc
] Cause the canvas to be displayed with its contents centered.proc
] This is a debug routine which displays an objects bounding box in red around an object.proc
] a mouse drag has endedproc
] a mouse drag has startedfunc
] If an object has been added to the canvas by gfxCanvasAddObject then this system can probablyfunc
] return the object IDs in a certain rect relative to the whole Off Screen Bufferfunc
] return the object ids in a certain rect relative to the gfxproc
] Cause the canvas's Horizontal sroll bar to be removedfunc
] Remove a graphex style shape from the canvas based on its IDproc
] Cause both scroll bars and the button to be removed from the canvasproc
] Removes the natural scroll bar buttonproc
] Cause the canvas's Vertical sroll bar to be removedproc
] Change the size of the canvas (eg if the window is resized)proc
] Redraws any objects on the offscreen buffer that need to be shownconst
] currently unused, and hopefully will never have to beproc
] the event handler for the unthoughtout mouse abstractionsfunc
] ??const
] Types of grid to be drawn, see setGfxCanvasGridconst
] sequence field positions for grid data for setGfxCanvasGridData and getGfxCanvasGridDatavar
] integer. Last id of object added to canvas.func
] Create a new canvasvar
] This remembers the routine id of the event handler for w32HClick on the scroll bar buttonproc
] Determine whether scroll bars will automatically appear on the canvas (default is true if needed)proc
] UNTESTED changing the graphex object on the canvasfunc
] Set the type of grid (if any) is displayed on the canvasproc
] Set the grid data of the canvas, usually from data obtained from getGfxCanvasGridDataproc
] Change the data held by the canvas about an object. It is safest to use getGfxCanvasObjectDataproc
] Change the top left coordinate offset (both X and Y) of the view portproc
] Set a property (really just a Euphoria object) on the canvasproc
] nominate the routine to receive w32HClick on the button between the scroll barsproc
] Set the property associated with an object added to the canvasproc
] Change the X offset of the view portproc
] Change the Y offset of the view portconst
] Should probably be O_* :-)