Skip to content

Commit 92208eb

Browse files
authored
Update README.md
1 parent 251142c commit 92208eb

1 file changed

Lines changed: 41 additions & 0 deletions

File tree

README.md

Lines changed: 41 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,45 @@
1+
## Why
2+
Default Unity's property look:
3+
4+
<img width="635" height="129" alt="image" src="https://github.com/user-attachments/assets/bbe845ac-b6b1-4880-bc28-710a70d54274" />
5+
6+
Clean and easier to use drawer:
7+
8+
<img width="636" height="160" alt="image" src="https://github.com/user-attachments/assets/7511cfcf-9161-42e8-8ab6-a4bb7d378216" />
9+
10+
All you need to do is mark `LocalizedString` field with `[CleanLocalizedString]` attribute:
11+
```c#
12+
using UnityEngine;
13+
using UnityEngine.Localization;
14+
using CleanLocalizedStringInspector;
15+
16+
public class SampleScript : MonoBehaviour
17+
{
18+
public LocalizedString defaultDrawer;
19+
20+
[CleanLocalizedString] // Single line
21+
public LocalizedString cleanDrawer;
22+
23+
[CleanLocalizedString(lineCount: 3)] // Multiline
24+
public LocalizedString cleanDrawerMultiline;
25+
}
26+
```
27+
28+
## Warning: Work-In-Progress
29+
This is not a battle-tested solution, but rather a quick prototype made in two evenings.
30+
31+
## More features
32+
- quickly clean table entry reference.
33+
- quickly create a new entry by simply typing into the text field.
34+
- set table reference where to put new localization keys per field.
35+
- context-aware key name generation using templates.
36+
137
## Installation
238
Install via git url by adding this entry in your **manifest.json**
339

440
`"com.starasgames.unity-clean-localized-string-inspector": "https://github.com/STARasGAMES/com.starasgames.unity-clean-localized-string-inspector.git#upm"`
41+
42+
## Credits
43+
44+
Based on this brilliant code by Thomas "noio" van den Berg:
45+
https://gist.github.com/noio/98a2b480321128ee4926973e33da0381

0 commit comments

Comments
 (0)