TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I am doing a poster using beamerposter . The text inside a block always seems to have no left margin. Can anyone tell me a way of introducing a left margin in a block ?

Here is a sample of how a block looks. Notice that the text starts off with no left margin.

enter image description here

It would be nice if you could tell me how to define left, right, top and bottom margins within the block. Please note that I have nested blocks, though the nested ones have a different environment name (i called then insideBlocks). Hence I wouldn't want the margins for the block environment to affect the margins for my insideBlocks environment.

Hope I am clear.

share|improve this question
up vote 4 down vote accepted

I think this can be achieved in many ways. One possibility is to define a new block environment with custom margins, like this:


 \def\insertblocktitle{\leftskip=10pt\rightskip=10pt\vspace{10pt} #1\vspace{10pt}}%
 \usebeamertemplate{block begin}\leftskip=10pt\rightskip=10pt\vspace{10pt}}
 {\par\vspace{10pt}\usebeamertemplate{block end}


\begin{myblock}{example title to show 10pt up, down, left and right margins}
 example text to show 10pt up, down, left and right margins

\begin{block}{example title to show standard margins}
 example text to show standard margins


In the new environment (I called it myblock) \leftskip, \rightskip and \vspace are used to set the margins. As an example I set everything to 10pt. If you don't want, e.g. a right margin, just remove the rightskip from the code. I assumed you also wanted to customize the title text margin, if you don't want to just remove the leftskip etc. from \def\insertblocktitle{}. the result is: enter image description here

Another possibility would be with the tcolorbox package, which lets you set margins like this:


\tcbset{                                               % custom tcolorbox  
        frame style={fill=blue},                       % sets the frame color
        bottom=10pt,                                    % distance between the body text and the bottom frame
        top=10pt,                                      % distance between the body text and the top frame
        boxrule=0pt,                                   % frame width
        bottomtitle=10pt,                               % distance between the title text and the bottom title frame               
        toptitle=10pt,                                  % distance between the title text and the top title frame
        lefttitle=10pt,                                  % title text left margin

result is: enter image description here

edit: I didn't add the beamerposterpackage in my example code because it works both in beamer and beamerposter without modifications.

share|improve this answer
Thanks a lot for the prompt reply. The text is now left-margined. This helps me, but It would be nice if you could tell me how to shift the block itself to the right. In otherwords, is it possible to see the background to the left of this block ? Actually that was what I intended for. Nevertheless the solution you told is also good for me. Is my description too confusing ? Hope not. – Pavithran Iyer Apr 14 '13 at 13:32
if you want to move the entire block to the right, you could for example use the columns environment. I believe this question has been asked many times, but if you want me to give an example I'll add it to my answer. – domenico Apr 14 '13 at 13:56

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.