/haiku/src/tests/kits/interface/flatten_picture/ |
H A D | PictureTestCases.cpp | 32 static void testNoOp(BView *view, BRect frame) in testNoOp() argument 37 static void testDrawChar(BView *view, BRect frame) in testDrawChar() argument 39 view->MovePenTo(frame.left, frame.bottom - 5); in testDrawChar() 42 view->DrawChar('B', BPoint(frame.left + 20, frame.bottom - 5)); in testDrawChar() 45 static void testDrawString(BView *view, BRect frame) in testDrawString() argument 51 float baseline = frame.bottom - height.descent; in testDrawString() 54 view->StrokeLine(BPoint(frame.left, baseline - 1), BPoint(frame.right, baseline -1)); in testDrawString() 57 view->DrawString("Haiku [ÖÜÄöüä]", BPoint(frame.left, baseline)); in testDrawString() 60 static void testDrawStringWithLength(BView *view, BRect frame) in testDrawStringWithLength() argument 66 float baseline = frame.bottom - height.descent; in testDrawStringWithLength() [all …]
|
/haiku/src/system/kernel/arch/riscv64/ |
H A D | arch_user_debugger.cpp | 48 iframe* frame = thread_get_current_thread()->arch_info.userFrame; in arch_set_debug_cpu_state() local 50 frame->ra = cpuState->x[ 0]; in arch_set_debug_cpu_state() 51 frame->sp = cpuState->x[ 1]; in arch_set_debug_cpu_state() 52 frame->gp = cpuState->x[ 2]; in arch_set_debug_cpu_state() 53 frame->tp = cpuState->x[ 3]; in arch_set_debug_cpu_state() 54 frame->t0 = cpuState->x[ 4]; in arch_set_debug_cpu_state() 55 frame->t1 = cpuState->x[ 5]; in arch_set_debug_cpu_state() 56 frame->t2 = cpuState->x[ 6]; in arch_set_debug_cpu_state() 57 frame->fp = cpuState->x[ 7]; in arch_set_debug_cpu_state() 58 frame->s1 = cpuState->x[ 8]; in arch_set_debug_cpu_state() [all …]
|
H A D | arch_thread.cpp | 124 iframe frame; in arch_thread_enter_userspace() local 125 memset(&frame, 0, sizeof(frame)); in arch_thread_enter_userspace() 131 frame.status = status.val; in arch_thread_enter_userspace() 132 frame.epc = entry; in arch_thread_enter_userspace() 133 frame.a0 = (addr_t)arg1; in arch_thread_enter_userspace() 134 frame.a1 = (addr_t)arg2; in arch_thread_enter_userspace() 135 frame.ra = threadExitAddr; in arch_thread_enter_userspace() 136 frame.sp = thread->user_stack_base + thread->user_stack_size; in arch_thread_enter_userspace() 137 frame.tp = thread->user_local_storage; in arch_thread_enter_userspace() 139 arch_load_user_iframe(stackHeader, &frame); in arch_thread_enter_userspace() [all …]
|
H A D | arch_debug.cpp | 41 iframe_is_user(iframe* frame) in iframe_is_user() argument 43 return SstatusReg{.val = frame->status}.spp == modeU; in iframe_is_user() 103 stack_frame frame; in get_next_frame_no_debugger() local 106 memcpy(&frame, (stack_frame*)fp - 1, sizeof(frame)); in get_next_frame_no_debugger() 108 || user_memcpy(&frame, (stack_frame*)fp - 1, sizeof(frame)) != B_OK) { in get_next_frame_no_debugger() 112 *_pc = frame.return_address; in get_next_frame_no_debugger() 113 *_next = frame.previous; in get_next_frame_no_debugger() 124 stack_frame frame; in get_next_frame_debugger() local 125 if (debug_memcpy(B_CURRENT_TEAM, &frame, (stack_frame*)fp - 1, sizeof(frame)) != B_OK) in get_next_frame_debugger() 128 *_pc = frame.return_address; in get_next_frame_debugger() [all …]
|
/haiku/src/system/kernel/arch/ppc/ |
H A D | arch_debug.cpp | 58 stack_frame *frame; in get_current_stack_frame() local 59 asm volatile("mr %0, %%r1" : "=r"(frame)); in get_current_stack_frame() 60 return frame; in get_current_stack_frame() 67 stack_frame frame; in get_next_frame() local 68 if (debug_memcpy(B_CURRENT_TEAM, &frame, (void*)framePointer, sizeof(frame)) in get_next_frame() 73 *ip = frame.return_address; in get_next_frame() 74 *next = (addr_t)frame.previous; in get_next_frame() 186 struct iframe *frame = NULL; in stack_trace() local 190 frame = frameStack->frames[i]; in stack_trace() 195 if (frame) { in stack_trace() [all …]
|
H A D | arch_int.cpp | 81 print_iframe(struct iframe *frame) in print_iframe() argument 83 dprintf("iframe at %p:\n", frame); in print_iframe() 84 dprintf("r0-r3: 0x%08lx 0x%08lx 0x%08lx 0x%08lx\n", frame->r0, frame->r1, frame->r2, frame->r3); in print_iframe() 85 dprintf("r4-r7: 0x%08lx 0x%08lx 0x%08lx 0x%08lx\n", frame->r4, frame->r5, frame->r6, frame->r7); in print_iframe() 86 …dprintf("r8-r11: 0x%08lx 0x%08lx 0x%08lx 0x%08lx\n", frame->r8, frame->r9, frame->r10, frame->r11… in print_iframe() 87 …dprintf("r12-r15: 0x%08lx 0x%08lx 0x%08lx 0x%08lx\n", frame->r12, frame->r13, frame->r14, frame->r… in print_iframe() 88 …dprintf("r16-r19: 0x%08lx 0x%08lx 0x%08lx 0x%08lx\n", frame->r16, frame->r17, frame->r18, frame->r… in print_iframe() 89 …dprintf("r20-r23: 0x%08lx 0x%08lx 0x%08lx 0x%08lx\n", frame->r20, frame->r21, frame->r22, frame->r… in print_iframe() 90 …dprintf("r24-r27: 0x%08lx 0x%08lx 0x%08lx 0x%08lx\n", frame->r24, frame->r25, frame->r26, frame->r… in print_iframe() 91 …dprintf("r28-r31: 0x%08lx 0x%08lx 0x%08lx 0x%08lx\n", frame->r28, frame->r29, frame->r30, frame->r… in print_iframe() [all …]
|
/haiku/src/system/kernel/arch/arm/ |
H A D | arch_thread.cpp | 47 arm_push_iframe(struct iframe_stack *stack, struct iframe *frame) in arm_push_iframe() argument 50 stack->frames[stack->index++] = frame; in arm_push_iframe() 199 iframe frame = {}; in arch_thread_enter_userspace() local 200 frame.r0 = (uint32)args1; in arch_thread_enter_userspace() 201 frame.r1 = (uint32)args2; in arch_thread_enter_userspace() 202 frame.usr_sp = stackTop; in arch_thread_enter_userspace() 203 frame.usr_lr = ((addr_t*)commPageAddress)[COMMPAGE_ENTRY_ARM_THREAD_EXIT] in arch_thread_enter_userspace() 205 frame.pc = entry; in arch_thread_enter_userspace() 208 arch_return_to_userland(&frame); in arch_thread_enter_userspace() 218 struct iframe* frame = thread->arch_info.userFrame; in arch_on_signal_stack() local [all …]
|
H A D | arch_int.cpp | 103 print_iframe(const char *event, struct iframe *frame) in print_iframe() argument 110 frame->r0, frame->r1, frame->r2, frame->r3, in print_iframe() 111 frame->r4, frame->r5, frame->r6, frame->r7); in print_iframe() 114 frame->r8, frame->r9, frame->r10, frame->r11, in print_iframe() 115 frame->r12, frame->svc_sp, frame->svc_lr, frame->pc); in print_iframe() 117 frame->usr_sp, frame->usr_lr, frame->spsr); in print_iframe() 349 arch_arm_page_fault(struct iframe *frame, addr_t far, uint32 fsr, bool isWrite, bool isExec) in arch_arm_page_fault() argument 355 bool isUser = (frame->spsr & CPSR_MODE_MASK) == CPSR_MODE_USR; in arch_arm_page_fault() 359 print_iframe("Page Fault", frame); in arch_arm_page_fault() 363 IFrameScope scope(frame); in arch_arm_page_fault() [all …]
|
/haiku/src/system/kernel/arch/x86/64/ |
H A D | thread.cpp | 82 x86_restart_syscall(iframe* frame) in x86_restart_syscall() argument 91 frame->ax = frame->orig_rax; in x86_restart_syscall() 92 frame->ip -= 2; in x86_restart_syscall() 121 get_signal_stack(Thread* thread, iframe* frame, struct sigaction* action, in get_signal_stack() argument 127 && (frame->user_sp < thread->signal_stack_base in get_signal_stack() 128 || frame->user_sp >= thread->signal_stack_base in get_signal_stack() 138 return (uint8*)((frame->user_sp - 128 - spaceNeeded) & ~addr_t(0xf)) - 8; in get_signal_stack() 298 iframe frame = {}; in arch_thread_enter_userspace() local 299 frame.type = IFRAME_TYPE_SYSCALL; in arch_thread_enter_userspace() 300 frame.si = (uint64)args2; in arch_thread_enter_userspace() [all …]
|
/haiku/src/system/kernel/arch/x86/32/ |
H A D | thread.cpp | 85 x86_restart_syscall(struct iframe* frame) in x86_restart_syscall() argument 92 frame->ax = frame->orig_eax; in x86_restart_syscall() 93 frame->dx = frame->orig_edx; in x86_restart_syscall() 94 frame->ip -= 2; in x86_restart_syscall() 125 get_signal_stack(Thread* thread, struct iframe* frame, struct sigaction* action, in get_signal_stack() argument 131 && (frame->user_sp < thread->signal_stack_base in get_signal_stack() 132 || frame->user_sp >= thread->signal_stack_base in get_signal_stack() 138 return (uint8*)((frame->user_sp - spaceNeeded) & ~addr_t(0xf)) - 4; in get_signal_stack() 246 iframe frame = {}; in arch_thread_enter_userspace() local 247 frame.type = IFRAME_TYPE_SYSCALL; in arch_thread_enter_userspace() [all …]
|
/haiku/src/system/kernel/arch/x86/ |
H A D | arch_debug.cpp | 73 stack_frame frame; in get_next_frame_no_debugger() local 75 && is_kernel_stack_address(thread, bp + sizeof(frame) - 1)) { in get_next_frame_no_debugger() 76 memcpy(&frame, (void*)bp, sizeof(frame)); in get_next_frame_no_debugger() 78 || user_memcpy(&frame, (void*)bp, sizeof(frame)) != B_OK) { in get_next_frame_no_debugger() 82 *_ip = frame.return_address; in get_next_frame_no_debugger() 83 *_next = (addr_t)frame.previous; in get_next_frame_no_debugger() 94 stack_frame frame; in get_next_frame_debugger() local 95 if (debug_memcpy(B_CURRENT_TEAM, &frame, (void*)bp, sizeof(frame)) != B_OK) in get_next_frame_debugger() 98 *_ip = frame.return_address; in get_next_frame_debugger() 99 *_next = (addr_t)frame.previous; in get_next_frame_debugger() [all …]
|
H A D | arch_int.cpp | 87 x86_invalid_exception(iframe* frame) in x86_invalid_exception() argument 92 (long unsigned int)frame->vector, in x86_invalid_exception() 93 exception_name(frame->vector, name, sizeof(name)), in x86_invalid_exception() 94 (long unsigned int)frame->ip, thread ? thread->id : -1); in x86_invalid_exception() 99 x86_fatal_exception(iframe* frame) in x86_fatal_exception() argument 103 exception_name(frame->vector, name, sizeof(name)), in x86_fatal_exception() 104 (long unsigned int)frame->error_code); in x86_fatal_exception() 109 x86_unexpected_exception(iframe* frame) in x86_unexpected_exception() argument 117 switch (frame->vector) { in x86_unexpected_exception() 122 signalAddress = frame->ip; in x86_unexpected_exception() [all …]
|
H A D | arch_thread.cpp | 30 extern "C" void x86_return_to_userland(iframe* frame); 39 find_previous_iframe(Thread* thread, addr_t frame) in find_previous_iframe() argument 42 while (frame >= thread->kernel_stack_base in find_previous_iframe() 43 && frame < thread->kernel_stack_top) { in find_previous_iframe() 44 addr_t previousFrame = *(addr_t*)frame; in find_previous_iframe() 48 return (struct iframe*)frame; in find_previous_iframe() 51 frame = previousFrame; in find_previous_iframe() 59 get_previous_iframe(struct iframe* frame) in get_previous_iframe() argument 61 if (frame == NULL) in get_previous_iframe() 64 return find_previous_iframe(thread_get_current_thread(), frame->bp); in get_previous_iframe() [all …]
|
H A D | arch_user_debugger.cpp | 79 get_iframe_registers(const iframe* frame, debug_cpu_state* cpuState) in get_iframe_registers() argument 82 cpuState->r15 = frame->r15; in get_iframe_registers() 83 cpuState->r14 = frame->r14; in get_iframe_registers() 84 cpuState->r13 = frame->r13; in get_iframe_registers() 85 cpuState->r12 = frame->r12; in get_iframe_registers() 86 cpuState->r11 = frame->r11; in get_iframe_registers() 87 cpuState->r10 = frame->r10; in get_iframe_registers() 88 cpuState->r9 = frame->r9; in get_iframe_registers() 89 cpuState->r8 = frame->r8; in get_iframe_registers() 90 cpuState->rbp = frame->bp; in get_iframe_registers() [all …]
|
/haiku/src/system/kernel/arch/arm64/ |
H A D | arch_int.cpp | 75 print_iframe(const char *event, struct iframe *frame) in print_iframe() argument 81 frame->elr, frame->spsr); in print_iframe() 83 frame->lr, frame->sp); in print_iframe() 231 do_sync_handler(iframe * frame) in do_sync_handler() argument 234 print_iframe("Sync abort", frame); in do_sync_handler() 237 IFrameScope scope(frame); in do_sync_handler() 240 switch (ESR_ELx_EXCEPTION(frame->esr)) { in do_sync_handler() 247 bool write = (frame->esr & ISS_DATA_WnR) != 0; in do_sync_handler() 252 bool addrType = (frame->far & (1UL << 63)) != 0; in do_sync_handler() 259 switch (frame->esr & ISS_DATA_DFSC_MASK) { in do_sync_handler() [all …]
|
/haiku/src/apps/pulse/ |
H A D | ProgressBar.cpp | 156 BRect frame = Bounds(); in Draw() local 157 StrokeLine(BPoint(frame.left, frame.top), BPoint(frame.right, frame.top)); in Draw() 158 StrokeLine(BPoint(frame.left, frame.top + 1), BPoint(frame.right, in Draw() 159 frame.top + 1)); in Draw() 160 StrokeLine(BPoint(frame.left, frame.top), BPoint(frame.left, in Draw() 161 frame.bottom)); in Draw() 162 StrokeLine(BPoint(frame.left + 1, frame.top), in Draw() 163 BPoint(frame.left + 1, frame.bottom)); in Draw() 166 StrokeLine(BPoint(frame.right-1, frame.top + 2), in Draw() 167 BPoint(frame.right - 1, frame.bottom)); in Draw() [all …]
|
/haiku/src/system/kernel/arch/m68k/ |
H A D | arch_debug.cpp | 59 stack_frame *frame; in get_current_stack_frame() local 60 asm volatile("move.l %%fp,%0" : "=r"(frame)); in get_current_stack_frame() 61 return frame; in get_current_stack_frame() 68 stack_frame frame; in get_next_frame() local 69 if (debug_memcpy(B_CURRENT_TEAM, &frame, (void*)framePointer, sizeof(frame)) in get_next_frame() 74 *ip = frame.return_address; in get_next_frame() 75 *next = (addr_t)frame.previous; in get_next_frame() 186 struct iframe *frame = NULL; in stack_trace() local 190 frame = frameStack->frames[i]; in stack_trace() 195 if (frame) { in stack_trace() [all …]
|
/haiku/src/tests/servers/app/draw_after_children/ |
H A D | DrawAfterChildren.cpp | 59 TestView(BRect frame); 67 TestView::TestView(BRect frame) in TestView() argument 68 : BView(frame, "TestView", B_FOLLOW_ALL, in TestView() 114 ChildView(BRect frame, const char* name, rgb_color viewColor); 121 ChildView::ChildView(BRect frame, const char* name, rgb_color viewColor) in ChildView() argument 122 : BView(frame, name, B_FOLLOW_ALL, 0) in ChildView() 151 BRect frame(100, 100, 700, 400); in main() local 152 BWindow* window = new BWindow(frame, "Window", in main() 155 frame.OffsetTo(B_ORIGIN); in main() 156 TestView* view = new TestView(frame); in main() [all …]
|
/haiku/src/add-ons/kernel/drivers/network/ether/wb840/ |
H A D | interface.c | 96 wb_mii_readreg(wb_device *device, wb_mii_frame *frame) in wb_mii_readreg() argument 103 frame->mii_stdelim = WB_MII_STARTDELIM; in wb_mii_readreg() 104 frame->mii_opcode = WB_MII_READOP; in wb_mii_readreg() 105 frame->mii_turnaround = 0; in wb_mii_readreg() 106 frame->mii_data = 0; in wb_mii_readreg() 120 mii_send(device, frame->mii_stdelim, 2); in wb_mii_readreg() 121 mii_send(device, frame->mii_opcode, 2); in wb_mii_readreg() 122 mii_send(device, frame->mii_phyaddr, 5); in wb_mii_readreg() 123 mii_send(device, frame->mii_regaddr, 5); in wb_mii_readreg() 163 frame->mii_data |= i; in wb_mii_readreg() [all …]
|
/haiku/src/apps/icon-o-matic/generic/gui/popup_control/ |
H A D | PopupControl.cpp | 83 BRect frame(fPopupWindow->Frame()); in ShowPopup() local 97 frame.OffsetTo(leftLocation); in ShowPopup() 101 if (frame.Width() > dest.Width()) in ShowPopup() 102 frame.right = frame.left + dest.Width(); in ShowPopup() 103 if (frame.Height() > dest.Height()) in ShowPopup() 104 frame.bottom = frame.top + dest.Height(); in ShowPopup() 108 if (frame.bottom > dest.bottom) in ShowPopup() 109 vOffset = dest.bottom - frame.bottom; in ShowPopup() 110 if (frame.top < dest.top) in ShowPopup() 111 vOffset = dest.top - frame.top; in ShowPopup() [all …]
|
/haiku/src/apps/launchbox/ |
H A D | support.cpp | 89 make_sure_frame_is_on_screen(BRect& frame, BWindow* window) in make_sure_frame_is_on_screen() argument 95 if (frame.IsValid() && screen->IsValid()) { in make_sure_frame_is_on_screen() 97 if (!screenFrame.Contains(frame)) { in make_sure_frame_is_on_screen() 99 if (frame.Width() > screenFrame.Width()) in make_sure_frame_is_on_screen() 100 frame.right -= frame.Width() - screenFrame.Width() + 10.0; in make_sure_frame_is_on_screen() 101 if (frame.Height() > screenFrame.Height()) in make_sure_frame_is_on_screen() 102 frame.bottom -= frame.Height() - screenFrame.Height() + 30.0; in make_sure_frame_is_on_screen() 104 if (frame.right > screenFrame.right) in make_sure_frame_is_on_screen() 105 frame.OffsetBy(-(frame.right - screenFrame.right), 0.0); in make_sure_frame_is_on_screen() 106 if (frame.bottom > screenFrame.bottom) in make_sure_frame_is_on_screen() [all …]
|
/haiku/src/servers/app/ |
H A D | WorkspacesView.cpp | 26 WorkspacesView::WorkspacesView(BRect frame, BPoint scrollingOffset, in WorkspacesView() argument 29 View(frame, scrollingOffset, name, token, resizeMode, flags), in WorkspacesView() 92 BRect frame = Bounds(); in _WorkspaceAt() local 93 LocalToScreenTransform().Apply(&frame); in _WorkspaceAt() 95 int32 width = frame.IntegerWidth() / columns; in _WorkspaceAt() 96 int32 height = frame.IntegerHeight() / rows; in _WorkspaceAt() 104 rect.OffsetBy(frame.LeftTop()); in _WorkspaceAt() 108 rect.right = frame.right; in _WorkspaceAt() 110 rect.bottom = frame.bottom; in _WorkspaceAt() 144 BRect frame = windowFrame; in _WindowFrame() local [all …]
|
/haiku/src/apps/processcontroller/ |
H A D | NoiseBarMenuItem.cpp | 39 BRect frame = Frame(); in DrawBar() local 45 frame = bar_rect(frame, &font); in DrawBar() 58 menu->StrokeRect(frame); in DrawBar() 61 frame.InsetBy(1, 1); in DrawBar() 62 BRect r = frame; in DrawBar() 63 float grenze1 = frame.left+(frame.right-frame.left)*fBusyWaiting; in DrawBar() 64 float grenze2 = frame.left+(frame.right-frame.left)*(fBusyWaiting+fLost); in DrawBar() 65 if (grenze1 > frame.right) in DrawBar() 66 grenze1 = frame.right; in DrawBar() 67 if (grenze2 > frame.right) in DrawBar() [all …]
|
/haiku/src/kits/interface/ |
H A D | LayoutUtils.cpp | 162 BLayoutUtils::AlignInFrame(BRect frame, BSize maxSize, BAlignment alignment) in AlignInFrame() argument 165 if (maxSize.width < frame.Width() in AlignInFrame() 167 frame.left += (int)((frame.Width() - maxSize.width) in AlignInFrame() 169 frame.right = frame.left + maxSize.width; in AlignInFrame() 171 if (maxSize.height < frame.Height() in AlignInFrame() 173 frame.top += (int)((frame.Height() - maxSize.height) in AlignInFrame() 175 frame.bottom = frame.top + maxSize.height; in AlignInFrame() 178 return frame; in AlignInFrame() 184 BLayoutUtils::AlignInFrame(BView* view, BRect frame) in AlignInFrame() argument 191 if (maxSize.width < frame.Width() in AlignInFrame() [all …]
|
/haiku/src/add-ons/kernel/file_systems/netfs/authentication_server/ |
H A D | AuthenticationPanel.cpp | 23 AuthenticationPanel::AuthenticationPanel(BRect frame) in AuthenticationPanel() argument 24 : Panel(frame, "Name Panel", in AuthenticationPanel() 32 BRect controlFrame(0.0, 0.0, frame.Width(), 15.0); in AuthenticationPanel() 126 BRect frame(fNameTC->Frame().LeftTop(), fOkB->Frame().RightBottom()); in GetAuthentication() local 132 nameFrame.right = nameFrame.left + frame.Width(); in GetAuthentication() 133 passFrame.right = passFrame.left + frame.Width(); in GetAuthentication() 157 frame.InsetBy(-10.0, -10.0); in GetAuthentication() 159 BBox* bg = new BBox(frame, "bg", B_FOLLOW_ALL, in GetAuthentication() 170 frame.OffsetTo(-10000.0, -10000.0); in GetAuthentication() 171 frame = _CalculateFrame(frame); in GetAuthentication() [all …]
|