From 4398113ee919a62c74af4d600510c074954428a0 Mon Sep 17 00:00:00 2001 From: =?utf8?q?J=C3=BCrgen=20Spitzm=C3=BCller?= Date: Sun, 2 Mar 2008 16:34:17 +0000 Subject: [PATCH] * src/insets/InsetWrap.{cpp,h}: - button label has to be set before drawing (bug 4602). git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23390 a592a061-630c-0410-9148-cb99ea01b6c8 --- src/insets/InsetWrap.cpp | 8 ++++++++ src/insets/InsetWrap.h | 2 ++ 2 files changed, 10 insertions(+) diff --git a/src/insets/InsetWrap.cpp b/src/insets/InsetWrap.cpp index 580c8c5a9c..b5b35e46cd 100644 --- a/src/insets/InsetWrap.cpp +++ b/src/insets/InsetWrap.cpp @@ -192,6 +192,14 @@ void InsetWrap::read(Lexer & lex) } +void InsetWrap::draw(PainterInfo & pi, int x, int y) const +{ + const_cast(*this).setLabel( + _("wrap: ") + floatName(params_.type, buffer().params())); + InsetCollapsable::draw(pi, x, y); +} + + void InsetWrap::validate(LaTeXFeatures & features) const { features.require("wrapfig"); diff --git a/src/insets/InsetWrap.h b/src/insets/InsetWrap.h index 789774241d..3256b03d84 100644 --- a/src/insets/InsetWrap.h +++ b/src/insets/InsetWrap.h @@ -53,6 +53,8 @@ public: /// void read(Lexer & lex); /// + void draw(PainterInfo & pi, int x, int y) const; + /// void validate(LaTeXFeatures & features) const; /// InsetCode lyxCode() const { return WRAP_CODE; } -- 2.39.2