module Cam_plug: sig end
Interface for plug-ins
type
command = string
val rc_dir : string
The directory with config files. Can be used by a plug-in
to create its own config file.
val display_message : string -> unit
Display the given string in the label at the bottom of the main window.
class type embedded_app = object end
The class type of embedded applications.
val add_embedded_app : command -> (unit -> embedded_app) -> unit
add_embedded_app com f
registers an application which can be started
by command com
. When this command is triggered, f ()
is evaluated to
get an application object.
val add_command : command -> string -> (string list -> unit) -> unit
add_command com desc f
adds the command com
to the list of
registered commands, with description desc
and callback f
.
The callback takes a list of arguments in parameter.
If the same command exists in the table, it is hidden by the new one.
val available_commands : unit -> command list
Return the list of the available commands.
val add_config_box : (unit -> Configwin.configuration_structure) -> unit
add_config_box f
registers a function creating a section for
the configuration window. This function is called each time
the configuration window is created.
val selected_dir : unit -> string option
Access to the selected directory (its name as it appears in the tree, absolute or relative).
type
cvs_status =
| |
Up_to_date |
| |
Locally_modified |
| |
Locally_added |
| |
Locally_removed |
| |
Needs_checkout |
| |
Needs_Patch |
| |
Needs_Merge |
| |
Conflicts_on_merge |
| |
Unknown |
type
editor =
| |
Efuns |
| |
Dbforge |
| |
Emacs |
| |
XEmacs |
| |
Report |
| |
Zoggy |
| |
Custom_editor of string |
type
file_type = {
|
mutable ft_regexp_string : string ; |
|
mutable ft_regexp : Str.regexp ; |
|
mutable ft_name : string ; |
|
mutable ft_color : string option ; |
|
mutable ft_edit : editor ; |
|
mutable ft_templates : string list ; |
|
mutable ft_binary : bool ; |
}
type
file = {
|
f_name : string ; |
|
f_abs_name : string ; |
|
f_date : float ; |
|
f_date_string : string ; |
|
f_work_rev : string ; |
|
f_rep_rev : string ; |
|
f_status : cvs_status ; |
|
mutable f_type : file_type ; |
}
val selected_files : unit -> file list
Access to the selected files.
val eval : string -> unit -> unit
eval com ()
execute the given command.
The command is a string and can be an internal command (with or without
arguments) or a shell command (beginning with '#').
Catch all the exceptions raised by the function. Do nothing if
there is no function associated to the command.
val background_execute : ?width:int -> ?height:int -> command -> unit -> unit
background_execute com ()
execute the given shell command in background,
showing in a window the output (stdout and stderr) of the command.
Catch all the exceptions raised by the function.
width
: the width of the window
height
: the height of the window
val background_execute_with_subst : ?width:int -> ?height:int -> command -> unit -> unit
Same as background_execute
but performs substitution
of %tags in the given command.
class type editor_app = object end
The class type to represent an editor.
val add_editor : string -> (?char:int -> file -> editor_app option) -> unit
add_editor id f
adds an editor identified by id
,
and f
is the function used to create an optional instance
of that editor, for the given file. id
is the string
which must be used in the editor field of a file type.
Default editor commands cannot be overriden.
If the given function returns None as editor, Cameleon
does not mark the file as open. If the function returns
(Some editor), Cameleon can ask this editor to close
(when the user quits Cameleon), to reload, or to save
if the changed method returns true
(before a commit for example).
val close_file : file -> unit
This function must be called when an editor is closed,
to warn Cameleon that this file is closed. If the function given
to add_editor returned None (i.e. no editor created), you don't have
to call this function, since Cameleon did not mark the file as
open.
Cameleon will not allow to edit the file as long as it is marked as open.
module Options: sig end
This module implements a simple mechanism to handle program options files.
module View: sig end
You can define new views using this module.