1 2@c %start of fragment 3 4@deffn Function gtk-check-version (required_major@tie{}@code{unsigned-int}) (required_minor@tie{}@code{unsigned-int}) (required_micro@tie{}@code{unsigned-int}) @result{}@tie{} (ret@tie{}@code{mchars}) 5Checks that the GTK+ library in use is compatible with the given version. 6Generally you would pass in the constants @code{<gtk-major-version>}, 7@code{<gtk-minor-version>}, @code{<gtk-micro-version>} as the three arguments to 8this function; that produces a check that the library in use is compatible with 9the version of GTK+ the application or module was compiled against. 10 11Compatibility is defined by two things: first the version of the running library 12is newer than the version 13@var{required-major.required-minor}.@var{required-micro}. Second the running 14library must be binary compatible with the version 15@var{required-major.required-minor}.@var{required-micro} (same major version.) 16 17This function is primarily for GTK+ modules; the module can call this function 18to check that it wasn't loaded into an incompatible version of GTK+. However, 19such a a check isn't completely reliable, since the module may be linked against 20an old version of GTK+ and calling the old version of @code{gtk-check-version}, 21but still get loaded into an application using a newer version of GTK+. 22 23@table @var 24@item required-major 25the required major version. 26 27@item required-minor 28the required major version. 29 30@item required-micro 31the required major version. 32 33@item ret 34@samp{@code{#f}} if the GTK+ library is compatible with the given version, or a 35string describing the version mismatch. The returned string is owned by GTK+ and 36should not be modified or freed. 37 38@end table 39 40@end deffn 41 42 43@c %end of fragment 44