Avi Drissman | 4e1b7bc3 | 2022-09-15 14:03:50 | [diff] [blame] | 1 | // Copyright 2016 The Chromium Authors |
Scott Violet | fdda96d | 2018-07-27 20:17:23 | [diff] [blame] | 2 | // Use of this source code is governed by a BSD-style license that can be |
| 3 | // found in the LICENSE file. |
| 4 | |
danakj | 89f4708 | 2020-09-02 17:53:43 | [diff] [blame] | 5 | #ifndef CONTENT_WEB_TEST_RENDERER_LAYOUT_DUMP_H_ |
| 6 | #define CONTENT_WEB_TEST_RENDERER_LAYOUT_DUMP_H_ |
Scott Violet | fdda96d | 2018-07-27 20:17:23 | [diff] [blame] | 7 | |
| 8 | #include <string> |
| 9 | |
Scott Violet | fdda96d | 2018-07-27 20:17:23 | [diff] [blame] | 10 | namespace blink { |
| 11 | class WebLocalFrame; |
| 12 | } // namespace blink |
| 13 | |
danakj | 741848a | 2020-04-07 22:48:06 | [diff] [blame] | 14 | namespace content { |
Scott Violet | fdda96d | 2018-07-27 20:17:23 | [diff] [blame] | 15 | |
danakj | 049cb6a | 2020-07-11 03:11:34 | [diff] [blame] | 16 | enum class TextResultType { |
| 17 | kEmpty, |
| 18 | kText, |
| 19 | kMarkup, |
| 20 | kLayout, |
| 21 | kLayoutAsPrinting, |
| 22 | }; |
| 23 | |
Scott Violet | fdda96d | 2018-07-27 20:17:23 | [diff] [blame] | 24 | // Dumps textual representation of |frame| contents. Exact dump mode depends |
| 25 | // on |flags| (i.e. dump_as_text VS dump_as_markup and/or is_printing). |
danakj | 741848a | 2020-04-07 22:48:06 | [diff] [blame] | 26 | std::string DumpLayoutAsString(blink::WebLocalFrame* frame, |
danakj | 049cb6a | 2020-07-11 03:11:34 | [diff] [blame] | 27 | TextResultType type); |
Scott Violet | fdda96d | 2018-07-27 20:17:23 | [diff] [blame] | 28 | |
danakj | 741848a | 2020-04-07 22:48:06 | [diff] [blame] | 29 | } // namespace content |
Scott Violet | fdda96d | 2018-07-27 20:17:23 | [diff] [blame] | 30 | |
danakj | 89f4708 | 2020-09-02 17:53:43 | [diff] [blame] | 31 | #endif // CONTENT_WEB_TEST_RENDERER_LAYOUT_DUMP_H_ |