Frame this nice ASCII-Art
Haskell, 139 bytes

q=length
g x|l&lt;-lines x,m&lt;-maximum$q&lt;$&gt;l,s&lt;-[-1..m]&gt;&gt;"═"='╔':s++"╗\n"++(l&gt;&gt;= \z-&gt;"║ "++z++([q z..m]&gt;&gt;" ")++"║\n")++'╚':s++"╝"


As an example I'm framing snowman "12333321".

*Main&gt; putStrLn $ g " _===_\n (O.O)\n/(] [)\\\n ( : )"
╔═════════╗
║  _===_  ║
║  (O.O)  ║
║ /(] [)\ ║
║  ( : )  ║
╚═════════╝


How it works:

bind
  l: input split into lines
  m: maximum line length
  s: m+2 times ═

build top line
prepend left frame to each line, pad with spaces, append right frame
build bottom line.