The branch, master, has been updated.

- Log -----------------------------------------------------------------

commit 34ef91bb70937c68462fd82fdc9373b0235e0492
Author: Juergen Spitzmueller <[email protected]>
Date:   Tue Nov 20 19:00:06 2012 +0100

    Allow arguments in PassThru environments (bug #7646)

diff --git a/src/Text3.cpp b/src/Text3.cpp
index ecb5d25..850003c 100644
--- a/src/Text3.cpp
+++ b/src/Text3.cpp
@@ -2320,6 +2320,7 @@ bool Text::getStatus(Cursor & cur, FuncRequest const & 
cmd,
 
        FontInfo const & fontinfo = cur.real_current_font.fontInfo();
        bool enable = true;
+       bool allow_in_passthru = false;
        InsetCode code = NO_CODE;
 
        switch (cmd.action()) {
@@ -2516,6 +2517,7 @@ bool Text::getStatus(Cursor & cur, FuncRequest const & 
cmd,
                break;
        case LFUN_ARGUMENT_INSERT: {
                code = ARG_CODE;
+               allow_in_passthru = true;
                Layout const & lay = cur.paragraph().layout();
                int const numargs = lay.reqargs + lay.optargs;
                enable = cur.paragraph().insetList().count(ARG_CODE) < numargs;
@@ -2889,7 +2891,7 @@ bool Text::getStatus(Cursor & cur, FuncRequest const & 
cmd,
        if (code != NO_CODE
            && (cur.empty() 
                || !cur.inset().insetAllowed(code)
-               || cur.paragraph().layout().pass_thru))
+               || (cur.paragraph().layout().pass_thru && !allow_in_passthru)))
                enable = false;
 
        flag.setEnabled(enable);

-----------------------------------------------------------------------

Summary of changes:
 src/Text3.cpp |    4 +++-
 1 files changed, 3 insertions(+), 1 deletions(-)


hooks/post-receive
-- 
The LyX Source Repository

Reply via email to