== Main Features/Changes for Users * Add horizontal bar at top of all non-temp windows, consisting out of two horizontal sub-bars. * Upper sub-bar contains global menus (File, Render, etc.), tabs for workspaces and scene selector. * Lower sub-bar contains object mode selector, screen-layout and render-layer selector. Later operator and/or tool settings will be placed here. * Individual sections of the topbar are individually scrollable. * Workspace tabs can be double- or ctrl-clicked for renaming and contain 'x' icon for deleting. * Top-bar should scale nicely with DPI. * The lower half of the top-bar can be hided by dragging the lower top-bar edge up. Better hiding options are planned (e.g. hide in fullscreen modes). * Info editors at the top of the window and using the full window width with be replaced by the top-bar. * In fullscreen modes, no more info editor is added on top, the top-bar replaces it. == Technical Features/Changes * Adds initial support for global areas A global area is part of the window, not part of the regular screen-layout. I've added a macro iterator to iterate over both, global and screen-layout level areas. When iterating over areas, from now on developers should always consider if they have to include global areas. * Adds a TOPBAR editor type The editor type is hidden in the UI editor type menu. * Adds a variation of the ID template to display IDs as tab buttons (template_ID_tabs in BPY) * Does various changes to RNA button creation code to improve their appearance in the horizontal top-bar. * Adds support for dynamically sized regions. That is, regions that scale automatically to the layout bounds. The code for this is currently a big hack (it's based on drawing the UI multiple times). This should definitely be improved. * Adds a template for displaying operator properties optimized for the top-bar. This will probably change a lot still and is in fact disabled in code. Since the final top-bar design depends a lot on other 2.8 designs (mainly tool-system and workspaces), we decided to not show the operator or tool settings in the top-bar for now. That means most of the lower sub-bar is empty for the time being. NOTE: Top-bar or global area data is not written to files or SDNA. They are simply added to the window when opening Blender or reading a file. This allows us doing changes to the top-bar without having to care for compatibility. == ToDo's It's a bit hard to predict all the ToDo's here are the known main ones: * Add options for the new active-tool system and for operator redo to the topbar. * Automatically hide the top-bar in fullscreen modes. * General visual polish. * Top-bar drag & drop support (WIP in temp-tab_drag_drop). * Improve dynamic regions (should also fix some layout glitches). * Make internal terminology consistent. * Enable topbar file writing once design is more advanced. * Address TODO's and XXX's in code :) Thanks @brecht for the review! And @sergey for the complaining ;) Differential Revision: D2758
84 lines
2.6 KiB
C++
84 lines
2.6 KiB
C++
/*
|
|
* ***** BEGIN GPL LICENSE BLOCK *****
|
|
*
|
|
* This program is free software; you can redistribute it and/or
|
|
* modify it under the terms of the GNU General Public License
|
|
* as published by the Free Software Foundation; either version 2
|
|
* of the License, or (at your option) any later version.
|
|
*
|
|
* This program is distributed in the hope that it will be useful,
|
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
* GNU General Public License for more details.
|
|
*
|
|
* You should have received a copy of the GNU General Public License
|
|
* along with this program; if not, write to the Free Software Foundation,
|
|
* Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
|
*
|
|
* The Original Code is Copyright (C) 2008 Blender Foundation.
|
|
* All rights reserved.
|
|
*
|
|
*
|
|
* Contributor(s): Blender Foundation
|
|
*
|
|
* ***** END GPL LICENSE BLOCK *****
|
|
*/
|
|
|
|
/** \file ED_space_api.h
|
|
* \ingroup editors
|
|
*/
|
|
|
|
#ifndef __ED_SPACE_API_H__
|
|
#define __ED_SPACE_API_H__
|
|
|
|
struct ARegionType;
|
|
struct bContext;
|
|
|
|
void ED_spacetypes_init(void);
|
|
void ED_spacemacros_init(void);
|
|
|
|
/* the pluginnable API for export to editors */
|
|
|
|
/* calls for registering default spaces */
|
|
void ED_spacetype_outliner(void);
|
|
void ED_spacetype_time(void);
|
|
void ED_spacetype_view3d(void);
|
|
void ED_spacetype_ipo(void);
|
|
void ED_spacetype_image(void);
|
|
void ED_spacetype_node(void);
|
|
void ED_spacetype_buttons(void);
|
|
void ED_spacetype_info(void);
|
|
void ED_spacetype_file(void);
|
|
void ED_spacetype_action(void);
|
|
void ED_spacetype_nla(void);
|
|
void ED_spacetype_script(void);
|
|
void ED_spacetype_text(void);
|
|
void ED_spacetype_sequencer(void);
|
|
void ED_spacetype_logic(void);
|
|
void ED_spacetype_console(void);
|
|
void ED_spacetype_userpref(void);
|
|
void ED_spacetype_clip(void);
|
|
void ED_spacetype_topbar(void);
|
|
|
|
/* calls for instancing and freeing spacetype static data
|
|
* called in WM_init_exit */
|
|
/* in space_file.c */
|
|
void ED_file_init(void);
|
|
void ED_file_exit(void);
|
|
|
|
#define REGION_DRAW_POST_VIEW 0
|
|
#define REGION_DRAW_POST_PIXEL 1
|
|
#define REGION_DRAW_PRE_VIEW 2
|
|
|
|
void *ED_region_draw_cb_activate(struct ARegionType *,
|
|
void (*draw)(const struct bContext *, struct ARegion *, void *),
|
|
void *custumdata, int type);
|
|
void ED_region_draw_cb_draw(const struct bContext *, struct ARegion *, int);
|
|
void ED_region_draw_cb_exit(struct ARegionType *, void *);
|
|
void *ED_region_draw_cb_customdata(void *handle);
|
|
/* generic callbacks */
|
|
/* ed_util.c */
|
|
void ED_region_draw_mouse_line_cb(const struct bContext *C, struct ARegion *ar, void *arg_info);
|
|
|
|
#endif /* __ED_SPACE_API_H__ */
|