Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
gmsh
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
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
Larry Price
gmsh
Commits
37e05213
Commit
37e05213
authored
10 years ago
by
Christophe Geuzaine
Browse files
Options
Downloads
Patches
Plain Diff
experiment with dark scheme
parent
f76e2f79
Branches
Branches containing commit
Tags
Tags containing commit
No related merge requests found
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
Fltk/FlGui.cpp
+15
-6
15 additions, 6 deletions
Fltk/FlGui.cpp
Fltk/inputRange.h
+5
-1
5 additions, 1 deletion
Fltk/inputRange.h
Fltk/outputRange.h
+5
-1
5 additions, 1 deletion
Fltk/outputRange.h
with
25 additions
and
8 deletions
Fltk/FlGui.cpp
+
15
−
6
View file @
37e05213
...
...
@@ -253,11 +253,16 @@ FlGui::FlGui(int argc, char **argv)
if
(
CTX
::
instance
()
->
display
.
size
())
Fl
::
display
(
CTX
::
instance
()
->
display
.
c_str
());
#if 0 // dark scheme... not bad, but needs work
Fl::background(110, 110, 110);
Fl::background2(140, 140, 140);
Fl::foreground(230, 230, 230);
//Fl::set_color(FL_SELECTION_COLOR, 50, 50, 0);
//#define DARK_SCHEME
#if defined(DARK_SCHEME)
Fl
::
background
(
50
,
50
,
50
);
Fl
::
background2
(
145
,
145
,
145
);
Fl
::
foreground
(
250
,
250
,
250
);
for
(
int
i
=
0
;
i
<
FL_NUM_GRAY
;
i
++
)
{
double
min
=
0.
,
max
=
165.
;
int
d
=
(
int
)(
min
+
i
*
(
max
-
min
)
/
(
FL_NUM_GRAY
-
1.
));
Fl
::
set_color
(
fl_gray_ramp
(
i
),
d
,
d
,
d
);
}
#endif
// add new box types (dx dy dw dh)
...
...
@@ -283,7 +288,7 @@ FlGui::FlGui(int argc, char **argv)
Fl
::
scheme
(
CTX
::
instance
()
->
guiTheme
.
c_str
());
Fl_Tooltip
::
size
(
FL_NORMAL_SIZE
);
Fl_Tooltip
::
delay
(
0.5
);
#if defined(__APPLE__)
#if defined(__APPLE__)
&& !defined(DARK_SCHEME)
Fl_Tooltip
::
color
(
FL_LIGHT2
);
#endif
...
...
@@ -349,6 +354,10 @@ FlGui::FlGui(int argc, char **argv)
graph
[
0
]
->
getWindow
()
->
show
(
argc
>
0
?
1
:
0
,
argv
);
if
(
graph
[
0
]
->
getMenuWindow
())
graph
[
0
]
->
getMenuWindow
()
->
show
();
#if defined(DARK_SCHEME)
Fl
::
set_color
(
FL_SELECTION_COLOR
,
200
,
200
,
200
);
#endif
// graphic window should have the initial focus (so we can e.g. directly loop
// through time steps with the keyboard)
Fl
::
focus
(
graph
[
0
]
->
gl
[
0
]);
...
...
This diff is collapsed.
Click to expand it.
Fltk/inputRange.h
+
5
−
1
View file @
37e05213
...
...
@@ -329,7 +329,11 @@ class inputRange : public Fl_Group {
std
::
string
loop
(){
return
_loop_val
;
}
void
graph
(
const
std
::
string
&
val
){
_set_graph_value
(
val
);
}
std
::
string
graph
(){
return
_graph_val
;
}
void
color
(
int
col
){
_input
->
color
(
col
);
}
void
color
(
int
col
)
{
_input
->
color
(
col
);
_input
->
textcolor
(
fl_contrast
(
FL_FOREGROUND_COLOR
,
col
));
}
int
color
(){
return
_input
->
color
();
}
Fl_Value_Input
*
input
(){
return
_input
;
}
};
...
...
This diff is collapsed.
Click to expand it.
Fltk/outputRange.h
+
5
−
1
View file @
37e05213
...
...
@@ -142,7 +142,11 @@ class outputRange : public Fl_Group {
}
void
graph
(
const
std
::
string
&
val
){
_set_graph_value
(
val
);
}
std
::
string
graph
(){
return
_graph_val
;
}
void
color
(
int
col
){
_output
->
color
(
col
);
}
void
color
(
int
col
)
{
_output
->
color
(
col
);
_output
->
textcolor
(
fl_contrast
(
FL_FOREGROUND_COLOR
,
col
));
}
};
#endif
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
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