Commit Graph

75 Commits

Author SHA1 Message Date
Gregory Nutt 42e2c9139c Squashed commit of the following:
libs/libnx/nxme:  Add front-end, client, message handling needed for cursor support.  Still actual cursor logic yet, just message handling.

    graphics/nxmu and graphics/nxbe:  Add back-end message handling needed for cursor support.  No actual cursor logic yet, just message handling.
2019-04-06 14:34:56 -06:00
Gregory Nutt 0b3375cb78 graphics/, lib/libnx, include/nutt/nx: Add support for modal windows. 2019-04-05 08:24:46 -06:00
Gregory Nutt ebbd91b441 Grrr.. Once again I forget to 'add' files before committing them. 2019-03-25 13:50:01 -06:00
Gregory Nutt 10388e9123 exmamples/, graphics/NxWidgets: Implement new interfaces nx_synch() and nxtk_synch(). This are used to syncrhonize the NX server with the window client. Currently most of the logic is equivalent to nx_block() and nxtk_block(), but with slightly different semantics. The are separate now because they are likely to diverge in the future. 2019-03-25 13:48:27 -06:00
Gregory Nutt f5e8dc60f4 graphics/nxmu, include/nuttx/nx/nxmu.h, libs/libnx: Add new server->client callback to notify the window client of server events. Remove the old 'blocked' callback and just make it one case of an 'event' callback. 2019-03-25 13:00:13 -06:00
Gregory Nutt 372e8b86a4 libs/libnx/nxmu/nx_filltrapezoid.c: Fix a coordinate system error. When no clipping rectangle is falls, it falls back to use the entire window as for the clip. However, that window must then then be in window relative coordinates, not in absoute device coordinates. 2019-03-20 12:26:45 -06:00
anchao bb8648e7a0 ibs/libc/Makefile, libs/libnx/Makefile, and mm/Makefile: Remove obj-path MKDEPS option since make dependency target (MT) is not supported by some toolchains. 2019-03-19 10:14:50 -06:00
Gregory Nutt 683cd4c045 libs/libnx/nxtk: Fix more cases where we were using the wrong coordinate system. 2019-03-18 13:29:58 -06:00
Gregory Nutt 5fda638cf0 libs/libnx/nxtk: Add logic to re-draw the frame when the toolbar is added or removed. 2019-03-18 12:13:22 -06:00
Gregory Nutt 10b73fde9d graphics/: Correct logic for copy of bit maps with resolution less than 8 bits from the per-window framebuffer to the device. 2019-03-18 09:45:09 -06:00
Gregory Nutt 4d4ae87cb7 libs/libnx/nxtk/nxtk_setsize.c: Add logic to redraw NXTK borders for the case of per-window framebuffers. There are no redraw callbacks in this case, so we cannot rely on the callbacks to redraw the borders. 2019-03-17 14:37:57 -06:00
Gregory Nutt a90364d14f libs/libnx/nxtk/nxtk_drawframe.c: Fix a one character typo in a comment 2019-03-17 13:47:10 -06:00
Gregory Nutt 92554257b9 Squashed commit of the following:
graphics/nxbe/nxbe_bitmap.c:  Fix another coordinate system problem.

    graphics/:  Review use of device coordinate system with window frambebuffer and make fixes accordingly.

    graphics/nxbe/nxbe_fill.c:  Fix a coordinate system bug.  Was trying to update the window fraembuffer using the device coordinate system.  Need to use the relative coordinate system.

    graphics/:  Use DEBUGASSERT instead of return an error since the is no user to handle the errors within the NX server.  Use CONFIG_DEBUG_GRAPHICS instead of CONFIG_DEBUG_FEATURES in most cases.

    graphics/:  Nothing under graphics/ should set the errno.
2019-03-17 11:34:45 -06:00
Gregory Nutt f2d90e6298 graphics: For consistency, rename fields fb->fbmem as in other structures. 2019-03-14 12:19:01 -06:00
Gregory Nutt 419c4cb6be A little more progress toward the implementation of per-window framebuffers. Still missing:
- Logic that generates the low lever framebuffer renderers for the per-window framebuffers,
- The logic that picks off the per-window framebuffer updates from normal graphics device updates.  This logic must update both the per-window framebuffer and the graphics device (from the framebuffer).

Squashed commit of the following:

    graphics:  Add logic to allocate the per-window framebuffer.

    graphics:  A few fragmentary thoughts on how a per-window framebuffer could be represented and allocated.
