Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
Z
zmap
Manage
Activity
Members
Labels
Plan
Issues
0
Issue boards
Milestones
Iterations
Wiki
Requirements
Jira
Code
Merge requests
0
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Test cases
Artifacts
Deploy
Releases
Package Registry
Container Registry
Operate
Environments
Terraform modules
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Issue analytics
Insights
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
ensembl-gh-mirror
zmap
Commits
4b001fa0
Commit
4b001fa0
authored
20 years ago
by
edgrif
Browse files
Options
Downloads
Patches
Plain Diff
initial version of foo canvas usage/coding doc.
parent
3ea535f0
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
doc/foo_canvas.html
+60
-0
60 additions, 0 deletions
doc/foo_canvas.html
with
60 additions
and
0 deletions
doc/foo_canvas.html
0 → 100755
+
60
−
0
View file @
4b001fa0
<HTML>
<HEAD>
<TITLE>
The Foo Canvas Widget
</TITLE>
</HEAD>
<BODY>
<H1>
The Foo Canvas Widget
</H1>
<H2>
Overview
</H2>
<H2>
Coordinate Systems
</H2>
<H2>
Event Handling
</H2>
<P>
Event handling is not completely straight forward because event handling is split between
events that happen within the root item of the canvas and events that happen within the
canvas window but
<b>
not
</b>
within the root item. These two areas will often be disjoint
because the width and/or height of one will be larger than the other. By default the root item
is set to be the size of the bounding rectangle of all the items on the canvas. I guess in theory
we could resize the root item to be at least as big as the canvas window.
<P>
Within the root item, event handling is consistent with a cascade of:
<pre><code>
top item --> parent item --> ....... --> parent item --> root item
</code></pre>
<P>
If any item event handler registered by the application returns
<code>
TRUE
</code>
the event is not
passed on to the items parent, otherwise it is until the root item is reached. At this point
however the event is
<b>
not
</b>
passed on to any other obvious handler. If you register an event
handler generally for the canvas window it gets called
<b>
before
</b>
the handlers registered
for the canvas items. This is even if you use the
<code>
g_signal_connect_after()
</code>
call
to register the handler. This is a pain for several reasons:
<ul>
<li>
it means the general event handler for canvas events is not in the same system as the
other event handlers.
<li>
interactions between this event handler and the others are complicated because this base
handler cannot act as the catch all for all events not handled by canvas items.
</ul>
<P>
But perhaps is also good in that handling of canvas
<b>
window
</b>
events can be separated
from handling of canvas
<b>
item
</b>
events.
<P>
Perhaps more thought required here.
<HR>
<ADDRESS><a
href=
"mailto:edgrif@sanger.ac.uk"
>
Ed Griffiths
<
edgrif@sanger.ac.uk
>
</a></ADDRESS>
<!-- hhmts start -->
Last modified: Mon Jan 17 15:16:35 GMT 2005
<!-- hhmts end -->
</BODY>
</HTML>
This diff is collapsed.
Click to expand it.
Preview
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment