Skip to content

Commit

Permalink
change main icon from png to svg format
Browse files Browse the repository at this point in the history
  • Loading branch information
doug-101 committed Apr 8, 2018
1 parent d51a7a1 commit 111cd04
Show file tree
Hide file tree
Showing 6 changed files with 246 additions and 11 deletions.
Binary file modified icons/calc_lg.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified icons/calc_sm.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified icons/rpcalc-icon.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
235 changes: 235 additions & 0 deletions icons/rpcalc-icon.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
18 changes: 9 additions & 9 deletions install.py
Original file line number Diff line number Diff line change
Expand Up @@ -258,15 +258,15 @@ def main():
'iconPath = None',
'iconPath = \'{0}\' # modified by install script\n'
.format(iconPrefixDir))
if os.path.isfile(os.path.join('icons', progName + '-icon.png')):
pngIconPrefixDir = os.path.join(prefixDir, 'share', 'icons',
'hicolor', '32x32', 'apps')
pngIconBuildDir = os.path.join(buildRoot, pngIconPrefixDir[1:])
print(' Copying app icon files to {0}'.format(pngIconBuildDir))
if not os.path.isdir(pngIconBuildDir):
os.makedirs(pngIconBuildDir)
shutil.copy2(os.path.join('icons', progName + '-icon.png'),
pngIconBuildDir)
if os.path.isfile(os.path.join('icons', progName + '-icon.svg')):
svgIconPrefixDir = os.path.join(prefixDir, 'share', 'icons',
'hicolor', 'scalable', 'apps')
svgIconBuildDir = os.path.join(buildRoot, svgIconPrefixDir[1:])
print(' Copying app icon files to {0}'.format(svgIconBuildDir))
if not os.path.isdir(svgIconBuildDir):
os.makedirs(svgIconBuildDir)
shutil.copy2(os.path.join('icons', progName + '-icon.svg'),
svgIconBuildDir)
if os.path.isfile(progName + '.desktop'):
desktopPrefixDir = os.path.join(prefixDir, 'share', 'applications')
desktopBuildDir = os.path.join(buildRoot, desktopPrefixDir[1:])
Expand Down
4 changes: 2 additions & 2 deletions uninstall.py
Original file line number Diff line number Diff line change
Expand Up @@ -74,8 +74,8 @@ def main():
removeAll(os.path.join(prefixDir, 'share', 'doc', progName))
removeAll(os.path.join(prefixDir, 'share', progName))
removeAll(os.path.join(prefixDir, 'share', 'icons', progName))
removeAll(os.path.join(prefixDir, 'share', 'icons', 'hicolor', '32x32',
'apps', progName + '-icon.png'))
removeAll(os.path.join(prefixDir, 'share', 'icons', 'hicolor', 'scalable',
'apps', progName + '-icon.svg'))
removeAll(os.path.join(prefixDir, 'share', 'applications',
progName + '.desktop'))
removeAll(os.path.join(prefixDir, 'bin', progName))
Expand Down

0 comments on commit 111cd04

Please sign in to comment.