Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allow multi-character DirArrows #985

Merged
merged 5 commits into from
Apr 22, 2019
Merged

Allow multi-character DirArrows #985

merged 5 commits into from
Apr 22, 2019

Conversation

PhilRunninger
Copy link
Member

Fixes #931.

The problem with #931 was that the users specified DirArrows that were more than one character long to improve the spacing. This caused the indentation calculation to be incorrect.

The solution is to improve the algorithm that calculates indentation, treating multi-character DirArrows as one character for purposes of indentation calculation.

Phil Runninger (mac) added 5 commits April 18, 2019 11:34
Actually, it's up to the user to make sure it's a single character after
leading and trailing spaces are removed. Spaces need to be removed so
that an accurate level of indentation can be calculated.
1. Replace the DirArrows with a single space.
2. Count the leading spaces.
3. Divide by 2.

This allows users to specify multi-character arrows, where a spaces
prevent characters printing on top of each other.
@PhilRunninger PhilRunninger merged commit 9226eab into master Apr 22, 2019
@PhilRunninger PhilRunninger deleted the must_cd_before_open branch April 22, 2019 20:01
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.

cant open file unless in that directory?
1 participant