Skip to content

Commit 6211846

Browse files
committed
A new high resolution calibre logo
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).
1 parent db2fdbc commit 6211846

15 files changed

Lines changed: 796 additions & 11 deletions

File tree

icons/book.icns

88 Bytes
Binary file not shown.

icons/calibre.png

-311 KB
Loading

icons/ebook-edit.ico

-6.42 KB
Binary file not shown.

icons/favicon.ico

-128 KB
Binary file not shown.

icons/icns/make_iconsets.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313
os.chdir(base)
1414

1515
imgsrc = j(d(d(base)), 'imgsrc')
16-
sources = {'calibre':j(d(base), 'calibre.png'), 'ebook-edit':j(imgsrc, 'tweak.svg'), 'ebook-viewer':j(imgsrc, 'viewer.svg'), 'book':j(imgsrc, 'book.svg')}
16+
sources = {'calibre':j(imgsrc, 'calibre.svg'), 'ebook-edit':j(imgsrc, 'tweak.svg'), 'ebook-viewer':j(imgsrc, 'viewer.svg'), 'book':j(imgsrc, 'book.svg')}
1717

1818
for name, src in sources.iteritems():
1919
iconset = name + '.iconset'
@@ -39,7 +39,7 @@
3939
os.remove(iname)
4040
for name in (iname, iname2x):
4141
if os.path.exists(name):
42-
subprocess.check_call(['optipng', '-o7', name])
42+
subprocess.check_call(['optipng', '-o7', '-strip', 'all', name])
4343
finally:
4444
os.chdir('..')
4545

icons/library.ico

-131 KB
Binary file not shown.

icons/make_ico_files.py

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
#!/usr/bin/env python2
2+
# vim:fileencoding=utf-8
3+
from __future__ import (unicode_literals, division, absolute_import,
4+
print_function)
5+
6+
__license__ = 'GPL v3'
7+
__copyright__ = '2014, Kovid Goyal <kovid at kovidgoyal.net>'
8+
9+
import os, shutil, subprocess
10+
11+
d, j, a = (getattr(os.path, x) for x in ('dirname', 'join', 'abspath'))
12+
base = d(a(__file__))
13+
os.chdir(base)
14+
15+
imgsrc = j(d(base), 'imgsrc')
16+
sources = {'library':j(imgsrc, 'calibre.svg'), 'ebook-edit':j(imgsrc, 'tweak.svg'), 'viewer':j(imgsrc, 'viewer.svg'), 'favicon':j(imgsrc, 'calibre.svg')}
17+
18+
for name, src in sources.iteritems():
19+
os.mkdir('ico_temp')
20+
try:
21+
names = []
22+
for sz in (16, 32, 48, 256):
23+
iname = os.path.join('ico_temp', '{0}x{0}.png'.format(sz))
24+
subprocess.check_call(['rsvg-convert', src, '-w', str(sz), '-h', str(sz), '-o', iname])
25+
subprocess.check_call(['optipng', '-o7', '-strip', 'all', iname])
26+
names.append(iname)
27+
names[-1:-1] = ['-r']
28+
subprocess.check_call(['icotool', '-c', '--output=' + name+'.ico'] + names)
29+
finally:
30+
shutil.rmtree('ico_temp')

icons/viewer.ico

-13 KB
Binary file not shown.

0 commit comments

Comments
 (0)