mirror of
https://github.com/gryf/wmdocklib.git
synced 2025-12-19 20:38:03 +01:00
1575762: initialization of pixmask
made some mess about borders: the whole tile is now used up by the application. colour 0 seems to be reserved for transparency.
This commit is contained in:
@@ -537,8 +537,8 @@ background = \
|
|||||||
]
|
]
|
||||||
|
|
||||||
char_width, char_height = wmdocklib.initPixmap(background,
|
char_width, char_height = wmdocklib.initPixmap(background,
|
||||||
font_name='6x8',
|
font_name='5x7',
|
||||||
bg='7', fg='a')
|
bg='8', fg='a')
|
||||||
|
|
||||||
if __name__ == '__main__':
|
if __name__ == '__main__':
|
||||||
main()
|
main()
|
||||||
|
|||||||
@@ -180,10 +180,10 @@ def initPixmap(xpm_background=None,
|
|||||||
"""
|
"""
|
||||||
|
|
||||||
if xpm_background is None:
|
if xpm_background is None:
|
||||||
xpm_background = [bg*width]*height
|
xpm_background = ['0'*width]*2 + ['00'+bg*(width-4)+'00']*(height-4) + ['0'*width]*2
|
||||||
if palette is None:
|
if palette is None:
|
||||||
palette = {
|
palette = {
|
||||||
0: ('#000000','black'),
|
0: ('#000000','transparent'),
|
||||||
1: ('#000080','blue'),
|
1: ('#000080','blue'),
|
||||||
2: ('#008080','cyan'),
|
2: ('#008080','cyan'),
|
||||||
3: ('#008000','green'),
|
3: ('#008000','green'),
|
||||||
@@ -191,7 +191,7 @@ def initPixmap(xpm_background=None,
|
|||||||
5: ('#800000','red'),
|
5: ('#800000','red'),
|
||||||
6: ('#800080','purple'),
|
6: ('#800080','purple'),
|
||||||
7: ('#c0c0c0','light_gray'),
|
7: ('#c0c0c0','light_gray'),
|
||||||
8: ('#808080','dark_gray'),
|
8: ('#010101','black'),
|
||||||
9: ('#0000ff','light_blue'),
|
9: ('#0000ff','light_blue'),
|
||||||
10: ('#00ffff','light_cyan'),
|
10: ('#00ffff','light_cyan'),
|
||||||
11: ('#00ff00','light_green'),
|
11: ('#00ff00','light_green'),
|
||||||
@@ -464,11 +464,3 @@ char_defs = {
|
|||||||
},
|
},
|
||||||
}
|
}
|
||||||
|
|
||||||
default_xpm_header = [
|
|
||||||
'128 112 4 1',
|
|
||||||
'_\tc #7f260a',
|
|
||||||
' \tc #000000 s background',
|
|
||||||
'/\tc #2020b2 s graph',
|
|
||||||
'%\tc #2081B2 s text',
|
|
||||||
]
|
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user