/* 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 <config.h>
-#include <ctype.h>
-#include <string.h>
-#include <stdlib.h>
+#include <cctype>
+#include <cstring>
+#include <cstdlib>
#ifdef __GNUG__
#pragma implementation
#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
void LyXFindReplace0::StartSearch()
{
+ static int ow = -1, oh;
+
FD_form_search *fd_fs = fd_form_search;
if (fd_fs->form_search->visible) {
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();
}
// 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));
}
}
-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());