Someone please review. Should errno be set to ENOMEM here?
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21903 a95241bf-73f2-0310-859d-f6bbb57e9c96
* Added a todo about unsafe access of the buffer
* Removed some types from is_type_swapped() to exactly mirror R5
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21902 a95241bf-73f2-0310-859d-f6bbb57e9c96
* Also swap the flattened size when creating the read buffer
* Define specialized byte_swap()s for unsigned types too so that type_code and the like get swapped correctly
This should fix bug #1371.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21901 a95241bf-73f2-0310-859d-f6bbb57e9c96
BView implementation (client side)
* introduced some private methods for _Convert*(BPoint*) methods which avoid
doing the check_lock() thing in the recursion, also Origin() would likely
have communicated with the app_server all the time, since the origin bit
was needlessly invalidated, so some speedup should be achieved
* this should fix ticket #98
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21900 a95241bf-73f2-0310-859d-f6bbb57e9c96
* compare recorded / restored picture to direct drawing into bitmap
* renamed Test Vertical Line -> Test Diagonal Line
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21898 a95241bf-73f2-0310-859d-f6bbb57e9c96
instead. Quite a few changes to account for the different interfaces.
The add-on size dropped from 438 to 302 KB, which is still quite heavy.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21893 a95241bf-73f2-0310-859d-f6bbb57e9c96
* Pulled the actual tree code into a non-templatized class AVLTree to
reduce the amount of code generated each time the template is
instantiated.
* Changed the iterator interface to Java-style.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21892 a95241bf-73f2-0310-859d-f6bbb57e9c96
implementation takes the byte count, even though it looks like this is
less efficient when the glyph count is already known (I tested to
optimize it away but it was not faster)
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21891 a95241bf-73f2-0310-859d-f6bbb57e9c96
since fault_find_page() does no longer insert a dummy page into a cache
that has a store from which it can read the page.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21887 a95241bf-73f2-0310-859d-f6bbb57e9c96
* Transfer removal is now done only from the finisher
* Processing is only done after the transfer has been removed from the list
* Canceling transfers only sets a flag so the finisher can remove the transfer
* The callback at cancel is done synchronously though
This fixes quite a few race conditions where transfers were processed while they where already removed. It could happen before that callbacks would have been called twice or freed descriptors/callback buffers were accessed.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21882 a95241bf-73f2-0310-859d-f6bbb57e9c96
* Removed a few instances where the page state was set busy directly after
allocating it. This is a no-op, since a page is always busy after
allocation.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21875 a95241bf-73f2-0310-859d-f6bbb57e9c96
cheap means to block threads until notified explicitely.
threads
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21874 a95241bf-73f2-0310-859d-f6bbb57e9c96
interrupts) and SpinLocker (acquires/releases spinlocks).
* Adjusted Jamfiles of components that used <util/AutoLock.h> but didn't
add all header directories required now (<int.h> was added).
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21873 a95241bf-73f2-0310-859d-f6bbb57e9c96
as all directories that might be needed by private kernel headers (arch,
platform,... headers).
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21872 a95241bf-73f2-0310-859d-f6bbb57e9c96
Now TermWindow::_SetTermColors() accepts a pointer to a TermView to fix
that.
Spotted by Andrea Bernardi. Thanks!
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21870 a95241bf-73f2-0310-859d-f6bbb57e9c96
Painter, that is needed to be able to tell if anti-aliasing is to be used,
since the flags in the font can be overruled by the flags in the view...
* fixes aliased fonts reliably, tested with FontDemo
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21869 a95241bf-73f2-0310-859d-f6bbb57e9c96
this for a long time... what happens when the app_server has requested a
redraw, but the client sends some drawing commands before starting the
redraw session? This would be the case, for example, when TextViews got
notified of their parent window becomming active (they would invert the
selection outside of any update session). When there was an additional
expose event, the app_server would already have the background cleared, so
the lonely "invert" command would invert the freshly painted background. Then
the normal Draw() of the TextView would be called because of the expose event.
By the time the text was rendered, it was rendered on the inverted background,
then the normal Draw() contained another "invert" command to invert the
region of the selection. Thus inverting just the text, and the background
twice. Solution:
* introduced a special handling for drawing commands arriving between
requested update session and beginning of that session: the pending
update region is clipped from the region the client is allowed to draw in.
* fixes funny text rendering in the selected part of text views. For example
ticket #908.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21867 a95241bf-73f2-0310-859d-f6bbb57e9c96
* fixed a bug in the font cache, the signature was generated in one way
(rendering type) while the initialization of the font engine could
use another way
* should fix non-antialiased straight text
* weird non-transformed text in FontDemo
* generally not using vector glyphs when it was supposed to use them (rotated
or sheared text, or non-antialiased text)
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21866 a95241bf-73f2-0310-859d-f6bbb57e9c96
it's reference to the vm_address_space - luckily, it doesn't even need a
reference, since it always runs in the current address space, which cannot
go away for obvious reasons.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21865 a95241bf-73f2-0310-859d-f6bbb57e9c96
* fixes a dead lock in vm_soft_fault() - the locking scheme enforces you to
lock the address space before a vm_cache, not the other way, around. Since
we need to lock the cache that has our page in fault_get_page(), we violated
that scheme by relocking the address space in order to get access to the
vm_area. Now, we read lock the address space during the whole page fault;
added a TODO that explains why this might not really be desirable, if
we can avoid it (the only way would be to reverse that locking scheme
which would potentially cause the more busy vm_cache locks to be held
longer).
* vm_copy_area() uses the MultiAddressSpaceLocker, but actually forget to
call Lock() on it...
* delete_area() leaks vm_address_space references - but fixing this currently
causes other problems to be investigated; I'll open a bug for that.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21862 a95241bf-73f2-0310-859d-f6bbb57e9c96
that they are blurry anyways, should give you a perfectly scalable version of
the logo in SVG
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21859 a95241bf-73f2-0310-859d-f6bbb57e9c96
(fixes ticket #1367, stefano I thought you knew that I meant this in an
earlier mail)
* move_pen_by() looked wrong in ServerPicture, have not tested though
* make sure the pen location is adjusted after stroke_line() and draw_string()
in ServerPicture
* set_pen_location() does not need to update the Painter drawing state
* ServerWindow AS_LAYER_SET_PEN_SIZE needs to set the resulting pen size of
the drawing state stack, not the one set on the current state
* ServerWindow AS_LAYER_GET_PEN_SIZE needs to return the current state's
size, not the result of the stack
* small cleanups
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21855 a95241bf-73f2-0310-859d-f6bbb57e9c96
and that the previous pattern is restored after execution
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21853 a95241bf-73f2-0310-859d-f6bbb57e9c96