Enumitem: Right align the label
Clash Royale CLAN TAG#URR8PPP
up vote
1
down vote
favorite
I am trying to use the enumitem
package to create the following
Farmer: It is a hard day today. The sun is
burning and we still haven't brought
in all the crop.
Farmer's Neighbour: Yes, it will be a long day!
Farmer: ...
I want the label to be right aligned and the text to wrap at that point too.
I tried the following solution (SetLabelAlignparrightparbox[t]labelwidthraggedleft#1
, but then my label and text overlap.
documentclassarticle
usepackageenumitem
SetLabelAlignparrightparbox[t]labelwidthraggedleft#1
setlist[enumerate]
align=parright,
leftmargin=0pt,
labelindent=20pt,
listparindent=40pt,
labelwidth=20pt,
itemindent=!
begindocument
beginenumerate[label=Farmer:]
item It is a hard day today. The sun is burning and we still haven't brought in all the crop.
endenumerate
beginenumerate[label=Farmer's Neigbour:]
item Yes, it will be a long day!
endenumerate
enddocument
horizontal-alignment enumitem
add a comment |Â
up vote
1
down vote
favorite
I am trying to use the enumitem
package to create the following
Farmer: It is a hard day today. The sun is
burning and we still haven't brought
in all the crop.
Farmer's Neighbour: Yes, it will be a long day!
Farmer: ...
I want the label to be right aligned and the text to wrap at that point too.
I tried the following solution (SetLabelAlignparrightparbox[t]labelwidthraggedleft#1
, but then my label and text overlap.
documentclassarticle
usepackageenumitem
SetLabelAlignparrightparbox[t]labelwidthraggedleft#1
setlist[enumerate]
align=parright,
leftmargin=0pt,
labelindent=20pt,
listparindent=40pt,
labelwidth=20pt,
itemindent=!
begindocument
beginenumerate[label=Farmer:]
item It is a hard day today. The sun is burning and we still haven't brought in all the crop.
endenumerate
beginenumerate[label=Farmer's Neigbour:]
item Yes, it will be a long day!
endenumerate
enddocument
horizontal-alignment enumitem
2
Why are you using anenumerate
list when you want adescription
type list?
– Alan Munn
Aug 8 at 2:36
Just tryalign=left
, It should work.
– javadr
Aug 8 at 2:41
add a comment |Â
up vote
1
down vote
favorite
up vote
1
down vote
favorite
I am trying to use the enumitem
package to create the following
Farmer: It is a hard day today. The sun is
burning and we still haven't brought
in all the crop.
Farmer's Neighbour: Yes, it will be a long day!
Farmer: ...
I want the label to be right aligned and the text to wrap at that point too.
I tried the following solution (SetLabelAlignparrightparbox[t]labelwidthraggedleft#1
, but then my label and text overlap.
documentclassarticle
usepackageenumitem
SetLabelAlignparrightparbox[t]labelwidthraggedleft#1
setlist[enumerate]
align=parright,
leftmargin=0pt,
labelindent=20pt,
listparindent=40pt,
labelwidth=20pt,
itemindent=!
begindocument
beginenumerate[label=Farmer:]
item It is a hard day today. The sun is burning and we still haven't brought in all the crop.
endenumerate
beginenumerate[label=Farmer's Neigbour:]
item Yes, it will be a long day!
endenumerate
enddocument
horizontal-alignment enumitem
I am trying to use the enumitem
package to create the following
Farmer: It is a hard day today. The sun is
burning and we still haven't brought
in all the crop.
Farmer's Neighbour: Yes, it will be a long day!
Farmer: ...
I want the label to be right aligned and the text to wrap at that point too.
I tried the following solution (SetLabelAlignparrightparbox[t]labelwidthraggedleft#1
, but then my label and text overlap.
documentclassarticle
usepackageenumitem
SetLabelAlignparrightparbox[t]labelwidthraggedleft#1
setlist[enumerate]
align=parright,
leftmargin=0pt,
labelindent=20pt,
listparindent=40pt,
labelwidth=20pt,
itemindent=!
begindocument
beginenumerate[label=Farmer:]
item It is a hard day today. The sun is burning and we still haven't brought in all the crop.
endenumerate
beginenumerate[label=Farmer's Neigbour:]
item Yes, it will be a long day!
endenumerate
enddocument
horizontal-alignment enumitem
edited Aug 8 at 2:35
Alan Munn
154k26411682
154k26411682
asked Aug 8 at 2:25
Jo-
5816
5816
2
Why are you using anenumerate
list when you want adescription
type list?
– Alan Munn
Aug 8 at 2:36
Just tryalign=left
, It should work.
– javadr
Aug 8 at 2:41
add a comment |Â
2
Why are you using anenumerate
list when you want adescription
type list?
– Alan Munn
Aug 8 at 2:36
Just tryalign=left
, It should work.
– javadr
Aug 8 at 2:41
2
2
Why are you using an
enumerate
list when you want a description
type list?– Alan Munn
Aug 8 at 2:36
Why are you using an
enumerate
list when you want a description
type list?– Alan Munn
Aug 8 at 2:36
Just try
align=left
, It should work.– javadr
Aug 8 at 2:41
Just try
align=left
, It should work.– javadr
Aug 8 at 2:41
add a comment |Â
1 Answer
1
active
oldest
votes
up vote
3
down vote
accepted
For a list-by-list basis, you can use the options below between [..]
. Notice that calc package is required to measure the width of the widest label automatically. If you need the same settings for all description lists, use this command
setlist[description]style=multiline, labelwidth=widthofFarmer's Neigbour: ,%
font=normalfont, leftmargin=labelwidth, align=right
in preamble.
documentclassarticle
usepackageenumitem
usepackagecalc
begindocument
begindescription[style=multiline, labelwidth=widthofFarmer's Neigbour: ,%
font=normalfont, leftmargin=labelwidth, align=right]
item[Farmer:] It is a hard day today. The sun is burning and we still haven't brought in all the crop.
item[Farmer's Neigbour:] Yes, it will be a long day!
enddescription
enddocument
If you want to keep the regular description list, you can define a new list, e.g.newlistdialoguedescription1
and then usesetlist[dialogue]style=multiline, labelwidth=widthofFarmer's Neigbour: ,font=normalfont, leftmargin=labelwidth, align=right
– Alan Munn
Aug 8 at 3:04
Is there a way to dynamically update `widthofFarmer's Neighbour:? So the list can be reused?
– Jo-
Aug 8 at 3:05
This will require more work, in such a case, alongtable
or just atabular
may be preferred.
– AboAmmar
Aug 8 at 3:10
1
@Jo- Not completely automatic, but if you define a new list, then for any particular instance of that environment you can just specify a new value for thelabelwidth
, e.g.begindialogue[labelwidth=widthofFarmer's son: ]
.
– Alan Munn
Aug 8 at 3:17
add a comment |Â
1 Answer
1
active
oldest
votes
1 Answer
1
active
oldest
votes
active
oldest
votes
active
oldest
votes
up vote
3
down vote
accepted
For a list-by-list basis, you can use the options below between [..]
. Notice that calc package is required to measure the width of the widest label automatically. If you need the same settings for all description lists, use this command
setlist[description]style=multiline, labelwidth=widthofFarmer's Neigbour: ,%
font=normalfont, leftmargin=labelwidth, align=right
in preamble.
documentclassarticle
usepackageenumitem
usepackagecalc
begindocument
begindescription[style=multiline, labelwidth=widthofFarmer's Neigbour: ,%
font=normalfont, leftmargin=labelwidth, align=right]
item[Farmer:] It is a hard day today. The sun is burning and we still haven't brought in all the crop.
item[Farmer's Neigbour:] Yes, it will be a long day!
enddescription
enddocument
If you want to keep the regular description list, you can define a new list, e.g.newlistdialoguedescription1
and then usesetlist[dialogue]style=multiline, labelwidth=widthofFarmer's Neigbour: ,font=normalfont, leftmargin=labelwidth, align=right
– Alan Munn
Aug 8 at 3:04
Is there a way to dynamically update `widthofFarmer's Neighbour:? So the list can be reused?
– Jo-
Aug 8 at 3:05
This will require more work, in such a case, alongtable
or just atabular
may be preferred.
– AboAmmar
Aug 8 at 3:10
1
@Jo- Not completely automatic, but if you define a new list, then for any particular instance of that environment you can just specify a new value for thelabelwidth
, e.g.begindialogue[labelwidth=widthofFarmer's son: ]
.
– Alan Munn
Aug 8 at 3:17
add a comment |Â
up vote
3
down vote
accepted
For a list-by-list basis, you can use the options below between [..]
. Notice that calc package is required to measure the width of the widest label automatically. If you need the same settings for all description lists, use this command
setlist[description]style=multiline, labelwidth=widthofFarmer's Neigbour: ,%
font=normalfont, leftmargin=labelwidth, align=right
in preamble.
documentclassarticle
usepackageenumitem
usepackagecalc
begindocument
begindescription[style=multiline, labelwidth=widthofFarmer's Neigbour: ,%
font=normalfont, leftmargin=labelwidth, align=right]
item[Farmer:] It is a hard day today. The sun is burning and we still haven't brought in all the crop.
item[Farmer's Neigbour:] Yes, it will be a long day!
enddescription
enddocument
If you want to keep the regular description list, you can define a new list, e.g.newlistdialoguedescription1
and then usesetlist[dialogue]style=multiline, labelwidth=widthofFarmer's Neigbour: ,font=normalfont, leftmargin=labelwidth, align=right
– Alan Munn
Aug 8 at 3:04
Is there a way to dynamically update `widthofFarmer's Neighbour:? So the list can be reused?
– Jo-
Aug 8 at 3:05
This will require more work, in such a case, alongtable
or just atabular
may be preferred.
– AboAmmar
Aug 8 at 3:10
1
@Jo- Not completely automatic, but if you define a new list, then for any particular instance of that environment you can just specify a new value for thelabelwidth
, e.g.begindialogue[labelwidth=widthofFarmer's son: ]
.
– Alan Munn
Aug 8 at 3:17
add a comment |Â
up vote
3
down vote
accepted
up vote
3
down vote
accepted
For a list-by-list basis, you can use the options below between [..]
. Notice that calc package is required to measure the width of the widest label automatically. If you need the same settings for all description lists, use this command
setlist[description]style=multiline, labelwidth=widthofFarmer's Neigbour: ,%
font=normalfont, leftmargin=labelwidth, align=right
in preamble.
documentclassarticle
usepackageenumitem
usepackagecalc
begindocument
begindescription[style=multiline, labelwidth=widthofFarmer's Neigbour: ,%
font=normalfont, leftmargin=labelwidth, align=right]
item[Farmer:] It is a hard day today. The sun is burning and we still haven't brought in all the crop.
item[Farmer's Neigbour:] Yes, it will be a long day!
enddescription
enddocument
For a list-by-list basis, you can use the options below between [..]
. Notice that calc package is required to measure the width of the widest label automatically. If you need the same settings for all description lists, use this command
setlist[description]style=multiline, labelwidth=widthofFarmer's Neigbour: ,%
font=normalfont, leftmargin=labelwidth, align=right
in preamble.
documentclassarticle
usepackageenumitem
usepackagecalc
begindocument
begindescription[style=multiline, labelwidth=widthofFarmer's Neigbour: ,%
font=normalfont, leftmargin=labelwidth, align=right]
item[Farmer:] It is a hard day today. The sun is burning and we still haven't brought in all the crop.
item[Farmer's Neigbour:] Yes, it will be a long day!
enddescription
enddocument
edited Aug 8 at 3:01
answered Aug 8 at 2:55
AboAmmar
30.4k22780
30.4k22780
If you want to keep the regular description list, you can define a new list, e.g.newlistdialoguedescription1
and then usesetlist[dialogue]style=multiline, labelwidth=widthofFarmer's Neigbour: ,font=normalfont, leftmargin=labelwidth, align=right
– Alan Munn
Aug 8 at 3:04
Is there a way to dynamically update `widthofFarmer's Neighbour:? So the list can be reused?
– Jo-
Aug 8 at 3:05
This will require more work, in such a case, alongtable
or just atabular
may be preferred.
– AboAmmar
Aug 8 at 3:10
1
@Jo- Not completely automatic, but if you define a new list, then for any particular instance of that environment you can just specify a new value for thelabelwidth
, e.g.begindialogue[labelwidth=widthofFarmer's son: ]
.
– Alan Munn
Aug 8 at 3:17
add a comment |Â
If you want to keep the regular description list, you can define a new list, e.g.newlistdialoguedescription1
and then usesetlist[dialogue]style=multiline, labelwidth=widthofFarmer's Neigbour: ,font=normalfont, leftmargin=labelwidth, align=right
– Alan Munn
Aug 8 at 3:04
Is there a way to dynamically update `widthofFarmer's Neighbour:? So the list can be reused?
– Jo-
Aug 8 at 3:05
This will require more work, in such a case, alongtable
or just atabular
may be preferred.
– AboAmmar
Aug 8 at 3:10
1
@Jo- Not completely automatic, but if you define a new list, then for any particular instance of that environment you can just specify a new value for thelabelwidth
, e.g.begindialogue[labelwidth=widthofFarmer's son: ]
.
– Alan Munn
Aug 8 at 3:17
If you want to keep the regular description list, you can define a new list, e.g.
newlistdialoguedescription1
and then use setlist[dialogue]style=multiline, labelwidth=widthofFarmer's Neigbour: ,font=normalfont, leftmargin=labelwidth, align=right
– Alan Munn
Aug 8 at 3:04
If you want to keep the regular description list, you can define a new list, e.g.
newlistdialoguedescription1
and then use setlist[dialogue]style=multiline, labelwidth=widthofFarmer's Neigbour: ,font=normalfont, leftmargin=labelwidth, align=right
– Alan Munn
Aug 8 at 3:04
Is there a way to dynamically update `widthofFarmer's Neighbour:? So the list can be reused?
– Jo-
Aug 8 at 3:05
Is there a way to dynamically update `widthofFarmer's Neighbour:? So the list can be reused?
– Jo-
Aug 8 at 3:05
This will require more work, in such a case, a
longtable
or just a tabular
may be preferred.– AboAmmar
Aug 8 at 3:10
This will require more work, in such a case, a
longtable
or just a tabular
may be preferred.– AboAmmar
Aug 8 at 3:10
1
1
@Jo- Not completely automatic, but if you define a new list, then for any particular instance of that environment you can just specify a new value for the
labelwidth
, e.g. begindialogue[labelwidth=widthofFarmer's son: ]
.– Alan Munn
Aug 8 at 3:17
@Jo- Not completely automatic, but if you define a new list, then for any particular instance of that environment you can just specify a new value for the
labelwidth
, e.g. begindialogue[labelwidth=widthofFarmer's son: ]
.– Alan Munn
Aug 8 at 3:17
add a comment |Â
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2ftex.stackexchange.com%2fquestions%2f445066%2fenumitem-right-align-the-label%23new-answer', 'question_page');
);
Post as a guest
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
2
Why are you using an
enumerate
list when you want adescription
type list?– Alan Munn
Aug 8 at 2:36
Just try
align=left
, It should work.– javadr
Aug 8 at 2:41