Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
Using KSScreenshotManager
Search
Sponsored
·
Ship Features Fearlessly
Turn features on and off without deploys. Used by thousands of Ruby developers.
→
Chuck Shnider
June 16, 2013
Programming
0
94
Using KSScreenshotManager
Slides from my talk at Ottawa Cocoaheads on March 14, 2013.
Chuck Shnider
June 16, 2013
Tweet
Share
More Decks by Chuck Shnider
See All by Chuck Shnider
A look back at GameDev on Apple II
chucks
0
610
Fun With Auto Layout
chucks
0
130
Introducing Skateway 2.0
chucks
0
51
Other Decks in Programming
See All in Programming
The Past, Present, and Future of Enterprise Java
ivargrimstad
0
340
ご飯食べながらエージェントが開発できる。そう、Agentic Engineeringならね。
yokomachi
1
280
モジュラモノリスにおける境界をGoのinternalパッケージで守る
magavel
0
3.4k
RAGでハマりがちな"Excelの罠"を、データの構造化で突破する
harumiweb
8
2.3k
Ruby x Terminal
a_matsuda
5
550
Go1.26 go fixをプロダクトに適用して困ったこと
kurakura0916
0
320
「ブロックテーマでは再現できない」は本当か?
inc2734
0
1.1k
AI時代のソフトウェア開発でも「人が仕様を書く」から始めよう-医療IT現場での実践とこれから
koukimiura
0
130
Python’s True Superpower
hynek
0
190
「やめとこ」がなくなった — 1月にZennを始めて22本書いた AI共創開発のリアル
atani14
0
340
24時間止められないシステムを守る-医療ITにおけるランサムウェア対策の実際
koukimiura
2
180
TipKitTips
ktcryomm
0
150
Featured
See All Featured
Leadership Guide Workshop - DevTernity 2021
reverentgeek
1
220
Hiding What from Whom? A Critical Review of the History of Programming languages for Music
tomoyanonymous
2
480
Getting science done with accelerated Python computing platforms
jacobtomlinson
2
130
Marketing Yourself as an Engineer | Alaka | Gurzu
gurzu
0
140
Information Architects: The Missing Link in Design Systems
soysaucechin
0
810
A Soul's Torment
seathinner
5
2.4k
The Web Performance Landscape in 2024 [PerfNow 2024]
tammyeverts
12
1k
Creating an realtime collaboration tool: Agile Flush - .NET Oxford
marcduiker
35
2.4k
Documentation Writing (for coders)
carmenintech
77
5.3k
The AI Revolution Will Not Be Monopolized: How open-source beats economies of scale, even for LLMs
inesmontani
PRO
3
3.1k
Effective software design: The role of men in debugging patriarchy in IT @ Voxxed Days AMS
baasie
0
240
Believing is Seeing
oripsolob
1
68
Transcript
KSScreenshotManager Chuck Shnider twi er: @cshnider ∑
It starts small enough…
None
None
None
None
We’re Gonna Need a Bigger Slide…
None
Production Work
Heaven forbid you have to update them later!
KSScreenshotManager wri en by Kent Sutherland from Flexibits twi er:
@KSuther
@KSuther
h ps://github.com/ksuther/KSScreenshotManager Open-Source
KSScreenshotManager •Make your code generate the screenshots •Fully-Automated •Runnable from
scripting environments •Sample Python Script included •Uses “WaxSim” to drive the iOS Simulator
Like Test Automation •Not “For Free” •Cheaper to repeat over
time •Effort scales more slowly than manual screenshots
Modifying Your Code •WARNING Private API Usage! •Make sure none
of this ships to the AppStore •Conditional Compile and perhaps use a new target
Modifying Your Code •Add KSScreenshotManager and KSScreenshotAction.h / .m to
your project. #de ne CREATING_SCREENSHOTS
Modifying Your Code •Create a subclass of KSScreenshotManager •Override -(void)setupScreenshotActions;
setupScreenshotActions •Create instances of KSScreenshotAction •block-based API with optional cleanup
blocks •synch or async, status bar or no [self addScreenshotAction:newAction];
KSScreenshotAction block •Get the app to the correct state •Cheat
as necessary •Fake Data, Mock Objects, etc. •Private APIs, both app and OS
AppDelegate Changes #if CREATING_SCREENSHOTS dispatch_time_t popTime = dispatch_time(DISPATCH_TIME_NOW, (int64_t)(2.0 *
NSEC_PER_SEC)); dispatch_after(popTime, dispatch_get_main_queue(), ^(void){ MyScreenshotManager *screenshotManager = [[MyScreenshotManager alloc] init]; [screenshotManager setTableViewController:viewController]; [screenshotManager takeScreenshots]; }); #endif
Demo