Did you know ...
Search Documentation:
Predicate get_style/3
HOME
DOWNLOAD
SWI-Prolog
Sources/building
Docker images
Add-ons
Browse GIT
DOCUMENTATION
Manual
Packages
FAQ
Command line
PlDoc
Bluffers
▶
Prolog syntax
PceEmacs
HTML generation
License
Publications
Rev 7 Extensions
TUTORIALS
Beginner
▶
Getting started
Learn Prolog Now!
Simply Logical
Debugger
Development tools
Advanced
▶
Modules
Grammars (DCGs)
clp(fd)
Printing messages
PlDoc
Web applications
▶
Web applications
Let's Encrypt!
Pengines
Semantic web
▶
ClioPatria
RDF namespaces
Graphics
▶
XPCE
GUI options
Machine learning
▶
Probabilistic Logic Programming
External collections
▶
Meta level tutorials
For packagers
▶
Linux packages
COMMUNITY
Forum & mailing list
Blog
News
Report a bug
Submit a patch
Submit an add-on
Roadmap (on GitHub)
External links
Contributing
Code of Conduct
Contributors
SWI-Prolog items
COMMERCIAL
WIKI
Login
View changes
Sandbox
Wiki help
All tags
Documentation
Reference manual
Using SWI-Prolog in your browser (WASM)
library(dialect/tau/dom): Tau-Prolog compatible DOM manipulation
add_class/2
append_child/2
attr/3
body/1
create/2
document/1
get_attr/3
get_attribute/3
get_by_class/2
get_by_class/3
get_by_id/2
get_by_name/2
get_by_tag/2
get_html/2
get_style/3
has_class/2
head/1
html/2
insert_after/2
insert_before/2
parent_of/2
prepend_child/2
remove/1
remove_class/2
set_attr/3
set_html/2
set_style/3
sibling/2
style/3
event_property/3
prevent_default/1
hide/1
show/1
toggle/1
unbind/2
bind/4
bind_async/4
Packages
[semidet]
get_style
(
+Elem, +Attr, =Value
)
True when
Value
is the computed value for the given style attribute. If the computed style is undefined,
Value
is unified to the element style. The DOM style string is translated into a Prolog term according to these rules:
px(N)
maps to Npx
’%’(N) maps to N%
url(URL)
maps to
url("URL")
rgb(R,G,B)
maps to
rgb(R,G,B)