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
2ded79e9
Commit
2ded79e9
authored
16 years ago
by
rds
Browse files
Options
Downloads
Patches
Plain Diff
Fix RT Ticket 55131 (Problems with marking when reverse complementing)
parent
0a0b04bc
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
src/zmapWindow/zmapWindowItem.c
+15
-3
15 additions, 3 deletions
src/zmapWindow/zmapWindowItem.c
src/zmapWindow/zmapWindowMark.c
+11
-3
11 additions, 3 deletions
src/zmapWindow/zmapWindowMark.c
with
26 additions
and
6 deletions
src/zmapWindow/zmapWindowItem.c
+
15
−
3
View file @
2ded79e9
...
...
@@ -26,9 +26,9 @@
*
* Exported functions: See zmapWindow_P.h
* HISTORY:
* Last edited:
Apr 24
11:
31
2008 (
edgrif
)
* Last edited:
May 13
11:
07
2008 (
rds
)
* Created: Thu Sep 8 10:37:24 2005 (edgrif)
* CVS info: $Id: zmapWindowItem.c,v 1.9
8
2008-0
4-24 12:55:40 edgrif
Exp $
* CVS info: $Id: zmapWindowItem.c,v 1.9
9
2008-0
5-13 10:16:34 rds
Exp $
*-------------------------------------------------------------------
*/
...
...
@@ -1614,6 +1614,8 @@ gboolean zmapWindowWorld2SeqCoords(ZMapWindow window,
else
{
get_item_at_workaround_struct
workaround_struct
=
{
NULL
};
double
scroll_x2
;
FooCanvasItem
*
cont_root
=
zmapWindowFToIFindItemFull
(
window
->
context_to_item
,
0
,
0
,
0
,
0
,
0
,
0
);
workaround_struct
.
wx1
=
wx1
;
...
...
@@ -1624,6 +1626,16 @@ gboolean zmapWindowWorld2SeqCoords(ZMapWindow window,
/* For some reason foo_canvas_get_item_at() fails to find items
* a lot of the time even when it shouldn't and so we need a solution. */
/* Incidentally some of the time, for some users, so does this. (RT # 55131) */
/* The cause: if the mark is > 10% out of the scroll region the threshold (90%)
* for intersection will not be met. So I'm going to clamp to the scroll
* region and lower the threshold to 55%...
*/
zmapWindowGetScrollRegion
(
window
,
NULL
,
NULL
,
&
scroll_x2
,
NULL
);
if
(
workaround_struct
.
wx2
>
scroll_x2
)
workaround_struct
.
wx2
=
scroll_x2
;
zmapWindowContainerExecute
(
FOO_CANVAS_GROUP
(
cont_root
),
ZMAPCONTAINER_LEVEL_BLOCK
,
fill_workaround_struct
,
&
workaround_struct
);
if
((
result
=
workaround_struct
.
result
))
...
...
@@ -2332,7 +2344,7 @@ static void fill_workaround_struct(FooCanvasGroup *container,
&
(
area_block
.
x2
),
&
(
area_block
.
y2
));
if
((
workaround
->
wx1
>=
area_block
.
x1
&&
workaround
->
wx2
<=
area_block
.
x2
&&
workaround
->
wy1
>=
area_block
.
y1
&&
workaround
->
wy2
<=
area_block
.
y2
)
||
areas_intersect_gt_threshold
(
&
area_src
,
&
area_block
,
0
.
9
))
areas_intersect_gt_threshold
(
&
area_src
,
&
area_block
,
0
.
55
))
{
/* We're inside */
workaround
->
block
=
container
;
...
...
This diff is collapsed.
Click to expand it.
src/zmapWindow/zmapWindowMark.c
+
11
−
3
View file @
2ded79e9
...
...
@@ -27,9 +27,9 @@
*
* Exported functions: See zmapWindow_P.h
* HISTORY:
* Last edited: Ma
r
1
2 09
:1
5
2008 (
edgrif
)
* Last edited: Ma
y
1
3 11
:1
4
2008 (
rds
)
* Created: Tue Jan 16 09:51:19 2007 (rds)
* CVS info: $Id: zmapWindowMark.c,v 1.1
2
2008-0
3
-1
2 09:15:34 edgrif
Exp $
* CVS info: $Id: zmapWindowMark.c,v 1.1
3
2008-0
5
-1
3 10:16:23 rds
Exp $
*-------------------------------------------------------------------
*/
...
...
@@ -228,6 +228,7 @@ gboolean zmapWindowMarkSetWorldRange(ZMapWindowMark mark,
{
gboolean
result
;
FooCanvasGroup
*
block_grp_out
;
double
scroll_x2
;
int
y1_out
,
y2_out
;
zMapAssert
(
mark
&&
ZMAP_MAGIC_IS_VALID
(
mark_magic_G
,
mark
->
magic
))
;
...
...
@@ -235,10 +236,17 @@ gboolean zmapWindowMarkSetWorldRange(ZMapWindowMark mark,
zmapWindowMarkReset
(
mark
)
;
y1_out
=
y2_out
=
0
;
/* clamp x to scroll region. Fix RT # 55131 */
zmapWindowGetScrollRegion
(
mark
->
window
,
NULL
,
NULL
,
&
scroll_x2
,
NULL
);
if
(
world_x2
>
scroll_x2
)
world_x2
=
scroll_x2
;
if
((
result
=
zmapWindowWorld2SeqCoords
(
mark
->
window
,
world_x1
,
world_y1
,
world_x2
,
world_y2
,
&
block_grp_out
,
&
y1_out
,
&
y2_out
)))
{
double
y1
,
y2
,
dummy
;
double
y1
,
y2
,
dummy
;
mark
->
block_group
=
block_grp_out
;
mark
->
block
=
g_object_get_data
(
G_OBJECT
(
mark
->
block_group
),
ITEM_FEATURE_DATA
)
;
...
...
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