Page Menu
Home
DevCentral
Search
Configure Global Search
Log In
Files
F2227963
Parse CSS
No One
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Flag For Later
Authored By
dereckson
May 26 2023, 02:06
2023-05-26 02:06:46 (UTC+0)
Size
265 B
Referenced Files
None
Subscribers
None
Parse CSS
View Options
import tinycss2
with open('data/SourceSansPro.css', "rb") as fd:
css = fd.read()
rules = tinycss2.parse_stylesheet_bytes(css)
print(rules)
print(rules[0])
print(rules[0][0])
print(rules[0][0].content)
for node in rules[0][0].content:
print(node)
File Metadata
Details
Attached
Mime Type
text/plain; charset=utf-8
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
1400983
Default Alt Text
Parse CSS (265 B)
Attached To
Mode
P335 Parse CSS
Attached
Detach File
Event Timeline
Log In to Comment