I just worked out how to make an empty box of various horizonal size easily in LaTex.

This is not a recommended method, but other methods that I have tried here have not worked.

This coding is really simple.  Just put letters inside but make the letters invisable!   laugh






\(\boxed{\color{white} ABC} \)






 Mar 15, 2022
edited by Melody  Mar 15, 2022

Another code I like to use to make things invisible is  \phantom{}


It will makes whatever you put inside invisible! I sometimes use it for spacing laugh


Also there is the  \hspace  command which can be used to make a horizontal space of a specified length.


For example, the code:  a\hspace{3cm}b

makes this:




So there are 3 cm of space between the a and the b.


(Also here is a list of the different types of units of length it recognizes)

 Mar 15, 2022

It looks like just making a box with the \hspace command makes a narrower box like this:




And I tried to use the \vspace command to make it taller but it seems like that doesn't work in math mode :\

hectictar  Mar 15, 2022

Thanks Hectictar,


I really like that \phantom one !  

And the \hspace{3cm}b  looks like it would be really useful.



It is good to have seome more commands that actually do work here  laugh


I will add an a link to this thread, to the Latex thread that is found in the sticky notes.

Melody  Mar 15, 2022
edited by Melody  Mar 15, 2022

8 Online Users