Codea 3.12.5 (505)

@sim @jfperusse @John - latest version 4 has an issue with text placement - it displaces the text by an offset of half the text size after text.align(). Seen this with vertical am checking horizontal and will report later.

Edit: I think it ‘s if you place the text align size after the text size. Try moving it in the following code and add the offset to the vertical axis of half the text size to align properly

    style.stroke(233, 231, 80)
    style.strokeWidth(6)
    style.fill(232, 0, 255)
    rect(420, 880, 240,240)
    style.fill(51, 184, 20)
    rect(0.5*sW, 0.264*sH, 240, 240 )
    style.font("AmericanTypewriter-Bold")
    style.fill(0,0,0,0)
    style.stroke(255, 0, 234)
    style.strokeWidth(6)
    style.fill(80, 176, 233)
    style.ellipseMode(CENTER)
    ellipse(cW,cH,230,230)
    style.textAlign(CENTER)
    style.fontSize(64)
    style.fill(256,0,256)
    text("V4", cW, cH)

p.s. cW, cH = WIDTH//2, HEIGHT//2

1 Like

Interesting, good find, logging it in the bug tracker

try style.textAlign(CENTER + MIDDLE)

Didn’t work, don’t think MIDDLE is a reserved word. But, if your text is say 64 pixels in width the style.textAlign(CENTER + 32) does.

isn’t it style.textAlign(CENTER | MIDDLE)

MIDDLE, TOP, and BOTTOM were added for Carbide. However, the text highlighting and auto-completion/suggestion for them don’t work.

ALSO, it turns out that Carbide has the directions inverted in 3.12.5. Sim et all have been informed, can duplicate and are working on a fix. (see the Discord bugs channel for more info )

@Raleigh -:thanks for the info, haven’t picked up on that - I’ll dig into it could prove useful.

@sim @jfperusse @john - odd issue with renaming a project. After renaming a project by extending its name it disappears from the list of projects. Tapping one of the subdirectory ‘>’ symbols or tapping and running another project re-instates the missing renamed project.