add session.screenN.defaultDeco: <bitmask> to the apps file
This commit is contained in:
parent
6d4d17b5f9
commit
9d5e2f143b
6 changed files with 20 additions and 16 deletions
|
@ -1,6 +1,10 @@
|
|||
(Format: Year/Month/Day)
|
||||
Changes for 1.0rc3:
|
||||
*07/01/04:
|
||||
* Added new resource for init file to control default window decorations:
|
||||
session.screenN.defaultDeco: <bitmask>, where the bitmask corresponds
|
||||
to the one used for [Deco] in the apps file (Mark)
|
||||
Screen.cc/hh Window.cc/hh doc/asciidoc/fluxbox.txt
|
||||
* Move minimized windows to the back of the focused list (Mark)
|
||||
Window.cc FocusControl.cc/hh
|
||||
*07/01/03:
|
||||
|
|
|
@ -946,6 +946,11 @@ session.screen0.decorateTransient: <boolean>
|
|||
This controls whether or not transient windows get window decorations,
|
||||
such as a titlebar. Default: False
|
||||
|
||||
session.screen0.defaultDeco: <bitmask>
|
||||
This specifies the default window decorations, according to the same
|
||||
bitmask as used by the `[Deco]' option in the `apps' file, described later
|
||||
in this document. Default: all bits set.
|
||||
|
||||
session.screen0.menuMode: Delay|Click
|
||||
This setting controls the circumstances under which submenus open. With
|
||||
`Click', the user must click on the menu item in order for the submenu to
|
||||
|
|
|
@ -270,6 +270,7 @@ BScreen::ScreenResource::ScreenResource(FbTk::ResourceManager &rm,
|
|||
auto_raise(rm, false, scrname+".autoRaise", altscrname+".AutoRaise"),
|
||||
click_raises(rm, true, scrname+".clickRaises", altscrname+".ClickRaises"),
|
||||
decorate_transient(rm, false, scrname+".decorateTransient", altscrname+".DecorateTransient"),
|
||||
default_deco(rm, FluxboxWindow::DECORM_LAST-1, scrname+".defaultDeco", altscrname+".DefaultDeco"),
|
||||
rootcommand(rm, "", scrname+".rootCommand", altscrname+".RootCommand"),
|
||||
resize_model(rm, BOTTOMRESIZE, scrname+".resizeMode", altscrname+".ResizeMode"),
|
||||
tab_placement(rm, FbWinFrame::TOPLEFT, scrname+".tab.placement", altscrname+".Tab.Placement"),
|
||||
|
|
|
@ -120,6 +120,7 @@ public:
|
|||
bool doFullMax() const { return *resource.full_max; }
|
||||
bool doShowWindowPos() const { return *resource.show_window_pos; }
|
||||
bool decorateTransient() const { return *resource.decorate_transient; }
|
||||
unsigned int defaultDeco() const { return *resource.default_deco; }
|
||||
const std::string &windowMenuFilename() const { return *resource.windowmenufile; }
|
||||
FbTk::ImageControl &imageControl() { return *m_image_control.get(); }
|
||||
// menus
|
||||
|
@ -440,7 +441,8 @@ private:
|
|||
workspace_warping,
|
||||
desktop_wheeling, reverse_wheeling, show_window_pos,
|
||||
auto_raise, click_raises, decorate_transient;
|
||||
FbTk::Resource<std::string> rootcommand;
|
||||
FbTk::Resource<unsigned int> default_deco;
|
||||
FbTk::Resource<std::string> rootcommand;
|
||||
FbTk::Resource<ResizeModel> resize_model;
|
||||
FbTk::Resource<FbWinFrame::TabPlacement> tab_placement;
|
||||
FbTk::Resource<std::string> windowmenufile;
|
||||
|
|
|
@ -447,18 +447,8 @@ void FluxboxWindow::init() {
|
|||
m_blackbox_attrib.premax_x = m_blackbox_attrib.premax_y = 0;
|
||||
m_blackbox_attrib.premax_w = m_blackbox_attrib.premax_h = 0;
|
||||
|
||||
//use tab as default
|
||||
decorations.tab = true;
|
||||
// enable decorations
|
||||
decorations.enabled = true;
|
||||
|
||||
// set default values for decoration
|
||||
decorations.menu = true; //override menu option
|
||||
// all decorations on by default
|
||||
decorations.titlebar = decorations.border = decorations.handle = true;
|
||||
decorations.maximize = decorations.close =
|
||||
decorations.sticky = decorations.shade = decorations.tab = true;
|
||||
|
||||
// set default decorations but don't apply them
|
||||
setDecorationMask(screen().defaultDeco(), false);
|
||||
|
||||
functions.resize = functions.move = functions.iconify = functions.maximize = functions.close = functions.tabable = true;
|
||||
decorations.close = false;
|
||||
|
@ -3298,7 +3288,7 @@ unsigned int FluxboxWindow::decorationMask() const {
|
|||
return ret;
|
||||
}
|
||||
|
||||
void FluxboxWindow::setDecorationMask(unsigned int mask) {
|
||||
void FluxboxWindow::setDecorationMask(unsigned int mask, bool apply) {
|
||||
decorations.titlebar = mask & DECORM_TITLEBAR;
|
||||
decorations.handle = mask & DECORM_HANDLE;
|
||||
decorations.border = mask & DECORM_BORDER;
|
||||
|
@ -3310,7 +3300,9 @@ void FluxboxWindow::setDecorationMask(unsigned int mask) {
|
|||
decorations.shade = mask & DECORM_SHADE;
|
||||
decorations.tab = mask & DECORM_TAB;
|
||||
decorations.enabled = mask & DECORM_ENABLED;
|
||||
applyDecorations();
|
||||
// we don't want to do this during initialization
|
||||
if (apply)
|
||||
applyDecorations();
|
||||
}
|
||||
|
||||
void FluxboxWindow::startMoving(int x, int y) {
|
||||
|
|
|
@ -281,7 +281,7 @@ public:
|
|||
void toggleDecoration();
|
||||
|
||||
unsigned int decorationMask() const;
|
||||
void setDecorationMask(unsigned int mask);
|
||||
void setDecorationMask(unsigned int mask, bool apply = true);
|
||||
/**
|
||||
* Start moving process, grabs the pointer and draws move rectangle
|
||||
* @param x position of pointer
|
||||
|
|
Loading…
Reference in a new issue