[prev in list] [next in list] [prev in thread] [next in thread]
List: lilypond-user
Subject: Re: Black borders with table using \markuplist and please center
From: Pierre Perol-Schneider <pierre.schneider.paris () gmail ! com>
Date: 2021-02-21 20:43:08
Message-ID: CAPHOTuWFUUcHehqqM5i1AEOkddyoqqWry7MccP0Rdb70wLc=4A () mail ! gmail ! com
[Download RAW message or body]
Hi Adam,
Here's my attempt:
\version "2.22.0"
cell = \markup
\override #'(line-join-style . miter)
\override #'(line-cap-style . square)
\path #.3 #'((moveto -1.5 -1.5)(lineto -1.5 3)(lineto 3 3)(lineto 3 -1.5))
\markup \fill-line {
\column
\override #'(baseline-skip . -.3)
\override #'(padding . -.3)
\table #'(0 0 0)
{
%\underline { right-aligned center-aligned left-aligned }
{ \combine\cell "1" }{ \combine\cell "3" }{ \combine\cell "3" }
{ \combine\cell "4" }{ \combine\cell "" }{ \combine\cell "6" }
{ \combine\cell "7" }{ \combine\cell "8" }{ \combine\cell "6" }
{ \combine\cell "10" }{ \combine\cell "" }{ \combine\cell "12" }
\with-dimensions-from\null
\override #'(line-cap-style . square)
\path #.3 #'((moveto -2.25 1.3)(lineto 11.25 1.3))
}
}
Cheers,
Pierre
Le dim. 21 févr. 2021 à 21:03, Adam Good <goodadamgood@gmail.com> a écrit :
> Harm thank you very much! I feel centered.
>
> If anyone could come up with a solution for borders it would be a nice
> option.
>
> best,
> Adam
>
> On Sun, Feb 21, 2021 at 11:57 AM Thomas Morley <thomasmorley65@gmail.com>
> wrote:
>
>> Am So., 21. Feb. 2021 um 17:24 Uhr schrieb Adam Good <
>> goodadamgood@gmail.com>:
>> >
>> > Hi Everyone,
>> > I can make this pretty little table, see below but could someone please
>> help me add borders / gridlines around the cells? And, I'd like to be able
>> to center the table to the middle of the page.
>> >
>> > Thank you in advance!
>> > Adam
>> >
>> > %%%
>> > \markuplist {
>> > \override #'(padding . 4)
>> > \table #'(0 0 0)
>> > {
>> > %\underline { right-aligned center-aligned left-aligned }
>> > "1" "2" "3"
>> > "4" "" "6"
>> > "7" "8" ""
>> > "10" "" "12"
>> > }
>> > }
>>
>> Borders / gridlines are not yet coded for \table, maybe I should have
>> done so, at least as an option.
>> Currently I've no time to delve into it maybe someone else can step in.
>>
>> If you don't mind loosing the page breaking option, centering is as
>> simple as:
>>
>> \markup \fill-line {
>> \column
>> \override #'(padding . 4)
>> \table #'(0 0 0)
>> {
>> %\underline { right-aligned center-aligned left-aligned }
>> "1" "2" "3"
>> "4" "" "6"
>> "7" "8" ""
>> "10" "" "12"
>> }
>> }
>>
>> Cheers,
>> Harm
>>
>
[Attachment #3 (text/html)]
<div dir="ltr"><div>Hi Adam,</div><div>Here's my \
attempt:</div><div><br></div><div>\version "2.22.0"<br><br>cell = \
\markup<br> \override #'(line-join-style . miter)<br> \override \
#'(line-cap-style . square)<br> \path #.3 #'((moveto -1.5 -1.5)(lineto -1.5 \
3)(lineto 3 3)(lineto 3 -1.5))<br><br><br>\markup \fill-line {<br> \column<br> \
\override #'(baseline-skip . -.3)<br> \override #'(padding . -.3)<br> \
\table #'(0 0 0)<br> {<br> %\underline { right-aligned \
center-aligned left-aligned }<br> { \combine\cell "1" }{ \
\combine\cell "3" }{ \combine\cell "3" }<br> { \
\combine\cell "4" }{ \combine\cell "" }{ \combine\cell \
"6" }<br> { \combine\cell "7" }{ \combine\cell \
"8" }{ \combine\cell "6" }<br> { \combine\cell \
"10" }{ \combine\cell "" }{ \combine\cell "12" }<br> \
\with-dimensions-from\null<br> \override #'(line-cap-style . square)<br> \
\path #.3 #'((moveto -2.25 1.3)(lineto 11.25 1.3))<br> \
}<br>}</div><div><br></div><div>Cheers,</div><div>Pierre<br></div></div><br><div \
class="gmail_quote"><div dir="ltr" class="gmail_attr">Le dim. 21 févr. 2021 à \
21:03, Adam Good <<a \
href="mailto:goodadamgood@gmail.com">goodadamgood@gmail.com</a>> a écrit \
:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px \
0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr">Harm \
thank you very much! I feel centered.<div><br></div><div>If anyone could come up \
with a solution for borders it would be a nice \
option.</div><div><br></div><div>best,</div><div>Adam</div></div><br><div \
class="gmail_quote"><div dir="ltr" class="gmail_attr">On Sun, Feb 21, 2021 at 11:57 \
AM Thomas Morley <<a href="mailto:thomasmorley65@gmail.com" \
target="_blank">thomasmorley65@gmail.com</a>> wrote:<br></div><blockquote \
class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid \
rgb(204,204,204);padding-left:1ex">Am So., 21. Feb. 2021 um 17:24 Uhr schrieb Adam \
Good <<a href="mailto:goodadamgood@gmail.com" \
target="_blank">goodadamgood@gmail.com</a>>:<br> ><br>
> Hi Everyone,<br>
> I can make this pretty little table, see below but could someone please help me \
add borders / gridlines around the cells? And, I'd like to be able to center the \
table to the middle of the page.<br> ><br>
> Thank you in advance!<br>
> Adam<br>
><br>
> %%%<br>
> \markuplist {<br>
> \override #'(padding . 4)<br>
> \table #'(0 0 0)<br>
> {<br>
> %\underline { right-aligned center-aligned left-aligned }<br>
> "1" "2" "3"<br>
> "4" "" "6"<br>
> "7" "8" ""<br>
> "10" "" "12"<br>
> }<br>
> }<br>
<br>
Borders / gridlines are not yet coded for \table, maybe I should have<br>
done so, at least as an option.<br>
Currently I've no time to delve into it maybe someone else can step in.<br>
<br>
If you don't mind loosing the page breaking option, centering is as simple \
as:<br> <br>
\markup \fill-line {<br>
\column<br>
\override #'(padding . 4)<br>
\table #'(0 0 0)<br>
{<br>
%\underline { right-aligned center-aligned left-aligned }<br>
"1" "2" "3"<br>
"4" "" "6"<br>
"7" "8" ""<br>
"10" "" "12"<br>
}<br>
}<br>
<br>
Cheers,<br>
Harm<br>
</blockquote></div>
</blockquote></div>
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic