Commit Graph

951 Commits

Author SHA1 Message Date
Yuri Kobets
14666553c1
Merge pull request #215 from TobiasBohnen/TobiasBohnen-fix-text-transform
fix missing text-transform
2022-10-14 19:11:38 +03:00
TobiasBohnen
f23c87b15b
fix missing text-transform 2022-10-14 13:14:04 +02:00
Yuri Kobets
7e9fda4a86 parsing flex related CSS properties 2022-10-11 23:57:05 +03:00
Yuri Kobets
e4d2ff9931 don't create rendering item for comments 2022-10-11 23:07:50 +03:00
Yuri Kobets
31cb197eef Added support for "text-align: justify".
Remove empty elements from the end of linebox to improve alignment.
2022-10-11 00:16:38 +03:00
Yuri Kobets
1aeade0c8c fixed: memory leak in container_linux::text_width 2022-09-27 17:41:50 +03:00
Yuri Kobets
b418ffa60e Windows: replace _snwprintf/snprintf with _snwprintf_s/_snprintf_s 2022-09-17 23:55:42 +03:00
Yuri Kobets
ff0e7c73bd Fixed: compilation is failed on Windows 2022-09-17 23:44:43 +03:00
Yuri Kobets
a4aae391fa
Merge pull request #211 from tig/fix_litehtmlsharp
Fixes LiteHtmlSharp build
2022-09-14 00:57:45 +03:00
Yuri Kobets
e56cd9b730
Internal refactoring (#212)
* Refactored CSS properties

All CSS related properties are moved into the separate class css_properties.
Getters and setters are removed from classes element and html_tag.
Access to the css_properties rleased via css() [ro] and css_w() [rw] methods

* fix: el_text don't have to copy all css properties from parent

* Refactored rendering code

* Added flex and inline_flex values for display css property

* Implementing box generation

https://www.w3.org/TR/CSS22/visuren.html#box-gen

* Split inlines on block box inside

* Split parsing and rendering trees.

* Fixed some bugs

* Fixed: impossible to click urls on Obama wiki's toc

* Make element::get_placement work again

* Fixed: incorrect rendering table captions

* find_styles_changes function returned to the element class

* set parent correctly during render items split

* fixed urls on https://en.cppreference.com/w/cpp/container/vector

* fixed rendering blocks with width in percents

Example:
https://web.archive.org/web/20110101155107/http://www.unicode.org/
Issue #208

* Fixed placement of blocks with "overflow: hidden" with floating boxes.

* refactoring of rendering block

* Selectors :before and :after returned back with fixed behaviour.

* fixed render_item::is_last_child_inline

* fixed: text inside nested inlines has extra paddings/margins

* fixed documet test
2022-09-14 00:39:44 +03:00
Tig Kindel
acd5615383 Fixes building LiteHtmlSharp post separating src/indlude dirs 2022-08-10 16:35:13 -06:00
Tig Kindel
d51d7c7b25 Merge branch 'tig_merge' 2022-08-10 15:30:17 -06:00
Tig Kindel
62d80a332d Upgraded to VS2022 2022-08-10 15:28:59 -06:00
Tig Kindel
8aa119c59b removed .orig files 2022-08-10 15:18:56 -06:00
Tig Kindel
1c4c9b49a8 merge 2022-08-10 15:17:19 -06:00
Yuri Kobets
436f49c07c
Merge pull request #207 from txgk/master
Add EXTERNAL_GTEST option in CMakeLists.txt
2022-06-24 22:36:58 +03:00
Grigory Kirillov
cc724cc33a Add EXTERNAL_GTEST option in CMakeLists.txt
EXTERNAL_GTEST option allows to use external GoogleTest instead of
fetching it from GitHub
2022-06-24 15:19:14 +03:00
Yuri Kobets
43af58e8ad
Merge pull request #203 from stasoid/master
fix list index overflow
2022-04-05 23:49:06 +03:00
stasoid
c7a329e7dc remove .clang-format
Looks like it was checked in by accident
2022-04-05 21:31:36 +06:00
stasoid
9e34db38f2 fix list index overflow
This is visible on https://en.wikipedia.org/wiki/Obama, which has an ordered list with more than 256 items
2022-04-05 21:24:41 +06:00
Yuri Kobets
63014557d7
Merge pull request #202 from stasoid/master
fixes for wikipedia
2022-04-01 02:11:21 +03:00
stasoid
55071070f6 fix font size on wikipedia
page: https://en.wikipedia.org/wiki/Obama
problem: font is too small
culprit: font-size:calc(1em * 0.875);

This is a partial fix: calc is unsupported, so the above declaration should be ignored completely,
but instead it sets font-size to that of a parent, so this code doesn't work as intended:
font-size:0.875em;font-size:calc(1em * 0.875);
2022-03-26 20:47:26 +06:00
stasoid
6b55a1b852 cosmetics 2022-03-26 20:36:05 +06:00
stasoid
ea3c8f7f33 cairo_container: fix handling of invalid list-style-image
page: https://en.wikipedia.org/wiki/UTF-8#Invalid_sequences_and_error_handling
culprit: ul{list-style-image:url(/w/skins/Vector/resources/common/images/bullet-icon.svg?d4515)}
(invalid because svg is not supported)
2022-03-26 20:12:55 +06:00
Yuri Kobets
ab66cb0999
Update README.md 2022-03-21 00:22:39 +03:00
Yuri Kobets
7e0241d2f4
Merge pull request #201 from stasoid/master
add var() and :root; remove xxd; fix floated table
2022-03-20 03:46:16 +03:00
stasoid
9c2c6fffa2 fix test 2022-03-19 09:30:22 +06:00
stasoid
3bef883879 fix #200 2022-03-19 08:56:59 +06:00
stasoid
0d8b75f3bd remove xxd
Use pure CMake solution as described here: https://stackoverflow.com/questions/410980/include-a-text-file-in-a-c-program-as-a-char/47801116#47801116
2022-03-17 21:53:01 +06:00
stasoid
e2b7f762d7 :root 2022-03-17 10:56:55 +06:00
stasoid
5a00888bbc var() 2022-03-17 10:37:42 +06:00
Yuri Kobets
9898cc633b
Merge pull request #197 from stasoid/master
Fix table issues
2022-03-13 22:59:52 +03:00
stasoid
9955e9f287 Revert "fix #199"
This reverts commit c161a0220d.

In Chrome <div align=center> sets text-align to -webkit-center, which centers both inline and block-level children.
text-align:center aligns only inline children.
2022-03-13 01:03:34 +06:00
stasoid
c161a0220d fix #199 2022-03-10 01:05:43 +06:00
stasoid
48a5496da0 fix #198 2022-03-09 10:14:34 +06:00
stasoid
315738cc4d fix blockquote 2022-03-08 20:48:26 +06:00
stasoid
e5f9beae05 fix #196 2022-03-08 20:47:12 +06:00
Yuri Kobets
759123b487
Merge pull request #195 from stasoid/master
Fix table issues #193 #194
2022-03-04 22:31:02 +03:00
stasoid
c8a4ee6f72 fix #194
Also fixes rendering of this HTML:
<table width=100px border=1>
<tr><td>aaa<td style="display:none">bbb<td>ccc

and this HTML:
<style>p{display:table-cell}</style>
<p>aaa</p><!----><p>bbb</p>

and improves rendering of this HTML:
<style>
p{display:table-cell}
span{white-space:pre}
</style>
<span>
<p>aaa</p>  <p>bbb</p>
2022-03-04 21:21:24 +06:00
stasoid
319b59ea14 fix #193 2022-03-04 20:27:54 +06:00
Yuri Kobets
051b5a5247
Merge pull request #186 from silversquirl/master
fix media_changed doing nothing when no media queries are present
2022-03-01 14:52:00 +03:00
Yuri Kobets
37ab92e4ce
Merge pull request #192 from stasoid/master
Fix nonstandard behavior of :before :after
2022-03-01 14:51:13 +03:00
stasoid
aad0a8ce0a fixes #191 2022-03-01 16:44:08 +06:00
Yuri Kobets
e3f37e3d5a
Merge pull request #188 from Waqar144/work/fix-order-list-start
Handle start attribute in ordered lists
2022-02-22 19:57:29 +03:00
Yuri Kobets
992a8905f9
Merge pull request #190 from cotn666/mingw_build_fix
Fix MinGW build
2022-02-22 19:50:31 +03:00
cotn666
f27e69b0b3
Fix MinGW build 2022-02-22 10:44:25 +01:00
Waqar Ahmed
b0d39ce6dd Handle start attribute in ordered lists
Handles the start attribute in:

```html
<ol start=2>
<li>xyz</li>
</ol>
```
2022-02-14 23:04:05 +05:00
Silver
3394fb521a fix media_changed doing nothing when no media queries are present
It should still update the document's media features
2022-02-01 16:18:31 +00:00
Yuri Kobets
e7fa81d19b
Merge pull request #185 from SwedishChef/fix_white-space_pre-wrap
fixed style property 'white-space: pre-wrap'
2021-12-29 11:49:48 +03:00
wih1hi
e91823d438 fixed style property 'white-space: pre-wrap' 2021-12-28 13:13:06 +01:00