feat(zoom): Allow users to override interface zoom. Fixes #699

This commit is contained in:
Ben Gotow 2016-01-08 11:30:58 -08:00
parent e5efa80216
commit 7e24a13466
3 changed files with 14 additions and 0 deletions

View file

@ -154,6 +154,11 @@ class WorkspaceSection extends React.Component
keyPath="core.workspace.showUnreadForAllCategories"
config={@props.config} />
<ConfigSchemaItem
configSchema={@props.configSchema.properties.workspace.properties.interfaceZoom}
keyPath="core.workspace.interfaceZoom"
config={@props.config} />
<ThemeSelector />
<h2>Layout</h2>

View file

@ -22,6 +22,12 @@ module.exports =
type: 'boolean'
default: false
title: "Show unread counts for all folders / labels"
interfaceZoom:
title: "Override standard interface scaling"
type: 'number'
default: 1
enum: [0.6, 0.8, 1, 1.2, 1.4]
enumLabels: ['60%', '80%', '100%', '120%', '140%']
disabledPackages:
type: 'array'
default: []

View file

@ -44,6 +44,9 @@ class WorkspaceStore extends NylasStore
@popToRootSheet()
@trigger()
NylasEnv.config.observe 'core.workspace.interfaceZoom', (zoom) =>
require('electron').webFrame.setZoomFactor(zoom)
NylasEnv.commands.add 'body', @_navigationCommands()
_navigationCommands: ->