Skip to content

Commit

Permalink
Reverse vertical alignment
Browse files Browse the repository at this point in the history
Fixes bug 1948 caused by the inversion of the coordinate system for translation between on screen and cdk coordianates
  • Loading branch information
Arvid Berg committed May 24, 2010
1 parent 8915156 commit aeae2e8
Showing 1 changed file with 2 additions and 2 deletions.
Expand Up @@ -354,8 +354,8 @@ public void visit(AtomSymbolElement element) {
switch(element.alignment) { switch(element.alignment) {
case -1: x = x -secondTextSize.x - hc.x;break; case -1: x = x -secondTextSize.x - hc.x;break;
case 1: x = x + textSize.x+cp.x;break; case 1: x = x + textSize.x+cp.x;break;
case 2: y = y + textSize.y;break; case -2: y = y + textSize.y;break;
case -2: y = y+cp.y/2 - Math.max( secondTextSize.y,secondTextSize.y/2 - hc.y);break; case 2: y = y+cp.y/2 - Math.max( secondTextSize.y,secondTextSize.y/2 - hc.y);break;
} }
if(element.hydrogenCount >1) { if(element.hydrogenCount >1) {
gc.drawText( Integer.toString( element.hydrogenCount), gc.drawText( Integer.toString( element.hydrogenCount),
Expand Down

0 comments on commit aeae2e8

Please sign in to comment.