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
?
Search
Keishin Yokomaku
February 18, 2015
Technology
2
470
?
Keishin Yokomaku
February 18, 2015
Tweet
Share
More Decks by Keishin Yokomaku
See All by Keishin Yokomaku
One screen, many BottomSheets
keithyokoma
0
350
LazyColumnのitemがViewPortの中で占める領域の割合を知りたい
keithyokoma
0
590
Build apps for Cars
keithyokoma
0
480
Save the state
keithyokoma
0
530
Either in Kotlin
keithyokoma
0
540
持続的なアプリ開発のためのDXを支える技術
keithyokoma
2
5k
Make the objects serializable with kotlinx.serialization
keithyokoma
0
5k
Kotlin で書く Gradle Custom Tasks
keithyokoma
0
510
DX Improvements
keithyokoma
3
380
Other Decks in Technology
See All in Technology
Visualize, Visualize, Visualize and rclone
tomoaki0705
9
76k
クラウドサービス事業者におけるOSS
tagomoris
3
980
サイト信頼性エンジニアリングとAmazon Web Services / SRE and AWS
ymotongpoo
2
380
人はなぜISUCONに夢中になるのか
kakehashi
PRO
6
1.8k
Apache Iceberg Case Study in LY Corporation
lycorptech_jp
PRO
0
260
Potential EM 制度を始めた理由、そして2年後にやめた理由 - EMConf JP 2025
hoyo
2
1.7k
遷移の高速化 ヤフートップの試行錯誤
narirou
6
950
Perlの生きのこり - エンジニアがこの先生きのこるためのカンファレンス2025
kfly8
1
250
PHPカンファレンス名古屋-テックリードの経験から学んだ設計の教訓
hayatokudou
2
530
コンピュータビジョンの社会実装について考えていたらゲームを作っていた話
takmin
1
570
脳波を用いた嗜好マッチングシステム
hokkey621
0
280
分解して理解する Aspire
nenonaninu
2
750
Featured
See All Featured
Building Applications with DynamoDB
mza
93
6.2k
Music & Morning Musume
bryan
46
6.4k
[RailsConf 2023 Opening Keynote] The Magic of Rails
eileencodes
28
9.3k
Building Your Own Lightsaber
phodgson
104
6.2k
The Cost Of JavaScript in 2023
addyosmani
47
7.3k
Thoughts on Productivity
jonyablonski
69
4.5k
The Psychology of Web Performance [Beyond Tellerrand 2023]
tammyeverts
46
2.3k
Testing 201, or: Great Expectations
jmmastey
42
7.2k
個人開発の失敗を避けるイケてる考え方 / tips for indie hackers
panda_program
100
18k
Chrome DevTools: State of the Union 2024 - Debugging React & Beyond
addyosmani
4
360
Making Projects Easy
brettharned
116
6k
Easily Structure & Communicate Ideas using Wireframe
afnizarnur
193
16k
Transcript
? @KeithYokoma - Drivemode, Inc. potatotips #14
KeithYokoma Keishin Yokomaku Drivemode, Inc. Android Engineer GitHub: https://github.com/KeithYokoma Qiita:
http://qiita.com/KeithYokoma e-Book: http://amzn.to/1mZNydv
?
<RelativeLayout xmlns:android=“http://schemas.android.com/apk/res/android" android:layout_width=“match_parent” android:layout_height=“wrap_content” android:minHeight=“?android:attr/listPreferredItemHeight”> <!—— content ——> </RelativeLayout>
<RelativeLayout xmlns:android=“http://schemas.android.com/apk/res/android" android:layout_width=“match_parent” android:layout_height=“wrap_content” android:minHeight=“?android:attr/listPreferredItemHeight”> <!—— content ——> </RelativeLayout>
<RelativeLayout xmlns:android=“http://schemas.android.com/apk/res/android" android:layout_width=“match_parent” android:layout_height=“wrap_content” android:minHeight=“?android:attr/listPreferredItemHeight”> <!—— content ——> </RelativeLayout>
?
Referencing style attributes Allows us to reference the value of
the attribute in the currently-applied theme. Format: ?[<package_name>:][<resource_type>/]<resource_name>
<RelativeLayout xmlns:android=“http://schemas.android.com/apk/res/android" android:layout_width=“match_parent” android:layout_height=“wrap_content” android:minHeight=“?android:attr/listPreferredItemHeight”> <!—— content ——> </RelativeLayout> <resources>
<style name=“MyTheme” parent=“Theme.Light”> <item name=“android:listPreferredItemHeight”>64dp</item> </style> </resources>
<RelativeLayout xmlns:android=“http://schemas.android.com/apk/res/android" android:layout_width=“match_parent” android:layout_height=“wrap_content” android:minHeight=“?android:attr/listPreferredItemHeight”> <!—— content ——> </RelativeLayout> <resources>
<style name=“MyTheme” parent=“Theme.Light”> <item name=“android:listPreferredItemHeight”>64dp</item> </style> </resources>
<RelativeLayout xmlns:android=“http://schemas.android.com/apk/res/android" android:layout_width=“match_parent” android:layout_height=“wrap_content” android:minHeight=“64dp”> <!—— content ——> </RelativeLayout> <resources>
<style name=“MyTheme” parent=“Theme.Light”> <item name=“android:listPreferredItemHeight”>64dp</item> </style> </resources>
Your own “?”
<resources> <attr name=“my_custom_attribute” format=“reference”/> </resources>
<RelativeLayout xmlns:android=“http://schemas.android.com/apk/res/android" android:layout_width=“match_parent” android:layout_height=“wrap_content” android:minHeight=“?attr/my_custom_attribute”> <!—— content ——> </RelativeLayout>
<RelativeLayout xmlns:android=“http://schemas.android.com/apk/res/android" android:layout_width=“match_parent” android:layout_height=“wrap_content” android:minHeight=“?attr/my_custom_attribute”> <!—— content ——> </RelativeLayout> <resources>
<style name=“MyTheme” parent=“Theme.Light”> <item name=“my_custom_attribute”>64dp</item> </style> </resources>
<RelativeLayout xmlns:android=“http://schemas.android.com/apk/res/android" android:layout_width=“match_parent” android:layout_height=“wrap_content” android:minHeight=“?attr/my_custom_attribute”> <!—— content ——> </RelativeLayout> <resources>
<style name=“MyTheme” parent=“Theme.Light”> <item name=“my_custom_attribute”>64dp</item> </style> </resources>
<RelativeLayout xmlns:android=“http://schemas.android.com/apk/res/android" android:layout_width=“match_parent” android:layout_height=“wrap_content” android:minHeight=“64dp”> <!—— content ——> </RelativeLayout> <resources>
<style name=“MyTheme” parent=“Theme.Light”> <item name=“my_custom_attribute”>64dp</item> </style> </resources>
Abstract Theme Using style attributes reference. ✓ Reduce costs to
change styles ✓ Reusable styling
themes_holo.xml <resources> <style name=“Theme.Holo”> <—— … ——> <item name="colorPrimary">@color/holo_primary</item> <item
name=“colorEdgeEffect”>?attr/colorPrimary</item> <—— … ——> </style> </resources>
themes_holo.xml <resources> <style name=“Theme.Holo.Light” parent=“Theme.Light”> <—— … ——> <item name="colorPrimary">@color/holo_light_primary</item>
<—— … ——> </style> </resources>
themes_holo.xml <resources> <style name=“Theme.Holo.Light” parent=“Theme.Light”> <—— … ——> <item name="colorPrimary">@color/holo_light_primary</item>
<—— … ——> </style> <style name=“Theme.Holo.Light.DarkActionBar"> </style> </resources>
–Ryan Brush “Code is design”
? @KeithYokoma - Drivemode, Inc. potatotips #14