emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

How to create a small child-frame which only show two lines


From: tumashu
Subject: How to create a small child-frame which only show two lines
Date: Thu, 7 Dec 2017 08:04:12 +0800 (CST)

Hello,
      Emacs26's child-frame feature is very useful. I have created a candadite menu of
chinese input method with its help, and find that it is much fast than popup-el's menu
and comparable with minibuffer.

the only problem I faced it that:  I only need show 2 lines with child-frame while its mini
size is show 4 lines,  anyone suggest how to deal with this problem?

---------------
(setq my-child-frame
      (let ((after-make-frame-functions nil))
        (make-frame
         `((parent-frame . ,(window-frame))
           (no-accept-focus . t)
           (min-width  . t)
           (min-height . t)
           (border-width . 0)
           (internal-border-width . 0)
           (vertical-scroll-bars . nil)
           (horizontal-scroll-bars . nil)
           (left-fringe . 10)
           (right-fringe . 0)
           (menu-bar-lines . 0)
           (tool-bar-lines . 0)
           (line-spacing . 0)
           (unsplittable . t)
           (no-other-frame . t)
           ;;(undecorated . t)
           (undecorated . nil)
           (visibility . t)
           (cursor-type . nil)
           (minibuffer . nil)
           (width . 50)
           (height . 1)
           (no-special-glyphs . t)))))

(let ((window (frame-root-window my-child-frame)))
  (set-window-parameter window 'mode-line-format 'none)
  (set-window-parameter window 'header-line-format 'none))
--------------

Attachment: child-frame-usage.png
Description: PNG image


reply via email to

[Prev in Thread] Current Thread [Next in Thread]