mirror of
https://github.com/kovidgoyal/calibre.git
synced 2025-07-09 03:04:10 -04:00
...
This commit is contained in:
parent
15c0e287da
commit
7b3bcbcbfa
@ -23,18 +23,18 @@ class TopBar:
|
|||||||
for bid in self.dummy_bar_id, self.bar_id:
|
for bid in self.dummy_bar_id, self.bar_id:
|
||||||
bar = E.div(
|
bar = E.div(
|
||||||
id=bid, class_='top-bar',
|
id=bid, class_='top-bar',
|
||||||
E.div(style="display:table-cell;"),
|
E.div(style="display:table-cell; padding-left: 0.5em"),
|
||||||
E.div(style="display:table-cell; text-align:right; padding-right: " + self.SPACING)
|
E.div(style="display:table-cell; text-align:right; padding-right: 0.5em")
|
||||||
)
|
)
|
||||||
if bid == self.bar_id:
|
if bid == self.bar_id:
|
||||||
set_css(bar, position='fixed', left='0', top='0')
|
set_css(bar, position='fixed', left='0', top='0')
|
||||||
bar.appendChild(E.style(style, type='text/css'))
|
bar.appendChild(E.style(style, type='text/css'))
|
||||||
set_css(bar,
|
set_css(bar,
|
||||||
width='100%', display='table', font_size=get_font_size('title'),
|
width='100%', display='table', font_size=get_font_size('title'),
|
||||||
padding_top='0.5ex', padding_bottom='0.5ex', user_select='none',
|
padding_top='0.5ex', padding_bottom='0.5ex', user_select='none',
|
||||||
color=get_color('bar-foreground'), background_color=get_color('bar-background'))
|
color=get_color('bar-foreground'), background_color=get_color('bar-background')
|
||||||
|
)
|
||||||
document.body.appendChild(bar)
|
document.body.appendChild(bar)
|
||||||
set_css(bar.firstChild, padding_left='0.5em')
|
|
||||||
|
|
||||||
@property
|
@property
|
||||||
def bar(self):
|
def bar(self):
|
||||||
|
Loading…
x
Reference in New Issue
Block a user