Thuộc tính writing-mode dùng để đặt liệu các dòng văn bản được bố cục ngang hay dọc. Các giá trị:
writing-mode: horizontal-tb | vertical-rl | vertical-lr;
Ví dụ
<!DOCTYPE html> <html> <head> <style> p { writing-mode: vertical-rl; } </style> </head> <body> <h1>Demo Heading</h1> <p>This is demo text.</p> </body> </html>
Kết quả

Ví dụ khác
<!DOCTYPE html> <html> <head> <style> p.demo1 { word-spacing: 1cm; color: blue; writing-mode: vertical-rl; } p.demo2 { word-spacing: 40px; writing-mode: horizontal-tb; } </style> </head> <body> <h1>Demo Heading</h1> <h2>Heading2</h2> <p class="demo1">This is demo text.</p> <h2>Heading2</h2> <p class="demo2">This is demo text.</p> </body> </html>
Kết quả
