Advertisement
Guest User

Untitled

a guest
Jun 16th, 2019
70
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 2.00 KB | None | 0 0
  1. mdfdefinestyle{MyFrame}{%
  2. linecolor=black,
  3. outerlinewidth=2pt,
  4. %roundcorner=20pt,
  5. innertopmargin=4pt,
  6. innerbottommargin=4pt,
  7. innerrightmargin=4pt,
  8. innerleftmargin=4pt,
  9. leftmargin = 4pt,
  10. rightmargin = 4pt
  11. %backgroundcolor=gray!50!white}
  12. }
  13.  
  14. % text
  15. begin{mdframed}[style=MyFrame,nobreak=true]
  16. begin{center}
  17. textbf{THIS TEXT SHOULD BE MORE TIGHTLY FRAMED }
  18. end{center}
  19. end{mdframed}
  20.  
  21. % sipka
  22. begin{figure}[h!]
  23. centering
  24. includegraphics[width=.1textwidth]{sipka3.pdf}
  25. end{figure}
  26. % arrow
  27. begin{mdframed}[style=MyFrame,nobreak=true]
  28. lipsum[2]
  29. end{mdframed}
  30.  
  31. % sipka
  32. begin{figure}[h!]
  33. centering
  34. includegraphics[width=.1textwidth]{sipka3.pdf}
  35. end{figure}
  36. % arrow
  37. begin{mdframed}[style=MyFrame,nobreak=true]
  38. lipsum[1]
  39. end{mdframed}
  40.  
  41. documentclass{article}
  42. usepackage{mdframed,lipsum}
  43. begin{document}
  44. mdfdefinestyle{MyFrame}{%
  45. linecolor=black,
  46. outerlinewidth=2pt,
  47. %roundcorner=20pt,
  48. innertopmargin=4pt,
  49. innerbottommargin=4pt,
  50. innerrightmargin=4pt,
  51. innerleftmargin=4pt,
  52. leftmargin = 4pt,
  53. rightmargin = 4pt
  54. %backgroundcolor=gray!50!white}
  55. }
  56.  
  57. % text
  58. lipsum[1]
  59. begin{mdframed}[style=MyFrame,nobreak=true,align=center,userdefinedwidth=30em]
  60. textbf{THIS TEXT SHOULD BE MORE TIGHTLY FRAMED}
  61. end{mdframed}
  62. lipsum[2]
  63. end{document}
  64.  
  65. documentclass{article}
  66. usepackage{mdframed,lipsum,calc}
  67. begin{document}
  68. mdfdefinestyle{MyFrame}{%
  69. linecolor=black,
  70. outerlinewidth=2pt,
  71. %roundcorner=20pt,
  72. innertopmargin=4pt,
  73. innerbottommargin=4pt,
  74. innerrightmargin=4pt,
  75. innerleftmargin=4pt,
  76. leftmargin = 4pt,
  77. rightmargin = 4pt
  78. %backgroundcolor=gray!50!white}
  79. }
  80.  
  81. newcommandheader[1]{
  82. newlength{headerwidth}
  83. setlength{headerwidth}{widthof{#1}}
  84. addtolength{headerwidth}{8pt}
  85. begin{mdframed}[style=MyFrame,nobreak=true,align=center,userdefinedwidth=headerwidth]
  86. #1
  87. end{mdframed}
  88. }
  89.  
  90.  
  91. % text
  92. lipsum[1]
  93. header{textbf{THIS TEXT SHOULD BE MORE TIGHTLY FRAMED}}
  94. lipsum[2]
  95. end{document}
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement