0

I am trying to display a string in UILabel and UItextView but its not coming properly.This is my string

                         \|/                          
                       `--+--'                        
                         /|\                          
                        ' | '                         
                          |                           
                          |                           
                      ,--'#`--.                       
                      |#######|                       
                   _.-'#######`-._                    
                ,-'###############`-.                 
              ,'#####################`,               
             /#########################\              
            |###########################|             
           |#############################|            
           |#############################|            
           |#############################|            
           |#############################|            
            |###########################|             
             \#########################/              
              `.#####################,'               
                `._###############_,'                 
                   `--..#####..--'

but its coming properly in NSlog message.

   I am fetching from Database    

         NSString *image_string = [[NSString alloc] initWithUTF8String:(const char *) sqlite3_column_text(statement, 0)];

      image_string=[image_string stringByTrimmingCharactersInSet:[NSCharacterSet whitespaceCharacterSet]];

  textView.text = image_string;
4

1 回答 1

0

尝试这个:

[lblWeiredString setNumberOfLines:0];
[lblWeiredString setTextAlignment:NSTextAlignmentLeft];
lblWeiredString.text = image_string;
[lblWeiredString sizeToFit];
[lblWeiredString setCenter:CGPointMake(self.view.frame.size.width / 2.0, self.view.frame.size.height / 2.0)];
于 2013-02-19T06:58:47.703 回答