groovy scripting examples (JAL-???)
[jalview.git] / examples / groovy / printtitle.groovy
1 // do something groovy in jalview\r
2 print "Hello World.\n";\r
3 def alf = Jalview.getAlignframes();\r
4 for (ala in alf)\r
5 {\r
6         // ala is an jalview.gui.AlignFrame object \r
7         print ala.getTitle()+"\n";\r
8         // get the parent jalview.datamodel.Alignment from the alignment viewport\r
9         def alignment = ala.viewport.alignment;\r
10         // get the first sequence from the jalview.datamodel.Alignment object\r
11         def seq = alignment.getSequenceAt(0); \r
12 }\r