mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-09-08 10:36:02 +00:00
LibPDF: Move ClipRAII to .h file
No behavior change.
This commit is contained in:
parent
a681429dff
commit
66f8259a0b
Notes:
sideshowbarker
2024-07-16 22:51:10 +09:00
Author: https://github.com/nico
Commit: 66f8259a0b
Pull-request: https://github.com/SerenityOS/serenity/pull/22871
Reviewed-by: https://github.com/ADKaster ✅
2 changed files with 12 additions and 13 deletions
|
@ -130,6 +130,18 @@ private:
|
|||
PDFErrorOr<void> handle_text_next_line_show_string(ReadonlySpan<Value> args, Optional<NonnullRefPtr<DictObject>> = {});
|
||||
PDFErrorOr<void> handle_text_next_line_show_string_set_spacing(ReadonlySpan<Value> args, Optional<NonnullRefPtr<DictObject>> = {});
|
||||
|
||||
class ClipRAII {
|
||||
public:
|
||||
ClipRAII(Renderer& renderer)
|
||||
: m_renderer(renderer)
|
||||
{
|
||||
m_renderer.activate_clip();
|
||||
}
|
||||
~ClipRAII() { m_renderer.deactivate_clip(); }
|
||||
|
||||
private:
|
||||
Renderer& m_renderer;
|
||||
};
|
||||
void activate_clip();
|
||||
void deactivate_clip();
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue