* DrawString() took the fast clipping path for rotated fonts which didn't work
out (visible when moving a window over the rotated texts in DriveSetup).
* Also, made it work correctly when using sheared fonts.
* Fixed typo.
* Automatic whitespace cleanup.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@28741 a95241bf-73f2-0310-859d-f6bbb57e9c96
-Make the window resizable. BUT as this is a multitab window when I resize, only the view in the active TAB is resized, as soon as I switch to another TAB the view in the new selected tab has its old size, messing all.
* Can any UI guru explain whats the Best/Elegant way fixing this?
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@28735 a95241bf-73f2-0310-859d-f6bbb57e9c96
a message.
* The DesktopSettings class is now using that to send the new
AS_SYSTEM_FONT_CHANGED message to all windows.
* The ServerWindow now propagates font changes to its decorator, causing it
to update its drawing. That means changing the bold font in the "Fonts"
preferences application will instantly change all window titles.
* Factored out a _RebuildAndRedrawAfterWindowChange() out of several Desktop
methods, simplifying some code.
* The DefaultDecorator no longer calls _DoLayout() twice (through SetLook()),
but instead calls the new _UpdateFont() method now also called by
FontsChanged(), and SetLook().
* BWindow::GetDecoratorSettings() now also includes "tab frame" BRect with the
exact footprint of the tab, allowing apps to know the size of the tab to
position itself accordingly.
* Automatic white space cleanup.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@28664 a95241bf-73f2-0310-859d-f6bbb57e9c96
window being the focus window that is a subset of the specified window.
* This is now used to bring the window to front belonging to a floating
or modal window (if on another workspace), ie. Desktop::ActivateWindow()
should now work with modal and floating windows.
* Fixed typo (in Window.cpp).
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@28649 a95241bf-73f2-0310-859d-f6bbb57e9c96
class/namespace. Renamed the B_GRADIENT_* types to TYPE_* as the context
is already given.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@28564 a95241bf-73f2-0310-859d-f6bbb57e9c96
consider the workspaces in the configured count.
* If the window is not on the current workspace after the workspace check,
always move it to the current instead. This lets windows on workspaces
outside of the ones currently configured show up on the current workspace
as if they had the B_NOT_ANCHORED_ON_ACTIVATE flag set.
* This fixes bug #3003.
* Minor cleanup.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@28549 a95241bf-73f2-0310-859d-f6bbb57e9c96
slightly strange redrawing, including scrolling the offscreen view
that it uses in "flicker free" mode (which is the default). Invalidation
does not work in offscreen windows, since the client thread is not running
and certainly won't redraw anything. But that will leave a non-drawable
region on the app_server side of things. Simply don't invalidate in
this case. From what I have seen, redrawing in NetPositive seems to
work fine now.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@28538 a95241bf-73f2-0310-859d-f6bbb57e9c96
for most messages, use debug_printf(), cleanup line breaks
* check return code of last link method in a lot more places
* changed some printf() and fprintf() into debug_printf()
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@28537 a95241bf-73f2-0310-859d-f6bbb57e9c96
on uninitialized accelerant, but that's what AS_GET_DRIVER_PATH is for.
* This should fix#2847.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@28534 a95241bf-73f2-0310-859d-f6bbb57e9c96
wrong check to see if the view was currently visible. This fixes the problem
that tool tips would popup for windows that are located on other workspaces.
* Removed commented out code that is no longer needed.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@28498 a95241bf-73f2-0310-859d-f6bbb57e9c96
SetMouseEventMask() from within it's mouse hooks. Among other things,
scroll bars won't stop scrolling in FFM mode now if you accidentally
leave the window with the mouse, something which is very likely.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@28481 a95241bf-73f2-0310-859d-f6bbb57e9c96
both double buffering and single buffering, Invalidate() needs to be
virtual and ViewHWInterface needs to decide where to invalidate it's host
window.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@28480 a95241bf-73f2-0310-859d-f6bbb57e9c96
device returned B_OK.
* In the InputServer destructor, don't check the fAddOnManager pointer,
but check the success of calling Lock() on it instead, which should
be much safer.
* In StartStopDevices(), really start or stop all published devices for
the given BInputServerDevice, not only the first one found. Simplify
the check whether anything needs to be done.
* Change a bit the return codes of StartStopDevices(). Especially the
version that's supposed to start or stop all devices will still try
to do it for the rest of them.
* Removed no longer needed _FindInputDeviceListItem().
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@28351 a95241bf-73f2-0310-859d-f6bbb57e9c96
at 0. A single AddPath()+RemovePath() would therefore leave a not
anymore needed path_entry(), while a AddPath()+AddPath()+RemovePath()
would remove/delete the path_entry while it was actually still used.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@28349 a95241bf-73f2-0310-859d-f6bbb57e9c96
tab width. This fixes the initially wrong tab width for windows where the title
does not fit and previously there would be 10 pixels waste on the right.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@28331 a95241bf-73f2-0310-859d-f6bbb57e9c96
device path, but instead pointing to memory owned by some device addon
instance.
* Added TODO in the AddOnManager init code about a possible race condition
which I have not varified yet.
* Check the return code of BList::RemoveItem() before deleting the item...
pure defensive programming.
* For the time being, print a warning into the syslog when a device name is
registered twice.
* When failing to Unflatten() an event, don't continue in the code after
deleting it.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@28319 a95241bf-73f2-0310-859d-f6bbb57e9c96
* Use new(nothrow) to allocate the MethodReplicant.
* fSignature needs to be free()d, not deleted.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@28318 a95241bf-73f2-0310-859d-f6bbb57e9c96
weird.
* Set fHandler to NULL in _UnregisterAddOns(), just in case it is called
twice (which it probably never is... but be defensive).
* If a B_NODE_MONITOR message does not contain all the necessary fields,
drop into the debugger when compiling in DEBUG mode.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@28317 a95241bf-73f2-0310-859d-f6bbb57e9c96
feels. This caused floating/modal app and subset windows to not work anymore.
* This fixes bug #2914.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@28309 a95241bf-73f2-0310-859d-f6bbb57e9c96
* Fixed unloading the add-on image twice in error case of failing to
add the add-on info to the list.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@28307 a95241bf-73f2-0310-859d-f6bbb57e9c96
* In this case, SoundRecorder shows a different error message, more informative, confer bug #134
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@28303 a95241bf-73f2-0310-859d-f6bbb57e9c96
updates during the vertical refresh, but it causes flickering again since
there is no guarantee that screen regions will stay clean from the time that
they were scheduled with the UpdateQueue until the UpdateQueue thread
transfers them. Therefor it is still disabled.
* Refactored a bit the distinction between Invalidate() and CopyToFront().
Invalidate() used to be virtual, but now CopyToFront() is. This was mainly
needed for the app_server test environment, because the host window needs
to call Invalidate() when the front buffer bitmap is clean. When the
UpdateQueue is used, this needs to be CopyToFront(). Now the separation is
cleaner in combination with the UpdateQueue.
* Fixed a problem in HWInterface::CopyToFront(): When separating the region
outside the cursor and the region with the cursor during a transfer, it
needs to hold the fFloatingOverlay lock to make sure the cursor is not
moved in the meantime. This fixes graphics glitches with remnants of the
cursor staying on screen. These could very rarely be observed, but much more
often with the accelerated double-buffer mode.
* Enabled the accelerated double buffered mode, since it works now very well.
I was able to test it with the nVidea driver on an nVideo 7300. It works by
allocating a frame buffer twice the height of the configured screen mode.
Then all drawing goes into the offscreen portion, including accelerated
driver functions. AccelerantHWInterface::_CopyToFront() then uses acceleration
to blit the clean regions in the offscreen portion of the frame buffer into
the visible part. Please tell me if there are problems, for example when
if there is too few video memory, or if a driver does not handle it correctly.
To disable it, see src/servers/app/drawing/AccelerantHWInterface.cpp line 511.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@28301 a95241bf-73f2-0310-859d-f6bbb57e9c96
when the HWInterface was using acceleration and at the same time double
buffering.
* _CopyToFront() should always be used, since it calls a protected virtual that
derived classes of HWInterface depend on. This fixes some graphics glitches
in certain situations.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@28300 a95241bf-73f2-0310-859d-f6bbb57e9c96
workspaces between this and the previous one.
* Note that this is mapped to a specific key on the keyboard (key 17), so
it will differ with the keymap, but will usually be the key below the escape
key.
* This closes ticket #2766.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@28282 a95241bf-73f2-0310-859d-f6bbb57e9c96
* Changed the password window to use this feel.
* Later, the screen saver itself should use this feel whenever the password
mode is enabled. The password window should then use a modal-app feel, but
this doesn't work yet.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@28281 a95241bf-73f2-0310-859d-f6bbb57e9c96
* Renamed _BDeviceAddOn_ to DeviceAddOn, and put it into the BPrivate namespace.
* Moved the DeviceManager functionality into the AddOnManager - this also
solves a locking issue, as BInputServerDevice::Control() was called in the
context of the DeviceManager before.
* The AddOnManager now uses the BPathMonitor to monitor the devices that
BInputServerDevices ask for - this greatly simplifies the code.
* Got rid of TList.h, and use ObjectList.h instead.
* Added PathList class that has a list of paths with reference count, used by
DeviceAddOn and the AddOnManager.
* DeviceAddOn got an actual implementation that lives in InputServerDevice.cpp.
* Added an experimental BInputServerDevice::AddDevices() that could be used
instead of recursing over devices manually. It replaces the functionality
that was found in the DeviceManager before (this was done implicitely for
all monitored devices).
* Greatly cleaned up and simplified the AddOnManager.
* Also fixed lots of potential errors/leaks when things go wrong.
* Removed the extra locker in AddOnManager - its BLooper lock is now used
instead.
* Replaced PRINT()/PRINTERR() macros in the AddOnManager with TRACE(), and
ERROR(), both now use debug_printf().
* Hopefully this fixes the problem that I don't have keyboard under VirtualBox
from time to time.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@28241 a95241bf-73f2-0310-859d-f6bbb57e9c96
that solves most app_server locking headaches: it now works asynchronously,
and therefore doesn't need to lock the EventDispatcher anymore.
* EventStreams now allow to inject messages into the stream to allow the above
functionality.
* InputServerStream::GetNextEvent() no longer returns when there is no event.
* Desktop::ActivateWindow() now locks all windows before checking the
workspaces of the windows, fixing a race condition that could lead to
Window::Foremost() being called for a window that isn't on the current
workspace, leading to a crash.
* I currently cannot access Trac, but I recall there should be an open bug
report about this.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@28224 a95241bf-73f2-0310-859d-f6bbb57e9c96
Desktop::ActivateWindow(), or Desktop::SendWindowBehind().
* This fixes a potential deadlock.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@28217 a95241bf-73f2-0310-859d-f6bbb57e9c96
As a consequence this setting was lost unless another setting was also altered
that affected the workspace configuration in some way.
Fixes#2849.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@28206 a95241bf-73f2-0310-859d-f6bbb57e9c96
set to its current position if that is the only workspace it's in.
* This fixes missing windows on other workspaces in the Workspaces app after
boot, ie. before you had visited that workspace.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@28204 a95241bf-73f2-0310-859d-f6bbb57e9c96
which call into Desktop methods which in turn grab the window
write lock are never supposed to hold this write lock themselves
already, since the Desktop code takes care to not hold the lock
when for example calling EventDispatcher methods, which would
cause a deadlock (as in this example).
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@28175 a95241bf-73f2-0310-859d-f6bbb57e9c96
(it would do that internally anyway).
* AS_MINIMIZE no longer calls _Show() when being unminimized, but
Desktop::ActivateWindow(), as this will also bring the window on the screen
if it's on another workspace (according to its flags).
* Whitespace cleanup.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@28168 a95241bf-73f2-0310-859d-f6bbb57e9c96
* Resolved TODO: The type of the gradient is no longer encoded twice in the
app_server link protocoll.
* Moved instantiation of the BGradient into the LinkReceiver::ReadGradient()
method.
* Check success for (at least) ReadGradient() in ServerWindow.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@28150 a95241bf-73f2-0310-859d-f6bbb57e9c96
* Implemented BGradient, BGradientLinear, BGradientRadial,
BGradientDiamond, BGradientConic and BGradientRadialFocus
new Interface Kit classes.
* Implemented all the (AGG-based) backend necessary in
the app_server to render gradients (Painter, DrawingEngine)
* app_server/View can convert a BGradient layout to screen
coordinates.
* Added BGradient methods of the Fill* methods in BView.
* Implemented a test app and added it to the image as a
demo.
* Adopted Icon-O-Matic and libs/icon in order to avoid
clashing with the new BGradient class. Re-use some
parts where possible.
Awesome work, Artur! Thanks a lot. Now a more modern
looking GUI has just become much easier to implement! :-)
TODO:
* Remove the need to have gradient type twice in the
app_server protocol.
* Refactor some parts of the patch to remove duplicated
code (Painter, DrawingEngine).
* Adopt the BPicture protocol to know about BGradients.
* Review some parts of the BArchivable implementation.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@28109 a95241bf-73f2-0310-859d-f6bbb57e9c96