Copied some old code into the ViewPsalm activity for later porting.