Skip to content

magiczzz07/LogView

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

10 Commits
 
 
 
 
 
 
 
 

Repository files navigation

LogView

Using

Initializing

First off, make a global variable LogView *logView;

To initialize the newly created logView use the -(void)initWithFrame:(CGRect) maxLines:(unsigned int) method. Here is an example:

CGRect screen = [[UIScreen mainScreen] bounds];
logView = [[LogView alloc] initWithFrame:screen maxLines:12];
[[[UIApplication sharedApplication] keyWindow] addSubview:logView];
[[[UIApplication sharedApplication] keyWindow] bringSubviewToFront:logView];

How to log

To log use the -(void)log:(NSString*) method. To log variables or other fun stuff use the stringWithFormat: method from NSString. Here is an example:

unsigned int myValue = 12;
[logView log:[NSString stringWithFormat:@"myValue is stored at %p with value %d", &myValue, myValue]];

Known Issues

  • Makes target app slow. (Reduces FPS probably due to memory being constantly updated)

About

Logging made easy

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Objective-C++ 86.7%
  • Objective-C 13.3%