-
-
Notifications
You must be signed in to change notification settings - Fork 2.3k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
The old log was only available as a raster image at 512x512. This is insufficient for the splash screen on high DPI monitors. So create a new SVG logo (similar in look to the old one, but simplified).
- Loading branch information
1 parent
db2fdbc
commit 6211846
Showing
15 changed files
with
796 additions
and
11 deletions.
There are no files selected for viewing
Binary file not shown.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file not shown.
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
#!/usr/bin/env python2 | ||
# vim:fileencoding=utf-8 | ||
from __future__ import (unicode_literals, division, absolute_import, | ||
print_function) | ||
|
||
__license__ = 'GPL v3' | ||
__copyright__ = '2014, Kovid Goyal <kovid at kovidgoyal.net>' | ||
|
||
import os, shutil, subprocess | ||
|
||
d, j, a = (getattr(os.path, x) for x in ('dirname', 'join', 'abspath')) | ||
base = d(a(__file__)) | ||
os.chdir(base) | ||
|
||
imgsrc = j(d(base), 'imgsrc') | ||
sources = {'library':j(imgsrc, 'calibre.svg'), 'ebook-edit':j(imgsrc, 'tweak.svg'), 'viewer':j(imgsrc, 'viewer.svg'), 'favicon':j(imgsrc, 'calibre.svg')} | ||
|
||
for name, src in sources.iteritems(): | ||
os.mkdir('ico_temp') | ||
try: | ||
names = [] | ||
for sz in (16, 32, 48, 256): | ||
iname = os.path.join('ico_temp', '{0}x{0}.png'.format(sz)) | ||
subprocess.check_call(['rsvg-convert', src, '-w', str(sz), '-h', str(sz), '-o', iname]) | ||
subprocess.check_call(['optipng', '-o7', '-strip', 'all', iname]) | ||
names.append(iname) | ||
names[-1:-1] = ['-r'] | ||
subprocess.check_call(['icotool', '-c', '--output=' + name+'.ico'] + names) | ||
finally: | ||
shutil.rmtree('ico_temp') |
Binary file not shown.
Oops, something went wrong.