X-Git-Url: https://git.lyx.org/gitweb/?a=blobdiff_plain;f=src%2Flyxfr0.C;h=27e85b893b4af5973a6a58b77782b78efbad533b;hb=a858be7332e331e0244e4dba7b0931b6072ffd3d;hp=4b995593355ebc94a200e1616e04769a5ebad705;hpb=27de1486ca34aaad446adb798d71a77d6f6304da;p=lyx.git diff --git a/src/lyxfr0.C b/src/lyxfr0.C index 4b99559335..27e85b893b 100644 --- a/src/lyxfr0.C +++ b/src/lyxfr0.C @@ -1,18 +1,18 @@ /* This file is part of -* ====================================================== -* -* LyX, The Document Processor -* -* Copyright (C) 1995 Matthias Ettrich, -* Copyright (C) 1995-1998 The LyX Team. -* -*======================================================*/ + * ====================================================== + * + * LyX, The Document Processor + * + * Copyright 1995 Matthias Ettrich, + * Copyright 1995-1999 The LyX Team. + * + * ======================================================*/ #include -#include -#include -#include +#include +#include +#include #ifdef __GNUG__ #pragma implementation @@ -26,7 +26,7 @@ #include "lyxfr1.h" #include "lyxfunc.h" #include "lyxscreen.h" -#include "error.h" +#include "debug.h" #include "lyxtext.h" #include "gettext.h" #include "LyXView.h" // only because of form_main @@ -85,6 +85,8 @@ LyXFindReplace0::LyXFindReplace0() void LyXFindReplace0::StartSearch() { + static int ow = -1, oh; + FD_form_search *fd_fs = fd_form_search; if (fd_fs->form_search->visible) { @@ -93,6 +95,11 @@ void LyXFindReplace0::StartSearch() fl_show_form(fd_fs->form_search, FL_PLACE_MOUSE | FL_FREE_SIZE, FL_FULLBORDER, _("Find & Replace")); // RVDK_PATCH_5 + if (ow < 0) { + ow = fd_form_search->form_search->w; + oh = fd_form_search->form_search->h; + } + fl_set_form_minsize(fd_form_search->form_search, ow, oh); } ReInitFromForm(); } @@ -109,9 +116,9 @@ void LyXFindReplace0::ReInitFromForm() // Returns the value of the replace string in the form -LString const LyXFindReplace0::ReplaceString() +string const LyXFindReplace0::ReplaceString() { - return LString(fl_get_input(fd_form_search->input_replace)); + return string(fl_get_input(fd_form_search->input_replace)); } @@ -143,7 +150,7 @@ void LyXFindReplace0::SetReplaceEnabled(bool fEnable) } -void LyXFindReplace0::SetSearchString(LString const &ls) +void LyXFindReplace0::SetSearchString(string const &ls) { lsSearch = ls; fl_set_input(fd_form_search->input_search, ls.c_str());