Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
P
proview
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Esteban Blanc
proview
Commits
3b3dee69
Commit
3b3dee69
authored
Jun 18, 2014
by
Claes Sjofors
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Plc trace, objects with old subscriptions dimmed
parent
78367e33
Changes
46
Expand all
Show whitespace changes
Inline
Side-by-side
Showing
46 changed files
with
376 additions
and
230 deletions
+376
-230
xtt/lib/flow/gtk/flow_draw_gtk.cpp
xtt/lib/flow/gtk/flow_draw_gtk.cpp
+41
-13
xtt/lib/flow/gtk/flow_draw_gtk.h
xtt/lib/flow/gtk/flow_draw_gtk.h
+5
-5
xtt/lib/flow/motif/flow_draw_xlib.cpp
xtt/lib/flow/motif/flow_draw_xlib.cpp
+23
-11
xtt/lib/flow/motif/flow_draw_xlib.h
xtt/lib/flow/motif/flow_draw_xlib.h
+4
-4
xtt/lib/flow/src/flow_annot.cpp
xtt/lib/flow/src/flow_annot.cpp
+4
-4
xtt/lib/flow/src/flow_annot.h
xtt/lib/flow/src/flow_annot.h
+1
-1
xtt/lib/flow/src/flow_annotpixmap.cpp
xtt/lib/flow/src/flow_annotpixmap.cpp
+5
-5
xtt/lib/flow/src/flow_annotpixmap.h
xtt/lib/flow/src/flow_annotpixmap.h
+3
-3
xtt/lib/flow/src/flow_api.cpp
xtt/lib/flow/src/flow_api.cpp
+15
-0
xtt/lib/flow/src/flow_api.h
xtt/lib/flow/src/flow_api.h
+3
-0
xtt/lib/flow/src/flow_arc.cpp
xtt/lib/flow/src/flow_arc.cpp
+8
-8
xtt/lib/flow/src/flow_arc.h
xtt/lib/flow/src/flow_arc.h
+3
-3
xtt/lib/flow/src/flow_array.cpp
xtt/lib/flow/src/flow_array.cpp
+14
-4
xtt/lib/flow/src/flow_array.h
xtt/lib/flow/src/flow_array.h
+3
-2
xtt/lib/flow/src/flow_array_elem.h
xtt/lib/flow/src/flow_array_elem.h
+4
-2
xtt/lib/flow/src/flow_arrow.cpp
xtt/lib/flow/src/flow_arrow.cpp
+5
-5
xtt/lib/flow/src/flow_arrow.h
xtt/lib/flow/src/flow_arrow.h
+3
-3
xtt/lib/flow/src/flow_con.cpp
xtt/lib/flow/src/flow_con.cpp
+49
-49
xtt/lib/flow/src/flow_con.h
xtt/lib/flow/src/flow_con.h
+1
-0
xtt/lib/flow/src/flow_conpoint.cpp
xtt/lib/flow/src/flow_conpoint.cpp
+2
-2
xtt/lib/flow/src/flow_conpoint.h
xtt/lib/flow/src/flow_conpoint.h
+1
-1
xtt/lib/flow/src/flow_ctx.cpp
xtt/lib/flow/src/flow_ctx.cpp
+4
-4
xtt/lib/flow/src/flow_ctx.h
xtt/lib/flow/src/flow_ctx.h
+2
-0
xtt/lib/flow/src/flow_draw.h
xtt/lib/flow/src/flow_draw.h
+4
-4
xtt/lib/flow/src/flow_frame.cpp
xtt/lib/flow/src/flow_frame.cpp
+2
-2
xtt/lib/flow/src/flow_frame.h
xtt/lib/flow/src/flow_frame.h
+1
-1
xtt/lib/flow/src/flow_image.cpp
xtt/lib/flow/src/flow_image.cpp
+5
-5
xtt/lib/flow/src/flow_image.h
xtt/lib/flow/src/flow_image.h
+3
-3
xtt/lib/flow/src/flow_line.cpp
xtt/lib/flow/src/flow_line.cpp
+9
-9
xtt/lib/flow/src/flow_line.h
xtt/lib/flow/src/flow_line.h
+3
-3
xtt/lib/flow/src/flow_node.cpp
xtt/lib/flow/src/flow_node.cpp
+27
-17
xtt/lib/flow/src/flow_node.h
xtt/lib/flow/src/flow_node.h
+3
-0
xtt/lib/flow/src/flow_nodeclass.cpp
xtt/lib/flow/src/flow_nodeclass.cpp
+4
-4
xtt/lib/flow/src/flow_nodeclass.h
xtt/lib/flow/src/flow_nodeclass.h
+1
-1
xtt/lib/flow/src/flow_pixmap.cpp
xtt/lib/flow/src/flow_pixmap.cpp
+5
-5
xtt/lib/flow/src/flow_pixmap.h
xtt/lib/flow/src/flow_pixmap.h
+3
-3
xtt/lib/flow/src/flow_pushbutton.cpp
xtt/lib/flow/src/flow_pushbutton.cpp
+3
-3
xtt/lib/flow/src/flow_radiobutton.cpp
xtt/lib/flow/src/flow_radiobutton.cpp
+15
-15
xtt/lib/flow/src/flow_radiobutton.h
xtt/lib/flow/src/flow_radiobutton.h
+3
-3
xtt/lib/flow/src/flow_rect.cpp
xtt/lib/flow/src/flow_rect.cpp
+8
-8
xtt/lib/flow/src/flow_rect.h
xtt/lib/flow/src/flow_rect.h
+3
-3
xtt/lib/flow/src/flow_text.cpp
xtt/lib/flow/src/flow_text.cpp
+6
-6
xtt/lib/flow/src/flow_text.h
xtt/lib/flow/src/flow_text.h
+3
-3
xtt/lib/flow/src/flow_tiptext.cpp
xtt/lib/flow/src/flow_tiptext.cpp
+2
-2
xtt/lib/xtt/src/xtt_trace.cpp
xtt/lib/xtt/src/xtt_trace.cpp
+59
-1
xtt/lib/xtt/src/xtt_trace.h
xtt/lib/xtt/src/xtt_trace.h
+1
-0
No files found.
xtt/lib/flow/gtk/flow_draw_gtk.cpp
View file @
3b3dee69
...
...
@@ -992,15 +992,19 @@ void FlowDrawGtk::enable_event( FlowCtx *ctx, flow_eEvent event,
}
int
FlowDrawGtk
::
rect
(
FlowCtx
*
ctx
,
int
x
,
int
y
,
int
width
,
int
height
,
flow_eDrawType
gc_type
,
int
idx
,
int
highlight
)
flow_eDrawType
gc_type
,
int
idx
,
int
highlight
,
int
dimmed
)
{
if
(
ctx
->
nodraw
)
return
1
;
if
(
gc_type
==
flow_eDrawType_LineGray
&&
highlight
)
if
(
dimmed
)
gc_type
=
flow_eDrawType_LineGray
;
else
if
(
gc_type
==
flow_eDrawType_LineGray
&&
highlight
)
gc_type
=
flow_eDrawType_Line
;
else
if
(
highlight
)
gc_type
=
flow_eDrawType
(
gc_type
+
1
);
gdk_draw_rectangle
(
window
,
gcs
[
gc_type
+
highlight
][
idx
],
0
,
gcs
[
gc_type
][
idx
],
0
,
x
,
y
,
width
,
height
);
return
1
;
}
...
...
@@ -1099,15 +1103,19 @@ int FlowDrawGtk::nav_arrow_erase( FlowCtx *ctx, int x1, int y1, int x2, int y2,
int
FlowDrawGtk
::
arc
(
FlowCtx
*
ctx
,
int
x
,
int
y
,
int
width
,
int
height
,
int
angle1
,
int
angle2
,
flow_eDrawType
gc_type
,
int
idx
,
int
highlight
)
flow_eDrawType
gc_type
,
int
idx
,
int
highlight
,
int
dimmed
)
{
if
(
ctx
->
nodraw
)
return
1
;
if
(
gc_type
==
flow_eDrawType_LineGray
&&
highlight
)
if
(
dimmed
)
gc_type
=
flow_eDrawType_LineGray
;
else
if
(
gc_type
==
flow_eDrawType_LineGray
&&
highlight
)
gc_type
=
flow_eDrawType_Line
;
else
if
(
highlight
)
gc_type
=
flow_eDrawType
(
gc_type
+
1
);
gdk_draw_arc
(
window
,
gcs
[
gc_type
+
highlight
][
idx
],
0
,
gcs
[
gc_type
][
idx
],
0
,
x
,
y
,
width
,
height
,
angle1
*
64
,
angle2
*
64
);
return
1
;
}
...
...
@@ -1152,15 +1160,19 @@ int FlowDrawGtk::nav_arc_erase( FlowCtx *ctx, int x, int y, int width, int heigh
}
int
FlowDrawGtk
::
line
(
FlowCtx
*
ctx
,
int
x1
,
int
y1
,
int
x2
,
int
y2
,
flow_eDrawType
gc_type
,
int
idx
,
int
highlight
)
flow_eDrawType
gc_type
,
int
idx
,
int
highlight
,
int
dimmed
)
{
if
(
ctx
->
nodraw
)
return
1
;
if
(
gc_type
==
flow_eDrawType_LineGray
&&
highlight
)
if
(
dimmed
)
gc_type
=
flow_eDrawType_LineGray
;
else
if
(
gc_type
==
flow_eDrawType_LineGray
&&
highlight
)
gc_type
=
flow_eDrawType_Line
;
else
if
(
highlight
)
gc_type
=
flow_eDrawType
(
gc_type
+
1
);
gdk_draw_line
(
window
,
gcs
[
gc_type
+
highlight
][
idx
],
gcs
[
gc_type
][
idx
],
x1
,
y1
,
x2
,
y2
);
return
1
;
}
...
...
@@ -1222,12 +1234,21 @@ static char *font_string( flow_eDrawType gc_type, double size)
}
int
FlowDrawGtk
::
text_pango
(
FlowCtx
*
ctx
,
int
x
,
int
y
,
char
*
text
,
int
len
,
flow_eDrawType
gc_type
,
int
idx
,
int
highlight
,
int
line
,
double
size
)
flow_eDrawType
gc_type
,
int
idx
,
int
highlight
,
int
dimmed
,
int
line
,
double
size
)
{
if
(
ctx
->
nodraw
)
return
1
;
PangoRenderer
*
pr
=
gdk_pango_renderer_get_default
(
screen
);
gdk_pango_renderer_set_drawable
(
GDK_PANGO_RENDERER
(
pr
),
window
);
if
(
dimmed
)
{
GdkGCValues
xgcv
;
gdk_gc_get_values
(
gcs
[
flow_eDrawType_LineGray
][
0
],
&
xgcv
);
gdk_gc_set_values
(
gcs
[
gc_type
][
0
],
&
xgcv
,
GDK_GC_FOREGROUND
);
}
gdk_pango_renderer_set_gc
(
GDK_PANGO_RENDERER
(
pr
),
gcs
[
gc_type
][
0
]);
PangoContext
*
pctx
=
gdk_pango_context_get_for_screen
(
screen
);
...
...
@@ -1259,6 +1280,13 @@ int FlowDrawGtk::text_pango( FlowCtx *ctx, int x, int y, char *text, int len,
pango_font_description_free
(
desc
);
g_object_unref
(
pctx
);
if
(
dimmed
)
{
GdkGCValues
xgcv
;
gdk_gc_get_values
(
gcs
[
flow_eDrawType_Line
][
0
],
&
xgcv
);
gdk_gc_set_values
(
gcs
[
gc_type
][
0
],
&
xgcv
,
GDK_GC_FOREGROUND
);
}
return
1
;
}
...
...
@@ -1348,12 +1376,12 @@ int FlowDrawGtk::text_erase_pango( FlowCtx *ctx, int x, int y, char *text, int l
}
int
FlowDrawGtk
::
text
(
FlowCtx
*
ctx
,
int
x
,
int
y
,
char
*
text
,
int
len
,
flow_eDrawType
gc_type
,
int
idx
,
int
highlight
,
int
line
,
double
size
)
flow_eDrawType
gc_type
,
int
idx
,
int
highlight
,
int
dimmed
,
int
line
,
double
size
)
{
if
(
ctx
->
nodraw
)
return
1
;
if
(
pango
)
return
text_pango
(
ctx
,
x
,
y
,
text
,
len
,
gc_type
,
idx
,
highlight
,
line
,
size
);
return
text_pango
(
ctx
,
x
,
y
,
text
,
len
,
gc_type
,
idx
,
highlight
,
dimmed
,
line
,
size
);
int
font_idx
=
get_font_idx
(
gc_type
);
...
...
xtt/lib/flow/gtk/flow_draw_gtk.h
View file @
3b3dee69
...
...
@@ -88,7 +88,7 @@ class FlowDrawGtk : public FlowDraw {
void
set_nav_window_size
(
FlowCtx
*
ctx
,
int
width
,
int
height
);
int
rect
(
FlowCtx
*
ctx
,
int
x
,
int
y
,
int
width
,
int
height
,
flow_eDrawType
gc_type
,
int
idx
,
int
highlight
);
flow_eDrawType
gc_type
,
int
idx
,
int
highlight
,
int
dimmed
);
int
rect_erase
(
FlowCtx
*
ctx
,
int
x
,
int
y
,
int
width
,
int
height
,
int
idx
);
int
nav_rect
(
FlowCtx
*
ctx
,
int
x
,
int
y
,
int
width
,
int
height
,
...
...
@@ -109,7 +109,7 @@ class FlowDrawGtk : public FlowDraw {
int
idx
);
int
arc
(
FlowCtx
*
ctx
,
int
x
,
int
y
,
int
width
,
int
height
,
int
angle1
,
int
angle2
,
flow_eDrawType
gc_type
,
int
idx
,
int
highlight
);
flow_eDrawType
gc_type
,
int
idx
,
int
highlight
,
int
dimmed
);
int
arc_erase
(
FlowCtx
*
ctx
,
int
x
,
int
y
,
int
width
,
int
height
,
int
angle1
,
int
angle2
,
int
idx
);
...
...
@@ -120,7 +120,7 @@ class FlowDrawGtk : public FlowDraw {
int
angle1
,
int
angle2
,
int
idx
);
int
line
(
FlowCtx
*
ctx
,
int
x1
,
int
y1
,
int
x2
,
int
y2
,
flow_eDrawType
gc_type
,
int
idx
,
int
highlight
);
flow_eDrawType
gc_type
,
int
idx
,
int
highlight
,
int
dimmed
);
int
line_erase
(
FlowCtx
*
ctx
,
int
x1
,
int
y1
,
int
x2
,
int
y2
,
int
idx
);
int
nav_line
(
FlowCtx
*
ctx
,
int
x1
,
int
y1
,
int
x2
,
int
y2
,
...
...
@@ -128,7 +128,7 @@ class FlowDrawGtk : public FlowDraw {
int
nav_line_erase
(
FlowCtx
*
ctx
,
int
x1
,
int
y1
,
int
x2
,
int
y2
,
int
idx
);
int
text
(
FlowCtx
*
ctx
,
int
x
,
int
y
,
char
*
text
,
int
len
,
flow_eDrawType
gc_type
,
int
idx
,
int
highlight
,
int
line
,
double
size
);
flow_eDrawType
gc_type
,
int
idx
,
int
highlight
,
int
dimmed
,
int
line
,
double
size
);
int
text_inverse
(
FlowCtx
*
ctx
,
int
x
,
int
y
,
char
*
text
,
int
len
,
flow_eDrawType
gc_type
,
int
idx
,
int
line
,
double
size
);
int
text_erase
(
FlowCtx
*
ctx
,
int
x
,
int
y
,
char
*
text
,
int
len
,
...
...
@@ -198,7 +198,7 @@ class FlowDrawGtk : public FlowDraw {
flow_tPixmap
*
im_pixmap
,
flow_tPixmap
*
im_mask
,
flow_tPixmap
*
im_nav_pixmap
,
flow_tPixmap
*
im_nav_mask
);
int
text_pango
(
FlowCtx
*
ctx
,
int
x
,
int
y
,
char
*
text
,
int
len
,
flow_eDrawType
gc_type
,
int
idx
,
int
highlight
,
int
line
,
double
size
);
flow_eDrawType
gc_type
,
int
idx
,
int
highlight
,
int
dimmed
,
int
line
,
double
size
);
int
text_inverse_pango
(
FlowCtx
*
ctx
,
int
x
,
int
y
,
char
*
text
,
int
len
,
flow_eDrawType
gc_type
,
int
idx
,
int
line
,
double
size
);
int
text_erase_pango
(
FlowCtx
*
ctx
,
int
x
,
int
y
,
char
*
text
,
int
len
,
...
...
xtt/lib/flow/motif/flow_draw_xlib.cpp
View file @
3b3dee69
...
...
@@ -936,15 +936,19 @@ void FlowDrawXLib::enable_event( FlowCtx *ctx, flow_eEvent event,
}
int
FlowDrawXLib
::
rect
(
FlowCtx
*
ctx
,
int
x
,
int
y
,
int
width
,
int
height
,
flow_eDrawType
gc_type
,
int
idx
,
int
highlight
)
flow_eDrawType
gc_type
,
int
idx
,
int
highlight
,
int
dimmed
)
{
if
(
ctx
->
nodraw
)
return
1
;
if
(
gc_type
==
flow_eDrawType_LineGray
&&
highlight
)
if
(
dimmed
)
gc_type
=
flow_eDrawType_LineGray
;
else
if
(
gc_type
==
flow_eDrawType_LineGray
&&
highlight
)
gc_type
=
flow_eDrawType_Line
;
else
if
(
highlight
)
gc_type
++
;
XDrawRectangle
(
display
,
window
,
gcs
[
gc_type
+
highlight
][
idx
],
gcs
[
gc_type
][
idx
],
x
,
y
,
width
,
height
);
return
1
;
}
...
...
@@ -1043,15 +1047,19 @@ int FlowDrawXLib::nav_arrow_erase( FlowCtx *ctx, int x1, int y1, int x2, int y2,
int
FlowDrawXLib
::
arc
(
FlowCtx
*
ctx
,
int
x
,
int
y
,
int
width
,
int
height
,
int
angle1
,
int
angle2
,
flow_eDrawType
gc_type
,
int
idx
,
int
highlight
)
flow_eDrawType
gc_type
,
int
idx
,
int
highlight
,
int
dimmed
)
{
if
(
ctx
->
nodraw
)
return
1
;
if
(
gc_type
==
flow_eDrawType_LineGray
&&
highlight
)
if
(
dimmed
)
gc_type
=
flow_eDrawType_LineGray
;
else
if
(
gc_type
==
flow_eDrawType_LineGray
&&
highlight
)
gc_type
=
flow_eDrawType_Line
;
else
if
(
highlight
)
gc_type
++
;
XDrawArc
(
display
,
window
,
gcs
[
gc_type
+
highlight
][
idx
],
gcs
[
gc_type
][
idx
],
x
,
y
,
width
,
height
,
angle1
*
64
,
angle2
*
64
);
return
1
;
}
...
...
@@ -1096,15 +1104,19 @@ int FlowDrawXLib::nav_arc_erase( FlowCtx *ctx, int x, int y, int width, int heig
}
int
FlowDrawXLib
::
line
(
FlowCtx
*
ctx
,
int
x1
,
int
y1
,
int
x2
,
int
y2
,
flow_eDrawType
gc_type
,
int
idx
,
int
highlight
)
flow_eDrawType
gc_type
,
int
idx
,
int
highlight
,
int
dimmed
)
{
if
(
ctx
->
nodraw
)
return
1
;
if
(
gc_type
==
flow_eDrawType_LineGray
&&
highlight
)
if
(
dimmed
)
gc_type
=
flow_eDrawType_LineGray
;
else
if
(
gc_type
==
flow_eDrawType_LineGray
&&
highlight
)
gc_type
=
flow_eDrawType_Line
;
else
if
(
highlight
)
gc_type
++
;
XDrawLine
(
display
,
window
,
gcs
[
gc_type
+
highlight
][
idx
],
gcs
[
gc_type
][
idx
],
x1
,
y1
,
x2
,
y2
);
return
1
;
}
...
...
@@ -1146,7 +1158,7 @@ int FlowDrawXLib::nav_line_erase( FlowCtx *ctx, int x1, int y1, int x2, int y2,
}
int
FlowDrawXLib
::
text
(
FlowCtx
*
ctx
,
int
x
,
int
y
,
char
*
text
,
int
len
,
flow_eDrawType
gc_type
,
int
idx
,
int
highlight
,
int
line
,
double
size
)
flow_eDrawType
gc_type
,
int
idx
,
int
highlight
,
int
dimmed
,
int
line
,
double
size
)
{
if
(
ctx
->
nodraw
)
return
1
;
...
...
xtt/lib/flow/motif/flow_draw_xlib.h
View file @
3b3dee69
...
...
@@ -111,7 +111,7 @@ class FlowDrawXLib : public FlowDraw {
void
set_nav_window_size
(
FlowCtx
*
ctx
,
int
width
,
int
height
);
int
rect
(
FlowCtx
*
ctx
,
int
x
,
int
y
,
int
width
,
int
height
,
flow_eDrawType
gc_type
,
int
idx
,
int
highlight
);
flow_eDrawType
gc_type
,
int
idx
,
int
highlight
,
int
dimmed
);
int
rect_erase
(
FlowCtx
*
ctx
,
int
x
,
int
y
,
int
width
,
int
height
,
int
idx
);
int
nav_rect
(
FlowCtx
*
ctx
,
int
x
,
int
y
,
int
width
,
int
height
,
...
...
@@ -132,7 +132,7 @@ class FlowDrawXLib : public FlowDraw {
int
idx
);
int
arc
(
FlowCtx
*
ctx
,
int
x
,
int
y
,
int
width
,
int
height
,
int
angle1
,
int
angle2
,
flow_eDrawType
gc_type
,
int
idx
,
int
highlight
);
flow_eDrawType
gc_type
,
int
idx
,
int
highlight
,
int
dimmed
);
int
arc_erase
(
FlowCtx
*
ctx
,
int
x
,
int
y
,
int
width
,
int
height
,
int
angle1
,
int
angle2
,
int
idx
);
...
...
@@ -143,7 +143,7 @@ class FlowDrawXLib : public FlowDraw {
int
angle1
,
int
angle2
,
int
idx
);
int
line
(
FlowCtx
*
ctx
,
int
x1
,
int
y1
,
int
x2
,
int
y2
,
flow_eDrawType
gc_type
,
int
idx
,
int
highlight
);
flow_eDrawType
gc_type
,
int
idx
,
int
highlight
,
int
dimmed
);
int
line_erase
(
FlowCtx
*
ctx
,
int
x1
,
int
y1
,
int
x2
,
int
y2
,
int
idx
);
int
nav_line
(
FlowCtx
*
ctx
,
int
x1
,
int
y1
,
int
x2
,
int
y2
,
...
...
@@ -151,7 +151,7 @@ class FlowDrawXLib : public FlowDraw {
int
nav_line_erase
(
FlowCtx
*
ctx
,
int
x1
,
int
y1
,
int
x2
,
int
y2
,
int
idx
);
int
text
(
FlowCtx
*
ctx
,
int
x
,
int
y
,
char
*
text
,
int
len
,
flow_eDrawType
gc_type
,
int
idx
,
int
highlight
,
int
line
,
double
size
);
flow_eDrawType
gc_type
,
int
idx
,
int
highlight
,
int
dimmed
,
int
line
,
double
size
);
int
text_erase
(
FlowCtx
*
ctx
,
int
x
,
int
y
,
char
*
text
,
int
len
,
flow_eDrawType
gc_type
,
int
idx
,
int
line
,
double
size
);
int
text_inverse
(
FlowCtx
*
ctx
,
int
x
,
int
y
,
char
*
text
,
int
len
,
...
...
xtt/lib/flow/src/flow_annot.cpp
View file @
3b3dee69
...
...
@@ -182,7 +182,7 @@ void FlowAnnot::open( ifstream& fp)
}
}
void
FlowAnnot
::
draw
(
void
*
pos
,
int
highlight
,
int
hot
,
void
*
node
)
void
FlowAnnot
::
draw
(
void
*
pos
,
int
highlight
,
int
dimmed
,
int
hot
,
void
*
node
)
{
int
x
;
...
...
@@ -208,7 +208,7 @@ void FlowAnnot::draw( void *pos, int highlight, int hot, void *node)
p
.
z_y
+
((
FlowPoint
*
)
pos
)
->
z_y
-
ctx
->
offset_y
,
((
FlowNode
*
)
node
)
->
annotv
[
number
],
strlen
(((
FlowNode
*
)
node
)
->
annotv
[
number
]),
draw_type
,
idx
,
highlight
,
0
,
highlight
,
dimmed
,
0
,
tsize
(
text_size
));
if
(
((
FlowNode
*
)
node
)
->
annotv_inputmode
[
number
])
ctx
->
fdraw
->
move_input
(
ctx
,
...
...
@@ -234,7 +234,7 @@ void FlowAnnot::draw( void *pos, int highlight, int hot, void *node)
if
(
len
)
{
*
s
=
0
;
ctx
->
fdraw
->
text
(
ctx
,
z_x
,
z_y
+
line_cnt
*
z_height
,
line
,
len
,
draw_type
,
idx
,
highlight
,
0
,
len
,
draw_type
,
idx
,
highlight
,
dimmed
,
0
,
tsize
(
text_size
));
*
s
=
10
;
}
...
...
@@ -247,7 +247,7 @@ void FlowAnnot::draw( void *pos, int highlight, int hot, void *node)
}
if
(
len
)
ctx
->
fdraw
->
text
(
ctx
,
z_x
,
z_y
+
line_cnt
*
z_height
,
line
,
len
,
draw_type
,
idx
,
highlight
,
0
,
len
,
draw_type
,
idx
,
highlight
,
dimmed
,
0
,
tsize
(
text_size
));
break
;
}
...
...
xtt/lib/flow/src/flow_annot.h
View file @
3b3dee69
...
...
@@ -65,7 +65,7 @@ class FlowAnnot : public FlowArrayElem {
void
print
(
void
*
pos
,
void
*
node
,
int
highlight
);
void
save
(
ofstream
&
fp
,
flow_eSaveMode
mode
);
void
open
(
ifstream
&
fp
);
void
draw
(
void
*
pos
,
int
highlight
,
int
hot
,
void
*
node
);
void
draw
(
void
*
pos
,
int
highlight
,
int
dimmed
,
int
hot
,
void
*
node
);
void
nav_draw
(
void
*
pos
,
int
highlight
,
void
*
node
);
void
draw_inverse
(
void
*
pos
,
int
hot
,
void
*
node
);
void
erase
(
void
*
pos
,
int
hot
,
void
*
node
);
...
...
xtt/lib/flow/src/flow_annotpixmap.cpp
View file @
3b3dee69
...
...
@@ -149,7 +149,7 @@ void FlowAnnotPixmap::open( ifstream& fp)
#endif
}
void
FlowAnnotPixmap
::
draw
(
void
*
pos
,
int
highlight
,
int
hot
,
void
*
node
)
void
FlowAnnotPixmap
::
draw
(
void
*
pos
,
int
highlight
,
int
dimmed
,
int
hot
,
void
*
node
)
{
int
x
;
...
...
@@ -307,7 +307,7 @@ void FlowAnnotPixmap::get_borders( double pos_x, double pos_y, double *x_right,
*/
}
void
FlowAnnotPixmap
::
move
(
void
*
pos
,
double
x
,
double
y
,
int
highlight
,
int
hot
)
void
FlowAnnotPixmap
::
move
(
void
*
pos
,
double
x
,
double
y
,
int
highlight
,
int
dimmed
,
int
hot
)
{
erase
(
pos
,
hot
,
NULL
);
nav_erase
(
pos
,
NULL
);
...
...
@@ -315,12 +315,12 @@ void FlowAnnotPixmap::move( void *pos, double x, double y, int highlight, int ho
p
.
y
=
y
;
zoom
();
nav_zoom
();
draw
(
pos
,
highlight
,
hot
,
NULL
);
draw
(
pos
,
highlight
,
dimmed
,
hot
,
NULL
);
nav_draw
(
pos
,
highlight
,
NULL
);
}
void
FlowAnnotPixmap
::
shift
(
void
*
pos
,
double
delta_x
,
double
delta_y
,
int
highlight
,
int
hot
)
int
highlight
,
int
dimmed
,
int
hot
)
{
erase
(
pos
,
hot
,
NULL
);
nav_erase
(
pos
,
NULL
);
...
...
@@ -329,7 +329,7 @@ void FlowAnnotPixmap::shift( void *pos, double delta_x, double delta_y,
zoom
();
nav_zoom
();
draw
(
pos
,
highlight
,
hot
,
NULL
);
draw
(
pos
,
highlight
,
dimmed
,
hot
,
NULL
);
nav_draw
(
pos
,
highlight
,
NULL
);
}
...
...
xtt/lib/flow/src/flow_annotpixmap.h
View file @
3b3dee69
...
...
@@ -62,14 +62,14 @@ class FlowAnnotPixmap : public FlowArrayElem {
void
print
(
void
*
pos
,
void
*
node
,
int
highlight
);
void
save
(
ofstream
&
fp
,
flow_eSaveMode
mode
);
void
open
(
ifstream
&
fp
);
void
draw
(
void
*
pos
,
int
highlight
,
int
hot
,
void
*
node
);
void
draw
(
void
*
pos
,
int
highlight
,
int
dimmed
,
int
hot
,
void
*
node
);
void
nav_draw
(
void
*
pos
,
int
highlight
,
void
*
node
);
void
draw_inverse
(
void
*
pos
,
int
hot
,
void
*
node
);
void
erase
(
void
*
pos
,
int
hot
,
void
*
node
);
void
nav_erase
(
void
*
pos
,
void
*
node
);
void
move
(
void
*
pos
,
double
x
,
double
y
,
int
highlight
,
int
hot
);
void
move
(
void
*
pos
,
double
x
,
double
y
,
int
highlight
,
int
dimmed
,
int
hot
);
void
shift
(
void
*
pos
,
double
delta_x
,
double
delta_y
,
int
highlight
,
int
hot
);
int
highlight
,
int
dimmed
,
int
hot
);
void
get_borders
(
double
pos_x
,
double
pos_y
,
double
*
x_right
,
double
*
x_left
,
double
*
y_high
,
double
*
y_low
,
void
*
node
);
int
get_conpoint
(
int
num
,
double
*
x
,
double
*
y
,
flow_eDirection
*
dir
)
...
...
xtt/lib/flow/src/flow_api.cpp
View file @
3b3dee69
...
...
@@ -105,6 +105,11 @@ void flow_ResetHighlightAll( flow_tCtx ctx)
ctx
->
set_highlight
(
0
);
}
void
flow_ResetDimmedAll
(
flow_tCtx
ctx
)
{
ctx
->
set_dimmed
(
0
);
}
void
flow_ResetInverseAll
(
flow_tCtx
ctx
)
{
ctx
->
set_inverse
(
0
);
...
...
@@ -185,6 +190,16 @@ void flow_GetHighlight( flow_tObject object, int *value)
*
value
=
((
FlowArrayElem
*
)
object
)
->
get_highlight
();
}
void
flow_SetDimmed
(
flow_tObject
object
,
int
value
)
{
((
FlowArrayElem
*
)
object
)
->
set_dimmed
(
value
);
}
void
flow_GetDimmed
(
flow_tObject
object
,
int
*
value
)
{
*
value
=
((
FlowArrayElem
*
)
object
)
->
get_dimmed
();
}
void
flow_SetInverse
(
flow_tObject
object
,
int
value
)
{
((
FlowArrayElem
*
)
object
)
->
set_inverse
(
value
);
...
...
xtt/lib/flow/src/flow_api.h
View file @
3b3dee69
...
...
@@ -109,6 +109,7 @@ void flow_DeleteNode( flow_tNode node);
void
flow_DeleteConnection
(
flow_tCon
con
);
int
flow_FindSelectedObject
(
flow_tCtx
ctx
,
flow_tObject
object
);
void
flow_ResetHighlightAll
(
flow_tCtx
ctx
);
void
flow_ResetDimmedAll
(
flow_tCtx
ctx
);
void
flow_ResetInverseAll
(
flow_tCtx
ctx
);
void
flow_SetSelectHighlight
(
flow_tCtx
ctx
);
void
flow_ResetSelectHighlight
(
flow_tCtx
ctx
);
...
...
@@ -125,6 +126,8 @@ void flow_GetSelectedNodes( flow_tCtx ctx, flow_tNode **nodes, int *num);
void
flow_GetSelectedCons
(
flow_tCtx
ctx
,
flow_tCon
**
cons
,
int
*
num
);
void
flow_SetHighlight
(
flow_tObject
object
,
int
value
);
void
flow_GetHighlight
(
flow_tObject
object
,
int
*
value
);
void
flow_SetDimmed
(
flow_tObject
object
,
int
value
);
void
flow_GetDimmed
(
flow_tObject
object
,
int
*
value
);
void
flow_SetInverse
(
flow_tObject
object
,
int
value
);
void
flow_CreateNode
(
flow_tCtx
ctx
,
const
char
*
name
,
flow_tNodeClass
nc
,
double
x
,
double
y
,
void
*
user_data
,
flow_tNode
*
node
);
...
...
xtt/lib/flow/src/flow_arc.cpp
View file @
3b3dee69
...
...
@@ -119,7 +119,7 @@ void FlowArc::open( ifstream& fp)
}
}
void
FlowArc
::
draw
(
void
*
pos
,
int
highlight
,
int
hot
,
void
*
node
)
void
FlowArc
::
draw
(
void
*
pos
,
int
highlight
,
int
dimmed
,
int
hot
,
void
*
node
)
{
int
idx
=
int
(
ctx
->
zoom_factor
/
ctx
->
base_zoom_factor
*
line_width
-
1
);
idx
+=
hot
;
...
...
@@ -128,7 +128,7 @@ void FlowArc::draw( void *pos, int highlight, int hot, void *node)
ctx
->
fdraw
->
arc
(
ctx
,
ll
.
z_x
+
((
FlowPoint
*
)
pos
)
->
z_x
-
ctx
->
offset_x
,
ll
.
z_y
+
((
FlowPoint
*
)
pos
)
->
z_y
-
ctx
->
offset_y
,
ur
.
z_x
-
ll
.
z_x
,
ur
.
z_y
-
ll
.
z_y
,
angle1
,
angle2
,
draw_type
,
idx
,
highlight
);
draw_type
,
idx
,
highlight
,
dimmed
);
}
void
FlowArc
::
erase
(
void
*
pos
,
int
hot
,
void
*
node
)
...
...
@@ -198,7 +198,7 @@ void FlowArc::get_borders( double pos_x, double pos_y, double *x_right,
}
void
FlowArc
::
move
(
void
*
pos
,
double
x1
,
double
y1
,
double
x2
,
double
y2
,
int
ang1
,
int
ang2
,
int
highlight
,
int
hot
)
int
ang1
,
int
ang2
,
int
highlight
,
int
dimmed
,
int
hot
)
{
erase
(
pos
,
hot
,
NULL
);
nav_erase
(
pos
,
NULL
);
...
...
@@ -210,12 +210,12 @@ void FlowArc::move( void *pos, double x1, double y1, double x2, double y2,
angle2
=
ang2
;
zoom
();
nav_zoom
();
draw
(
pos
,
highlight
,
hot
,
NULL
);
draw
(
pos
,
highlight
,
dimmed
,
hot
,
NULL
);
nav_draw
(
pos
,
highlight
,
NULL
);
}
void
FlowArc
::
shift
(
void
*
pos
,
double
delta_x
,
double
delta_y
,
int
highlight
,
int
hot
)
int
highlight
,
int
dimmed
,
int
hot
)
{
erase
(
pos
,
hot
,
NULL
);
nav_erase
(
pos
,
NULL
);
...
...
@@ -226,7 +226,7 @@ void FlowArc::shift( void *pos, double delta_x, double delta_y,
zoom
();
nav_zoom
();
draw
(
pos
,
highlight
,
hot
,
NULL
);
draw
(
pos
,
highlight
,
dimmed
,
hot
,
NULL
);
nav_draw
(
pos
,
highlight
,
NULL
);
}
...
...
xtt/lib/flow/src/flow_arc.h
View file @
3b3dee69
...
...
@@ -65,7 +65,7 @@ class FlowArc : public FlowArrayElem {
void
print
(
void
*
pos
,
void
*
node
,
int
highlight
);
void
save
(
ofstream
&
fp
,
flow_eSaveMode
mode
);
void
open
(
ifstream
&
fp
);
void
draw
(
void
*
pos
,
int
highlight
,
int
hot
,
void
*
node
);
void
draw
(
void
*
pos
,
int
highlight
,
int
dimmed
,
int
hot
,
void
*
node
);
void
nav_draw
(
void
*
pos
,
int
highlight
,
void
*
node
);
void
erase
(
void
*
pos
,
int
hot
,
void
*
node
);
void
draw_inverse
(
void
*
pos
,
int
hot
,
void
*
node
)
...
...
@@ -74,9 +74,9 @@ class FlowArc : public FlowArrayElem {
void
get_borders
(
double
pos_x
,
double
pos_y
,
double
*
x_right
,
double
*
x_left
,
double
*
y_high
,
double
*
y_low
,
void
*
node
);
void
move
(
void
*
pos
,
double
x1
,
double
y1
,
double
x2
,
double
y2
,
int
ang1
,
int
ang2
,
int
highlight
,
int
hot
);
int
ang1
,
int
ang2
,
int
highlight
,
int
dimmed
,
int
hot
);
void
shift
(
void
*
pos
,
double
delta_x
,
double
delta_y
,
int
highlight
,
int
hot
);
int
highlight
,
int
dimmed
,
int
hot
);
int
get_conpoint
(
int
num
,
double
*
x
,
double
*
y
,
flow_eDirection
*
dir
)
{
return
0
;};
flow_eObjectType
type
()
{
return
flow_eObjectType_Arc
;};
...
...
xtt/lib/flow/src/flow_array.cpp
View file @
3b3dee69
...
...
@@ -787,13 +787,13 @@ void FlowArray::open( void *ctx, ifstream& fp)
}
}
void
FlowArray
::
draw
(
void
*
pos
,
int
highlight
,
int
hot
,
void
*
node
)
void
FlowArray
::
draw
(
void
*
pos
,
int
highlight
,
int
dimmed
,
int
hot
,
void
*
node
)
{
int
i
;
for
(
i
=
0
;
i
<
a_size
;
i
++
)
{
a
[
i
]
->
draw
(
pos
,
highlight
,
hot
,
node
);
a
[
i
]
->
draw
(
pos
,
highlight
,
dimmed
,
hot
,
node
);
}
}
...
...
@@ -901,6 +901,16 @@ void FlowArray::set_highlight( int on)
}
}
void
FlowArray
::
set_dimmed
(
int
on
)
{
int
i
;
for
(
i
=
0
;
i
<
a_size
;
i
++
)
{
a
[
i
]
->
set_dimmed
(
on
);
}
}
void
FlowArray
::
set_hot
(
int
on
)
{
int
i
;
...
...
@@ -963,13 +973,13 @@ void FlowArray::move( int delta_x, int delta_y, int grid)
}
}
void
FlowArray
::
shift
(
void
*
pos
,
double
delta_x
,
double
delta_y
,
int
highlight
,
int
hot
)
void
FlowArray
::
shift
(
void
*
pos
,
double
delta_x
,
double
delta_y
,
int
highlight
,
int
dimmed
,
int
hot
)
{
int
i
;
for
(
i
=
0
;
i
<
a_size
;
i
++
)
{
a
[
i
]
->
shift
(
pos
,
delta_x
,
delta_y
,
highlight
,
hot
);
a
[
i
]
->
shift
(
pos
,
delta_x
,
delta_y
,
highlight
,
dimmed
,
hot
);
}
}
...
...
xtt/lib/flow/src/flow_array.h
View file @
3b3dee69
...
...
@@ -64,7 +64,7 @@ class FlowArray {
void
print
(
void
*
pos
,
void
*
node
,
int
highlight
);
void
save
(
ofstream
&
fp
,
flow_eSaveMode
mode
);
void
open
(
void
*
ctx
,
ifstream
&
fp
);
void
draw
(
void
*
pos
,
int
highlight
,
int
hot
,
void
*
node
);
void
draw
(
void
*
pos
,
int
highlight
,
int
dimmed
,
int
hot
,
void
*
node
);
void
erase
(
void
*
pos
,
int
hot
,
void
*
node
);
void
draw_inverse
(
void
*
pos
,
int
hot
,
void
*
node
);
void
nav_draw
(
void
*
pos
,
int
highlight
,
void
*
node
);
...
...
@@ -82,10 +82,11 @@ class FlowArray {
void
**
cp
);
int
get_conpoint
(
int
num
,
double
*
x
,
double
*
y
,
flow_eDirection
*
dir
);
void
set_highlight
(
int
on
);
void
set_dimmed
(
int
on
);
void
set_hot
(
int
on
);
void
select_region_insert
(
double
ll_x
,
double
ll_y
,
double
ur_x
,
double
ur_y
);
void
shift
(
void
*
pos
,
double
delta_x
,
double
delta_y
,
int
highlight
,
void
shift
(
void
*
pos
,
double
delta_x
,
double
delta_y
,
int
highlight
,
int
dimmed
,
int
hot
);
void
move
(
int
delta_x
,
int
delta_y
,
int
grid
);
void
move_noerase
(
int
delta_x
,
int
delta_y
,
int
grid
);
...
...
xtt/lib/flow/src/flow_array_elem.h
View file @
3b3dee69
...
...
@@ -64,14 +64,14 @@ class FlowArrayElem {
virtual
void
open
(
ifstream
&
fp
)
{};
virtual
void
print
(
void
*
pos
,
void
*
node
,
int
highlight
)
{};
virtual
void
draw
(
int
ll_x
,
int
ll_y
,
int
ur_x
,
int
ur_y
)
{};
virtual
void
draw
(
void
*
pos
,
int
highlight
,
int
hot
,
void
*
node
)
{};
virtual
void
draw
(
void
*
pos
,
int
highlight
,
int
dimmed
,
int
hot
,
void
*
node
)
{};
virtual
void
erase
()
{};
virtual
void
erase
(
void
*
pos
,
int
hot
,
void
*
node
)
{};
virtual
void
draw_inverse
(
void
*
pos
,
int
hot
,
void
*
node
)
{};
virtual
void
move
(
int
delta_x
,
int
delta_y
,
int
grid
)
{};
virtual
void
move_noerase
(
int
delta_x
,
int
delta_y
,
int
grid
)
{};
virtual
void
shift
(
void
*
pos
,
double
delta_x
,
double
delta_y
,
int
highlight
,
int
hot
)
{};
int
highlight
,
int
dimmed
,
int
hot
)
{};
virtual
void
nav_draw
(
int
ll_x
,
int
ll_y
,
int
ur_x
,
int
ur_y
)
{};
virtual
void
nav_draw
(
void
*
pos
,
int
highlight
,
void
*
node
)
{};
virtual
void
nav_erase
()
{};
...
...
@@ -84,6 +84,8 @@ class FlowArrayElem {
virtual
int
delete_node_cons
(
void
*
node
)
{
return
0
;};
virtual
void
set_highlight
(
int
on
)
{};
virtual
int
get_highlight
()
{
return
1
;};
virtual
void
set_dimmed
(
int
on
)
{};
virtual
int
get_dimmed
()
{
return
1
;};
virtual
void
set_inverse
(
int
on
)
{};
virtual
void
set_hot
(
int
on
)
{};
virtual
void
select_region_insert
(
double
ll_x
,
double
ll_y
,
double
ur_x
,
...
...
xtt/lib/flow/src/flow_arrow.cpp
View file @
3b3dee69
...
...
@@ -187,7 +187,7 @@ void FlowArrow::open( ifstream& fp)
}
}
void
FlowArrow
::
draw
(
void
*
pos
,
int
highlight
,
int
hot
,
void
*
node
)
void
FlowArrow
::
draw
(
void
*
pos
,
int
highlight
,
int
dimmed
,
int
hot
,
void
*
node
)
{
int
idx
=
int
(
ctx
->
zoom_factor
/
ctx
->
base_zoom_factor
*
line_width
-
1
);
idx
+=
hot
;
...
...
@@ -250,7 +250,7 @@ void FlowArrow::nav_erase( void *pos, void *node)
}
void
FlowArrow
::
move
(
void
*
pos
,
double
x1
,
double
y1
,
double
x2
,
double
y2
,
int
highlight
,
int
hot
)
int
highlight
,
int
dimmed
,
int
hot
)
{
erase
(
pos
,
hot
,
NULL
);
nav_erase
(
pos
,
NULL
);
...
...
@@ -301,12 +301,12 @@ void FlowArrow::move( void *pos, double x1, double y1, double x2, double y2,
p_dest
.
y
=
y2
;
zoom
();
nav_zoom
();
draw
(
pos
,
highlight
,
hot
,
NULL
);
draw
(
pos
,
highlight
,
dimmed
,
hot
,
NULL
);
nav_draw
(
pos
,
highlight
,
NULL
);
}
void
FlowArrow
::
shift
(
void
*
pos
,
double
delta_x
,
double
delta_y
,
int
highlight
,
int
hot
)
int
highlight
,
int
dimmed
,
int
hot
)
{
erase
(
pos
,
hot
,
NULL
);
nav_erase
(
pos
,
NULL
);
...
...
@@ -319,7 +319,7 @@ void FlowArrow::shift( void *pos, double delta_x, double delta_y,
zoom
();
nav_zoom
();
draw
(
pos
,
highlight
,
hot
,
NULL
);
draw
(
pos
,
highlight
,
dimmed
,
hot
,
NULL
);
nav_draw
(
pos
,
highlight
,
NULL
);
}
...
...
xtt/lib/flow/src/flow_arrow.h
View file @
3b3dee69
...
...
@@ -59,7 +59,7 @@ class FlowArrow : public FlowArrayElem {
void
print
(
void
*
pos
,
void
*
node
,
int
highlight
);
void
save
(
ofstream
&
fp
,
flow_eSaveMode
mode
);
void
open
(
ifstream
&
fp
);
void
draw
(
void
*
pos
,
int
hightlight
,
int
hot
,
void
*
node
);
void
draw
(
void
*
pos
,
int
hightlight
,
int
dimmed
,
int
hot
,
void
*
node
);
void
nav_draw
(
void
*
pos
,
int
highlight
,
void
*
node
);
void
erase
(
void
*
pos
,
int
hot
,
void
*
node
);
void
draw_inverse
(
void
*
pos
,
int
hot
,
void
*
node
)
...
...
@@ -72,9 +72,9 @@ class FlowArrow : public FlowArrayElem {
{
return
0
;};
flow_eObjectType
type
()
{
return
flow_eObjectType_Arrow
;};
void
move
(
void
*
pos
,
double
x1
,
double
y1
,
double
x2
,
double
y2
,
int
highlight
,
int
hot
);
int
highlight
,
int
dimmed
,
int
hot
);
void
shift
(
void
*
pos
,
double
delta_x
,
double
delta_y
,
int
highlight
,
int
hot
);
int
highlight
,
int
dimmed
,
int
hot
);
FlowCtx
*
ctx
;
FlowPoint
p_dest
;
FlowPoint
p1
;
...
...
xtt/lib/flow/src/flow_con.cpp
View file @
3b3dee69
This diff is collapsed.
Click to expand it.
xtt/lib/flow/src/flow_con.h
View file @
3b3dee69
...
...
@@ -151,6 +151,7 @@ class FlowCon : public FlowArrayElem {
flow_tName
c_name
;
int
hot
;
int
highlight
;
int
dimmed
;
flow_eMoveType
movement_type
;
flow_tTraceObj
trace_object
;
flow_tTraceAttr
trace_attribute
;
...
...
xtt/lib/flow/src/flow_conpoint.cpp
View file @
3b3dee69
...
...
@@ -158,7 +158,7 @@ void FlowConPoint::get_trace_attr( char *object, char *attribute,
*
inverted
=
0
;
}
void
FlowConPoint
::
draw
(
void
*
pos
,
int
highlight
,
int
hot
,
void
*
node
)
void
FlowConPoint
::
draw
(
void
*
pos
,
int
highlight
,
int
dimmed
,
int
hot
,
void
*
node
)
{
int
line_width
=
1
;
int
idx
=
int
(
ctx
->
zoom_factor
/
ctx
->
base_zoom_factor
*
line_width
-
1
)
+
2
;
...
...
@@ -191,7 +191,7 @@ void FlowConPoint::draw( void *pos, int highlight, int hot, void *node)
y
=
p
.
z_y
+
((
FlowPoint
*
)
pos
)
->
z_y
-
ctx
->
offset_y
-
size
/
2
;
}
ctx
->
fdraw
->
arc
(
ctx
,
x
,
y
,
size
,
size
,
0
,
360
,
flow_eDrawType_LineRed
,
idx
,
0
);
flow_eDrawType_LineRed
,
idx
,
0
,
0
);
}
}
...
...
xtt/lib/flow/src/flow_conpoint.h
View file @
3b3dee69
...
...
@@ -63,7 +63,7 @@ class FlowConPoint : public FlowArrayElem {
void
print
(
void
*
pos
,
void
*
node
)
{};
void
save
(
ofstream
&
fp
,
flow_eSaveMode
mode
);
void
open
(
ifstream
&
fp
);
void
draw
(
void
*
pos
,
int
highlight
,
int
hot
,
void
*
node
);
void
draw
(
void
*
pos
,
int
highlight
,
int
dimmed
,
int
hot
,
void
*
node
);
void
nav_draw
(
void
*
pos
,
int
highlight
,
void
*
node
)
{};
void
erase
(
void
*
pos
,
int
hot
,
void
*
node
);
void
nav_erase
(
void
*
pos
,
void
*
node
)
{};
...
...
xtt/lib/flow/src/flow_ctx.cpp
View file @
3b3dee69
/*
/*
* Proview Open Source Process Control.
* Copyright (C) 2005-2014 SSAB EMEA AB.
*
...
...
@@ -571,7 +571,7 @@ void FlowCtx::draw( int ll_x, int ll_y, int ur_x, int ur_y)
{
fdraw
->
rect
(
this
,
select_rect_ll_x
,
select_rect_ll_y
,
select_rect_ur_x
-
select_rect_ll_x
,
select_rect_ur_y
-
select_rect_ll_y
,
flow_eDrawType_Line
,
0
,
0
);
select_rect_ur_y
-
select_rect_ll_y
,
flow_eDrawType_Line
,
0
,
0
,
0
);
}
tiptext
->
draw
();
}
...
...
@@ -1148,7 +1148,7 @@ int FlowCtx::event_handler( flow_eEvent event, int x, int y, int w, int h)
draw
(
con_create_conpoint_x
,
con_create_conpoint_y
,
con_create_last_x
,
con_create_last_y
);
fdraw
->
line
(
this
,
con_create_conpoint_x
,
con_create_conpoint_y
,
x
,
y
,
flow_eDrawType_Line
,
0
,
0
);
x
,
y
,
flow_eDrawType_Line
,
0
,
0
,
0
);
con_create_last_x
=
x
;
con_create_last_y
=
y
;
for
(
i
=
0
;
i
<
a
.
a_size
;
i
++
)
...
...
xtt/lib/flow/src/flow_ctx.h
View file @
3b3dee69
...
...
@@ -127,6 +127,8 @@ class FlowCtx {
void
copy
();
void
set_highlight
(
int
on
)
{
a
.
set_highlight
(
on
);};
void
set_dimmed
(
int
on
)
{
a
.
set_dimmed
(
on
);};
void
set_inverse
(
int
on
)
{
a
.
set_inverse
(
on
);};
void
set_select_highlight
(
int
on
)
...
...
xtt/lib/flow/src/flow_draw.h
View file @
3b3dee69
...
...
@@ -61,7 +61,7 @@ class FlowDraw {
virtual
void
set_nav_window_size
(
FlowCtx
*
ctx
,
int
width
,
int
height
)
{}
virtual
int
rect
(
FlowCtx
*
ctx
,
int
x
,
int
y
,
int
width
,
int
height
,
flow_eDrawType
gc_type
,
int
idx
,
int
highlight
)
{
return
1
;}
flow_eDrawType
gc_type
,
int
idx
,
int
highlight
,
int
dimmed
)
{
return
1
;}
virtual
int
rect_erase
(
FlowCtx
*
ctx
,
int
x
,
int
y
,
int
width
,
int
height
,
int
idx
)
{
return
1
;}
virtual
int
nav_rect
(
FlowCtx
*
ctx
,
int
x
,
int
y
,
int
width
,
int
height
,
...
...
@@ -82,7 +82,7 @@ class FlowDraw {
int
idx
)
{
return
1
;}
virtual
int
arc
(
FlowCtx
*
ctx
,
int
x
,
int
y
,
int
width
,
int
height
,
int
angle1
,
int
angle2
,
flow_eDrawType
gc_type
,
int
idx
,
int
highlight
)
{
return
1
;}
flow_eDrawType
gc_type
,
int
idx
,
int
highlight
,
int
dimmed
)
{
return
1
;}
virtual
int
arc_erase
(
FlowCtx
*
ctx
,
int
x
,
int
y
,
int
width
,
int
height
,
int
angle1
,
int
angle2
,
int
idx
)
{
return
1
;}
...
...
@@ -93,7 +93,7 @@ class FlowDraw {
int
angle1
,
int
angle2
,
int
idx
)
{
return
1
;}
virtual
int
line
(
FlowCtx
*
ctx
,
int
x1
,
int
y1
,
int
x2
,
int
y2
,
flow_eDrawType
gc_type
,
int
idx
,
int
highlight
)
{
return
1
;}
flow_eDrawType
gc_type
,
int
idx
,
int
highlight
,
int
dimmed
)
{
return
1
;}
virtual
int
line_erase
(
FlowCtx
*
ctx
,
int
x1
,
int
y1
,
int
x2
,
int
y2
,
int
idx
)
{
return
1
;}
virtual
int
nav_line
(
FlowCtx
*
ctx
,
int
x1
,
int
y1
,
int
x2
,
int
y2
,
...
...
@@ -101,7 +101,7 @@ class FlowDraw {
virtual
int
nav_line_erase
(
FlowCtx
*
ctx
,
int
x1
,
int
y1
,
int
x2
,
int
y2
,
int
idx
)
{
return
1
;}
virtual
int
text
(
FlowCtx
*
ctx
,
int
x
,
int
y
,
char
*
text
,
int
len
,
flow_eDrawType
gc_type
,
int
idx
,
int
highlight
,
int
line
,
double
size
)
flow_eDrawType
gc_type
,
int
idx
,
int
highlight
,
int
dimmed
,
int
line
,
double
size
)
{
return
1
;}
virtual
int
text_inverse
(
FlowCtx
*
ctx
,
int
x
,
int
y
,
char
*
text
,
int
len
,
flow_eDrawType
gc_type
,
int
idx
,
int
line
,
double
size
)
...
...
xtt/lib/flow/src/flow_frame.cpp
View file @
3b3dee69
...
...
@@ -54,7 +54,7 @@ void FlowFrame::open( ifstream& fp)
// nyi
}
void
FlowFrame
::
draw
(
void
*
pos
,
int
highlight
,
int
hot
,
void
*
node
)
void
FlowFrame
::
draw
(
void
*
pos
,
int
highlight
,
int
dimmed
,
int
hot
,
void
*
node
)
{
double
ur_x
,
ur_y
;
int
idx
;
...
...
@@ -83,7 +83,7 @@ void FlowFrame::draw( void *pos, int highlight, int hot, void *node)
ll
.
z_y
+
((
FlowPoint
*
)
pos
)
->
z_y
-
ctx
->
offset_y
,
int
(
ur_x
*
ctx
->
zoom_factor
-
ll
.
z_x
-
((
FlowPoint
*
)
pos
)
->
z_x
-
1
),
int
(
ur_y
*
ctx
->
zoom_factor
-
ll
.
z_y
-
((
FlowPoint
*
)
pos
)
->
z_y
-
1
),
draw_type
,
idx
,
highlight
);
draw_type
,
idx
,
highlight
,
0
);
}
void
FlowFrame
::
erase
(
void
*
pos
,
int
hot
,
void
*
node
)
...
...
xtt/lib/flow/src/flow_frame.h
View file @
3b3dee69
...
...
@@ -53,7 +53,7 @@ class FlowFrame : public FlowRect {
FlowRect
(
flow_ctx
,
x
,
y
,
w
,
h
,
d_type
,
line_w
,
fix_line_w
)
{};
void
save
(
ofstream
&
fp
,
flow_eSaveMode
mode
);
void
open
(
ifstream
&
fp
);
void
draw
(
void
*
pos
,
int
hightlight
,
int
hot
,
void
*
node
);
void
draw
(
void
*
pos
,
int
hightlight
,
int
dimmed
,
int
hot
,
void
*
node
);
void
erase
(
void
*
pos
,
int
hot
,
void
*
node
);
void
get_borders
(
double
pos_x
,
double
pos_y
,
double
*
x_right
,
double
*
x_left
,
double
*
y_high
,
double
*
y_low
,
void
*
node
);
...
...
xtt/lib/flow/src/flow_image.cpp
View file @
3b3dee69
...
...
@@ -171,7 +171,7 @@ void FlowImage::open( ifstream& fp)
}
}
void
FlowImage
::
draw
(
void
*
pos
,
int
highlight
,
int
hot
,
void
*
node
)
void
FlowImage
::
draw
(
void
*
pos
,
int
highlight
,
int
dimmed
,
int
hot
,
void
*
node
)
{
if
(
!
(
display_level
&
ctx
->
display_level
))
return
;
...
...
@@ -249,7 +249,7 @@ void FlowImage::get_borders( double pos_x, double pos_y, double *x_right,
*
y_high
=
pos_y
+
ur
.
y
;
}
void
FlowImage
::
move
(
void
*
pos
,
double
x
,
double
y
,
int
highlight
,
int
hot
)
void
FlowImage
::
move
(
void
*
pos
,
double
x
,
double
y
,
int
highlight
,
int
dimmed
,
int
hot
)
{
double
width
,
height
;
...
...
@@ -263,12 +263,12 @@ void FlowImage::move( void *pos, double x, double y, int highlight, int hot)
ur
.
y
=
y
+
height
;
zoom
();
nav_zoom
();
draw
(
pos
,
highlight
,
hot
,
NULL
);
draw
(
pos
,
highlight
,
dimmed
,
hot
,
NULL
);
nav_draw
(
pos
,
highlight
,
NULL
);
}
void
FlowImage
::
shift
(
void
*
pos
,
double
delta_x
,
double
delta_y
,
int
highlight
,
int
hot
)
int
highlight
,
int
dimmed
,
int
hot
)
{
erase
(
pos
,
hot
,
NULL
);
nav_erase
(
pos
,
NULL
);
...
...
@@ -279,7 +279,7 @@ void FlowImage::shift( void *pos, double delta_x, double delta_y,
zoom
();
nav_zoom
();
draw
(
pos
,
highlight
,
hot
,
NULL
);
draw
(
pos
,
highlight
,
dimmed
,
hot
,
NULL
);
nav_draw
(
pos
,
highlight
,
NULL
);
}
...
...
xtt/lib/flow/src/flow_image.h
View file @
3b3dee69
...
...
@@ -60,7 +60,7 @@ class FlowImage : public FlowArrayElem {
void
print
(
void
*
pos
,
void
*
node
,
int
highlight
);
void
save
(
ofstream
&
fp
,
flow_eSaveMode
mode
);
void
open
(
ifstream
&
fp
);
void
draw
(
void
*
pos
,
int
hightlight
,
int
hot
,
void
*
node
);
void
draw
(
void
*
pos
,
int
hightlight
,
int
dimmed
,
int
hot
,
void
*
node
);
void
nav_draw
(
void
*
pos
,
int
highlight
,
void
*
node
);
void
draw_inverse
(
void
*
pos
,
int
hot
,
void
*
node
)
{
erase
(
pos
,
hot
,
node
);};
...
...
@@ -68,9 +68,9 @@ class FlowImage : public FlowArrayElem {
void
nav_erase
(
void
*
pos
,
void
*
node
);
void
get_borders
(
double
pos_x
,
double
pos_y
,
double
*
x_right
,
double
*
x_left
,
double
*
y_high
,
double
*
y_low
,
void
*
node
);
void
move
(
void
*
pos
,
double
x
,
double
y
,
int
highlight
,
int
hot
);
void
move
(
void
*
pos
,
double
x
,
double
y
,
int
highlight
,
int
dimmed
,
int
hot
);
void
shift
(
void
*
pos
,
double
delta_x
,
double
delta_y
,
int
highlight
,
int
hot
);
int
highlight
,
int
dimmed
,
int
hot
);
int
get_conpoint
(
int
num
,
double
*
x
,
double
*
y
,
flow_eDirection
*
dir
)
{
return
0
;};
flow_eObjectType
type
()
{
return
flow_eObjectType_Image
;};
...
...
xtt/lib/flow/src/flow_line.cpp
View file @
3b3dee69
...
...
@@ -117,7 +117,7 @@ void FlowLine::open( ifstream& fp)
}
}
void
FlowLine
::
draw
(
void
*
pos
,
int
high
tlight
,
int
hot
,
void
*
node
)
void
FlowLine
::
draw
(
void
*
pos
,
int
high
light
,
int
dimmed
,
int
hot
,
void
*
node
)
{
if
(
p1
.
z_x
==
p2
.
z_x
&&
p1
.
z_y
==
p2
.
z_y
)
return
;
...
...
@@ -129,7 +129,7 @@ void FlowLine::draw( void *pos, int hightlight, int hot, void *node)
p1
.
z_y
+
((
FlowPoint
*
)
pos
)
->
z_y
-
ctx
->
offset_y
,
p2
.
z_x
+
((
FlowPoint
*
)
pos
)
->
z_x
-
ctx
->
offset_x
,
p2
.
z_y
+
((
FlowPoint
*
)
pos
)
->
z_y
-
ctx
->
offset_y
,
draw_type
,
idx
,
hightlight
);
draw_type
,
idx
,
highlight
,
dimmed
);
}
void
FlowLine
::
erase
(
void
*
pos
,
int
hot
,
void
*
node
)
...
...
@@ -243,7 +243,7 @@ void FlowLine::get_borders( double pos_x, double pos_y,
}
void
FlowLine
::
move
(
void
*
pos
,
double
x1
,
double
y1
,
double
x2
,
double
y2
,
int
highlight
,
int
hot
)
int
highlight
,
int
dimmed
,
int
hot
)
{
erase
(
pos
,
hot
,
NULL
);
nav_erase
(
pos
,
NULL
);
...
...
@@ -253,12 +253,12 @@ void FlowLine::move( void *pos, double x1, double y1, double x2, double y2,
p2
.
y
=
y2
;
zoom
();
nav_zoom
();
draw
(
pos
,
highlight
,
hot
,
NULL
);
draw
(
pos
,
highlight
,
dimmed
,
hot
,
NULL
);
nav_draw
(
pos
,
highlight
,
NULL
);
}
void
FlowLine
::
shift
(
void
*
pos
,
double
delta_x
,
double
delta_y
,
int
highlight
,
int
hot
)
int
highlight
,
int
dimmed
,
int
hot
)
{
erase
(
pos
,
hot
,
NULL
);
nav_erase
(
pos
,
NULL
);
...
...
@@ -269,7 +269,7 @@ void FlowLine::shift( void *pos, double delta_x, double delta_y,
zoom
();
nav_zoom
();
draw
(
pos
,
highlight
,
hot
,
NULL
);
draw
(
pos
,
highlight
,
dimmed
,
hot
,
NULL
);
nav_draw
(
pos
,
highlight
,
NULL
);
}
...
...
xtt/lib/flow/src/flow_line.h
View file @
3b3dee69
...
...
@@ -64,7 +64,7 @@ class FlowLine : public FlowArrayElem {
void
print
(
void
*
pos
,
void
*
node
,
int
highlight
);
void
save
(
ofstream
&
fp
,
flow_eSaveMode
mode
);
void
open
(
ifstream
&
fp
);
void
draw
(
void
*
pos
,
int
highlight
,
int
hot
,
void
*
node
);
void
draw
(
void
*
pos
,
int
highlight
,
int
dimmed
,
int
hot
,
void
*
node
);
void
nav_draw
(
void
*
pos
,
int
hightlight
,
void
*
node
);
void
draw_inverse
(
void
*
pos
,
int
hot
,
void
*
node
)
{
erase
(
pos
,
hot
,
node
);};
...
...
@@ -73,8 +73,8 @@ class FlowLine : public FlowArrayElem {
void
get_borders
(
double
pos_x
,
double
pos_y
,
double
*
x_right
,
double
*
x_left
,
double
*
y_high
,
double
*
y_low
,
void
*
node
);
void
move
(
void
*
pos
,
double
x1
,
double
y1
,
double
x2
,
double
y2
,
int
highlight
,
int
hot
);
void
shift
(
void
*
pos
,
double
delta_x
,
double
delta_y
,
int
highlight
,
int
hot
);
int
highlight
,
int
dimmed
,
int
hot
);
void
shift
(
void
*
pos
,
double
delta_x
,
double
delta_y
,
int
highlight
,
int
dimmed
,
int
hot
);
int
get_conpoint
(
int
num
,
double
*
x
,
double
*
y
,
flow_eDirection
*
dir
)
{
return
0
;};
flow_eObjectType
type
()
{
return
flow_eObjectType_Line
;};
...
...
xtt/lib/flow/src/flow_node.cpp
View file @
3b3dee69
...
...
@@ -54,7 +54,7 @@ FlowNode::FlowNode( FlowCtx *flow_ctx, const char *name, FlowNodeClass *node_cla
obst_x_right
(
x1
),
obst_x_left
(
x1
),
obst_y_high
(
y1
),
obst_y_low
(
y1
),
hot
(
0
),
ctx
(
flow_ctx
),
nc
(
node_class
),
pos
(
flow_ctx
,
x1
,
y1
),
stored_pos
(
flow_ctx
,
x1
,
y1
),
highlight
(
0
),
inverse
(
0
),
trace_attr_type
(
flow_eTraceType_Boolean
),
highlight
(
0
),
dimmed
(
0
),
inverse
(
0
),
trace_attr_type
(
flow_eTraceType_Boolean
),
trace_inverted
(
0
),
trace_p
(
NULL
),
user_data
(
0
),
level
(
0
),
node_open
(
0
),
relative_annot_pos
(
rel_annot_pos
),
relative_annot_x
(
0
),
...
...
@@ -424,7 +424,7 @@ void FlowNode::draw( int ll_x, int ll_y, int ur_x, int ur_y)
y_low
*
ctx
->
zoom_factor
-
ctx
->
offset_y
<=
ur_y
)
{
if
(
!
inverse
)
nc
->
draw
(
&
pos
,
highlight
,
hot
,
(
void
*
)
this
);
nc
->
draw
(
&
pos
,
highlight
,
dimmed
,
hot
,
(
void
*
)
this
);
else
draw_inverse
();
}
...
...
@@ -447,7 +447,7 @@ void FlowNode::draw_inverse()
int
(
obst_x_right
*
ctx
->
zoom_factor
-
obst_x_left
*
ctx
->
zoom_factor
),
int
(
obst_y_high
*
ctx
->
zoom_factor
-
obst_y_low
*
ctx
->
zoom_factor
),
flow_eDrawType_Line
);
nc
->
draw
(
&
pos
,
highlight
,
hot
,
(
void
*
)
this
);
nc
->
draw
(
&
pos
,
highlight
,
dimmed
,
hot
,
(
void
*
)
this
);
}
else
{
ctx
->
fdraw
->
fill_rect
(
ctx
,
...
...
@@ -531,7 +531,17 @@ void FlowNode::set_highlight( int on)
{
highlight
=
on
;
if
(
!
inverse
)
nc
->
draw
(
&
pos
,
highlight
,
hot
,
(
void
*
)
this
);
nc
->
draw
(
&
pos
,
highlight
,
dimmed
,
hot
,
(
void
*
)
this
);
else
draw_inverse
();
nc
->
nav_draw
(
&
pos
,
highlight
,
(
void
*
)
this
);
}
void
FlowNode
::
set_dimmed
(
int
on
)
{
dimmed
=
on
;
if
(
!
inverse
)
nc
->
draw
(
&
pos
,
highlight
,
dimmed
,
hot
,
(
void
*
)
this
);
else
draw_inverse
();
nc
->
nav_draw
(
&
pos
,
highlight
,
(
void
*
)
this
);
...
...
@@ -545,7 +555,7 @@ void FlowNode::set_hot( int on)
nc
->
erase
(
&
pos
,
hot
,
(
void
*
)
this
);
hot
=
on
;
if
(
!
inverse
)
nc
->
draw
(
&
pos
,
highlight
,
hot
,
(
void
*
)
this
);
nc
->
draw
(
&
pos
,
highlight
,
dimmed
,
hot
,
(
void
*
)
this
);
else
draw_inverse
();
nc
->
nav_draw
(
&
pos
,
highlight
,
(
void
*
)
this
);
...
...
@@ -571,7 +581,7 @@ void FlowNode::set_inverse( int on)
int
(
obst_x_right
*
ctx
->
zoom_factor
-
obst_x_left
*
ctx
->
zoom_factor
),
int
(
obst_y_high
*
ctx
->
zoom_factor
-
obst_y_low
*
ctx
->
zoom_factor
),
flow_eDrawType_LineErase
);
nc
->
draw
(
&
pos
,
highlight
,
hot
,
(
void
*
)
this
);
nc
->
draw
(
&
pos
,
highlight
,
dimmed
,
hot
,
(
void
*
)
this
);
}
else
{
ctx
->
fdraw
->
fill_rect
(
ctx
,
...
...
@@ -580,7 +590,7 @@ void FlowNode::set_inverse( int on)
int
(
x_r
*
ctx
->
zoom_factor
-
x_left
*
ctx
->
zoom_factor
),
int
(
y_high
*
ctx
->
zoom_factor
-
y_low
*
ctx
->
zoom_factor
+
1
),
flow_eDrawType_LineErase
);
nc
->
draw
(
&
pos
,
highlight
,
hot
,
(
void
*
)
this
);
nc
->
draw
(
&
pos
,
highlight
,
dimmed
,
hot
,
(
void
*
)
this
);
}
}
else
...
...
@@ -635,7 +645,7 @@ void FlowNode::set_annotation( int num, const char *text, int size, int nodraw)
relative_annot_x
=
0
;
nc
->
configure_annotations
(
&
pos
,
(
void
*
)
this
);
if
(
!
inverse
)
nc
->
draw
(
&
pos
,
highlight
,
hot
,
(
void
*
)
this
);
nc
->
draw
(
&
pos
,
highlight
,
dimmed
,
hot
,
(
void
*
)
this
);
else
draw_inverse
();
}
...
...
@@ -715,7 +725,7 @@ void FlowNode::set_annot_pixmap( int num, flow_sAnnotPixmap *pixmap,
return
;
if
(
!
inverse
)
nc
->
draw
(
&
pos
,
highlight
,
hot
,
(
void
*
)
this
);
nc
->
draw
(
&
pos
,
highlight
,
dimmed
,
hot
,
(
void
*
)
this
);
else
draw_inverse
();
nc
->
nav_draw
(
&
pos
,
highlight
,
(
void
*
)
this
);
...
...
@@ -736,7 +746,7 @@ void FlowNode::remove_annot_pixmap( int num)
annotpixmapv
[
num
]
=
0
;
if
(
!
inverse
)
nc
->
draw
(
&
pos
,
highlight
,
hot
,
(
void
*
)
this
);
nc
->
draw
(
&
pos
,
highlight
,
dimmed
,
hot
,
(
void
*
)
this
);
else
draw_inverse
();
nc
->
nav_draw
(
&
pos
,
highlight
,
(
void
*
)
this
);
...
...
@@ -751,7 +761,7 @@ void FlowNode::set_radiobutton( int num, int value, int nodraw)
return
;
if
(
!
inverse
)
nc
->
draw
(
&
pos
,
highlight
,
hot
,
(
void
*
)
this
);
nc
->
draw
(
&
pos
,
highlight
,
dimmed
,
hot
,
(
void
*
)
this
);
else
draw_inverse
();
nc
->
nav_draw
(
&
pos
,
highlight
,
(
void
*
)
this
);
...
...
@@ -865,7 +875,7 @@ int FlowNode::event_handler( flow_eEvent event, int x, int y)
if
(
redraw
)
{
if
(
!
inverse
)
nc
->
draw
(
&
pos
,
highlight
,
hot
,
(
void
*
)
this
);
nc
->
draw
(
&
pos
,
highlight
,
dimmed
,
hot
,
(
void
*
)
this
);
else
draw_inverse
();
}
...
...
@@ -1053,7 +1063,7 @@ void FlowNode::conpoint_select( int num)
sel_conpoint1
=
num
;
else
if
(
sel_conpoint2
==
-
1
)
sel_conpoint2
=
num
;
nc
->
draw
(
&
pos
,
highlight
,
hot
,
(
void
*
)
this
);
nc
->
draw
(
&
pos
,
highlight
,
dimmed
,
hot
,
(
void
*
)
this
);
}
void
FlowNode
::
conpoint_select_clear
(
int
num
)
...
...
@@ -1061,12 +1071,12 @@ void FlowNode::conpoint_select_clear( int num)
if
(
sel_conpoint1
==
num
)
{
erase
();
sel_conpoint1
=
-
1
;
nc
->
draw
(
&
pos
,
highlight
,
hot
,
(
void
*
)
this
);
nc
->
draw
(
&
pos
,
highlight
,
dimmed
,
hot
,
(
void
*
)
this
);
}
else
if
(
sel_conpoint2
==
num
)
{
erase
();
sel_conpoint2
=
-
1
;
nc
->
draw
(
&
pos
,
highlight
,
hot
,
(
void
*
)
this
);
nc
->
draw
(
&
pos
,
highlight
,
dimmed
,
hot
,
(
void
*
)
this
);
}
}
...
...
@@ -1076,7 +1086,7 @@ void FlowNode::conpoint_select_clear()
erase
();
sel_conpoint1
=
-
1
;
sel_conpoint2
=
-
1
;
nc
->
draw
(
&
pos
,
highlight
,
hot
,
(
void
*
)
this
);
nc
->
draw
(
&
pos
,
highlight
,
dimmed
,
hot
,
(
void
*
)
this
);
}
}
...
...
@@ -1090,7 +1100,7 @@ void FlowNode::change_nodeclass( FlowNodeClass *new_nc)
erase
();
nc
=
new_nc
;
if
(
!
inverse
)
nc
->
draw
(
&
pos
,
highlight
,
hot
,
(
void
*
)
this
);
nc
->
draw
(
&
pos
,
highlight
,
dimmed
,
hot
,
(
void
*
)
this
);
else
draw_inverse
();
}
xtt/lib/flow/src/flow_node.h
View file @
3b3dee69
...
...
@@ -88,6 +88,8 @@ class FlowNode : public FlowArrayElem {
int
delete_node_cons
(
void
*
node
)
{
return
0
;};
void
set_highlight
(
int
on
);
int
get_highlight
()
{
return
highlight
;};
void
set_dimmed
(
int
on
);
int
get_dimmed
()
{
return
dimmed
;};
void
set_inverse
(
int
on
);
int
get_inverse
()
{
return
inverse
;};
void
set_hot
(
int
on
);
...
...
@@ -120,6 +122,7 @@ class FlowNode : public FlowArrayElem {
FlowPoint
stored_pos
;
flow_tName
n_name
;
int
highlight
;
int
dimmed
;
int
inverse
;
char
*
annotv
[
10
];
int
annotsize
[
10
];
...
...
xtt/lib/flow/src/flow_nodeclass.cpp
View file @
3b3dee69
...
...
@@ -115,13 +115,13 @@ void FlowNodeClass::open( ifstream& fp)
}
}
void
FlowNodeClass
::
draw
(
FlowPoint
*
pos
,
int
highlight
,
int
hot
,
void
*
node
)
void
FlowNodeClass
::
draw
(
FlowPoint
*
pos
,
int
highlight
,
int
dimmed
,
int
hot
,
void
*
node
)
{
int
i
;
for
(
i
=
0
;
i
<
a
.
a_size
;
i
++
)
{
a
.
a
[
i
]
->
draw
(
pos
,
highlight
,
hot
,
node
);
a
.
a
[
i
]
->
draw
(
pos
,
highlight
,
dimmed
,
hot
,
node
);
}
}
...
...
@@ -145,7 +145,7 @@ void FlowNodeClass::draw_inverse( FlowPoint *pos, int hot, void *node)
{
case
flow_eObjectType_Radiobutton
:
case
flow_eObjectType_Image
:
a
.
a
[
i
]
->
draw
(
pos
,
0
,
hot
,
node
);
a
.
a
[
i
]
->
draw
(
pos
,
0
,
0
,
hot
,
node
);
break
;
default:
a
.
a
[
i
]
->
draw_inverse
(
pos
,
hot
,
node
);
...
...
@@ -237,7 +237,7 @@ void FlowNodeClass::draw_annotation( void *pos, int highlight, int hot,
if
(
a
.
a
[
i
]
->
type
()
==
flow_eObjectType_Annot
&&
((
FlowAnnot
*
)
a
.
a
[
i
])
->
number
==
num
)
{
a
.
a
[
i
]
->
draw
(
pos
,
highlight
,
hot
,
node
);
a
.
a
[
i
]
->
draw
(
pos
,
highlight
,
0
,
hot
,
node
);
a
.
a
[
i
]
->
nav_draw
(
pos
,
highlight
,
node
);
break
;
}
...
...
xtt/lib/flow/src/flow_nodeclass.h
View file @
3b3dee69
...
...
@@ -64,7 +64,7 @@ class FlowNodeClass : public FlowArrayElem {
void
save
(
ofstream
&
fp
,
flow_eSaveMode
mode
);
void
open
(
ifstream
&
fp
);
int
load
(
char
*
filename
);
void
draw
(
FlowPoint
*
pos
,
int
highlight
,
int
hot
,
void
*
node
);
void
draw
(
FlowPoint
*
pos
,
int
highlight
,
int
dimmed
,
int
hot
,
void
*
node
);
void
nav_draw
(
FlowPoint
*
pos
,
int
highlight
,
void
*
node
);
void
draw_inverse
(
FlowPoint
*
pos
,
int
hot
,
void
*
node
);
void
erase
(
FlowPoint
*
pos
,
int
hot
,
void
*
node
);
...
...
xtt/lib/flow/src/flow_pixmap.cpp
View file @
3b3dee69
...
...
@@ -142,7 +142,7 @@ void FlowPixmap::open( ifstream& fp)
#endif
}
void
FlowPixmap
::
draw
(
void
*
pos
,
int
highlight
,
int
hot
,
void
*
node
)
void
FlowPixmap
::
draw
(
void
*
pos
,
int
highlight
,
int
dimmed
,
int
hot
,
void
*
node
)
{
int
idx
=
int
(
ctx
->
zoom_factor
/
ctx
->
base_zoom_factor
*
(
pixmap_size
+
4
)
-
4
);
...
...
@@ -250,7 +250,7 @@ void FlowPixmap::get_borders( double pos_x, double pos_y, double *x_right,
*/
}
void
FlowPixmap
::
move
(
void
*
pos
,
double
x
,
double
y
,
int
highlight
,
int
hot
)
void
FlowPixmap
::
move
(
void
*
pos
,
double
x
,
double
y
,
int
highlight
,
int
dimmed
,
int
hot
)
{
erase
(
pos
,
hot
,
NULL
);
...
...
@@ -259,12 +259,12 @@ void FlowPixmap::move( void *pos, double x, double y, int highlight, int hot)
p
.
y
=
y
;
zoom
();
nav_zoom
();
draw
(
pos
,
highlight
,
hot
,
NULL
);
draw
(
pos
,
highlight
,
dimmed
,
hot
,
NULL
);
nav_draw
(
pos
,
highlight
,
NULL
);
}
void
FlowPixmap
::
shift
(
void
*
pos
,
double
delta_x
,
double
delta_y
,
int
highlight
,
int
hot
)
int
highlight
,
int
dimmed
,
int
hot
)
{
erase
(
pos
,
hot
,
NULL
);
nav_erase
(
pos
,
NULL
);
...
...
@@ -273,7 +273,7 @@ void FlowPixmap::shift( void *pos, double delta_x, double delta_y,
zoom
();
nav_zoom
();
draw
(
pos
,
highlight
,
hot
,
NULL
);
draw
(
pos
,
highlight
,
dimmed
,
hot
,
NULL
);
nav_draw
(
pos
,
highlight
,
NULL
);
}
...
...
xtt/lib/flow/src/flow_pixmap.h
View file @
3b3dee69
...
...
@@ -62,14 +62,14 @@ class FlowPixmap : public FlowArrayElem {
void
print
(
void
*
pos
,
void
*
node
,
int
highlight
);
void
save
(
ofstream
&
fp
,
flow_eSaveMode
mode
);
void
open
(
ifstream
&
fp
);
void
draw
(
void
*
pos
,
int
highlight
,
int
hot
,
void
*
node
);
void
draw
(
void
*
pos
,
int
highlight
,
int
dimmed
,
int
hot
,
void
*
node
);
void
nav_draw
(
void
*
pos
,
int
highlight
,
void
*
node
);
void
draw_inverse
(
void
*
pos
,
int
hot
,
void
*
node
);
void
erase
(
void
*
pos
,
int
hot
,
void
*
node
);
void
nav_erase
(
void
*
pos
,
void
*
node
);
void
move
(
void
*
pos
,
double
x
,
double
y
,
int
highlight
,
int
hot
);
void
move
(
void
*
pos
,
double
x
,
double
y
,
int
highlight
,
int
dimmed
,
int
hot
);
void
shift
(
void
*
pos
,
double
delta_x
,
double
delta_y
,
int
highlight
,
int
hot
);
int
highlight
,
int
dimmed
,
int
hot
);
void
get_borders
(
double
pos_x
,
double
pos_y
,
double
*
x_right
,
double
*
x_left
,
double
*
y_high
,
double
*
y_low
,
void
*
node
);
int
get_conpoint
(
int
num
,
double
*
x
,
double
*
y
,
flow_eDirection
*
dir
)
...
...
xtt/lib/flow/src/flow_pushbutton.cpp
View file @
3b3dee69
...
...
@@ -69,9 +69,9 @@ void FlowPushButton::draw( int ll_x, int ll_y, int ur_x, int ur_y)
ctx
->
fdraw
->
rect
(
ctx
,
pos
.
z_x
+
r
.
ll
.
z_x
,
pos
.
z_y
+
r
.
ll
.
z_y
,
r
.
ur
.
z_x
-
r
.
ll
.
z_x
,
r
.
ur
.
z_y
-
r
.
ll
.
z_y
,
r
.
draw_type
,
r
.
line_width
-
1
,
0
);
r
.
line_width
-
1
,
0
,
0
);
ctx
->
fdraw
->
text
(
ctx
,
pos
.
z_x
+
t
.
p
.
z_x
,
pos
.
z_y
+
t
.
p
.
z_y
,
t
.
text
,
strlen
(
t
.
text
),
t
.
draw_type
,
t
.
text_size
,
0
,
0
,
strlen
(
t
.
text
),
t
.
draw_type
,
t
.
text_size
,
0
,
0
,
0
,
ctx
->
zoom_factor
/
ctx
->
base_zoom_factor
*
(
8
+
2
*
t
.
text_size
));
}
...
...
xtt/lib/flow/src/flow_radiobutton.cpp
View file @
3b3dee69
...
...
@@ -115,7 +115,7 @@ void FlowRadiobutton::open( ifstream& fp)
// Not yet implemented
}
void
FlowRadiobutton
::
draw
(
void
*
pos
,
int
highlight
,
int
hot
,
void
*
node
)
void
FlowRadiobutton
::
draw
(
void
*
pos
,
int
highlight
,
int
dimmed
,
int
hot
,
void
*
node
)
{
int
ll_x
,
ll_y
,
ur_x
,
ur_y
;
int
idx
=
0
;
...
...
@@ -125,17 +125,17 @@ void FlowRadiobutton::draw( void *pos, int highlight, int hot, void *node)
ur_x
=
ll_x
+
ur
.
z_x
-
ll
.
z_x
;
ur_y
=
ll_y
+
ur
.
z_y
-
ll
.
z_y
;
ctx
->
fdraw
->
rect
(
ctx
,
ll_x
,
ll_y
,
ur_x
-
ll_x
,
ur_y
-
ll_y
,
draw_type
,
idx
,
0
);
draw_type
,
idx
,
0
,
0
);
if
(
((
FlowNode
*
)
node
)
->
rbuttonv
[
number
])
{
ctx
->
fdraw
->
line
(
ctx
,
ll_x
+
1
,
ll_y
+
1
,
ur_x
-
1
,
ll_y
+
1
,
flow_eDrawType_LineGray
,
idx
,
0
);
flow_eDrawType_LineGray
,
idx
,
0
,
0
);
ctx
->
fdraw
->
line
(
ctx
,
ll_x
+
2
,
ll_y
+
2
,
ur_x
-
2
,
ll_y
+
2
,
flow_eDrawType_LineGray
,
idx
,
0
);
flow_eDrawType_LineGray
,
idx
,
0
,
0
);
ctx
->
fdraw
->
line
(
ctx
,
ll_x
+
1
,
ll_y
+
1
,
ll_x
+
1
,
ur_y
-
1
,
flow_eDrawType_LineGray
,
idx
,
0
);
flow_eDrawType_LineGray
,
idx
,
0
,
0
);
ctx
->
fdraw
->
line
(
ctx
,
ll_x
+
2
,
ll_y
+
2
,
ll_x
+
2
,
ur_y
-
2
,
flow_eDrawType_LineGray
,
idx
,
0
);
flow_eDrawType_LineGray
,
idx
,
0
,
0
);
ctx
->
fdraw
->
line_erase
(
ctx
,
ur_x
-
1
,
ur_y
-
1
,
ll_x
+
1
,
ur_y
-
1
,
idx
);
ctx
->
fdraw
->
line_erase
(
ctx
,
ur_x
-
2
,
ur_y
-
2
,
ll_x
+
2
,
ur_y
-
2
,
...
...
@@ -158,13 +158,13 @@ void FlowRadiobutton::draw( void *pos, int highlight, int hot, void *node)
ctx
->
fdraw
->
line_erase
(
ctx
,
ll_x
+
2
,
ll_y
+
2
,
ll_x
+
2
,
ur_y
-
2
,
idx
);
ctx
->
fdraw
->
line
(
ctx
,
ur_x
-
1
,
ur_y
-
1
,
ll_x
+
1
,
ur_y
-
1
,
flow_eDrawType_LineGray
,
idx
,
0
);
flow_eDrawType_LineGray
,
idx
,
0
,
0
);
ctx
->
fdraw
->
line
(
ctx
,
ur_x
-
2
,
ur_y
-
2
,
ll_x
+
2
,
ur_y
-
2
,
flow_eDrawType_LineGray
,
idx
,
0
);
flow_eDrawType_LineGray
,
idx
,
0
,
0
);
ctx
->
fdraw
->
line
(
ctx
,
ur_x
-
1
,
ur_y
-
1
,
ur_x
-
1
,
ll_y
+
1
,
flow_eDrawType_LineGray
,
idx
,
0
);
flow_eDrawType_LineGray
,
idx
,
0
,
0
);
ctx
->
fdraw
->
line
(
ctx
,
ur_x
-
2
,
ur_y
-
2
,
ur_x
-
2
,
ll_y
+
2
,
flow_eDrawType_LineGray
,
idx
,
0
);
flow_eDrawType_LineGray
,
idx
,
0
,
0
);
ctx
->
fdraw
->
fill_rect
(
ctx
,
ll_x
+
3
,
ll_y
+
3
,
ur_x
-
ll_x
-
5
,
ur_y
-
ll_y
-
5
,
flow_eDrawType_LineErase
);
}
...
...
@@ -273,7 +273,7 @@ void FlowRadiobutton::get_borders( double pos_x, double pos_y, double *x_right,
*
y_high
=
pos_y
+
ur
.
y
;
}
void
FlowRadiobutton
::
move
(
void
*
pos
,
double
x
,
double
y
,
int
highlight
,
int
hot
)
void
FlowRadiobutton
::
move
(
void
*
pos
,
double
x
,
double
y
,
int
highlight
,
int
dimmed
,
int
hot
)
{
double
width
,
height
;
...
...
@@ -287,12 +287,12 @@ void FlowRadiobutton::move( void *pos, double x, double y, int highlight, int ho
ur
.
y
=
y
+
height
;
zoom
();
nav_zoom
();
draw
(
pos
,
highlight
,
hot
,
NULL
);
draw
(
pos
,
highlight
,
dimmed
,
hot
,
NULL
);
nav_draw
(
pos
,
highlight
,
NULL
);
}
void
FlowRadiobutton
::
shift
(
void
*
pos
,
double
delta_x
,
double
delta_y
,
int
highlight
,
int
hot
)
int
highlight
,
int
dimmed
,
int
hot
)
{
erase
(
pos
,
hot
,
NULL
);
nav_erase
(
pos
,
NULL
);
...
...
@@ -303,7 +303,7 @@ void FlowRadiobutton::shift( void *pos, double delta_x, double delta_y,
zoom
();
nav_zoom
();
draw
(
pos
,
highlight
,
hot
,
NULL
);
draw
(
pos
,
highlight
,
dimmed
,
hot
,
NULL
);
nav_draw
(
pos
,
highlight
,
NULL
);
}
...
...
xtt/lib/flow/src/flow_radiobutton.h
View file @
3b3dee69
...
...
@@ -64,7 +64,7 @@ class FlowRadiobutton : public FlowArrayElem {
void
print
(
void
*
pos
,
void
*
node
,
int
highlight
);
void
save
(
ofstream
&
fp
,
flow_eSaveMode
mode
);
void
open
(
ifstream
&
fp
);
void
draw
(
void
*
pos
,
int
hightlight
,
int
hot
,
void
*
node
);
void
draw
(
void
*
pos
,
int
hightlight
,
int
dimmed
,
int
hot
,
void
*
node
);
void
nav_draw
(
void
*
pos
,
int
highlight
,
void
*
node
);
void
draw_inverse
(
void
*
pos
,
int
hot
,
void
*
node
)
{
erase
(
pos
,
hot
,
node
);};
...
...
@@ -72,9 +72,9 @@ class FlowRadiobutton : public FlowArrayElem {
void
nav_erase
(
void
*
pos
,
void
*
node
);
void
get_borders
(
double
pos_x
,
double
pos_y
,
double
*
x_right
,
double
*
x_left
,
double
*
y_high
,
double
*
y_low
,
void
*
node
);
void
move
(
void
*
pos
,
double
x
,
double
y
,
int
highlight
,
int
hot
);
void
move
(
void
*
pos
,
double
x
,
double
y
,
int
highlight
,
int
dimmed
,
int
hot
);
void
shift
(
void
*
pos
,
double
delta_x
,
double
delta_y
,
int
highlight
,
int
hot
);
int
highlight
,
int
dimmed
,
int
hot
);
int
get_conpoint
(
int
num
,
double
*
x
,
double
*
y
,
flow_eDirection
*
dir
)
{
return
0
;};
flow_eObjectType
type
()
{
return
flow_eObjectType_Radiobutton
;};
...
...
xtt/lib/flow/src/flow_rect.cpp
View file @
3b3dee69
...
...
@@ -138,12 +138,12 @@ void FlowRect::draw_inverse( void *pos, int hot, void *node)
draw_type
==
flow_eDrawType_Green
||
draw_type
==
flow_eDrawType_DarkGray
||
draw_type
==
flow_eDrawType_Yellow
))
draw
(
pos
,
hot
,
0
,
node
);
draw
(
pos
,
0
,
0
,
hot
,
node
);
else
erase
(
pos
,
hot
,
node
);
}
void
FlowRect
::
draw
(
void
*
pos
,
int
highlight
,
int
hot
,
void
*
node
)
void
FlowRect
::
draw
(
void
*
pos
,
int
highlight
,
int
dimmed
,
int
hot
,
void
*
node
)
{
if
(
!
(
display_level
&
ctx
->
display_level
))
return
;
...
...
@@ -168,7 +168,7 @@ void FlowRect::draw( void *pos, int highlight, int hot, void *node)
if
(
!
fill
)
ctx
->
fdraw
->
rect
(
ctx
,
ll
.
z_x
+
((
FlowPoint
*
)
pos
)
->
z_x
-
ctx
->
offset_x
,
ll
.
z_y
+
((
FlowPoint
*
)
pos
)
->
z_y
-
ctx
->
offset_y
,
ur
.
z_x
-
ll
.
z_x
,
ur
.
z_y
-
ll
.
z_y
,
draw_type
,
idx
,
highlight
);
ur
.
z_x
-
ll
.
z_x
,
ur
.
z_y
-
ll
.
z_y
,
draw_type
,
idx
,
highlight
,
dimmed
);
else
{
flow_eDrawType
dtype
;
if
(
node
&&
((
FlowNode
*
)
node
)
->
fill_color
!=
flow_eDrawType_Inherit
)
...
...
@@ -290,7 +290,7 @@ void FlowRect::get_borders( double pos_x, double pos_y, double *x_right,
*
y_high
=
pos_y
+
ur
.
y
;
}
void
FlowRect
::
move
(
void
*
pos
,
double
x
,
double
y
,
int
highlight
,
int
hot
)
void
FlowRect
::
move
(
void
*
pos
,
double
x
,
double
y
,
int
highlight
,
int
dimmed
,
int
hot
)
{
double
width
,
height
;
...
...
@@ -304,12 +304,12 @@ void FlowRect::move( void *pos, double x, double y, int highlight, int hot)
ur
.
y
=
y
+
height
;
zoom
();
nav_zoom
();
draw
(
pos
,
highlight
,
hot
,
NULL
);
draw
(
pos
,
highlight
,
dimmed
,
hot
,
NULL
);
nav_draw
(
pos
,
highlight
,
NULL
);
}
void
FlowRect
::
shift
(
void
*
pos
,
double
delta_x
,
double
delta_y
,
int
highlight
,
int
hot
)
int
highlight
,
int
dimmed
,
int
hot
)
{
erase
(
pos
,
hot
,
NULL
);
nav_erase
(
pos
,
NULL
);
...
...
@@ -320,7 +320,7 @@ void FlowRect::shift( void *pos, double delta_x, double delta_y,
zoom
();
nav_zoom
();
draw
(
pos
,
highlight
,
hot
,
NULL
);
draw
(
pos
,
highlight
,
dimmed
,
hot
,
NULL
);
nav_draw
(
pos
,
highlight
,
NULL
);
}
...
...
xtt/lib/flow/src/flow_rect.h
View file @
3b3dee69
...
...
@@ -66,16 +66,16 @@ class FlowRect : public FlowArrayElem {
void
print
(
void
*
pos
,
void
*
node
,
int
highlight
);
void
save
(
ofstream
&
fp
,
flow_eSaveMode
mode
);
void
open
(
ifstream
&
fp
);
void
draw
(
void
*
pos
,
int
hightlight
,
int
hot
,
void
*
node
);
void
draw
(
void
*
pos
,
int
hightlight
,
int
dimmed
,
int
hot
,
void
*
node
);
void
nav_draw
(
void
*
pos
,
int
highlight
,
void
*
node
);
void
draw_inverse
(
void
*
pos
,
int
hot
,
void
*
node
);
void
erase
(
void
*
pos
,
int
hot
,
void
*
node
);
void
nav_erase
(
void
*
pos
,
void
*
node
);
void
get_borders
(
double
pos_x
,
double
pos_y
,
double
*
x_right
,
double
*
x_left
,
double
*
y_high
,
double
*
y_low
,
void
*
node
);
void
move
(
void
*
pos
,
double
x
,
double
y
,
int
highlight
,
int
hot
);
void
move
(
void
*
pos
,
double
x
,
double
y
,
int
highlight
,
int
dimmed
,
int
hot
);
void
shift
(
void
*
pos
,
double
delta_x
,
double
delta_y
,
int
highlight
,
int
hot
);
int
highlight
,
int
dimmed
,
int
hot
);
int
get_conpoint
(
int
num
,
double
*
x
,
double
*
y
,
flow_eDirection
*
dir
)
{
return
0
;};
flow_eObjectType
type
()
{
return
flow_eObjectType_Rect
;};
...
...
xtt/lib/flow/src/flow_text.cpp
View file @
3b3dee69
...
...
@@ -115,7 +115,7 @@ void FlowText::open( ifstream& fp)
}
}
void
FlowText
::
draw
(
void
*
pos
,
int
highlight
,
int
hot
,
void
*
node
)
void
FlowText
::
draw
(
void
*
pos
,
int
highlight
,
int
dimmed
,
int
hot
,
void
*
node
)
{
int
idx
=
int
(
ctx
->
zoom_factor
/
ctx
->
base_zoom_factor
*
(
text_size
+
4
)
-
4
);
if
(
idx
<
0
)
...
...
@@ -123,7 +123,7 @@ void FlowText::draw( void *pos, int highlight, int hot, void *node)
idx
=
MIN
(
idx
,
DRAW_TYPE_SIZE
-
1
);
ctx
->
fdraw
->
text
(
ctx
,
p
.
z_x
+
((
FlowPoint
*
)
pos
)
->
z_x
-
ctx
->
offset_x
,
p
.
z_y
+
((
FlowPoint
*
)
pos
)
->
z_y
-
ctx
->
offset_y
,
text
,
strlen
(
text
),
draw_type
,
idx
,
highlight
,
0
,
draw_type
,
idx
,
highlight
,
dimmed
,
0
,
ctx
->
zoom_factor
/
ctx
->
base_zoom_factor
*
(
8
+
2
*
text_size
));
}
...
...
@@ -221,7 +221,7 @@ void FlowText::get_borders( double pos_x, double pos_y, double *x_right,
*/
}
void
FlowText
::
move
(
void
*
pos
,
double
x
,
double
y
,
int
highlight
,
int
hot
)
void
FlowText
::
move
(
void
*
pos
,
double
x
,
double
y
,
int
highlight
,
int
dimmed
,
int
hot
)
{
erase
(
pos
,
hot
,
NULL
);
...
...
@@ -230,12 +230,12 @@ void FlowText::move( void *pos, double x, double y, int highlight, int hot)
p
.
y
=
y
;
zoom
();
nav_zoom
();
draw
(
pos
,
highlight
,
hot
,
NULL
);
draw
(
pos
,
highlight
,
dimmed
,
hot
,
NULL
);
nav_draw
(
pos
,
highlight
,
NULL
);
}
void
FlowText
::
shift
(
void
*
pos
,
double
delta_x
,
double
delta_y
,
int
highlight
,
int
hot
)
int
highlight
,
int
dimmed
,
int
hot
)
{
erase
(
pos
,
hot
,
NULL
);
nav_erase
(
pos
,
NULL
);
...
...
@@ -244,7 +244,7 @@ void FlowText::shift( void *pos, double delta_x, double delta_y,
zoom
();
nav_zoom
();
draw
(
pos
,
highlight
,
hot
,
NULL
);
draw
(
pos
,
highlight
,
dimmed
,
hot
,
NULL
);
nav_draw
(
pos
,
highlight
,
NULL
);
}
...
...
xtt/lib/flow/src/flow_text.h
View file @
3b3dee69
...
...
@@ -61,14 +61,14 @@ class FlowText : public FlowArrayElem {
void
print
(
void
*
pos
,
void
*
node
,
int
highlight
);
void
save
(
ofstream
&
fp
,
flow_eSaveMode
mode
);
void
open
(
ifstream
&
fp
);
void
draw
(
void
*
pos
,
int
highlight
,
int
hot
,
void
*
node
);
void
draw
(
void
*
pos
,
int
highlight
,
int
dimmed
,
int
hot
,
void
*
node
);
void
nav_draw
(
void
*
pos
,
int
highlight
,
void
*
node
);
void
draw_inverse
(
void
*
pos
,
int
hot
,
void
*
node
);
void
erase
(
void
*
pos
,
int
hot
,
void
*
node
);
void
nav_erase
(
void
*
pos
,
void
*
node
);
void
move
(
void
*
pos
,
double
x
,
double
y
,
int
highlight
,
int
hot
);
void
move
(
void
*
pos
,
double
x
,
double
y
,
int
highlight
,
int
dimmed
,
int
hot
);
void
shift
(
void
*
pos
,
double
delta_x
,
double
delta_y
,
int
highlight
,
int
hot
);
int
highlight
,
int
dimmed
,
int
hot
);
void
get_borders
(
double
pos_x
,
double
pos_y
,
double
*
x_right
,
double
*
x_left
,
double
*
y_high
,
double
*
y_low
,
void
*
node
);
int
get_conpoint
(
int
num
,
double
*
x
,
double
*
y
,
flow_eDirection
*
dir
)
...
...
xtt/lib/flow/src/flow_tiptext.cpp
View file @
3b3dee69
...
...
@@ -129,13 +129,13 @@ void FlowTipText::draw()
ctx
->
fdraw
->
fill_rect
(
ctx
,
text_x
,
text_y
,
text_width
,
text_height
,
flow_eDrawType_LineErase
);
ctx
->
fdraw
->
rect
(
ctx
,
text_x
,
text_y
,
text_width
,
text_height
,
flow_eDrawType_Line
,
0
,
0
);
flow_eDrawType_Line
,
0
,
0
,
0
);
int
y
=
text_y
+
4
+
(
text_height
-
4
)
/
tiptext_rows
;
for
(
int
i
=
0
;
i
<
tiptext_rows
;
i
++
)
{
ctx
->
fdraw
->
text
(
ctx
,
text_x
+
6
,
y
-
text_descent
-
2
,
tiptext
[
i
],
strlen
(
tiptext
[
i
]),
flow_eDrawType_TextHelvetica
,
text_size
,
0
,
0
,
ctx
->
zoom_factor
/
ctx
->
base_zoom_factor
*
(
8
+
2
*
text_size
));
0
,
0
,
0
,
ctx
->
zoom_factor
/
ctx
->
base_zoom_factor
*
(
8
+
2
*
text_size
));
y
+=
(
text_height
-
3
)
/
tiptext_rows
;
}
...
...
xtt/lib/xtt/src/xtt_trace.cpp
View file @
3b3dee69
...
...
@@ -273,6 +273,63 @@ int RtTrace::disconnect_bc( flow_tObject object)
return
1
;
}
int
RtTrace
::
scan_bc
(
flow_tObject
object
,
void
*
trace_p
)
{
flow_tTraceObj
trace_object
;
flow_tTraceAttr
trace_attribute
;
flow_eTraceType
trace_attr_type
;
int
trace_inverted
;
int
highlight
;
int
on
;
char
txt
[
80
];
pwr_tSubid
*
subid_p
;
pwr_tStatus
sts
;
pwr_tBoolean
old
;
int
dimmed
;
if
(
flow_GetObjectType
(
object
)
==
flow_eObjectType_Node
)
{
flow_GetTraceAttr
(
object
,
trace_object
,
trace_attribute
,
&
trace_attr_type
,
&
trace_inverted
);
flow_GetHighlight
(
object
,
&
highlight
);
switch
(
trace_attr_type
)
{
case
flow_eTraceType_Boolean
:
on
=
trace_inverted
?
*
(
unsigned
int
*
)
trace_p
==
0
:
*
(
unsigned
int
*
)
trace_p
!=
0
;
if
(
highlight
!=
on
)
flow_SetHighlight
(
object
,
on
);
if
(
flow_GetNodeGroup
(
object
)
==
flow_eNodeGroup_Trace
)
{
sprintf
(
txt
,
"%d"
,
*
(
unsigned
int
*
)
trace_p
);
flow_SetAnnotation
(
object
,
0
,
txt
,
strlen
(
txt
));
}
break
;
case
flow_eTraceType_Int32
:
sprintf
(
txt
,
"%d"
,
*
(
unsigned
int
*
)
trace_p
);
flow_SetAnnotation
(
object
,
0
,
txt
,
strlen
(
txt
));
break
;
case
flow_eTraceType_Float32
:
sprintf
(
txt
,
"%f"
,
*
(
float
*
)
trace_p
);
flow_SetAnnotation
(
object
,
0
,
txt
,
strlen
(
txt
));
break
;
default:
break
;
}
if
(
!
(
strcmp
(
trace_object
,
""
)
==
0
||
strcmp
(
trace_attribute
,
""
)
==
0
))
{
flow_GetUserData
(
object
,
(
void
**
)
&
subid_p
);
if
(
subid_p
)
{
sts
=
gdh_GetSubscriptionOldness
(
*
subid_p
,
&
old
,
0
,
0
);
if
(
ODD
(
sts
))
{
flow_GetDimmed
(
object
,
&
dimmed
);
if
(
(
int
)
old
!=
dimmed
)
flow_SetDimmed
(
object
,
old
);
}
}
}
}
return
1
;
}
void
RtTrace
::
trace_scan
(
void
*
data
)
{
...
...
@@ -1285,7 +1342,7 @@ int RtTrace::trace_start()
flow_ResetHighlightAll
(
flow_ctx
);
flow_SelectClear
(
flow_ctx
);
sts
=
flow_TraceInit
(
flow_ctx
,
connect_bc
,
disconnect_bc
,
NULL
);
sts
=
flow_TraceInit
(
flow_ctx
,
connect_bc
,
disconnect_bc
,
scan_bc
);
if
(
EVEN
(
sts
))
return
sts
;
trace_started
=
1
;
...
...
@@ -1323,6 +1380,7 @@ int RtTrace::trace_stop()
if
(
trace_started
)
{
flow_TraceClose
(
flow_ctx
);
flow_ResetHighlightAll
(
flow_ctx
);
flow_ResetDimmedAll
(
flow_ctx
);
flow_SelectClear
(
flow_ctx
);
flow_RemoveTraceObjects
(
flow_ctx
);
trace_started
=
0
;
...
...
xtt/lib/xtt/src/xtt_trace.h
View file @
3b3dee69
...
...
@@ -145,6 +145,7 @@ class RtTrace {
static
int
connect_bc
(
flow_tObject
object
,
char
*
name
,
char
*
attr
,
flow_eTraceType
type
,
void
**
p
);
static
int
disconnect_bc
(
flow_tObject
object
);
static
int
scan_bc
(
flow_tObject
object
,
void
*
p
);
static
void
trace_scan
(
void
*
data
);
static
int
init_flow
(
FlowCtx
*
ctx
,
void
*
client_data
);
static
int
flow_cb
(
FlowCtx
*
ctx
,
flow_tEvent
event
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment