File tree Expand file tree Collapse file tree 1 file changed +6
-5
lines changed
Expand file tree Collapse file tree 1 file changed +6
-5
lines changed Original file line number Diff line number Diff line change 22 * @module Typography
33 */
44
5- import { textCoreConstants } from './textCore.js' ;
5+ import { textCoreConstants } from './textCore' ;
6+ import * as constants from '../core/constants' ;
67
78/*
89 API:
@@ -329,19 +330,19 @@ class Font {
329330 let x = bounds . x ;
330331 let y = bounds . y + ( i * textLeading ) + ascent ;
331332 let lineWidth = renderer . _fontWidthSingle ( text ) ;
332- if ( textAlign === fn . CENTER ) {
333+ if ( textAlign === constants . CENTER ) {
333334 x += ( bounds . w - lineWidth ) / 2 ;
334335 }
335- else if ( textAlign === fn . RIGHT ) {
336+ else if ( textAlign === constants . RIGHT ) {
336337 x += ( bounds . w - lineWidth ) ;
337338 }
338339 if ( typeof width !== 'undefined' ) {
339340 switch ( renderer . states . rectMode ) {
340- case fn . CENTER :
341+ case constants . CENTER :
341342 x -= width / 2 ;
342343 y -= height / 2 ;
343344 break ;
344- case fn . RADIUS :
345+ case constants . RADIUS :
345346 x -= width ;
346347 y -= height ;
347348 break ;
You can’t perform that action at this time.
0 commit comments