Skip to content

Conversation

igorocampos
Copy link
Collaborator

@igorocampos igorocampos commented Jan 26, 2024

Addresses suggestions of #210 and #147

A new property that holds the column count so it's easier to write horizontal line and align texts to both left and right on the same line.

{
public abstract partial class BaseCommandEmitter : ICommandEmitter
{
public int Columns { get; set; } = 42;
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I wasn't sure about the default for this, 42 columns is what the majority of printers I dealt with in Brazil had, but as an alternative, we could just not set any default value for the property, make it a getter-only property and force the constructor to receive the column count. However that would be a breaking change, so between having a random number as default and breaking existing code from others, I decided to stick with a default value.

What do you think @lukevp ?

@igorocampos igorocampos requested a review from lukevp January 26, 2024 15:58
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant