 
   initialize: ->
     @lineOverdraw = atom.config.get('minimap.lineOverdraw')
+
     atom.config.observe 'minimap.lineOverdraw', =>
       @lineOverdraw = atom.config.get('minimap.lineOverdraw')
 
-    @lines.css 'line-height', atom.config.get('editor.lineHeight') + 'em'
     atom.config.observe 'editor.lineHeight', =>
-      @lines.css 'line-height', atom.config.get('editor.lineHeight') + 'em'
+      if @editorView?
+        @lines.css lineHeight: "#{@getLineHeight()}px"
+
+    atom.config.observe 'editor.fontSize', =>
+      if @editorView?
+        @lines.css fontSize: "#{@getFontSize()}px"
 
   destroy: ->
     @unsubscribe()


  getMinimapHeight: -> @getLinesCount() * @getLineHeight()
  getLineHeight: -> @lineHeight ||= parseInt @editorView.find('.lines').css('line-height')
  getLinesCount: -> @editorView.getEditor().getScreenLineCount()

  getMinimapScreenHeight: -> @minimapView.height() / @minimapView.scaleY

  setEditorView: (@editorView) ->
    @editor = @editorView.getModel()
    @buffer = @editorView.getEditor().buffer

    @lines.css
      lineHeight: "#{@getLineHeight()}px"
      fontSize: "#{@getFontSize()}px"

    @subscribe @editor, 'screen-lines-changed.minimap', (changes) =>
      @pendingChanges.push changes
