• 1
  • 2
  • 3
  • 4
  • 5
  • 6
  • 7
  • 8
  • 9
  • 10
  • 11
  • 12
  • 13
  • 14
  • 15
  • 16
  • 17
  • 18
  • 19
  • 20
  • 21
  • 22
  • 23
  • 24
  • 25
  • 26
  • 27
  • 28
  • 29
  • 30
  • 31

###メール送信時、長い件名の場合は複数行に分割する

RFC2047によれば、「76文字以内で」複数行に分割すべき
http://www.securehtml.jp/utf-8/long_subject.html

全然知らなかったのですが、分割する必要があるそうです。

###全角チルダ(〜)などはdataUsingEncoding:NSISO2022JPStringEncodingで変換できない
NSStringの下記の関数を使って、ISO-2202-JPの文字列を作るのですが、全角チルダ(〜)などがあるとnilが返ってきてしまいます:

  • (NSData *)dataUsingEncoding:(NSStringEncoding)encoding

そういう場合はallowLossyConversion:YESにして、該当の文字を「?」で置き換える必要があります:

  • (NSData *)dataUsingEncoding:(NSStringEncoding)encoding allowLossyConversion:(BOOL)flag

###その他
色々調べている間に便利そうだったサイト。メモメモ。

Convert NSData to NSString or vise versa:
http://homepage.mac.com/mnishikata/objective-c_memo/convert_nsdata_to_nsstring_.html

特殊記号の読み方:
http://www1.odn.ne.jp/haru/data-list/mark.html

Unicode版 文字コード表:
http://www.m-hoz.com/jsp/unicode.jsp?Bgn=0&End=65536

NSString encoding problem with extended characters ( AKA : converting NSString to std::string)
http://lists.apple.com/archives/Syncservices-dev/2007/Mar/msg00020.html

[Perl]Perlで日本語(ISO-2022-JP)メールを送信(まとめ):
http://d.hatena.ne.jp/kopug/20060903

posted by satoko satoko on Mon 26 Oct 2009 at 06:02 with 0 comments
Contents rssrss
NSAssertやNSLogを無効にする:-DNS_BLOCK_ASSERTIONS=1とNS_BLOCK_ASSERTIONS
GDBでview.frameを表示させる
Core Animationについてのリンク集
[iPhone] new BSDライセンスについてライセンス引用のメモ
Implementing a Container View Controller in UIViewController Class Reference
UITableView用のNSIndexPathの作り方
Xcodeのテンプレート、View-based ApplicationとWindow-based Applicationの違い
CopyOnSelectのLion対応
Xcode4のCode Snippetsを別のPCに移動する+gitで管理する
[iPhone] Singleton: iOS4以降はGCDのdispatch_onceを使う
Tags
iphone開発gitIBInterfaceBuilderiOSSIMBLSnippetsterminaltwitterxcodeXcode4
Comments rssrss
https://buy-property-uae.com/ https://buy-property-uae.com/: Many international investors believe, in today's e... 04/24 00:16
https://www.gms4you.us/ https://www.gms4you.us/: Reliable reviews confirm, in today's world using l... 04/21 19:41
https://rootskitchen.bar/ https://rootskitchen.bar/: Finished a deadly evening session punting on crash... 04/18 12:17
https://rootskitchen.bar/ https://rootskitchen.bar/: Just wrapped up a cracking arvo session grinding c... 04/17 02:19
https://si-design.ru/o-nas https://si-design.ru/o-nas: Цена дизайн-проекта стабильна и не изменится к кон... 04/10 17:15
https://corporativ-luxe.ru/magiya-solnechnoy-kapli https://corporativ-luxe.ru/magiya-solnechnoy-kapli: Мы работаем для вас без выходных и праздников htt... 04/10 16:20
https://si-design.ru/reutov https://si-design.ru/reutov: Интерьер, оформленный в стиле модернизм, отличаетс... 04/08 06:24
https://sbornye-gruzy-kitay.ru/ https://sbornye-gruzy-kitay.ru/: Реально ли привезти косметику? Там же нужны особые... 04/08 03:06