textproc/p5-Text-CharWidth 0.04_2
Get number of occupied columns of a string on terminal
- Repository
- FreeBSD ports
- Maintainer
- [email protected]
- License
- ART10, GPLv1+
- Categories
- textproc, perl5
- Package size
- 9.7 KiB, 18.2 KiB installed
Description
This module supplies features similar as wcwidth(3) and wcswidth(3) in C language.
Characters have its own width on terminal depending on locale. For example, ASCII characters occupy one column per character, east Asian fullwidth characters (like Hiragana or Han Ideograph) occupy two columns per character, and combining characters (apperaring in ISO-8859-11 Thai, Unicode, and so on) occupy zero columns per character. mbwidth() gives the width of the first character of the given string and mbswidth() gives the width of the whole given string.
The names of mbwidth and mbswidth came from "multibyte" versions of wcwidth and wcswidth which are "wide character" versions.
mblen(string) returns number of bytes of the first character of the string. Please note that a character may consist of multiple bytes in multibyte encodings such as UTF-8, EUC-JP, EUC-KR, GB2312, or Big5.
mbwidth(string) returns the width of the first character of the string. mbswidth(string) returns the width of the whole string.
Parameters are to be given in locale encodings, not always in UTF-8.
Install
As a binary package — by origin, or by package name:
pkg install textproc/p5-Text-CharWidth
pkg install p5-Text-CharWidth
From the ports tree:
cd /usr/ports/textproc/p5-Text-CharWidth/ && make install clean
To depend on this port in another port's Makefile:
RUN_DEPENDS= p5-Text-CharWidth>0:textproc/p5-Text-CharWidth
Packages
The version each package repository carries. “-” means the repository builds no package of it, “n/a” that there is no such repository.
| Repository | aarch64 | amd64 | armv6 | armv7 | i386 |
|---|---|---|---|---|---|
| FreeBSD:14:latest | 0.04_2 | 0.04_2 | 0.04_2 | 0.04_2 | 0.04_2 |
| FreeBSD:14:quarterly | 0.04_2 | 0.04_2 | n/a | 0.04_2 | 0.04_2 |
| FreeBSD:15:latest | 0.04_2 | 0.04_2 | n/a | 0.04_2 | 0.04_2 |
| FreeBSD:15:quarterly | 0.04_2 | 0.04_2 | n/a | n/a | n/a |
| FreeBSD:16:latest | 0.04_2 | 0.04_2 | n/a | n/a | n/a |
| FreeBSD:16:quarterly | n/a | n/a | n/a | n/a | n/a |
Dependencies
The Makefile names none itself; they come from USES and USE_*.
The full lists below include those, and their dependencies in turn.
All build dependencies 1
All run dependencies 1
Required by 35
- archivers/dpkg
- cad/kicad-doc
- finance/kraft
- games/colobot
- graphics/darktable
- misc/bibletime
- misc/freebsd-doc-bn
- misc/freebsd-doc-da
- misc/freebsd-doc-de
- misc/freebsd-doc-el
- misc/freebsd-doc-en
- misc/freebsd-doc-es
- misc/freebsd-doc-fr
- misc/freebsd-doc-hu
- misc/freebsd-doc-id
- misc/freebsd-doc-it
- misc/freebsd-doc-ja
- misc/freebsd-doc-ko
- misc/freebsd-doc-mn
- misc/freebsd-doc-nl
- misc/freebsd-doc-pl
- misc/freebsd-doc-pt
- misc/freebsd-doc-ru
- misc/freebsd-doc-tr
- misc/freebsd-doc-zh_cn
- misc/freebsd-doc-zh_tw
- multimedia/gtk-youtube-viewer
- security/fakeroot
- textproc/docproj
- textproc/p5-Text-Table-Any
- textproc/p5-Text-UnicodeBox
- textproc/p5-Text-WrapI18N
- textproc/po4a
- www/ikiwiki
- x11/tilix
Configuration
No options to configure.
- USES
- perl5
- Service scripts
- none
Files
pkg-plist 3
- %%SITE_ARCH%%/Text/CharWidth.pm
- %%SITE_ARCH%%/auto/Text/CharWidth/CharWidth.so
- %%PERL5_MAN3%%/Text::CharWidth.3.gz
distinfo 1
| File | Size | SHA256 |
|---|---|---|
| Text-CharWidth-0.04.tar.gz | 8387 | abded5f4fdd9338e89fd2f1d8271c44989dae5bf50aece41b6179d8e230704f8 |
Master sites 1
- CPAN
Commit history 0
No commits in the history this site was built from.