summaryrefslogtreecommitdiff
path: root/src/split.c
AgeCommit message (Collapse)Author
2006-04-20* src/split.c (show_frame_message): use XmbDrawString and XmbTextEscapementsabetts
* src/screen.c (init_screen): don't include the font in the gc * src/ratpoison.h: include Xlocale.h * src/manage.c (get_wmname): support i18n characters * src/main.c (init_defaults): call load_query_font_set and set_extents_of_fontset (main): call setlocale (clean_up): call XFreeFontSet (set_extents_of_fontset): new function (load_query_font_set): likewise * src/input.c (update_input_window): use XmbTextEscapement and XmbDrawString * src/globals.h (FONT_HEIGHT): use rp_font_ascent and rp_font_descent (MAX_FONT_WIDTH): use rp_font_width new globals rp_font_ascent, rp_font_descent, rp_font_width * src/globals.c: new globals rp_font_ascent, rp_font_descent, rp_font_width * src/data.h (struct rp_defaults): font is a XFontSet * src/bar.c (max_line_length): call XmbTextEscapement (draw_string): call XmbDrawString (get_mark_box): call XmbTextEscapement * src/actions.c (read_frame): call XmbTextEscapement (cmd_license): likewise (read_frame): call XmbDrawString (cmd_license): likewise (cmd_help): likewise (update_gc): don't include the font (set_font): call load_query_font_set
2006-03-16remove tabs and trailing whitespace.sabetts
2006-01-05* src/conf.h (ASPECT_WINDOWS_ARE_TRANSIENTS): new definesabetts
* src/manage.c (window_is_transient): new function (maximize_normal): honour aspect ratio hint * src/window.c (update_window_gravity): use maxsize_gravity for windows with aspect hints. (set_active_window_body): call window_is_transient * src/split.c (cleanup_frame): call window_is_transient
2006-01-03* src/number.c (numset_add_num): store the ret val ofsabetts
numset_find_empty_cell in a variable and use it as an index into the numbers_taken array. * src/actions.c (cmd_curframe): return the frame number in non-interactive mode. * src/split.c (cleanup_frame): in the maxsize windows are transients check either the width or height must be less than the screen width/height (just like in windows.c).
2004-12-04update copyright.sabetts
2004-12-02Updated copyright notices.sabetts
2004-11-03(blank_frame): use the frames screen, not the current screen.sabetts
2004-11-03* src/group.c (group_last_window): add argument, the screen to find thesabetts
window in. All callers updated. (group_prev_window): make sure the matched window is in the same screen as win. (group_next_window): likewise * src/window.c (find_window_other): add argument, the screen to find the window in. All callers updated.
2004-02-27* src/screen.c (screen_free_nums): new function. prototype addedsabetts
(init_screens): init rp_frame_numset (init_screen): set screen's frames_numset to rp_frame_numset * src/globals.h: new global prototype, rp_frame_numset * src/globals.c: new global, rp_frame_numset * src/split.c (find_last_frame): find the last from of all the screens. prototype updated. Callers updated. (find_frame_number): search all screens. prototype updated. callers updated. * src/actions.c (cmd_fselect): select from frames in all screens.
2004-02-27* src/window.c (give_window_focus): save the mouse position beforesabetts
checking if win is NULL. (give_window_focus): set rp_current_screen to xine_screen_num of the window's screen. (set_active_window): when using xinerama get the frame from the current screen. * src/split.c (set_frames_window): update the window's scr attribute to point to the frame's screen. (find_window_for_frame): when xinerama is being used search all windows. (set_active_frame): update rp_current_screen to point to the frame's screen. * src/screen.h (init_screens): new prototype (is_rp_window_for_screen): likewise * src/screen.c: include string.h and X11/cursorfont.h (init_screens): new function (is_rp_window_for_screen): new function. (init_screen): fill in xine_screen_num when using xinerama. * src/ratpoison.h: include xinerama.h * src/manage.c (current_screen): use xine_screen_num to find the current screen. (scanwins): use is_rp_window_for_screen to skip over ratpoison windows. (scanwins): when using xinerama only manage windows inside the viewable area. * src/main.c (main): call init_xinerama and init_screens. Move screen initing code to these functions. (init_rat_cursor): move to screen.c (init_screen): likewise (find_screen): likewise (clean_up): call free_xinerama * src/group.c (group_last_window): only check windows in the current screen, unless xinerama is being used in which case all windows are accessible. (group_next_window): likewise (group_prev_window): likewise * src/globals.h: new globals rp_have_xinerama, xine_screen_num. * src/events.c (new_window): when using xinerama, the new window's screen is the current screen. (key_press): when using xinerama, use the current screen. * src/data.h (struct rp_screen): remove root_attr and add left, top, width, height. All dependant code updated. Add xine_screen_num. * src/actions.c (cmd_remove): show the frame indicator in the new current frame after removing the frame. * src/Makefile.am (ratpoison_SOURCES): add xinerama.c and xinerama.h
2004-02-27(hide_frame_indicator): unmap all 'current frame'sabetts
indicator windows. (show_frame_indicator): hide the 'current frame' indicator before showing it.
2003-08-29* src/window.c (give_window_focus): use set_rp_window_focus.sabetts
* src/split.c (set_active_frame): use set_window_focus. (blank_frame): likewise * src/main.c (main): use set_window_focus. * src/input.c (get_more_input): use set_window_focus * src/globals.h (set_window_focus): new prototype (set_rp_window_focus): likewise * src/events.c (handle_key): use set_window_focus. * src/actions.c (cmd_resize): use set_window_focus. (cmd_license): likewise (cmd_help): likewise (cmd_tmpwm): likewise (cmd_fselect): likewise * src/globals.c (set_rp_window_focus): new function (set_window_focus): likewise
2003-08-23* src/split.c (remove_all_splits): only hide the windows in thesabetts
current screen. * src/group.h (group_delete_group): new prototype * src/group.c (group_last_window): find the last window in the current screen. (group_next_window): find next window in current screen. (group_prev_window): find previous window in current screen. * src/manage.c (force_maximize): call XSync() after first resize. * src/globals.h (GROUP_DELETE_GROUP_OK): new define (GROUP_DELETE_GROUP_NONEMPTY): likewise * src/actions.h (cmd_gdelete): new prototype * src/actions.c (user_commands): new command gdelete (cmd_gdelete): new command
2003-07-17* src/window.c (set_active_window): run the switch window hook.sabetts
* src/split.c (set_active_frame): run the switch frame hook. * src/ratpoison.h: include hook.h * src/group.h (set_current_group): new prototype * src/group.c (set_current_group): new function * src/globals.h (rp_prefix_hook): new extern (rp_switch_win_hook): likewise (rp_switch_frame_hook): likewise (rp_switch_group_hook): likewise (rp_hook_db): likewise * src/globals.c (rp_prefix_hook): new hook (rp_switch_win_hook): likewise (rp_switch_frame_hook): likewise (rp_switch_group_hook): likewise (rp_hook_db): new global * src/events.c (handle_key): call the prefix hook. * src/data.h (struct rp_hook_db_entry): new struct * src/actions.h (cmd_addhook): new prototype (cmd_remhook): likewise * src/actions.c (user_commands): add commands addhook and remhook. (cmd_windows): show the window bar no matter what if the bar timeout is > 0. (cmd_gnext): call set_current_group (cmd_gprev): likewise (cmd_gnew): likewise (cmd_gselect): likewise (cmd_addhook): new function (cmd_remhook): likewise * src/Makefile.am (ratpoison_SOURCES): add hook.c and hook.h
2003-05-25* src/window.c: do not include ctype.hsabetts
* src/ratpoison.h (str_comp): new prototype * src/messages.h (MESSAGE_PROMPT_SWITCH_TO_GROUP): new define * src/main.c: include ctype.h (str_comp): moved from window.c * src/group.h (groups_find_group_by_name): new prototype. (groups_find_group_by_number): likewise. (groups_merge): likewise (group_move_window): likewise * src/group.c: include string.h (group_new): new argument, name. All callers updated. prototype updated. (init_groups): create the first group with DEFAULT_GROUP_NAME as its name. (group_new): new argument, name. All callers updated. Prototype updated. (group_free): free the group's name. (group_add_new_group): new argument, name. All callers updated. Prototype updated. (groups_find_group_by_name): new function (groups_find_group_by_number): likewise (group_move_window): likewise (groups_merge): likewise * src/conf.h (DEFAULT_GROUP_NAME): new define * src/actions.h (cmd_gselect): new prototype (cmd_groups): likewise (cmd_gmove): likewise (cmd_gmerge): likewise (cmd_gnewbg): likewise * src/actions.c (user_commands): new commands gselect, groups, gmove, gmerge, gnewbg. (cmd_gnewbg): new function (find_group): likewise (cmd_gselect): likewise (cmd_groups): likewise (cmd_gmove): likewise (cmd_gmerge): likewise
2003-05-16* src/window.c (add_to_window_list): add the window to the currentsabetts
group. (find_window_name): search the current group for a matching window. (find_window_other): likewise. (format_window_name): take a rp_window_elem as an argument, not an rp_window. Print the group window's number, not the window's internal number. (get_window_list): loop through the current group. * src/split.c (find_window_for_frame): search the current group for a window to fit in the frame. * src/ratpoison.h: include globals.h and group.h * src/manage.c (unmanage): remove the window from any groups it was in. (map_window): map the window in any groups it is in. (withdraw_window): unmap the window in any groups it is in. * src/main.c: Move all globals to globals.h (main): initialize the group functions. * src/data.h: Move all defines and extern globals to globals.h (struct rp_window_elem): new struct (struct rp_group): likewise * src/actions.h (cmd_gnext): new prototype (cmd_gprev): likewise (cmd_gnew): likewise * src/actions.c (user_commands): new commands gnext, gprev, and gnew (cmd_prev): fix to work with new group code. (cmd_next): likewise (cmd_gnext): new function (cmd_gprev): likewise (cmd_gnew): likewise * src/Makefile.am (ratpoison_SOURCES): add files globals.h, globals.c, group.h and group.c
2003-05-15* src/data.h (struct rp_frame): renamed from rp_window_frame. Allsabetts
dependant code updated. * src/main.c: remove child_info global. Add rp_children global. (chld_handler): update the terminated and status fields of any terminated children. * src/events.c (handle_signals): loop through each child process and remove them from the list. Print a message for any child that doesn't return a 0 status. * src/data.h (rp_child_info): new fields, terminated and node. remove child_info global. Add rp_children global. * src/actions.c (spawn): Add the command to the list of children.
2003-05-15(struct rp_screen): rename fromsabetts
screen_info. Dependant code updated.
2003-05-09* src/split.c (split_frame): call update_bar() instead ofsabetts
update_window_names(). (set_active_frame): likewise (blank_frame): likewise * src/bar.h (update_bar): new prototype. * src/bar.c (BAR_IS_HIDDEN): new define. (update_bar): new function. * src/actions.c (cmd_frestore): call update_bar() instead of update_window_names(). * src/split.c (set_active_frame): update the window list after switching frames. (blank_frame): update the window list after blanking the screen. * src/actions.c (cmd_frestore): update the window list after restoring the frames. * src/split.c (split_frame): update the window list after the split.
2003-05-09* src/split.c (set_active_frame): update the window list aftersabetts
switching frames. * src/actions.c (cmd_frestore): update the window list after restoring the frames. * src/split.c (split_frame): update the window list after the split.
2003-04-04(set_active_frame): fix NULL pointer crash bug.sabetts
2003-03-31* src/window.c (set_current_window): use current_frame()sabetts
* src/split.h (current_frame): new prototype * src/split.c (current_frame): new function (current_window): use current_frame() (split_frame): likewise (remove_all_splits): likewise (set_active_frame): likewise (show_frame_message): likewise (remove_all_splits): use current_screen() * src/actions.c (cmd_prev_frame): use current_frame() (cmd_next_frame): likewise (cmd_select): likewise (cmd_h_split): likewise (cmd_v_split): likewise (cmd_remove): likewise (cmd_shrink): likewise (cmd_resize): likewise (cmd_focusup): likewise (cmd_focusdown): likewise (cmd_focusleft): likewise (cmd_focusright): likewise
2003-03-31* src/split.c (current_window): call screen_get_frame.sabetts
(split_frame): call screen_get_frame to get appropriate structure. (split_frame): call find_window_number to get appropriate structure. (remove_all_splits): call screen_get_frame to get appropriate structure. (resize_frame): make sure all frames that will be resized are big enough for the resize. (resize_frame): return int (resize_shrink_to_window): call find_window_number to get the appropriate structure. (resize_frame_right): return int (resize_frame_left): likewise (resize_frame_top): likewise (resize_frame_bottom): likewise (resize_frame_horizontally): backup the frameset and restore it if the resize fails. Do not allow a frame to be resized too small or too big. (resize_frame_vertically): likewise (remove_frame): call find_window_number to get the appropriate structure. (set_active_frame): likewise (blank_frame): likewise (show_frame_message): call screen_get_frame to get the appropriate structure. * src/screen.c (screen_width): new function (and prototype) (screen_height): likewise (screen_left): likewise (screen_right): likewise (screen_top): likewise (screen_bottom): likewise (screen_copy_frameset): likewise (screen_restore_frameset): likewise (frameset_free): likewise (screen_get_frame): likewise * src/split.c (maximize_frame): call screen_width and screen_height to get the size for the frame. * src/ratpoison.h: include screen.h * src/manage.c (move_window): * src/frame.h (frame_copy): new prototype (frame_dump): likewise * src/frame.c (frame_copy): new function (frame_dump): likewise * src/events.c (unmap_notify): compare frame numbers, not pointers. (client_msg): call screen_get_frame when blanking the frame. * src/data.h (EMPTY): new define (struct rp_window_frame): replace the win field with win_number. Dependant code updated. (struct rp_window): replace frame with frame_number. Dependant code updated. (struct screen_info): replace rp_current_frame with current_frame and change type to int. Dependant code updated. * src/Makefile.am (ratpoison_SOURCES): added screen.h and screen.c
2003-03-26* src/split.h (show_frame_message): new prototypesabetts
* src/split.c (show_frame_message): new function * src/main.c (init_screen): listen for key release events in the key_window and input_window. * src/input.c (read_key): new argument, gobble_rel. All callers updated. * src/actions.c (cmd_remove): only remove the current frame if it isn't the ONLY one. (cmd_remove): display a message informing the user if the frame cannot be removed. (cmd_resize): clean up resize loop. (cmd_resize): display a window indicating which frame is being resized.
2003-03-23(resize_frame_vertically): fix typo error (frame_topsabetts
not frame_left).
2003-03-18* src/split.c (resize_frame_horizontally): only resize to the leftsabetts
if the frame isn't against the left side of the screen. (resize_frame_vertically): only resize to the left if the frame isn't against the top of the screen. * src/split.c (create_initial_frame): call frame_new to allocate a frame. (split_frame): likewise
2003-03-18mess upsabetts
2003-03-18* src/actions.c (initialize_default_keybindings): add keybindingssabetts
for fselect and resize. Move keybinding for curframe. * src/split.c (create_initial_frame): call frame_new to allocate a frame. (split_frame): likewise * src/main.c (free_screen): call frame_free to free the screen frames. * src/frame.h (frame_new): new prototype (frame_free): likewise * src/frame.c (frame_new): new function. (frame_free): likewise
2003-03-07* src/Makefile.am (ratpoison_SOURCES): add frame.c and frame.hsabetts
* src/frame.h (frame_left): new prototype (frame_top): likewise (frame_right): likewise (frame_bottom): likewise (frame_width): likewise (frame_height): likewise (frame_resize_left): likewise (frame_resize_right): likewise (frame_resize_up): likewise (frame_resize_down): likewise (frame_move_left): likewise (frame_move_right): likewise (frame_move_up): likewise (frame_move_down): likewise * src/frame.c (frame_left): new function (frame_top): likewise (frame_right): likewise (frame_bottom): likewise (frame_width): likewise (frame_height): likewise (frame_resize_left): likewise (frame_resize_right): likewise (frame_resize_up): likewise (frame_resize_down): likewise (frame_move_left): likewise (frame_move_right): likewise (frame_move_up): likewise (frame_move_down): likewise * src/split.c (resize_frame): new function (resize_frame_right): likewise (resize_frame_left): likewise (resize_frame_top): likewise (resize_frame_bottom): likewise (resize_frame_horizontally): use resize_frame_right and resize_frame_left to do the resizing. (resize_frame_vertically): use resize_frame_top and resize_frame_bottom to do the resizing. * src/ratpoison.h (PRINT_ERROR): flush stdout (PRINT_DEBUG): likewise include frame.h
2003-03-07* src/split.h (find_frame_number): new prototypesabetts
* src/split.c (create_initial_frame): give a number to the initial frame (split_frame): give the new frame a unique number (split_frame): add the new frame after the current frame (remove_all_splits): return the frame's number when deleting it. (remove_frame): likewise (find_frame_number): new function * src/main.c (init_screen): initialize the frames_numset member (free_screen): free the frames_numset member * src/data.h (struct screen_info): new member, frames_numset * src/actions.h (cmd_fselect): new prototype * src/actions.c (user_commands): new command "fselect" (cmd_fselect): new function
2003-02-24(remove_all_splits): fix bug hiding windows not insabetts
the current frame.
2003-02-24* src/split.h (cleanup_frame): new protoypesabetts
* src/manage.c (scanwins): added better debugging output * src/events.c (cleanup_frame): move to split.c (handle_key): ungrab the rat right after we read the key. * src/actions.h (cmd_tmpwm): new prototype. * src/actions.c (spawn): return the pid of the child process. prototype updated. (cmd_tmpwm): new function (user_commands): new command, tmp_wm.
2003-02-23* configure.in: don't check for variable argument support insabetts
preprocessor. * src/ratpoison.h (PRINT_LINE): new macro. (PRE_PRINT_LOCATION): remove macro (PRINT_ERROR): takes one argument which is the argument list ,parens and all, to be passed to printf. Callers updated. * src/actions.c (cmd_number): use list delete entry macro (cmd_number): likewise (cmd_escape): use list looping macro (cmd_escape): likewise (cmd_defpadding): likewise (cmd_defborder): likewise * src/events.c (mapping_notify): use list looping macro (mapping_notify): likewise * src/list.c: rename rp_unmapped_window_sentinel to rp_unmapped_window and rp_mapped_window_sentinel to rp_mapped_window. Use LIST_HEAD to create them. externs updated. (add_to_window_list): use list add entry macro. (find_window_in_list): list head is of type list_head. Prototype and callers updated. (find_window_in_list): use list looping macro (init_window_list): remove function (find_window_number): use list looping macro (find_window_name): likewise (find_window_prev): use list previous entry macro (find_window_next): use list next entry macro (find_window_other): use list looping macro (append_to_list): remove function (insert_into_list): use list looping macro (insert_into_list): use list add entry macro (remove_from_list): remove function (get_window_list): use list looping macro * src/main.c (main): do not call init_window_list() * src/manage.c (unmanage): use list delete macro (map_window): likewise (withdraw_window): use list moving macro to move entry to another list. (hide_others): use list looping macro * src/split.c (num_frames): use list looping macro (frames_screen): likewise (maximize_all_windows_in_frame): likewise (delete_frame_from_list): remove function (create_initial_frame): remove list init code. Add current frame to screen's frame list. (init_frame_list): use list init macro (find_last_frame): use list looping macro (find_windows_frame): likewise (find_frame_next): use list next entry macro (find_frame_prev): use list previous entry macro (find_window_for_frame): use list looping macro (split_frame): use list add entry macro (remove_all_splits): use list looping macro (resize_frame_vertically): likewise (resize_frame_horizontally): likewise (total_frame_area): likewise (frame_overlaps): likewise (remove_frame): likewise (find_frame_up): likewise (find_frame_down): likewise (find_frame_left): likewise (find_frame_right): likewise
2003-02-22* src/actions.c (cmd_number): use list delete entry macrosabetts
(cmd_number): likewise (cmd_escape): use list looping macro (cmd_escape): likewise (cmd_defpadding): likewise (cmd_defborder): likewise * src/data.h: include linkedlist.h (struct rp_window_frame): use struct list_head instead of next, prev pointers. (struct rp_window): likewise (struct screen_info): rename rp_window_frame_sentinel to rp_window_frames and change it's type to list_head. * src/events.c (mapping_notify): use list looping macro (mapping_notify): likewise * src/list.c: rename rp_unmapped_window_sentinel to rp_unmapped_window and rp_mapped_window_sentinel to rp_mapped_window. Use LIST_HEAD to create them. externs updated. (add_to_window_list): use list add entry macro. (find_window_in_list): list head is of type list_head. Prototype and callers updated. (find_window_in_list): use list looping macro (init_window_list): remove function (find_window_number): use list looping macro (find_window_name): likewise (find_window_prev): use list previous entry macro (find_window_next): use list next entry macro (find_window_other): use list looping macro (append_to_list): remove function (insert_into_list): use list looping macro (insert_into_list): use list add entry macro (remove_from_list): remove function (get_window_list): use list looping macro * src/main.c (main): do not call init_window_list() * src/manage.c (unmanage): use list delete macro (map_window): likewise (withdraw_window): use list moving macro to move entry to another list. (hide_others): use list looping macro * src/split.c (num_frames): use list looping macro (frames_screen): likewise (maximize_all_windows_in_frame): likewise (delete_frame_from_list): remove function (create_initial_frame): remove list init code. Add current frame to screen's frame list. (init_frame_list): use list init macro (find_last_frame): use list looping macro (find_windows_frame): likewise (find_frame_next): use list next entry macro (find_frame_prev): use list previous entry macro (find_window_for_frame): use list looping macro (split_frame): use list add entry macro (remove_all_splits): use list looping macro (resize_frame_vertically): likewise (resize_frame_horizontally): likewise (total_frame_area): likewise (frame_overlaps): likewise (remove_frame): likewise (find_frame_up): likewise (find_frame_down): likewise (find_frame_left): likewise (find_frame_right): likewise
2003-02-10* src/split.h (num_frames): new prototypesabetts
(resize_shrink_to_window): likewise (resize_frame_vertically): likewise (resize_frame_horizontally): likewise * src/split.c (num_frames): no longer a static function (resize_shrink_to_window): new function (resize_frame_vertically): likewise (resize_frame_horizontally): likewise * src/main.c (init_defaults): init frame_resize_unit. * src/data.h (struct rp_defaults): new member frame_resize_unit. * src/conf.h (RESIZE_VGROW_KEY): new define (RESIZE_VGROW_MODIFIER): likewise (RESIZE_VSHRINK_KEY): likewise (RESIZE_VSHRINK_MODIFIER): likewise (RESIZE_HGROW_KEY): likewise (RESIZE_HGROW_MODIFIER): likewise (RESIZE_HSHRINK_KEY): likewise (RESIZE_HSHRINK_MODIFIER): likewise (RESIZE_SHRINK_TO_WINDOW_KEY): likewise (RESIZE_SHRINK_TO_WINDOW_MODIFIER): likewise (RESIZE_END_KEY): likewise (RESIZE_END_MODIFIER): likewise * src/actions.h (cmd_shrink): new prototype (cmd_resize): likewise (cmd_defresizeunit): likewise * src/actions.c (user_commands): add commands cmd_resize and cmd_shrink, and cmd_defresizeunit. (cmd_shrink): new function (cmd_resize): likewise (cmd_defresizeunit): likewise
2002-10-18* src/split.c (VERTICALLY): new definesabetts
(VERTICALLY): likewise (split_frame): new argument 'pixels'. The current frame is split and resized to 'pixels' pixels. (v_split_frame): new argument 'pixels'. prototype updated. (h_split_frame): likewise * src/actions.c (user_commands): hsplit, vsplit, and split take a string argument. (read_split): new function (cmd_h_split): takes a ratio or number to determine how big the frame split will be. (cmd_v_split): likewise
2002-03-13* src/split.c (set_active_frame): fix to operate properly withsabetts
multiple screens. * src/data.h (struct rp_window_frame): new data member 'number'. * src/actions.h (cmd_prevscreen): new prototype (cmd_nextscreen): likewise * src/actions.c (user_commands): new commands "nextscreen" and "prevscreen" (cmd_nextscreen): new function (cmd_prevscreen): likewise
2002-02-20* src/split.c: include string.hsabetts
* src/sbuf.c: likewise * src/events.c: likewise * src/communications.c: likewise
2001-12-09* src/events.c (handle_key): revert the focus immediately aftersabetts
reading the key. * src/list.c (give_window_focus): update rp_current_frame when setting the window focus. * src/main.c (main): scan for windows in a seperate pass after initializing the screen structures. (init_screen): build a display string for each screen. (init_screen): remove the call to scanwins. * src/manage.c (current_screen): return the current screen using rp_current_screen. * src/split.h (init_frame_lists): new function * src/split.c (rp_window_frame_sentinel): remove. (rp_current_frame): remove. (frames_screen): new function (maximize_frame): use the frame's screen to find out the width and height of the display. (create_initial_frame): take a pointer to a screen_info as an argument. (init_frame_lists): new function (init_frame_list): take a pointer to a screen_info as an argument. (find_last_frame): take a pointer to a screen_info as an argument. * src/actions.c (spawn): Set the DISPLAY environment variable to point to the current screen. * src/data.h (struct screen_info): add display_string, rp_window_frame_sentinel, rp_current_frame. (rp_current_screen): new global (rp_current_frame): Remove. Dependant code uses screen_info.rp_current_frame.
2001-10-18* src/split.c (show_frame_indicator): call XSync after clearing the window.sabetts
* src/input.c (get_more_input): clear the window after it is raised. Call XSync aftwards. * src/conf.h (MAX_LINK_DEPTH): new define * src/bar.c (marked_message): clear the window after it is raised. Call XSync aftwards. * src/actions.h (cmd_link): new prototype * src/actions.c (user_command): new command 'link' (find_command_by_keydesc): new function (resolve_command_from_keydesc): likewise (cmd_link): likewise
2001-10-18* src/split.h (find_last_frame): new prototypesabetts
* src/split.c (update_last_access): new function (find_last_frame): likewise (split_frame): update the new frame's last_access field (set_active_frame): update the new current frame's last_access field * src/input.h (x11_mask_to_rp_mask): new prototype (rp_mask_to_x11_mask): likewise * src/input.c (x11_mask_to_rp_mask): new function (rp_mask_to_x11_mask): likewise * src/events.c (handle_key): convert X11 modifier masks to rp modifier masks where appropriate. * src/actions.h (cmd_focuslast): new prototype * src/actions.c (initialize_default_keybindings): new keybinding for "focuslast" (cmd_focuslast): new function (user_command): new command "focuslast"
2001-10-10(remove_frame): Make sure the frame attempting tosabetts
take up the space of the deleted frame overlaps the deleted frame after the size change. (remove_frame): More debug messages
2001-09-21* src/split.h (find_frame_up): new prototypesabetts
(find_frame_down): likewise (find_frame_left): likewise (find_frame_right): likewise * src/split.c (find_frame_up): new function (find_frame_down): likewise (find_frame_left): likewise (find_frame_right): likewise * src/manage.c (move_window): use x11 gravity constants to denote gravity. * src/main.c (ratpoison_longopts): remove --kill and --restart. Dependant code updated. (init_defaults): use x11 gravity constants to denote gravity. (main): only display the startup message if defaults.startup_message is on. * src/list.c (update_window_gravity): rename from update_window_position. dependant code updated * src/events.c (client_msg): don't test for restart or kill client messages. (client_msg): properly handle iconify requests. (get_event): kill and restart the process here. * src/data.h (TOP_LEFT): remove define (TOP_CENTER): likewise (TOP_RIGHT): likewise (CENTER_LEFT): likewise (CENTER_CENTER): likewise (CENTER_RIGHT): likewise (BOTTOM_LEFT): likewise (BOTTOM_CENTER): likewise (BOTTOM_RIGHT): likewise (struct rp_window): rename field to position to gravity. (struct rp_defaults): rename win_pos to win_gravity, trans_pos to trans_gravity and maxsize_pos to maxsize_gravity. (rp_restart): remove global variable (rp_kill): likewise * src/communications.h (send_kill): remove prototype (send_restart): likewise * src/communications.c (send_restart): remove function. obsolete. (send_kill): likewise * src/bar.c (bar_x): Use X11 gravity constants to denote location. (bar_y): likewise * src/actions.h (cmd_focusup): new prototype (cmd_focusdown): likewise (cmd_focusleft): likewise (cmd_focusright): likewise (cmd_startup_message): likewise (cmd_restart): likewise * src/actions.c (cmd_quit): just set the kill_signalled variable. (parse_wingravity): use compass directions to describe the gravity (parse_wingravity): renamed from parse_winpos. dependant code updated. (cmd_gravity): renamed from cmd_pos. dependant code updated. (cmd_defwingravity): renamed from cmd_defwinpos. dependant code updated. (cmd_deftransgravity): renamed from cmd_deftranspos. dependant code updated. (cmd_defmaxsizegravity): renamed from cmd_defmaxsizepos. dependant code updated. (cmd_focusup): new function (cmd_focusdown): likewise (cmd_focusleft): likewise (cmd_focusright): likewise (cmd_restart): likewise (cmd_startup_message): likewise (user_commands): new commands "focusup" "focusdown" "focusright" "focusleft" "startup_message" "restart".
2001-09-09* src/split.c (set_active_frame): give the key_window focus whensabetts
no window has focus. (blank_frame): give the key_window focus. * src/main.c (init_screen): don't listen for keystrokes on the root window. (main): give the key_window focus in the case that no window has focus.
2001-09-09* src/list.h (update_window_position): new prototypesabetts
(window_name): new prototype (get_window_list): update prototype * src/events.c (grab_rat): Don't wrap in an #ifdef (ungrab_rat): likewise (handle_key): record if the rat is grabbed and only ungrab it at the end if it was first grabbed. * src/actions.h (cmd_pos): new prototype (cmd_defwinpos): new prototype (cmd_deftranspos): new prototype (cmd_defmaxsizepos): new prototype (cmd_defbartimeout): new prototype (cmd_defbarloc): new prototype (cmd_deffont): new prototype (cmd_defpadding): new prototype (cmd_defborder): new prototype (cmd_definputwidth): new prototype (cmd_defwaitcursor): new prototype (cmd_defwinfmt): new prototype (cmd_defwinname): new prototype * src/messages.h (MESSAGE_FRAME_STRING): new message * src/manage.c (get_wmname): renamed from get_window_name (get_class_hints): new function (get_res_name): likewise (get_res_class): likewise (update_window_name): update the window's wm_name, res_name, and res_class fields. (update_window_name): calls functions get_wmname, get_res_name, get_res_class. (update_window_name): Don't crop the window name. (update_window_information): call update_window_position. (move_window): new function (maximize_transient): only set the window's width and height fields. (maximize_normal): likewise (maximize): call move_window (force_maximize): likewise (force_maximize): if the window has resize hints, resize it 1 resize unit. * src/main.c: new global variable, defaults. remove static variable, font, and move to defaults. Dependant code updated. (init_defaults): new function (main): call init_defaults. (init_screen): initialize the screen's fg_color to black and bg_color to white. * src/list.c (free_window): free the fields user_name, res_name, res_class, and wm_name. (update_window_position): new function (window_name): new function. Code accessing a window's name uses this function. All code updated. (add_to_window_list): call update_window_position (add_to_window_list): initialize wm_name, res_name, and res_class for the new window. (format_window_name): new function (get_window_list): Add parameter fmt. All callers updated. (get_window_list): call format_window_name. * src/conf.h: move Configuration variables to the global variable, defaults. Dependant code updated. * src/data.h (TOP_LEFT): new define (TOP_CENTER): likewise (TOP_RIGHT): likewise (CENTER_LEFT): likewise (CENTER_CENTER): likewise (CENTER_RIGHT): likewise (BOTTOM_LEFT): likewise (BOTTOM_CENTER): likewise (BOTTOM_RIGHT): likewise (struct rp_window): new fields user_name, wm_name, res_name, res_class, position. (struct rp_window): remove field name. Replaced with user_name. Dependant code updated. (struct screen_info): remove field font. dependant code updated. (struct screen_info): new fields fg_color, bg_color. (struct rp_defaults): new struct (defaults): new global * src/actions.c (parse_winpos): new function (cmd_pos): likewise (cmd_defwinpos): likewise (cmd_deftranspos): likewise (cmd_defmaxsizepos): likewise (cmd_defbartimeout): likewise (cmd_defbarloc): likewise (cmd_deffont): likewise (cmd_defpadding): likewise (cmd_defborder): likewise (cmd_definputwidth): likewise (cmd_defwaitcursor): likewise (cmd_defwinfmt): likewise (cmd_defwinname): likewise (user_commands): New commands defbarloc, defbartimeout, defborder, deffont, defintputwidth, defmaxsizepos, defpadding, deftranspos, defwaitcursor, defwinfmt, defwinname, defwinpos.
2001-08-31maximize bug fixed. frame indicator is less intrusivesabetts
2001-08-27code cleanup, unmap_notify bug fixessabetts
2001-08-26frame indicator suppressed when there is only 1 framesabetts
2001-08-23new code to handle transient windowssabetts
2001-08-18window flicker problems fixedsabetts