mirror of
https://github.com/rabbibotton/clog.git
synced 2025-12-06 02:30:42 -08:00
add style and class to envelope
This commit is contained in:
parent
8e955ce586
commit
f66c9e34e1
1 changed files with 7 additions and 4 deletions
|
|
@ -148,7 +148,8 @@ nil. Resizable only works if overflow is set to :SCROLL"))
|
||||||
;; envelope-panel ;;
|
;; envelope-panel ;;
|
||||||
;;;;;;;;;;;;;;;;;;;;
|
;;;;;;;;;;;;;;;;;;;;
|
||||||
|
|
||||||
(defgeneric envelope-panel (clog-element panel width height &key units)
|
(defgeneric envelope-panel (clog-element panel width height
|
||||||
|
&key class style units)
|
||||||
(:documentation "Create a panel of WIDTH and HEIGHT with :relative
|
(:documentation "Create a panel of WIDTH and HEIGHT with :relative
|
||||||
positioning to envelope PANEL. This allows any type of clog-panel (including
|
positioning to envelope PANEL. This allows any type of clog-panel (including
|
||||||
those created by CLOG Builder, to be positioned within DISPLAY :flex or
|
those created by CLOG Builder, to be positioned within DISPLAY :flex or
|
||||||
|
|
@ -156,9 +157,11 @@ those created by CLOG Builder, to be positioned within DISPLAY :flex or
|
||||||
Returns envelope-panel"))
|
Returns envelope-panel"))
|
||||||
|
|
||||||
(defmethod envelope-panel ((obj clog-element) (panel clog-element)
|
(defmethod envelope-panel ((obj clog-element) (panel clog-element)
|
||||||
width height &key (units :px))
|
width height
|
||||||
(let ((e (create-div obj :style (format nil "position:relative;width:~A~A;height:~A~A"
|
&key (units :px) class (style ""))
|
||||||
width units height units))))
|
(let ((e (create-div obj :class class
|
||||||
|
:style (format nil "position:relative;width:~A~A;height:~A~A;~A"
|
||||||
|
width units height units style))))
|
||||||
(place-inside-top-of e panel)
|
(place-inside-top-of e panel)
|
||||||
e))
|
e))
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue