Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
GooCalendar
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
External wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Model registry
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
Tryton
GooCalendar
Commits
ecad211c2f67
Commit
ecad211c2f67
authored
4 years ago
by
Cédric Krier
Browse files
Options
Downloads
Patches
Plain Diff
Remove lighter background on event
bug34
parent
1b28087d575a
No related branches found
No related tags found
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
CHANGELOG
+2
-0
2 additions, 0 deletions
CHANGELOG
goocalendar/_calendar.py
+2
-15
2 additions, 15 deletions
goocalendar/_calendar.py
with
4 additions
and
15 deletions
CHANGELOG
+
2
−
0
View file @
ecad211c
* Remove lighter background on event
Version 0.7.1 - 2020-04-18
* Bug fixes (see mercurial logs for details)
...
...
This diff is collapsed.
Click to expand it.
goocalendar/_calendar.py
+
2
−
15
View file @
ecad211c
...
...
@@ -3,7 +3,6 @@
import
datetime
import
calendar
import
math
from
operator
import
add
from
gi.repository
import
Gdk
,
GObject
,
GooCanvas
,
Gtk
,
Pango
...
...
@@ -1198,14 +1197,7 @@
self
.
box
.
set_property
(
'
width
'
,
self
.
width
)
self
.
box
.
set_property
(
'
height
'
,
self
.
height
)
self
.
box
.
set_property
(
'
stroke_color
'
,
the_event_bg_color
)
bg_rgba_color
=
self
.
box
.
get_property
(
'
stroke_color_rgba
'
)
bg_colors
=
list
(
util
.
rgba_to_colors
(
bg_rgba_color
))
# We make background color 1/4 brighter (+64 over 255)
bg_colors
[:
3
]
=
list
(
map
(
min
,
list
(
map
(
add
,
bg_colors
[:
3
],
(
64
,)
*
3
)),
(
255
,)
*
3
))
bg_colors
=
util
.
colors_to_rgba
(
*
bg_colors
)
self
.
box
.
set_property
(
'
fill_color_rgba
'
,
bg_colors
)
self
.
box
.
set_property
(
'
fill_color
'
,
the_event_bg_color
)
# Alpha color is set to half of 255, i.e an opacity of 5O percents
transparent_color
=
self
.
box
.
get_property
(
'
fill_color_rgba
'
)
-
128
if
self
.
transparent
:
...
...
@@ -1271,12 +1263,7 @@
self
.
box
.
set_property
(
'
width
'
,
self
.
width
)
self
.
box
.
set_property
(
'
height
'
,
self
.
height
)
self
.
box
.
set_property
(
'
stroke_color
'
,
the_event_bg_color
)
bg_rgba_color
=
self
.
box
.
get_property
(
'
stroke_color_rgba
'
)
bg_colors
=
list
(
util
.
rgba_to_colors
(
bg_rgba_color
))
bg_colors
[:
3
]
=
list
(
map
(
min
,
list
(
map
(
add
,
bg_colors
[:
3
],
(
64
,)
*
3
)),
(
255
,)
*
3
))
bg_colors
=
util
.
colors_to_rgba
(
*
bg_colors
)
self
.
box
.
set_property
(
'
fill_color_rgba
'
,
bg_colors
)
self
.
box
.
set_property
(
'
fill_color
'
,
the_event_bg_color
)
transparent_color
=
self
.
box
.
get_property
(
'
fill_color_rgba
'
)
-
128
if
self
.
transparent
:
self
.
box
.
set_property
(
'
stroke_color_rgba
'
,
transparent_color
)
...
...
This diff is collapsed.
Click to expand it.
Roundup Robot
@roundup-bot
mentioned in issue
#34 (closed)
·
2 years ago
mentioned in issue
#34 (closed)
mentioned in issue #34
Toggle commit list
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