2011-07-20 10:33:24 +02:00
|
|
|
/**
|
|
|
|
*******************************************************************************
|
|
|
|
* @file Search.h
|
|
|
|
* @brief Editeur De N'ours : Search system (header)
|
|
|
|
* @author Edouard DUPIN
|
|
|
|
* @date 03/01/2011
|
|
|
|
* @par Project
|
|
|
|
* Edn
|
|
|
|
*
|
|
|
|
* @par Copyright
|
|
|
|
* Copyright 2010 Edouard DUPIN, all right reserved
|
|
|
|
*
|
|
|
|
* This software is distributed in the hope that it will be useful, but WITHOUT
|
|
|
|
* ANY WARRANTY.
|
|
|
|
*
|
|
|
|
* Licence summary :
|
|
|
|
* You can modify and redistribute the sources code and binaries.
|
|
|
|
* You can send me the bug-fix
|
|
|
|
* You can not earn money with this Software (if the source extract from Edn
|
|
|
|
* represent less than 50% of original Sources)
|
|
|
|
* Term of the licence in in the file licence.txt.
|
|
|
|
*
|
|
|
|
*******************************************************************************
|
|
|
|
*/
|
|
|
|
|
|
|
|
#ifndef __SEARCH_H__
|
|
|
|
#define __SEARCH_H__
|
|
|
|
|
2012-04-23 10:15:43 +02:00
|
|
|
#include <appl/Debug.h>
|
2011-07-20 10:33:24 +02:00
|
|
|
|
|
|
|
|
2012-02-20 20:30:26 +01:00
|
|
|
class Search
|
2011-07-20 10:33:24 +02:00
|
|
|
{
|
2012-02-20 20:30:26 +01:00
|
|
|
public:
|
2011-07-20 10:33:24 +02:00
|
|
|
// Constructeur
|
|
|
|
Search(void);
|
|
|
|
~Search(void);
|
|
|
|
|
|
|
|
public:
|
|
|
|
void Destroy(void);
|
2012-01-11 15:26:53 +01:00
|
|
|
//void Display(GtkWindow *parent);
|
2011-07-20 10:33:24 +02:00
|
|
|
void Hide(void);
|
2012-01-11 15:26:53 +01:00
|
|
|
/*
|
2011-07-20 10:33:24 +02:00
|
|
|
private:
|
|
|
|
GtkWidget * m_localDialog; //!< local dialog element
|
|
|
|
// entry
|
|
|
|
GtkWidget * m_searchLabel; //!< gtk label of the search section
|
|
|
|
GtkWidget * m_searchEntry; //!< gtk entry of the search section
|
|
|
|
GtkWidget * m_replaceLabel; //!< gtk label of the replace section
|
|
|
|
GtkWidget * m_replaceEntry; //!< gtk entry of the replace section
|
|
|
|
// checkbox
|
|
|
|
GtkWidget * m_CkMatchCase; //!< tick of the case matching
|
|
|
|
GtkWidget * m_CkWrapAround; //!< tick of the wrap the file
|
|
|
|
GtkWidget * m_CkRegularExpression; //!< the test is a regular expression
|
|
|
|
// button
|
|
|
|
GtkWidget * m_BtPrevious; //!< Button Previous
|
|
|
|
GtkWidget * m_BtNext; //!< Button Next
|
|
|
|
GtkWidget * m_BtReplace; //!< Button Replace
|
|
|
|
GtkWidget * m_BtReplaceAndNext; //!< Button Replace and find next
|
|
|
|
GtkWidget * m_BtQuit; //!< Button Quit
|
|
|
|
bool m_haveSearchData;
|
|
|
|
bool m_haveReplaceData;
|
|
|
|
// CallBack for GTK+ gui
|
|
|
|
private :
|
|
|
|
static void OnButtonPrevious(GtkWidget *widget, gpointer user_data);
|
|
|
|
static void OnButtonNext(GtkWidget *widget, gpointer user_data);
|
|
|
|
static void OnButtonReplace(GtkWidget *widget, gpointer user_data);
|
|
|
|
static void OnButtonReplaceAndNext(GtkWidget *widget, gpointer user_data);
|
|
|
|
static void OnButtonQuit(GtkWidget *widget, gpointer user_data);
|
|
|
|
static void OnCheckBoxEventCase(GtkWidget *widget, gpointer user_data);
|
|
|
|
static void OnCheckBoxEventWrap(GtkWidget *widget, gpointer user_data);
|
|
|
|
static void OnCheckBoxEventRegExp(GtkWidget *widget, gpointer user_data);
|
|
|
|
static void OnEntrySearchChange(GtkWidget *widget, gpointer user_data);
|
|
|
|
static void OnEntryReplaceChange(GtkWidget *widget, gpointer user_data);
|
2012-01-11 15:26:53 +01:00
|
|
|
*/
|
2011-07-20 10:33:24 +02:00
|
|
|
};
|
|
|
|
|
|
|
|
|
|
|
|
#endif
|
|
|
|
|
|
|
|
|