블로그 이미지
Every unexpected event is a path to learning for you. blueasa

카테고리

분류 전체보기 (2794)
Unity3D (852)
Programming (478)
Server (33)
Unreal (4)
Gamebryo (56)
Tip & Tech (234)
협업 (11)
3DS Max (3)
Game (12)
Utility (68)
Etc (98)
Link (32)
Portfolio (19)
Subject (90)
iOS,OSX (55)
Android (14)
Linux (5)
잉여 프로젝트 (2)
게임이야기 (3)
Memories (20)
Interest (38)
Thinking (38)
한글 (30)
PaperCraft (5)
Animation (408)
Wallpaper (2)
재테크 (18)
Exercise (3)
나만의 맛집 (3)
냥이 (10)
육아 (16)
Total
Today
Yesterday

 

////////////////////////////////////////////////////////////////
/// 0-9: 숫자 (0부터 9까지)
/// a-zA-Z: 영어 대소문자
/// 가-힣: 한글 완성형(가부터 힣까지의 모든 완성된 한글 음절)
/// [제외] ㄱ-ㅎ: 한글 자음(자음 'ㄱ'부터 'ㅎ'까지)
/// [제외] ㅏ-ㅣ: 한글 모음(모음 'ㅏ'부터 'ㅣ'까지)
/// ぁ-ゔ: 일본어 히라가나
/// ァ-ヴ: 일본어 가타카나
/// ー: 일본어 가타카나의 장음부호(ー)
/// 々〆〤: 일본어에서 사용되는 반복 문자 및 기타 기호
/// 一-龥: 한자(기본 한자 범위)
/// [결과] "0-9a-zA-Z가-힣ぁ-ゔァ-ヴー々〆〤一-龥"
//////////////////////////////////////////////////////////////// 
/// ऀ-ॿ: 힌디어(데바나가리 문자)
/// ก-๙: 태국어 문자
/// \u0600-\u06FF: 아랍어 문자
/// \u0400-\u04FF: 키릴 문자(러시아어 문자)
/// [결과] "0-9a-zA-Z가-힣ぁ-ゔァ-ヴー々〆〤一-龥ऀ-ॿก-๙\\u0600-\\u06FF\\u0400-\\u04FF"
////////////////////////////////////////////////////////////////

// 기존 허용하는 문자 외에는 Replace로 제거
Regex.Replace(_strString, @"[^a-zA-Z가-힣ぁ-ゔァ-ヴー々〆〤一-龥ऀ-ॿก-๙\u0600-\u06FF\u0400-\u04FF]", "");

 

[참조] https://codechacha.com/ko/csharp-remove-special-letters/

 

C# - 문자열에서 특수문자 제거

문자열에서 특수문자를 제거하거나, 특정 언어를 제외한 다른 언어를 제거하는 방법을 소개합니다. 정규표현식(Regex)를 이용한 방법 Regex.Replace(string, pattern, replacement)는 string에서 정규표현식 patt

codechacha.com

 

[참조] https://blog.naver.com/bassfrontier/221787732602

 

C# 에서의 정규식 (Regex) 특수문자의 입력 확인 방법

프로그램 내에서 입력 양식을 제공하고, 입력된 값을 검사하는 일은 꽤나 빈번하게 일어나는 일이다. 대부...

blog.naver.com

 

반응형
Posted by blueasa
, |

[링크] https://github.com/Unity-UI-Extensions/com.unity.uiextensions

 

GitHub - Unity-UI-Extensions/com.unity.uiextensions

Contribute to Unity-UI-Extensions/com.unity.uiextensions development by creating an account on GitHub.

github.com

 

반응형
Posted by blueasa
, |

 

 

RegExLib.com Regular Expression Cheat Sheet (.NET)

   

Character Escapes http://tinyurl.com/5wm3wlEscaped CharDescription

ordinary characters Characters other than . $ ^ { [ ( | ) ] } * + ? \ match themselves.
\a Matches a bell (alarm) \u0007.
\b Matches a backspace \u0008 if in a []; otherwise matches a word boundary (between \w and \W characters).
\t Matches a tab \u0009.
\r Matches a carriage return \u000D.
\v Matches a vertical tab \u000B.
\f Matches a form feed \u000C.
\n Matches a new line \u000A.
\e Matches an escape \u001B.
\040 Matches an ASCII character as octal (up to three digits); numbers with no leading zero are backreferences if they have only one digit or if they correspond to a capturing group number. (For more information, see Backreferences.) For example, the character \040 represents a space.
\x20 Matches an ASCII character using hexadecimal representation (exactly two digits).
\cC Matches an ASCII control character; for example \cC is control-C.
\u0020 Matches a Unicode character using a hexadecimal representation (exactly four digits).
\* When followed by a character that is not recognized as an escaped character, matches that character. For example, \* is the same as \x2A.

Character Classes http://tinyurl.com/5ck4llChar ClassDescription

. Matches any character except \n. If modified by the Singleline option, a period character matches any character. For more information, see Regular Expression Options.
[aeiou] Matches any single character included in the specified set of characters.
[^aeiou] Matches any single character not in the specified set of characters.
[0-9a-fA-F] Use of a hyphen (–) allows specification of contiguous character ranges.
\p{name} Matches any character in the named character class specified by {name}. Supported names are Unicode groups and block ranges. For example, Ll, Nd, Z, IsGreek, IsBoxDrawing.
\P{name} Matches text not included in groups and block ranges specified in {name}.
\w Matches any word character. Equivalent to the Unicode character categories [\p{Ll}\p{Lu}\p{Lt}\p{Lo}\p{Nd}\p{Pc}]. If ECMAScript-compliant behavior is specified with the ECMAScript option, \w is equivalent to [a-zA-Z_0-9].
\W Matches any nonword character. Equivalent to the Unicode categories [^\p{Ll}\p{Lu}\p{Lt}\p{Lo}\p{Nd}\p{Pc}]. If ECMAScript-compliant behavior is specified with the ECMAScript option, \W is equivalent to [^a-zA-Z_0-9].
\s Matches any white-space character. Equivalent to the Unicode character categories [\f\n\r\t\v\x85\p{Z}]. If ECMAScript-compliant behavior is specified with the ECMAScript option, \s is equivalent to [ \f\n\r\t\v].
\S Matches any non-white-space character. Equivalent to the Unicode character categories [^\f\n\r\t\v\x85\p{Z}]. If ECMAScript-compliant behavior is specified with the ECMAScript option, \S is equivalent to [^ \f\n\r\t\v].
\d Matches any decimal digit. Equivalent to \p{Nd} for Unicode and [0-9] for non-Unicode, ECMAScript behavior.
\D Matches any nondigit. Equivalent to \P{Nd} for Unicode and [^0-9] for non-Unicode, ECMAScript behavior.

 

 

[출처] https://regexlib.com/CheatSheet.aspx?AspxAutoDetectCookieSupport=1

 

RegExLib.com Regular Expression Cheat Sheet (.NET Framework)

\p{name}Matches any character in the named character class specified by {name}. Supported names are Unicode groups and block ranges. For example, Ll, Nd, Z, IsGreek, IsBoxDrawing.

regexlib.com

 

반응형
Posted by blueasa
, |