Skip to content

color console output screws up length of string format when used with writefln #26

@SingingBush

Description

@SingingBush

I expected the following to output "Hello........World" but it comes out as "Hello.World"
(had to swap spaces for . due to markdown formatting)

import std.stdio, consoled;

alias GreenText = ColorTheme!(Color.green, Color.black);

void main() {
    writefln("%s %12s", "Hello" GreenText("World"));
}

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions