Enumitem: Right align the label
![Creative The name of the picture](https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgO9GURib1T8z7lCwjOGLQaGtrueEthgQ8LO42ZX8cOfTqDK4jvDDpKkLFwf2J49kYCMNW7d4ABih_XCb_2UXdq5fPJDkoyg7-8g_YfRUot-XnaXkNYycsNp7lA5_TW9td0FFpLQ2APzKcZ/s1600/1.jpg)
![Creative The name of the picture](https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhYQ0N5W1qAOxLP7t7iOM6O6AzbZnkXUy16s7P_CWfOb5UbTQY_aDsc727chyphenhyphen5W4IppVNernMMQeaUFTB_rFzAd95_CDt-tnwN-nBx6JyUp2duGjPaL5-VgNO41AVsA_vu30EJcipdDG409/s400/Clash+Royale+CLAN+TAG%2523URR8PPP.png)
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
horizontal-alignment enumitem
edited Aug 8 at 2:35
Alan Munn
155k27414686
155k27414686
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.5k22780
30.5k22780
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');
var $window = $(window),
onScroll = function(e)
var $elem = $('.new-login-left'),
docViewTop = $window.scrollTop(),
docViewBottom = docViewTop + $window.height(),
elemTop = $elem.offset().top,
elemBottom = elemTop + $elem.height();
if ((docViewTop elemBottom))
StackExchange.using('gps', function() StackExchange.gps.track('embedded_signup_form.view', location: 'question_page' ); );
$window.unbind('scroll', onScroll);
;
$window.on('scroll', onScroll);
);
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');
var $window = $(window),
onScroll = function(e)
var $elem = $('.new-login-left'),
docViewTop = $window.scrollTop(),
docViewBottom = docViewTop + $window.height(),
elemTop = $elem.offset().top,
elemBottom = elemTop + $elem.height();
if ((docViewTop elemBottom))
StackExchange.using('gps', function() StackExchange.gps.track('embedded_signup_form.view', location: 'question_page' ); );
$window.unbind('scroll', onScroll);
;
$window.on('scroll', onScroll);
);
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');
var $window = $(window),
onScroll = function(e)
var $elem = $('.new-login-left'),
docViewTop = $window.scrollTop(),
docViewBottom = docViewTop + $window.height(),
elemTop = $elem.offset().top,
elemBottom = elemTop + $elem.height();
if ((docViewTop elemBottom))
StackExchange.using('gps', function() StackExchange.gps.track('embedded_signup_form.view', location: 'question_page' ); );
$window.unbind('scroll', onScroll);
;
$window.on('scroll', onScroll);
);
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');
var $window = $(window),
onScroll = function(e)
var $elem = $('.new-login-left'),
docViewTop = $window.scrollTop(),
docViewBottom = docViewTop + $window.height(),
elemTop = $elem.offset().top,
elemBottom = elemTop + $elem.height();
if ((docViewTop elemBottom))
StackExchange.using('gps', function() StackExchange.gps.track('embedded_signup_form.view', location: 'question_page' ); );
$window.unbind('scroll', onScroll);
;
$window.on('scroll', onScroll);
);
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