Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
saeed
odb_view
Commits
91991641
Commit
91991641
authored
Oct 05, 2019
by
saeed
Browse files
a bit modification
parent
aaabe394
Changes
3
Hide whitespace changes
Inline
Side-by-side
compile.sh
View file @
91991641
time
gcc
-g
-std
=
c99
-O2
rita.c
-o
odbview
-lX11
-lm
-lpthread
time
gcc
-std
=
c99
-O2
rita.c
-o
odbview
-lX11
-lm
-lpthread
renderer.c
View file @
91991641
...
...
@@ -80,7 +80,8 @@ static struct Vis init_x(int w, int h){
result
.
win
=
XCreateWindow
(
result
.
dsp
,
RootWindow
(
result
.
dsp
,
result
.
screen_num
),
0
,
0
,
w
,
h
,
0
,
result
.
depth
,
InputOutput
,
result
.
visual
,
CWBackPixel
|
CWBorderPixel
|
CWOverrideRedirect
,
&
attributes
);
XSelectInput
(
result
.
dsp
,
result
.
win
,
ExposureMask
|
KeyPressMask
|
ButtonPressMask
|
StructureNotifyMask
|
PointerMotionMask
|
FocusChangeMask
);
char
*
fontname
=
"lucidasanstypewriter-bold-12"
;
//char * fontname = "lucidasanstypewriter-bold-12";
char
*
fontname
=
"10x20"
;
result
.
fontinfo
=
XLoadQueryFont
(
result
.
dsp
,
fontname
);
if
(
!
result
.
fontinfo
)
{
fprintf
(
stderr
,
"unable to load font %s: using fixed
\n
"
,
fontname
);
...
...
rita.c
View file @
91991641
...
...
@@ -48,7 +48,14 @@ struct station {
int
ns
;
};
struct
stn_set
{
struct
station
**
stns
;
int
icur
;
int
nt
;
};
static
struct
station
*
stns
;
static
struct
stn_set
stns_set
;
struct
odbinfo
{
char
*
filename
;
...
...
@@ -63,6 +70,13 @@ struct odbinfo{
static
struct
odbinfo
odbinfo
=
{
NULL
,{
'\0'
},{
'\0'
},{
'\0'
},{
'\0'
},{
'\0'
},
NULL
,
NULL
};
struct
odbinfo_set
{
struct
odbinfo
**
odb_set
;
int
icur
;
int
nt
;
};
static
struct
odbinfo_set
odbinfo_set
;
struct
Vis
{
Display
*
dsp
;
Window
win
;
...
...
Write
Preview
Supports
Markdown
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