         (assoc-in [:cursor :x] 0)
         (update-in [:cursor :y] inc))))
 
-(defn move-cursor-down [{height :height {y :y} :cursor :as vt}]
+(defn move-cursor-down [{:keys [height] {y :y} :cursor :as vt}]
   (if (= height (inc y))
     (scroll-up vt)
     (update-in vt [:cursor :y] inc)))

(defn execute-ht [vt]
  (move-cursor-to-next-tab vt 1))

(defn execute-lf [{height :height {y :y} :cursor :as vt}]
  (if (= height (inc y))
    (-> vt
        scroll-up

  (vec (concat (take x line)
               (repeat (- (count line) x) (empty-cell char-attrs)))))

(defn clear-to-end-of-screen [{{:keys [x y]} :cursor :keys [width height char-attrs] :as vt}]
  (update-in vt [:lines] (fn [lines]
                           (let [top-lines (take y lines)
                                 curr-line (clear-line-right (nth lines y) x char-attrs)
