File: center_text.go

package info (click to toggle)
golang-github-pterm-pterm 0.12.79-2
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 3,640 kB
  • sloc: makefile: 4
file content (8 lines) | stat: -rw-r--r-- 231 bytes parent folder | download
1
2
3
4
5
6
7
8
package putils

import "github.com/pterm/pterm/internal"

// CenterText returns a centered string with each line centered in respect to the longest line.
func CenterText(text string) string {
	return internal.CenterText(text, 0)
}