How can I write in a box with fixed height?

Clash Royale CLAN TAG#URR8PPP
up vote
7
down vote
favorite
I am using report class and have been using framebox[linewidth]rule0pt2cm to create an empty box with a certain height. Now, I would like to write in that empty box. By referring to How can I write something in a box with makeemptybox1.8in?, I achieved the following:
documentclass[a4paper,11pt]report
newcommandmakenonemptybox[2]%
parnobreakvspacehtstrutboxnoindent
fbox%
parbox[c][dimexpr#1-2fboxsep][t]dimexprlinewidth-2fboxsep
hrule width hsize height 0pt
#2
%
%
parvspacehtstrutbox
makeatother
begindocument
beginenumerate
item Tell me about yourself.
beginenumerate
item What is your name?
makenonemptybox2cmMy name is Nadia.
item Where are you from?
makenonemptybox2cmLorem ipsum dolor sit amet, consectetur adipiscing elit. Nullam a venenatis lacus. Nunc vitae mollis neque. Maecenas vel arcu erat.
item How old are you?
item framebox[linewidth]rule0pt2cm
endenumerate
endenumerate
enddocument
As you can see makenoemptybox makes a bigger vertical space compared to framebox (refer to the coloured arrows). How can I make the vertical space made by makenoemptybox follows that of framebox?

box
add a comment |Â
up vote
7
down vote
favorite
I am using report class and have been using framebox[linewidth]rule0pt2cm to create an empty box with a certain height. Now, I would like to write in that empty box. By referring to How can I write something in a box with makeemptybox1.8in?, I achieved the following:
documentclass[a4paper,11pt]report
newcommandmakenonemptybox[2]%
parnobreakvspacehtstrutboxnoindent
fbox%
parbox[c][dimexpr#1-2fboxsep][t]dimexprlinewidth-2fboxsep
hrule width hsize height 0pt
#2
%
%
parvspacehtstrutbox
makeatother
begindocument
beginenumerate
item Tell me about yourself.
beginenumerate
item What is your name?
makenonemptybox2cmMy name is Nadia.
item Where are you from?
makenonemptybox2cmLorem ipsum dolor sit amet, consectetur adipiscing elit. Nullam a venenatis lacus. Nunc vitae mollis neque. Maecenas vel arcu erat.
item How old are you?
item framebox[linewidth]rule0pt2cm
endenumerate
endenumerate
enddocument
As you can see makenoemptybox makes a bigger vertical space compared to framebox (refer to the coloured arrows). How can I make the vertical space made by makenoemptybox follows that of framebox?

box
Related Question: mdframed box of fixed minimum height.
â Peter Grill
Sep 8 at 7:05
Perhaps I am missing something, but if you just want an empty box of the same size, why not just usemakenonemptybox2cm?
â Peter Grill
Sep 8 at 7:08
@PeterGrill I've just edited the picture.
â Nadia
Sep 8 at 7:47
1
side remark: as got clarified later theparbox[c][dimexpr#1-2fboxsep]inmakenonemptyboxshould have beenparbox[c][#1]to start with, because whenframebox[linewidth]rule0pt2cmis used the total height is 2cm +2fboxsep+2fboxrule. To do the same withmakenonemptyboxfor the height it thus should beparbox[c][#1]when#1is2cm. Besides, removingfboxsepmakes no sense if not removing alsofboxrule, then total height including frame and separation would be2cm. Butframebox[linewidth]rule0pt2cmgives2cm+2fboxsep+2fboxrule.
â jfbu
Sep 8 at 9:31
add a comment |Â
up vote
7
down vote
favorite
up vote
7
down vote
favorite
I am using report class and have been using framebox[linewidth]rule0pt2cm to create an empty box with a certain height. Now, I would like to write in that empty box. By referring to How can I write something in a box with makeemptybox1.8in?, I achieved the following:
documentclass[a4paper,11pt]report
newcommandmakenonemptybox[2]%
parnobreakvspacehtstrutboxnoindent
fbox%
parbox[c][dimexpr#1-2fboxsep][t]dimexprlinewidth-2fboxsep
hrule width hsize height 0pt
#2
%
%
parvspacehtstrutbox
makeatother
begindocument
beginenumerate
item Tell me about yourself.
beginenumerate
item What is your name?
makenonemptybox2cmMy name is Nadia.
item Where are you from?
makenonemptybox2cmLorem ipsum dolor sit amet, consectetur adipiscing elit. Nullam a venenatis lacus. Nunc vitae mollis neque. Maecenas vel arcu erat.
item How old are you?
item framebox[linewidth]rule0pt2cm
endenumerate
endenumerate
enddocument
As you can see makenoemptybox makes a bigger vertical space compared to framebox (refer to the coloured arrows). How can I make the vertical space made by makenoemptybox follows that of framebox?

box
I am using report class and have been using framebox[linewidth]rule0pt2cm to create an empty box with a certain height. Now, I would like to write in that empty box. By referring to How can I write something in a box with makeemptybox1.8in?, I achieved the following:
documentclass[a4paper,11pt]report
newcommandmakenonemptybox[2]%
parnobreakvspacehtstrutboxnoindent
fbox%
parbox[c][dimexpr#1-2fboxsep][t]dimexprlinewidth-2fboxsep
hrule width hsize height 0pt
#2
%
%
parvspacehtstrutbox
makeatother
begindocument
beginenumerate
item Tell me about yourself.
beginenumerate
item What is your name?
makenonemptybox2cmMy name is Nadia.
item Where are you from?
makenonemptybox2cmLorem ipsum dolor sit amet, consectetur adipiscing elit. Nullam a venenatis lacus. Nunc vitae mollis neque. Maecenas vel arcu erat.
item How old are you?
item framebox[linewidth]rule0pt2cm
endenumerate
endenumerate
enddocument
As you can see makenoemptybox makes a bigger vertical space compared to framebox (refer to the coloured arrows). How can I make the vertical space made by makenoemptybox follows that of framebox?

box
box
edited Sep 8 at 7:44
asked Sep 8 at 6:22
Nadia
505
505
Related Question: mdframed box of fixed minimum height.
â Peter Grill
Sep 8 at 7:05
Perhaps I am missing something, but if you just want an empty box of the same size, why not just usemakenonemptybox2cm?
â Peter Grill
Sep 8 at 7:08
@PeterGrill I've just edited the picture.
â Nadia
Sep 8 at 7:47
1
side remark: as got clarified later theparbox[c][dimexpr#1-2fboxsep]inmakenonemptyboxshould have beenparbox[c][#1]to start with, because whenframebox[linewidth]rule0pt2cmis used the total height is 2cm +2fboxsep+2fboxrule. To do the same withmakenonemptyboxfor the height it thus should beparbox[c][#1]when#1is2cm. Besides, removingfboxsepmakes no sense if not removing alsofboxrule, then total height including frame and separation would be2cm. Butframebox[linewidth]rule0pt2cmgives2cm+2fboxsep+2fboxrule.
â jfbu
Sep 8 at 9:31
add a comment |Â
Related Question: mdframed box of fixed minimum height.
â Peter Grill
Sep 8 at 7:05
Perhaps I am missing something, but if you just want an empty box of the same size, why not just usemakenonemptybox2cm?
â Peter Grill
Sep 8 at 7:08
@PeterGrill I've just edited the picture.
â Nadia
Sep 8 at 7:47
1
side remark: as got clarified later theparbox[c][dimexpr#1-2fboxsep]inmakenonemptyboxshould have beenparbox[c][#1]to start with, because whenframebox[linewidth]rule0pt2cmis used the total height is 2cm +2fboxsep+2fboxrule. To do the same withmakenonemptyboxfor the height it thus should beparbox[c][#1]when#1is2cm. Besides, removingfboxsepmakes no sense if not removing alsofboxrule, then total height including frame and separation would be2cm. Butframebox[linewidth]rule0pt2cmgives2cm+2fboxsep+2fboxrule.
â jfbu
Sep 8 at 9:31
Related Question: mdframed box of fixed minimum height.
â Peter Grill
Sep 8 at 7:05
Related Question: mdframed box of fixed minimum height.
â Peter Grill
Sep 8 at 7:05
Perhaps I am missing something, but if you just want an empty box of the same size, why not just use
makenonemptybox2cm?â Peter Grill
Sep 8 at 7:08
Perhaps I am missing something, but if you just want an empty box of the same size, why not just use
makenonemptybox2cm?â Peter Grill
Sep 8 at 7:08
@PeterGrill I've just edited the picture.
â Nadia
Sep 8 at 7:47
@PeterGrill I've just edited the picture.
â Nadia
Sep 8 at 7:47
1
1
side remark: as got clarified later the
parbox[c][dimexpr#1-2fboxsep] in makenonemptybox should have been parbox[c][#1] to start with, because when framebox[linewidth]rule0pt2cm is used the total height is 2cm + 2fboxsep + 2fboxrule. To do the same with makenonemptybox for the height it thus should be parbox[c][#1] when #1 is 2cm. Besides, removing fboxsep makes no sense if not removing also fboxrule, then total height including frame and separation would be 2cm. But framebox[linewidth]rule0pt2cm gives 2cm+2fboxsep+2fboxrule.â jfbu
Sep 8 at 9:31
side remark: as got clarified later the
parbox[c][dimexpr#1-2fboxsep] in makenonemptybox should have been parbox[c][#1] to start with, because when framebox[linewidth]rule0pt2cm is used the total height is 2cm + 2fboxsep + 2fboxrule. To do the same with makenonemptybox for the height it thus should be parbox[c][#1] when #1 is 2cm. Besides, removing fboxsep makes no sense if not removing also fboxrule, then total height including frame and separation would be 2cm. But framebox[linewidth]rule0pt2cm gives 2cm+2fboxsep+2fboxrule.â jfbu
Sep 8 at 9:31
add a comment |Â
2 Answers
2
active
oldest
votes
up vote
7
down vote
accepted
Use in the definition of makenonemptybox the same method you use for framebox to close current paragraph. Of course, that will restrict its usage to list environments.
documentclass[a4paper,11pt]report
newcommandmakenonemptybox[2]%
%parnobreakvspacehtstrutboxnoindent
item
fbox% added -2fboxrule to specified width to avoid overfull hboxes
% and removed the -2fboxsep from height specification (image not updated)
% because in MWE 2cm is should be height of contents excluding sep and frame
parbox[c][#1][t]dimexprlinewidth-2fboxsep-2fboxrule
hrule width hsize height 0pt
#2
%
%
parvspacehtstrutbox
makeatother
begindocument
beginenumerate
item Tell me about yourself.
beginenumerate
item What is your name?
makenonemptybox2cmMy name is Nadia.
item Where are you from?
makenonemptybox2cmLorem ipsum dolor sit amet, consectetur adipiscing elit. Nullam a venenatis lacus. Nunc vitae mollis neque. Maecenas vel arcu erat.
item How old are you?
item framebox[linewidth]rule0pt2cm
endenumerate
endenumerate
enddocument

1
you could also drop theitemfrom the macro definition and use it explicitely as input mark-up like you do before theframebox. Then the macro could be used in other contexts, with some adapted prefix such as apar.
â jfbu
Sep 8 at 8:12
Why doesmakenonemptyboxgive me overfull hbox?
â Nadia
Sep 8 at 8:55
@Nadia because the original code forgot to reduce width by2fboxrule. I will add that.
â jfbu
Sep 8 at 9:10
Added also-2fboxruleto height specification.
â jfbu
Sep 8 at 9:13
wait.... why are2fboxsepremoved from height specs to start with? they should not because2cmis used by theruleinframebox. I will remove them (and the2fboxruleI temporarily added)
â jfbu
Sep 8 at 9:17
add a comment |Â
up vote
0
down vote
A par and a minipage works:
documentclass[a4paper,11pt]report
newcommandmakenonemptybox[2]%
parfboxsep1exfbox%
beginminipage[c][#1][t]dimexprlinewidth-2fboxsep-2fboxrule%
#2endminipage}%
begindocument
beginenumerate
item Tell me about yourself.
beginenumerate
item What is your name?
makenonemptybox2cmMy name is Nadia.
item Where are you from?
makenonemptybox2cmLorem ipsum dolor sit amet, consectetur adipiscing elit. Nullam a venenatis lacus. Nunc vitae mollis neque. Maecenas vel arcu erat.
item How old are you?
item framebox[linewidth]rule0pt2cm
endenumerate
endenumerate
enddocument
add a comment |Â
2 Answers
2
active
oldest
votes
2 Answers
2
active
oldest
votes
active
oldest
votes
active
oldest
votes
up vote
7
down vote
accepted
Use in the definition of makenonemptybox the same method you use for framebox to close current paragraph. Of course, that will restrict its usage to list environments.
documentclass[a4paper,11pt]report
newcommandmakenonemptybox[2]%
%parnobreakvspacehtstrutboxnoindent
item
fbox% added -2fboxrule to specified width to avoid overfull hboxes
% and removed the -2fboxsep from height specification (image not updated)
% because in MWE 2cm is should be height of contents excluding sep and frame
parbox[c][#1][t]dimexprlinewidth-2fboxsep-2fboxrule
hrule width hsize height 0pt
#2
%
%
parvspacehtstrutbox
makeatother
begindocument
beginenumerate
item Tell me about yourself.
beginenumerate
item What is your name?
makenonemptybox2cmMy name is Nadia.
item Where are you from?
makenonemptybox2cmLorem ipsum dolor sit amet, consectetur adipiscing elit. Nullam a venenatis lacus. Nunc vitae mollis neque. Maecenas vel arcu erat.
item How old are you?
item framebox[linewidth]rule0pt2cm
endenumerate
endenumerate
enddocument

1
you could also drop theitemfrom the macro definition and use it explicitely as input mark-up like you do before theframebox. Then the macro could be used in other contexts, with some adapted prefix such as apar.
â jfbu
Sep 8 at 8:12
Why doesmakenonemptyboxgive me overfull hbox?
â Nadia
Sep 8 at 8:55
@Nadia because the original code forgot to reduce width by2fboxrule. I will add that.
â jfbu
Sep 8 at 9:10
Added also-2fboxruleto height specification.
â jfbu
Sep 8 at 9:13
wait.... why are2fboxsepremoved from height specs to start with? they should not because2cmis used by theruleinframebox. I will remove them (and the2fboxruleI temporarily added)
â jfbu
Sep 8 at 9:17
add a comment |Â
up vote
7
down vote
accepted
Use in the definition of makenonemptybox the same method you use for framebox to close current paragraph. Of course, that will restrict its usage to list environments.
documentclass[a4paper,11pt]report
newcommandmakenonemptybox[2]%
%parnobreakvspacehtstrutboxnoindent
item
fbox% added -2fboxrule to specified width to avoid overfull hboxes
% and removed the -2fboxsep from height specification (image not updated)
% because in MWE 2cm is should be height of contents excluding sep and frame
parbox[c][#1][t]dimexprlinewidth-2fboxsep-2fboxrule
hrule width hsize height 0pt
#2
%
%
parvspacehtstrutbox
makeatother
begindocument
beginenumerate
item Tell me about yourself.
beginenumerate
item What is your name?
makenonemptybox2cmMy name is Nadia.
item Where are you from?
makenonemptybox2cmLorem ipsum dolor sit amet, consectetur adipiscing elit. Nullam a venenatis lacus. Nunc vitae mollis neque. Maecenas vel arcu erat.
item How old are you?
item framebox[linewidth]rule0pt2cm
endenumerate
endenumerate
enddocument

1
you could also drop theitemfrom the macro definition and use it explicitely as input mark-up like you do before theframebox. Then the macro could be used in other contexts, with some adapted prefix such as apar.
â jfbu
Sep 8 at 8:12
Why doesmakenonemptyboxgive me overfull hbox?
â Nadia
Sep 8 at 8:55
@Nadia because the original code forgot to reduce width by2fboxrule. I will add that.
â jfbu
Sep 8 at 9:10
Added also-2fboxruleto height specification.
â jfbu
Sep 8 at 9:13
wait.... why are2fboxsepremoved from height specs to start with? they should not because2cmis used by theruleinframebox. I will remove them (and the2fboxruleI temporarily added)
â jfbu
Sep 8 at 9:17
add a comment |Â
up vote
7
down vote
accepted
up vote
7
down vote
accepted
Use in the definition of makenonemptybox the same method you use for framebox to close current paragraph. Of course, that will restrict its usage to list environments.
documentclass[a4paper,11pt]report
newcommandmakenonemptybox[2]%
%parnobreakvspacehtstrutboxnoindent
item
fbox% added -2fboxrule to specified width to avoid overfull hboxes
% and removed the -2fboxsep from height specification (image not updated)
% because in MWE 2cm is should be height of contents excluding sep and frame
parbox[c][#1][t]dimexprlinewidth-2fboxsep-2fboxrule
hrule width hsize height 0pt
#2
%
%
parvspacehtstrutbox
makeatother
begindocument
beginenumerate
item Tell me about yourself.
beginenumerate
item What is your name?
makenonemptybox2cmMy name is Nadia.
item Where are you from?
makenonemptybox2cmLorem ipsum dolor sit amet, consectetur adipiscing elit. Nullam a venenatis lacus. Nunc vitae mollis neque. Maecenas vel arcu erat.
item How old are you?
item framebox[linewidth]rule0pt2cm
endenumerate
endenumerate
enddocument

Use in the definition of makenonemptybox the same method you use for framebox to close current paragraph. Of course, that will restrict its usage to list environments.
documentclass[a4paper,11pt]report
newcommandmakenonemptybox[2]%
%parnobreakvspacehtstrutboxnoindent
item
fbox% added -2fboxrule to specified width to avoid overfull hboxes
% and removed the -2fboxsep from height specification (image not updated)
% because in MWE 2cm is should be height of contents excluding sep and frame
parbox[c][#1][t]dimexprlinewidth-2fboxsep-2fboxrule
hrule width hsize height 0pt
#2
%
%
parvspacehtstrutbox
makeatother
begindocument
beginenumerate
item Tell me about yourself.
beginenumerate
item What is your name?
makenonemptybox2cmMy name is Nadia.
item Where are you from?
makenonemptybox2cmLorem ipsum dolor sit amet, consectetur adipiscing elit. Nullam a venenatis lacus. Nunc vitae mollis neque. Maecenas vel arcu erat.
item How old are you?
item framebox[linewidth]rule0pt2cm
endenumerate
endenumerate
enddocument

edited Sep 8 at 9:19
answered Sep 8 at 7:50
jfbu
42.4k63136
42.4k63136
1
you could also drop theitemfrom the macro definition and use it explicitely as input mark-up like you do before theframebox. Then the macro could be used in other contexts, with some adapted prefix such as apar.
â jfbu
Sep 8 at 8:12
Why doesmakenonemptyboxgive me overfull hbox?
â Nadia
Sep 8 at 8:55
@Nadia because the original code forgot to reduce width by2fboxrule. I will add that.
â jfbu
Sep 8 at 9:10
Added also-2fboxruleto height specification.
â jfbu
Sep 8 at 9:13
wait.... why are2fboxsepremoved from height specs to start with? they should not because2cmis used by theruleinframebox. I will remove them (and the2fboxruleI temporarily added)
â jfbu
Sep 8 at 9:17
add a comment |Â
1
you could also drop theitemfrom the macro definition and use it explicitely as input mark-up like you do before theframebox. Then the macro could be used in other contexts, with some adapted prefix such as apar.
â jfbu
Sep 8 at 8:12
Why doesmakenonemptyboxgive me overfull hbox?
â Nadia
Sep 8 at 8:55
@Nadia because the original code forgot to reduce width by2fboxrule. I will add that.
â jfbu
Sep 8 at 9:10
Added also-2fboxruleto height specification.
â jfbu
Sep 8 at 9:13
wait.... why are2fboxsepremoved from height specs to start with? they should not because2cmis used by theruleinframebox. I will remove them (and the2fboxruleI temporarily added)
â jfbu
Sep 8 at 9:17
1
1
you could also drop the
item from the macro definition and use it explicitely as input mark-up like you do before the framebox. Then the macro could be used in other contexts, with some adapted prefix such as a par.â jfbu
Sep 8 at 8:12
you could also drop the
item from the macro definition and use it explicitely as input mark-up like you do before the framebox. Then the macro could be used in other contexts, with some adapted prefix such as a par.â jfbu
Sep 8 at 8:12
Why does
makenonemptybox give me overfull hbox?â Nadia
Sep 8 at 8:55
Why does
makenonemptybox give me overfull hbox?â Nadia
Sep 8 at 8:55
@Nadia because the original code forgot to reduce width by
2fboxrule. I will add that.â jfbu
Sep 8 at 9:10
@Nadia because the original code forgot to reduce width by
2fboxrule. I will add that.â jfbu
Sep 8 at 9:10
Added also
-2fboxrule to height specification.â jfbu
Sep 8 at 9:13
Added also
-2fboxrule to height specification.â jfbu
Sep 8 at 9:13
wait.... why are
2fboxsep removed from height specs to start with? they should not because 2cm is used by the rule in framebox. I will remove them (and the 2fboxrule I temporarily added)â jfbu
Sep 8 at 9:17
wait.... why are
2fboxsep removed from height specs to start with? they should not because 2cm is used by the rule in framebox. I will remove them (and the 2fboxrule I temporarily added)â jfbu
Sep 8 at 9:17
add a comment |Â
up vote
0
down vote
A par and a minipage works:
documentclass[a4paper,11pt]report
newcommandmakenonemptybox[2]%
parfboxsep1exfbox%
beginminipage[c][#1][t]dimexprlinewidth-2fboxsep-2fboxrule%
#2endminipage}%
begindocument
beginenumerate
item Tell me about yourself.
beginenumerate
item What is your name?
makenonemptybox2cmMy name is Nadia.
item Where are you from?
makenonemptybox2cmLorem ipsum dolor sit amet, consectetur adipiscing elit. Nullam a venenatis lacus. Nunc vitae mollis neque. Maecenas vel arcu erat.
item How old are you?
item framebox[linewidth]rule0pt2cm
endenumerate
endenumerate
enddocument
add a comment |Â
up vote
0
down vote
A par and a minipage works:
documentclass[a4paper,11pt]report
newcommandmakenonemptybox[2]%
parfboxsep1exfbox%
beginminipage[c][#1][t]dimexprlinewidth-2fboxsep-2fboxrule%
#2endminipage}%
begindocument
beginenumerate
item Tell me about yourself.
beginenumerate
item What is your name?
makenonemptybox2cmMy name is Nadia.
item Where are you from?
makenonemptybox2cmLorem ipsum dolor sit amet, consectetur adipiscing elit. Nullam a venenatis lacus. Nunc vitae mollis neque. Maecenas vel arcu erat.
item How old are you?
item framebox[linewidth]rule0pt2cm
endenumerate
endenumerate
enddocument
add a comment |Â
up vote
0
down vote
up vote
0
down vote
A par and a minipage works:
documentclass[a4paper,11pt]report
newcommandmakenonemptybox[2]%
parfboxsep1exfbox%
beginminipage[c][#1][t]dimexprlinewidth-2fboxsep-2fboxrule%
#2endminipage}%
begindocument
beginenumerate
item Tell me about yourself.
beginenumerate
item What is your name?
makenonemptybox2cmMy name is Nadia.
item Where are you from?
makenonemptybox2cmLorem ipsum dolor sit amet, consectetur adipiscing elit. Nullam a venenatis lacus. Nunc vitae mollis neque. Maecenas vel arcu erat.
item How old are you?
item framebox[linewidth]rule0pt2cm
endenumerate
endenumerate
enddocument
A par and a minipage works:
documentclass[a4paper,11pt]report
newcommandmakenonemptybox[2]%
parfboxsep1exfbox%
beginminipage[c][#1][t]dimexprlinewidth-2fboxsep-2fboxrule%
#2endminipage}%
begindocument
beginenumerate
item Tell me about yourself.
beginenumerate
item What is your name?
makenonemptybox2cmMy name is Nadia.
item Where are you from?
makenonemptybox2cmLorem ipsum dolor sit amet, consectetur adipiscing elit. Nullam a venenatis lacus. Nunc vitae mollis neque. Maecenas vel arcu erat.
item How old are you?
item framebox[linewidth]rule0pt2cm
endenumerate
endenumerate
enddocument
answered Sep 9 at 10:13
Fran
48.5k6110170
48.5k6110170
add a comment |Â
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%2f449961%2fhow-can-i-write-in-a-box-with-fixed-height%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
Related Question: mdframed box of fixed minimum height.
â Peter Grill
Sep 8 at 7:05
Perhaps I am missing something, but if you just want an empty box of the same size, why not just use
makenonemptybox2cm?â Peter Grill
Sep 8 at 7:08
@PeterGrill I've just edited the picture.
â Nadia
Sep 8 at 7:47
1
side remark: as got clarified later the
parbox[c][dimexpr#1-2fboxsep]inmakenonemptyboxshould have beenparbox[c][#1]to start with, because whenframebox[linewidth]rule0pt2cmis used the total height is 2cm +2fboxsep+2fboxrule. To do the same withmakenonemptyboxfor the height it thus should beparbox[c][#1]when#1is2cm. Besides, removingfboxsepmakes no sense if not removing alsofboxrule, then total height including frame and separation would be2cm. Butframebox[linewidth]rule0pt2cmgives2cm+2fboxsep+2fboxrule.â jfbu
Sep 8 at 9:31