2010-04-16 16:51:25 -04:00
|
|
|
#ifndef _MATCH_H
|
|
|
|
#define _MATCH_H
|
|
|
|
|
2010-08-15 06:18:27 -04:00
|
|
|
/*
|
|
|
|
* Initializes the Match data structure. This function is necessary because the
|
|
|
|
* members representing boolean values (like dock) need to be initialized with
|
|
|
|
* -1 instead of 0.
|
|
|
|
*
|
|
|
|
*/
|
|
|
|
void match_init(Match *match);
|
|
|
|
|
2010-07-13 05:35:05 -04:00
|
|
|
/**
|
|
|
|
* Check if a match is empty. This is necessary while parsing commands to see
|
|
|
|
* whether the user specified a match at all.
|
|
|
|
*
|
|
|
|
*/
|
2010-04-16 16:51:25 -04:00
|
|
|
bool match_is_empty(Match *match);
|
2010-07-13 05:35:05 -04:00
|
|
|
|
|
|
|
/**
|
2011-05-23 12:41:17 -04:00
|
|
|
* Copies the data of a match from src to dest.
|
2010-07-13 05:35:05 -04:00
|
|
|
*
|
|
|
|
*/
|
2011-05-23 12:41:17 -04:00
|
|
|
void match_copy(Match *dest, Match *src);
|
2010-04-16 16:51:25 -04:00
|
|
|
|
2011-05-02 17:29:26 -04:00
|
|
|
/**
|
2011-05-23 12:41:17 -04:00
|
|
|
* Check if a match data structure matches the given window.
|
2011-05-02 17:29:26 -04:00
|
|
|
*
|
|
|
|
*/
|
2011-05-23 12:41:17 -04:00
|
|
|
bool match_matches_window(Match *match, i3Window *window);
|
2011-05-02 17:29:26 -04:00
|
|
|
|
2011-09-11 18:41:46 -04:00
|
|
|
/**
|
|
|
|
* Frees the given match. It must not be used afterwards!
|
|
|
|
*
|
|
|
|
*/
|
|
|
|
void match_free(Match *match);
|
|
|
|
|
2010-04-16 16:51:25 -04:00
|
|
|
#endif
|