Skip to content

Commit

Permalink
Center circuit symbol better when painting custom gate
Browse files Browse the repository at this point in the history
  • Loading branch information
Strilanc committed Aug 15, 2017
1 parent 47cee2a commit ee074ec
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/ui/DisplayedCircuit.js
Original file line number Diff line number Diff line change
Expand Up @@ -131,7 +131,7 @@ class DisplayedCircuit {
*/
desiredWidth(forTooltip=false) {
if (forTooltip) {
return this.gateRect(1, this.circuitDefinition.columns.length).x + CIRCUIT_OP_LEFT_SPACING;
return this.opRect(this.circuitDefinition.columns.length - 1).right() + CIRCUIT_OP_LEFT_SPACING;
}
return this._rectForSuperpositionDisplay().right() + 101;
}
Expand Down

0 comments on commit ee074ec

Please sign in to comment.