from paraview import servermanager
servermanager.Connect()
V = servermanager.CreateRenderView()
Y = 0.9
direction = ["Left", "Center", "Right"];
for i in range(3):
   T = servermanager.sources.TextSource()
   T.Text = "%s justification:\nMore text illustrating the justification.\nStill more text." % (direction[i])

   TR = servermanager.CreateRepresentation( T, V,\
      proxyName="TextSourceRepresentation" )

   TR.ScaledText = 0
   TR.FontSize = 12
   print TR.Justification
   TR.Justification = i
   TR.Position = [ 0.1, Y ]
   Y -= 0.3
   
V.StillRender()
V.ResetCamera()
V.StillRender()
raw_input("Exit: ")	
