2011-09-29 3 views

답변

0

"-j"옵션을 사용 했습니까? 자바 지역화 된 문자열 (% 1 $ @과 같은 형식)을 생성합니다.

[편집]

죄송합니다. 잘못된 매뉴얼 페이지를 보았습니다. 위치 매개 변수 생성을 끄려면 -noPositionalParameters 옵션을 사용하십시오. ->Info's here

0

%[email protected]은 형식 문자열에 주어진 첫 번째 인수를 참조하기 때문에 다시 변경할 필요가 없습니다.

실제로 다른 경우에는 인수의 순서가 번역에서 다른 순서로 변경 될 수 있습니다. 코드가 형식을 사용하는 경우 예를 들어, 같은 일부 플레이어 속성 값을 표시합니다 :

let fmt = NSLocalizedString("Player property value", comment: "The player property value") 
String(format:fmt, playerName, playerProperty, value) 
당신은 "en.lproj/Localizable.strings"에있을 수 있습니다

:

/* The player property value */ 
"Player property value" = "Player %[email protected]'s %[email protected] is %3$d" 

과의 "에서 fr.lproj/Localizable.strings "

/* The player property value */ 
"Player property value" = "Le %[email protected] du joueur %[email protected] is %3$d" 

나 :

/* The player property value */ 
"Player property value" = "Le joueur %[email protected] a %3$d points de %[email protected]" 
관련 문제