GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — GitHub - BetterAndroid/PanguText: A typographic solution for the optimal alignment of CJK characters, English words, and half-width digits.

BranchesTags
Open more actions menu

Latest commit

 

History

99 Commits
99 Commits

Folders and files

NameName
Last commit message
Last commit date
.github/workflows
.github/workflows
 
 
.idea
.idea
 
 
docs-source
docs-source
 
 
gradle
gradle
 
 
img-src
img-src
 
 
pangutext-android
pangutext-android
 
 
samples/demo-android
samples/demo-android
 
 
.editorconfig
.editorconfig
 
 
.gitignore
.gitignore
 
 
LICENSE
LICENSE
 
 
README-zh-CN.md
README-zh-CN.md
 
 
README.md
README.md
 
 
build.gradle.kts
build.gradle.kts
 
 
gradle.properties
gradle.properties
 
 
gradlew
gradlew
 
 
gradlew.bat
gradlew.bat
 
 
settings.gradle.kts
settings.gradle.kts
 
 

Repository files navigation

Pangu Text

GitHub license Telegram QQ

LOGO

A typographic solution for the optimal alignment of CJK characters, English words, and half-width digits.

English | 简体中文

LOGO BetterAndroid

This project belongs to the organization above. Click the link to follow us and discover more awesome projects.

Project Reason

This project was created because, until now, there hasn’t been a public solution to perfectly address the typography issues between Chinese, Japanese, Korean, and English. Typically, when mixing CJK (i.e. Chinese, Japanese, Korean) with English, aesthetic issues can arise—a historical legacy stemming from the differences in writing conventions between full-width and half-width characters. Although the W3C has now established CJK typography guidelines, only a few individuals or companies willing to adhere to these standards have adopted this approach.

Currently, the known vendor solutions are as follows:

  • Apple platforms (iOS, iPadOS, macOS, tvOS, watchOS) text typography solutions
  • Xiaomi’s (HyperOS) text typography optimization
  • OrginOS’s font-based text typography optimization

However, these solutions are closed and cannot be implemented on other platforms. We aim to provide an open-source solution adaptable to various scenarios, featuring low intrusiveness and easy integration, allowing more developers to effectively address text typography issues.

The primary inspiration for this project comes from pangu.js, which offers a set of regular expressions for CJK typography. We have optimized these solutions to format text across platforms without inserting extra space characters. We extend this approach further to explore additional possibilities.

Heartfelt thanks to the original developer of pangu.js for providing the foundational solution.

Effects

As you can see, the typography scheme of PanguText does not work by simply inserting spaces between CJK characters and English words. Instead, it leverages each platform's native handling to automatically add whitespace between these characters, ensuring minimal intrusion.

Before Applying (Top) vs. After Applying (Bottom)

Dynamic Application

PanguText supports dynamic application, which means it can add whitespace gaps to each character on-the-fly as you input text.

Get Started

LOGO PanguText Documentation

You can go to the documentation page for more detailed tutorials and content.

What's next?

  1. Add dependencies: Add the corresponding platform modules to your project.
  2. Sync the project: After a Gradle sync, you can start using PanguText.

In the opened page, select the Quick Start section in the sidebar to continue reading.

More Projects

Hey, wait a second! 👋

If this project was helpful, why not stick around and check out more of my work below?

Feel free to leave a follow or a star ⭐️ if they bring you value!

→ Click here to discover more of my projects ←

Star History

Star History Chart

License

  • Apache-2.0
Apache License Version 2.0

Copyright (C) 2019 HighCapable

Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at

    https://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.

Copyright © 2019 HighCapable

About

A typographic solution for the optimal alignment of CJK characters, English words, and half-width digits.

betterandroid.github.io/PanguText/

Topics

androidappkotlinpangu-spacingtext-spacingtypography

Resources

Readme
Apache-2.0 license
Activity
Custom properties

Stars

34 stars

Watchers

1 watching

Forks

0 forks
Report repository

Releases

Packages

Used by

Contributors

Languages

You are visitor 01402503 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.