Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
K
kicad-source-mirror
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Commits
Open sidebar
Elphel
kicad-source-mirror
Commits
81c67438
Commit
81c67438
authored
Jun 24, 2013
by
Maciej Suminski
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Added convertsion from wxColour to COLOR4D.
parent
08c54e8a
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
20 additions
and
0 deletions
+20
-0
color4d.cpp
common/gal/color4d.cpp
+11
-0
color4d.h
include/gal/color4d.h
+9
-0
No files found.
common/gal/color4d.cpp
View file @
81c67438
...
@@ -37,6 +37,17 @@ COLOR4D::COLOR4D( EDA_COLOR_T aColor )
...
@@ -37,6 +37,17 @@ COLOR4D::COLOR4D( EDA_COLOR_T aColor )
}
}
#ifdef WX_COMPATIBILITY
COLOR4D
::
COLOR4D
(
const
wxColour
&
aColor
)
{
r
=
aColor
.
Red
();
g
=
aColor
.
Green
();
b
=
aColor
.
Blue
();
a
=
aColor
.
Alpha
();
}
#endif
const
bool
COLOR4D
::
operator
==
(
const
COLOR4D
&
aColor
)
const
bool
COLOR4D
::
operator
==
(
const
COLOR4D
&
aColor
)
{
{
return
a
==
aColor
.
a
&&
r
==
aColor
.
r
&&
g
==
aColor
.
g
&&
b
==
aColor
.
b
;
return
a
==
aColor
.
a
&&
r
==
aColor
.
r
&&
g
==
aColor
.
g
&&
b
==
aColor
.
b
;
...
...
include/gal/color4d.h
View file @
81c67438
...
@@ -65,6 +65,15 @@ public:
...
@@ -65,6 +65,15 @@ public:
*/
*/
COLOR4D
(
EDA_COLOR_T
aColor
);
COLOR4D
(
EDA_COLOR_T
aColor
);
#ifdef WX_COMPATIBILITY
/**
* @brief Constructor
*
* @param aColor is the color type used by wxWidgets.
*/
COLOR4D
(
const
wxColour
&
aColor
);
#endif
/* WX_COMPATIBLITY */
/**
/**
* Function Highlight
* Function Highlight
* Makes the color brighter by a given factor.
* Makes the color brighter by a given factor.
...
...
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