2019-03-14 11:20:14 -06:00
Gregory Nutt 8a46b1f488 Squashed commit of the following:
graphics:  nx_openwindow() and nxtk_openwindow() now accept an addtional 'flag' parameter.  This argument is not used at present but will, eventually enable a RAM backed, per-window framebuffer.

    graphics/Kconfig:  Add configuration to support a rambacked framebuffer. Current marked as EXPERIMENTAL because this is a work in progress.
2019-03-13 12:34:13 -06:00
Gregory Nutt 0454ae2a10 This commit removes naming associated with and naming for the now non-existent NXFE graphics layer.
Squashed commit of the following:

    graphics/:  Rename nxfe_reportposition to nxmu_reportposition.  The is no longer an nxfe layer.

    graphics/:  Renmae nxfe_redrawreq to nxmu_redrawreq.  The is no longer an nxfe layer.

    graphics/nxmu/nxmu.h:  Renmae nxfe.h to nxmu.h.  There is no long an nxfe layer.

    graphics/: Rename nxfe_state_s to nxmu_state_s.  There is no longer an nxfe layer.

    graphics/: Rename nxfe_conn_s to nxmu_conn_s.  There is no longer an nxfe layer.
2019-03-13 09:16:30 -06:00
Gregory Nutt 1f22ebfac3 libs/libnx/nxfonts: Fix a memory leak in the font cache. With a busy NxTerm display, this could drain off all the memory pretty quickly! 2019-03-08 11:52:49 -06:00
Gregory Nutt aefacb05ca Minor NxTerm-related clean-up 2019-03-08 08:43:16 -06:00
Gregory Nutt 2d4ce4e047 graphics/nxterm and configs/open1788: Various fixes to get the NxTerm example working in PROTECTED mode with the Open1788 knxterm configuration. Basically works until the screen becomes full and it starts scrolling. Then characters are missing from the display. Needs more debug and test. 2019-03-07 15:57:34 -06:00
Gregory Nutt 1a754deaa0 Cosmetic updates from review of last PR. 2018-11-12 09:43:33 -06:00
Petteri Aimonen fe0532c226 Merged in paimonen/nuttx/pullreq_libc_libnx_updates (pull request #757)
Pullreq libc libnx updates

* NuttX: make strerror() return 'Success' for 0

* NuttX: fix strrchr() so that it considers null terminator as part of string

    From strrchr(3) man page:
    "The terminating null byte is considered part of the string, so that if c
    is specified as '\0', these functions return a pointer to the terminator."

* NuttX: mm_free(): Add DEBUGASSERT()'s to catch memory corruption early.

    It's easier to find the source when asserts fail already when freeing
    an overflowed buffer, than if the corruption is only detected on next
    malloc().

* MM_FILL_ALLOCATIONS: Add debug option to fill all mallocs()

    This is helpful for detecting uninitialized variables,
    especially in C++ code. I seem to be forgetting to initialize
    member variables and then they just get random values..

* NuttX: nxtk_bitmapwindow: Fix warning message when bitmap is fully off-screen.

* nxfonts_getfont: Avoid unnecessary warnings for other whitespace chars also.

* NuttX: Fix kerning of 'I' in Sans17x22 font

    The I character was running together with some other
    characters, e.g. in sequence "IMI".

* NXMU: Revalidate window pointer for mouse events.

    NXMU caches the previous window pointer so that further mouse
    events can be sent to the same window. However, if the window
    is destroyed while mouse button is held down, the pointer may
    become invalid and cause a crash. This patch revalidates the
    pointer before using it.

Approved-by: GregoryN <gnutt@nuttx.org>
2018-11-12 15:36:35 +00:00
Xiang Xiao e1202d2ed3 Replace all ASSERT with DEBUGASSERT to save the code space 2018-08-24 06:58:30 -06:00
Xiang Xiao 467d2a58ea Replace non critical PANIC with DEBUGPANIC to save the code space 2018-08-24 06:21:15 -06:00
Gregory Nutt cf99fb40c9 This commit moves all of the libraries under a common directory called libs/. This most certainly break libcxx and uClibc++ for now.
Squashed commit of the following:

    libs/libxx:  Fix some confusing in naming.  If the directory is called libxx, then the library must be libxx.a (unless perhaps LIBCXX is selected).
    libs/:  Fix paths in moved library directories.
    libs:  Brute force move of libc, libnx, and libxx to libs.  Cannot yet build it in that configuration.
2018-05-29 13:21:26 -06:00