summaryrefslogtreecommitdiff
path: root/nuttx/graphics
diff options
context:
space:
mode:
authorGregory Nutt <gnutt@nuttx.org>2014-09-20 15:53:28 -0600
committerGregory Nutt <gnutt@nuttx.org>2014-09-20 15:53:28 -0600
commit77e4ba3764c959d1ddf5605496197f2f443c52d9 (patch)
treeda292fd81f472e98deff8be63b78a3c9645e7801 /nuttx/graphics
parent8ae7ecf5a4ba19ce28b91730ac100ab7c03d5a7c (diff)
downloadnuttx-77e4ba3764c959d1ddf5605496197f2f443c52d9.tar.gz
nuttx-77e4ba3764c959d1ddf5605496197f2f443c52d9.tar.bz2
nuttx-77e4ba3764c959d1ddf5605496197f2f443c52d9.zip
More naming changes to get the stm3240g-eval/nxterm configuration building again
Diffstat (limited to 'nuttx/graphics')
-rw-r--r--nuttx/graphics/Kconfig2
-rw-r--r--nuttx/graphics/Makefile4
-rw-r--r--nuttx/graphics/README.txt2
-rw-r--r--nuttx/graphics/nxterm/Make.defs14
-rw-r--r--nuttx/graphics/nxterm/nx_register.c34
-rw-r--r--nuttx/graphics/nxterm/nxterm.h (renamed from nuttx/graphics/nxterm/nxcon_internal.h)86
-rw-r--r--nuttx/graphics/nxterm/nxterm_driver.c (renamed from nuttx/graphics/nxterm/nxcon_driver.c)56
-rw-r--r--nuttx/graphics/nxterm/nxterm_font.c (renamed from nuttx/graphics/nxterm/nxcon_font.c)114
-rw-r--r--nuttx/graphics/nxterm/nxterm_kbdin.c (renamed from nuttx/graphics/nxterm/nxcon_kbdin.c)64
-rw-r--r--nuttx/graphics/nxterm/nxterm_putc.c (renamed from nuttx/graphics/nxterm/nxcon_putc.c)38
-rw-r--r--nuttx/graphics/nxterm/nxterm_redraw.c (renamed from nuttx/graphics/nxterm/nxcon_redraw.c)18
-rw-r--r--nuttx/graphics/nxterm/nxterm_register.c (renamed from nuttx/graphics/nxterm/nxcon_register.c)24
-rw-r--r--nuttx/graphics/nxterm/nxterm_scroll.c (renamed from nuttx/graphics/nxterm/nxcon_scroll.c)26
-rw-r--r--nuttx/graphics/nxterm/nxterm_sem.c (renamed from nuttx/graphics/nxterm/nxcon_sem.c)10
-rw-r--r--nuttx/graphics/nxterm/nxterm_unregister.c (renamed from nuttx/graphics/nxterm/nxcon_unregister.c)14
-rw-r--r--nuttx/graphics/nxterm/nxterm_vt100.c (renamed from nuttx/graphics/nxterm/nxcon_vt100.c)38
-rw-r--r--nuttx/graphics/nxterm/nxtk_register.c20
-rw-r--r--nuttx/graphics/nxterm/nxtool_register.c20
18 files changed, 292 insertions, 292 deletions
diff --git a/nuttx/graphics/Kconfig b/nuttx/graphics/Kconfig
index 0b21d997a..f001f83fc 100644
--- a/nuttx/graphics/Kconfig
+++ b/nuttx/graphics/Kconfig
@@ -436,7 +436,7 @@ config NXTERM_NXKBDIN
---help---
Take input from the NX keyboard input callback. By default, keyboard
input is taken from stdin (/dev/console). If this option is set, then
- the interface nxcon_kdbin() is enabled. That interface may be driven
+ the interface nxterm_kdbin() is enabled. That interface may be driven
by window callback functions so that keyboard input *only* goes to the
top window.
diff --git a/nuttx/graphics/Makefile b/nuttx/graphics/Makefile
index c66f68a1b..d2fbef52d 100644
--- a/nuttx/graphics/Makefile
+++ b/nuttx/graphics/Makefile
@@ -65,10 +65,10 @@ DEPPATH += --dep-path nxterm
CFLAGS += ${shell $(INCDIR) $(INCDIROPT) "$(CC)" $(TOPDIR)/graphics/nxterm}
endif
-ASRCS = $(NXGLIB_ASRCS) $(NXBE_ASRCS) $(NX_ASRCS) $(NXTK_ASRCS) $(NXCON_ASRCS)
+ASRCS = $(NXGLIB_ASRCS) $(NXBE_ASRCS) $(NX_ASRCS) $(NXTK_ASRCS) $(NXTERM_ASRCS)
AOBJS = $(ASRCS:.S=$(OBJEXT))
-CSRCS = $(NXGLIB_CSRCS) $(NXBE_CSRCS) $(NX_CSRCS) $(NXTK_CSRCS) $(NXCON_CSRCS)
+CSRCS = $(NXGLIB_CSRCS) $(NXBE_CSRCS) $(NX_CSRCS) $(NXTK_CSRCS) $(NXTERM_CSRCS)
COBJS = $(CSRCS:.c=$(OBJEXT))
SRCS = $(ASRCS) $(CSRCS)
diff --git a/nuttx/graphics/README.txt b/nuttx/graphics/README.txt
index cfc0e42de..1c0488d87 100644
--- a/nuttx/graphics/README.txt
+++ b/nuttx/graphics/README.txt
@@ -396,7 +396,7 @@ NxTerm Input options
CONFIG_NXTERM_NXKBDIN
Take input from the NX keyboard input callback. By default, keyboard
input is taken from stdin (/dev/console). If this option is set, then
- the interface nxcon_kdbin() is enabled. That interface may be driven
+ the interface nxterm_kdbin() is enabled. That interface may be driven
by window callback functions so that keyboard input *only* goes to the
top window.
CONFIG__NXTERM_KBDBUFSIZE
diff --git a/nuttx/graphics/nxterm/Make.defs b/nuttx/graphics/nxterm/Make.defs
index 7a44ba263..a6d5e7e14 100644
--- a/nuttx/graphics/nxterm/Make.defs
+++ b/nuttx/graphics/nxterm/Make.defs
@@ -33,16 +33,16 @@
#
############################################################################
-NXCON_ASRCS =
-NXCON_CSRCS = nx_register.c nxcon_driver.c nxcon_font.c nxcon_putc.c
-NXCON_CSRCS += nxcon_redraw.c nxcon_register.c nxcon_scroll.c
-NXCON_CSRCS += nxcon_vt100.c nxcon_unregister.c nxtk_register.c
-NXCON_CSRCS += nxtool_register.c
+NXTERM_ASRCS =
+NXTERM_CSRCS = nx_register.c nxterm_driver.c nxterm_font.c nxterm_putc.c
+NXTERM_CSRCS += nxterm_redraw.c nxterm_register.c nxterm_scroll.c
+NXTERM_CSRCS += nxterm_vt100.c nxterm_unregister.c nxtk_register.c
+NXTERM_CSRCS += nxtool_register.c
ifeq ($(CONFIG_NXTERM_NXKBDIN),y)
-NXCON_CSRCS += nxcon_kbdin.c
+NXTERM_CSRCS += nxterm_kbdin.c
endif
ifeq ($(CONFIG_DEBUG),y)
-NXCON_CSRCS += nxcon_sem.c
+NXTERM_CSRCS += nxterm_sem.c
endif
diff --git a/nuttx/graphics/nxterm/nx_register.c b/nuttx/graphics/nxterm/nx_register.c
index ed84d3d28..52f7c3116 100644
--- a/nuttx/graphics/nxterm/nx_register.c
+++ b/nuttx/graphics/nxterm/nx_register.c
@@ -42,7 +42,7 @@
#include <nuttx/nx/nx.h>
#include <nuttx/nx/nxterm.h>
-#include "nxcon_internal.h"
+#include "nxterm.h"
/****************************************************************************
* Pre-processor Definitions
@@ -52,15 +52,15 @@
* Private Function Prototypes
****************************************************************************/
-static int nxcon_fill(FAR struct nxcon_state_s *priv,
+static int nxterm_fill(FAR struct nxterm_state_s *priv,
FAR const struct nxgl_rect_s *rect,
nxgl_mxpixel_t wcolor[CONFIG_NX_NPLANES]);
#ifndef CONFIG_NX_WRITEONLY
-static int nxcon_move(FAR struct nxcon_state_s *priv,
+static int nxterm_move(FAR struct nxterm_state_s *priv,
FAR const struct nxgl_rect_s *rect,
FAR const struct nxgl_point_s *offset);
#endif
-static int nxcon_bitmap(FAR struct nxcon_state_s *priv,
+static int nxterm_bitmap(FAR struct nxterm_state_s *priv,
FAR const struct nxgl_rect_s *dest,
FAR const void *src[CONFIG_NX_NPLANES],
FAR const struct nxgl_point_s *origin,
@@ -70,13 +70,13 @@ static int nxcon_bitmap(FAR struct nxcon_state_s *priv,
* Private Data
****************************************************************************/
-static const struct nxcon_operations_s g_nxops =
+static const struct nxterm_operations_s g_nxops =
{
- nxcon_fill,
+ nxterm_fill,
#ifndef CONFIG_NX_WRITEONLY
- nxcon_move,
+ nxterm_move,
#endif
- nxcon_bitmap
+ nxterm_bitmap
};
/****************************************************************************
@@ -84,7 +84,7 @@ static const struct nxcon_operations_s g_nxops =
****************************************************************************/
/****************************************************************************
- * Name: nxcon_fill
+ * Name: nxterm_fill
*
* Description:
* Fill the specified rectangle in the window with the specified color
@@ -99,7 +99,7 @@ static const struct nxcon_operations_s g_nxops =
*
****************************************************************************/
-static int nxcon_fill(FAR struct nxcon_state_s *priv,
+static int nxterm_fill(FAR struct nxterm_state_s *priv,
FAR const struct nxgl_rect_s *rect,
nxgl_mxpixel_t wcolor[CONFIG_NX_NPLANES])
{
@@ -107,7 +107,7 @@ static int nxcon_fill(FAR struct nxcon_state_s *priv,
}
/****************************************************************************
- * Name: nxcon_move
+ * Name: nxterm_move
*
* Description:
* Move a rectangular region within the window
@@ -124,7 +124,7 @@ static int nxcon_fill(FAR struct nxcon_state_s *priv,
****************************************************************************/
#ifndef CONFIG_NX_WRITEONLY
-static int nxcon_move(FAR struct nxcon_state_s *priv,
+static int nxterm_move(FAR struct nxterm_state_s *priv,
FAR const struct nxgl_rect_s *rect,
FAR const struct nxgl_point_s *offset)
{
@@ -133,7 +133,7 @@ static int nxcon_move(FAR struct nxcon_state_s *priv,
#endif
/****************************************************************************
- * Name: nxcon_bitmap
+ * Name: nxterm_bitmap
*
* Description:
* Copy a rectangular region of a larger image into the rectangle in the
@@ -155,7 +155,7 @@ static int nxcon_move(FAR struct nxcon_state_s *priv,
*
****************************************************************************/
-static int nxcon_bitmap(FAR struct nxcon_state_s *priv,
+static int nxterm_bitmap(FAR struct nxterm_state_s *priv,
FAR const struct nxgl_rect_s *dest,
FAR const void *src[CONFIG_NX_NPLANES],
FAR const struct nxgl_point_s *origin,
@@ -173,7 +173,7 @@ static int nxcon_bitmap(FAR struct nxcon_state_s *priv,
*
* Description:
* Register a console device on a raw NX window. The device will be
- * registered at /dev/nxconN where N is the provided minor number.
+ * registered at /dev/nxtermN where N is the provided minor number.
*
* Input Parameters:
* hwnd - A handle that will be used to access the window. The window must
@@ -186,8 +186,8 @@ static int nxcon_bitmap(FAR struct nxcon_state_s *priv,
*
****************************************************************************/
-NXTERM nx_register(NXWINDOW hwnd, FAR struct nxcon_window_s *wndo, int minor)
+NXTERM nx_register(NXWINDOW hwnd, FAR struct nxterm_window_s *wndo, int minor)
{
- return nxcon_register((NXTERM)hwnd, wndo, &g_nxops, minor);
+ return nxterm_register((NXTERM)hwnd, wndo, &g_nxops, minor);
}
diff --git a/nuttx/graphics/nxterm/nxcon_internal.h b/nuttx/graphics/nxterm/nxterm.h
index 9bee64c3e..9bc2c4e43 100644
--- a/nuttx/graphics/nxterm/nxcon_internal.h
+++ b/nuttx/graphics/nxterm/nxterm.h
@@ -1,7 +1,7 @@
/****************************************************************************
- * nuttx/graphics/nxterm/nxcon_internal.h
+ * nuttx/graphics/nxterm/nxterm.h
*
- * Copyright (C) 2012 Gregory Nutt. All rights reserved.
+ * Copyright (C) 2012, 2014 Gregory Nutt. All rights reserved.
* Author: Gregory Nutt <gnutt@nuttx.org>
*
* Redistribution and use in source and binary forms, with or without
@@ -33,8 +33,8 @@
*
****************************************************************************/
-#ifndef __GRAPHICS_NXTERM_NXCON_INTERNAL_H
-#define __GRAPHICS_NXTERM_NXCON_INTERNAL_H
+#ifndef __GRAPHICS_NXTERM_NXTERM_INTERNAL_H
+#define __GRAPHICS_NXTERM_NXTERM_INTERNAL_H
/****************************************************************************
* Included Files
@@ -67,7 +67,7 @@
/* Device path formats */
-#define NX_DEVNAME_FORMAT "/dev/nxcon%d"
+#define NX_DEVNAME_FORMAT "/dev/nxterm%d"
#define NX_DEVNAME_SIZE 16
/* Semaphore protection */
@@ -83,7 +83,7 @@
****************************************************************************/
/* Identifies the state of the VT100 escape sequence processing */
-enum nxcon_vt100state_e
+enum nxterm_vt100state_e
{
VT100_NOT_CONSUMED = 0, /* Character is not part of a VT100 escape sequence */
VT100_CONSUMED, /* Character was consumed as part of the VT100 escape processing */
@@ -93,18 +93,18 @@ enum nxcon_vt100state_e
/* Describes on set of console window callbacks */
-struct nxcon_state_s;
-struct nxcon_operations_s
+struct nxterm_state_s;
+struct nxterm_operations_s
{
- int (*fill)(FAR struct nxcon_state_s *priv,
+ int (*fill)(FAR struct nxterm_state_s *priv,
FAR const struct nxgl_rect_s *rect,
nxgl_mxpixel_t wcolor[CONFIG_NX_NPLANES]);
#ifndef CONFIG_NX_WRITEONLY
- int (*move)(FAR struct nxcon_state_s *priv,
+ int (*move)(FAR struct nxterm_state_s *priv,
FAR const struct nxgl_rect_s *rect,
FAR const struct nxgl_point_s *offset);
#endif
- int (*bitmap)(FAR struct nxcon_state_s *priv,
+ int (*bitmap)(FAR struct nxterm_state_s *priv,
FAR const struct nxgl_rect_s *dest,
FAR const void *src[CONFIG_NX_NPLANES],
FAR const struct nxgl_point_s *origin,
@@ -113,7 +113,7 @@ struct nxcon_operations_s
/* Describes one cached glyph bitmap */
-struct nxcon_glyph_s
+struct nxterm_glyph_s
{
uint8_t code; /* Character code */
uint8_t height; /* Height of this glyph (in rows) */
@@ -125,7 +125,7 @@ struct nxcon_glyph_s
/* Describes on character on the display */
-struct nxcon_bitmap_s
+struct nxterm_bitmap_s
{
uint8_t code; /* Character code */
uint8_t flags; /* See BMFLAGS_* */
@@ -134,11 +134,11 @@ struct nxcon_bitmap_s
/* Describes the state of one NX console driver*/
-struct nxcon_state_s
+struct nxterm_state_s
{
- FAR const struct nxcon_operations_s *ops; /* Window operations */
+ FAR const struct nxterm_operations_s *ops; /* Window operations */
FAR void *handle; /* The window handle */
- FAR struct nxcon_window_s wndo; /* Describes the window and font */
+ FAR struct nxterm_window_s wndo; /* Describes the window and font */
NXHANDLE font; /* The current font handle */
sem_t exclsem; /* Forces mutually exclusive access */
#ifdef CONFIG_DEBUG
@@ -165,12 +165,12 @@ struct nxcon_state_s
/* Font cache data storage */
- struct nxcon_bitmap_s cursor;
- struct nxcon_bitmap_s bm[CONFIG_NXTERM_MXCHARS];
+ struct nxterm_bitmap_s cursor;
+ struct nxterm_bitmap_s bm[CONFIG_NXTERM_MXCHARS];
/* Glyph cache data storage */
- struct nxcon_glyph_s glyph[CONFIG_NXTERM_CACHESIZE];
+ struct nxterm_glyph_s glyph[CONFIG_NXTERM_CACHESIZE];
/* Keyboard input support */
@@ -199,7 +199,7 @@ struct nxcon_state_s
/* This is the common NX driver file operations */
-extern const struct file_operations g_nxcon_drvrops;
+extern const struct file_operations g_nxterm_drvrops;
/****************************************************************************
* Public Function Prototypes
@@ -207,48 +207,48 @@ extern const struct file_operations g_nxcon_drvrops;
/* Semaphore helpers */
#ifdef CONFIG_DEBUG
-int nxcon_semwait(FAR struct nxcon_state_s *priv);
-int nxcon_sempost(FAR struct nxcon_state_s *priv);
+int nxterm_semwait(FAR struct nxterm_state_s *priv);
+int nxterm_sempost(FAR struct nxterm_state_s *priv);
#else
-# define nxcon_semwait(p) sem_wait(&p->exclsem)
-# define nxcon_sempost(p) sem_post(&p->exclsem)
+# define nxterm_semwait(p) sem_wait(&p->exclsem)
+# define nxterm_sempost(p) sem_post(&p->exclsem)
#endif
/* Common device registration */
-FAR struct nxcon_state_s *nxcon_register(NXTERM handle,
- FAR struct nxcon_window_s *wndo, FAR const struct nxcon_operations_s *ops,
+FAR struct nxterm_state_s *nxterm_register(NXTERM handle,
+ FAR struct nxterm_window_s *wndo, FAR const struct nxterm_operations_s *ops,
int minor);
#ifdef CONFIG_NXTERM_NXKBDIN
-ssize_t nxcon_read(FAR struct file *filep, FAR char *buffer, size_t len);
+ssize_t nxterm_read(FAR struct file *filep, FAR char *buffer, size_t len);
#ifndef CONFIG_DISABLE_POLL
-int nxcon_poll(FAR struct file *filep, FAR struct pollfd *fds, bool setup);
+int nxterm_poll(FAR struct file *filep, FAR struct pollfd *fds, bool setup);
#endif
#endif
/* VT100 Terminal emulation */
-enum nxcon_vt100state_e nxcon_vt100(FAR struct nxcon_state_s *priv, char ch);
+enum nxterm_vt100state_e nxterm_vt100(FAR struct nxterm_state_s *priv, char ch);
/* Generic text display helpers */
-void nxcon_home(FAR struct nxcon_state_s *priv);
-void nxcon_newline(FAR struct nxcon_state_s *priv);
-FAR const struct nxcon_bitmap_s *nxcon_addchar(NXHANDLE hfont,
- FAR struct nxcon_state_s *priv, uint8_t ch);
-int nxcon_hidechar(FAR struct nxcon_state_s *priv,
- FAR const struct nxcon_bitmap_s *bm);
-int nxcon_backspace(FAR struct nxcon_state_s *priv);
-void nxcon_fillchar(FAR struct nxcon_state_s *priv,
- FAR const struct nxgl_rect_s *rect, FAR const struct nxcon_bitmap_s *bm);
+void nxterm_home(FAR struct nxterm_state_s *priv);
+void nxterm_newline(FAR struct nxterm_state_s *priv);
+FAR const struct nxterm_bitmap_s *nxterm_addchar(NXHANDLE hfont,
+ FAR struct nxterm_state_s *priv, uint8_t ch);
+int nxterm_hidechar(FAR struct nxterm_state_s *priv,
+ FAR const struct nxterm_bitmap_s *bm);
+int nxterm_backspace(FAR struct nxterm_state_s *priv);
+void nxterm_fillchar(FAR struct nxterm_state_s *priv,
+ FAR const struct nxgl_rect_s *rect, FAR const struct nxterm_bitmap_s *bm);
-void nxcon_putc(FAR struct nxcon_state_s *priv, uint8_t ch);
-void nxcon_showcursor(FAR struct nxcon_state_s *priv);
-void nxcon_hidecursor(FAR struct nxcon_state_s *priv);
+void nxterm_putc(FAR struct nxterm_state_s *priv, uint8_t ch);
+void nxterm_showcursor(FAR struct nxterm_state_s *priv);
+void nxterm_hidecursor(FAR struct nxterm_state_s *priv);
/* Scrolling support */
-void nxcon_scroll(FAR struct nxcon_state_s *priv, int scrollheight);
+void nxterm_scroll(FAR struct nxterm_state_s *priv, int scrollheight);
-#endif /* __GRAPHICS_NXTERM_NXCON_INTERNAL_H */
+#endif /* __GRAPHICS_NXTERM_NXTERM_INTERNAL_H */
diff --git a/nuttx/graphics/nxterm/nxcon_driver.c b/nuttx/graphics/nxterm/nxterm_driver.c
index 5132183b2..77cb7b037 100644
--- a/nuttx/graphics/nxterm/nxcon_driver.c
+++ b/nuttx/graphics/nxterm/nxterm_driver.c
@@ -1,5 +1,5 @@
/****************************************************************************
- * nuttx/graphics/nxterm/nxcon_driver.c
+ * nuttx/graphics/nxterm/nxterm_driver.c
*
* Copyright (C) 2012 Gregory Nutt. All rights reserved.
* Author: Gregory Nutt <gnutt@nuttx.org>
@@ -49,14 +49,14 @@
#include <nuttx/fs/fs.h>
-#include "nxcon_internal.h"
+#include "nxterm.h"
/****************************************************************************
* Private Function Prototypes
****************************************************************************/
-static int nxcon_open(FAR struct file *filep);
-static ssize_t nxcon_write(FAR struct file *filep, FAR const char *buffer,
+static int nxterm_open(FAR struct file *filep);
+static ssize_t nxterm_write(FAR struct file *filep, FAR const char *buffer,
size_t buflen);
/****************************************************************************
@@ -66,28 +66,28 @@ static ssize_t nxcon_write(FAR struct file *filep, FAR const char *buffer,
#ifdef CONFIG_NXTERM_NXKBDIN
-const struct file_operations g_nxcon_drvrops =
+const struct file_operations g_nxterm_drvrops =
{
- nxcon_open, /* open */
+ nxterm_open, /* open */
0, /* close */
- nxcon_read, /* read */
- nxcon_write, /* write */
+ nxterm_read, /* read */
+ nxterm_write, /* write */
0, /* seek */
0 /* ioctl */
#ifndef CONFIG_DISABLE_POLL
,
- nxcon_poll /* poll */
+ nxterm_poll /* poll */
#endif
};
#else /* CONFIG_NXTERM_NXKBDIN */
-const struct file_operations g_nxcon_drvrops =
+const struct file_operations g_nxterm_drvrops =
{
- nxcon_open, /* open */
+ nxterm_open, /* open */
0, /* close */
0, /* read */
- nxcon_write, /* write */
+ nxterm_write, /* write */
0, /* seek */
0 /* ioctl */
#ifndef CONFIG_DISABLE_POLL
@@ -107,20 +107,20 @@ const struct file_operations g_nxcon_drvrops =
****************************************************************************/
/****************************************************************************
- * Name: nxcon_open
+ * Name: nxterm_open
****************************************************************************/
-static int nxcon_open(FAR struct file *filep)
+static int nxterm_open(FAR struct file *filep)
{
FAR struct inode *inode = filep->f_inode;
- FAR struct nxcon_state_s *priv = inode->i_private;
+ FAR struct nxterm_state_s *priv = inode->i_private;
DEBUGASSERT(filep && filep->f_inode);
/* Get the driver structure from the inode */
inode = filep->f_inode;
- priv = (FAR struct nxcon_state_s *)inode->i_private;
+ priv = (FAR struct nxterm_state_s *)inode->i_private;
DEBUGASSERT(priv);
/* Verify that the driver is opened for write-only access */
@@ -140,14 +140,14 @@ static int nxcon_open(FAR struct file *filep)
}
/****************************************************************************
- * Name: nxcon_write
+ * Name: nxterm_write
****************************************************************************/
-static ssize_t nxcon_write(FAR struct file *filep, FAR const char *buffer,
+static ssize_t nxterm_write(FAR struct file *filep, FAR const char *buffer,
size_t buflen)
{
- FAR struct nxcon_state_s *priv;
- enum nxcon_vt100state_e state;
+ FAR struct nxterm_state_s *priv;
+ enum nxterm_vt100state_e state;
ssize_t remaining;
char ch;
int ret;
@@ -155,11 +155,11 @@ static ssize_t nxcon_write(FAR struct file *filep, FAR const char *buffer,
/* Recover our private state structure */
DEBUGASSERT(filep && filep->f_priv);
- priv = (FAR struct nxcon_state_s *)filep->f_priv;
+ priv = (FAR struct nxterm_state_s *)filep->f_priv;
/* Get exclusive access */
- ret = nxcon_semwait(priv);
+ ret = nxterm_semwait(priv);
if (ret < 0)
{
return ret;
@@ -167,7 +167,7 @@ static ssize_t nxcon_write(FAR struct file *filep, FAR const char *buffer,
/* Hide the cursor while we update the display */
- nxcon_hidecursor(priv);
+ nxterm_hidecursor(priv);
/* Loop writing each character to the display */
@@ -183,7 +183,7 @@ static ssize_t nxcon_write(FAR struct file *filep, FAR const char *buffer,
{
/* Is the character part of a VT100 escape sequnce? */
- state = nxcon_vt100(priv, ch);
+ state = nxterm_vt100(priv, ch);
switch (state)
{
/* Character is not part of a VT100 escape sequence (and no
@@ -195,7 +195,7 @@ static ssize_t nxcon_write(FAR struct file *filep, FAR const char *buffer,
{
/* We can output the character to the window */
- nxcon_putc(priv, (uint8_t)ch);
+ nxterm_putc(priv, (uint8_t)ch);
}
break;
@@ -223,7 +223,7 @@ static ssize_t nxcon_write(FAR struct file *filep, FAR const char *buffer,
/* Add the first unhandled character to the window */
- nxcon_putc(priv, (uint8_t)priv->seq[0]);
+ nxterm_putc(priv, (uint8_t)priv->seq[0]);
/* Move all buffer characters down one */
@@ -246,8 +246,8 @@ static ssize_t nxcon_write(FAR struct file *filep, FAR const char *buffer,
/* Show the cursor at its new position */
- nxcon_showcursor(priv);
- nxcon_sempost(priv);
+ nxterm_showcursor(priv);
+ nxterm_sempost(priv);
return (ssize_t)buflen;
}
diff --git a/nuttx/graphics/nxterm/nxcon_font.c b/nuttx/graphics/nxterm/nxterm_font.c
index 310985ec4..dcbb8759b 100644
--- a/nuttx/graphics/nxterm/nxcon_font.c
+++ b/nuttx/graphics/nxterm/nxterm_font.c
@@ -1,5 +1,5 @@
/****************************************************************************
- * nuttx/graphics/nxterm/nxcon_font.c
+ * nuttx/graphics/nxterm/nxterm_font.c
*
* Copyright (C) 2012 Gregory Nutt. All rights reserved.
* Author: Gregory Nutt <gnutt@nuttx.org>
@@ -46,7 +46,7 @@
#include <nuttx/kmalloc.h>
-#include "nxcon_internal.h"
+#include "nxterm.h"
/****************************************************************************
* Definitions
@@ -95,27 +95,27 @@
****************************************************************************/
/****************************************************************************
- * Name: nxcon_freeglyph
+ * Name: nxterm_freeglyph
****************************************************************************/
-static void nxcon_freeglyph(FAR struct nxcon_glyph_s *glyph)
+static void nxterm_freeglyph(FAR struct nxterm_glyph_s *glyph)
{
if (glyph->bitmap)
{
kmm_free(glyph->bitmap);
}
- memset(glyph, 0, sizeof(struct nxcon_glyph_s));
+ memset(glyph, 0, sizeof(struct nxterm_glyph_s));
}
/****************************************************************************
- * Name: nxcon_allocglyph
+ * Name: nxterm_allocglyph
****************************************************************************/
-static inline FAR struct nxcon_glyph_s *
-nxcon_allocglyph(FAR struct nxcon_state_s *priv)
+static inline FAR struct nxterm_glyph_s *
+nxterm_allocglyph(FAR struct nxterm_state_s *priv)
{
- FAR struct nxcon_glyph_s *glyph = NULL;
- FAR struct nxcon_glyph_s *luglyph = NULL;
+ FAR struct nxterm_glyph_s *glyph = NULL;
+ FAR struct nxterm_glyph_s *luglyph = NULL;
uint8_t luusecnt;
int i;
@@ -150,7 +150,7 @@ nxcon_allocglyph(FAR struct nxcon_state_s *priv)
*/
luusecnt = luglyph->usecnt;
- nxcon_freeglyph(luglyph);
+ nxterm_freeglyph(luglyph);
/* But lets decrement all of the usecnts so that the new one one be so
* far behind in the counts as the older ones.
@@ -179,11 +179,11 @@ nxcon_allocglyph(FAR struct nxcon_state_s *priv)
}
/****************************************************************************
- * Name: nxcon_findglyph
+ * Name: nxterm_findglyph
****************************************************************************/
-static FAR struct nxcon_glyph_s *
-nxcon_findglyph(FAR struct nxcon_state_s *priv, uint8_t ch)
+static FAR struct nxterm_glyph_s *
+nxterm_findglyph(FAR struct nxterm_state_s *priv, uint8_t ch)
{
int i;
@@ -191,7 +191,7 @@ nxcon_findglyph(FAR struct nxcon_state_s *priv, uint8_t ch)
for (i = 0; i < priv->maxglyphs; i++)
{
- FAR struct nxcon_glyph_s *glyph = &priv->glyph[i];
+ FAR struct nxterm_glyph_s *glyph = &priv->glyph[i];
if (glyph->usecnt > 0 && glyph->code == ch)
{
/* Increment the use count (unless it is already at the max) */
@@ -210,14 +210,14 @@ nxcon_findglyph(FAR struct nxcon_state_s *priv, uint8_t ch)
}
/****************************************************************************
- * Name: nxcon_renderglyph
+ * Name: nxterm_renderglyph
****************************************************************************/
-static inline FAR struct nxcon_glyph_s *
-nxcon_renderglyph(FAR struct nxcon_state_s *priv,
+static inline FAR struct nxterm_glyph_s *
+nxterm_renderglyph(FAR struct nxterm_state_s *priv,
FAR const struct nx_fontbitmap_s *fbm, uint8_t ch)
{
- FAR struct nxcon_glyph_s *glyph = NULL;
+ FAR struct nxterm_glyph_s *glyph = NULL;
FAR nxgl_mxpixel_t *ptr;
#if CONFIG_NXTERM_BPP < 8
nxgl_mxpixel_t pixel;
@@ -229,7 +229,7 @@ nxcon_renderglyph(FAR struct nxcon_state_s *priv,
/* Allocate the glyph (always succeeds) */
- glyph = nxcon_allocglyph(priv);
+ glyph = nxterm_allocglyph(priv);
glyph->code = ch;
/* Get the dimensions of the glyph */
@@ -318,8 +318,8 @@ nxcon_renderglyph(FAR struct nxcon_state_s *priv,
{
/* Actually, the RENDERER never returns a failure */
- gdbg("nxcon_renderglyph: RENDERER failed\n");
- nxcon_freeglyph(glyph);
+ gdbg("nxterm_renderglyph: RENDERER failed\n");
+ nxterm_freeglyph(glyph);
glyph = NULL;
}
}
@@ -328,10 +328,10 @@ nxcon_renderglyph(FAR struct nxcon_state_s *priv,
}
/****************************************************************************
- * Name: nxcon_fontsize
+ * Name: nxterm_fontsize
****************************************************************************/
-static int nxcon_fontsize(NXHANDLE hfont, uint8_t ch, FAR struct nxgl_size_s *size)
+static int nxterm_fontsize(NXHANDLE hfont, uint8_t ch, FAR struct nxgl_size_s *size)
{
FAR const struct nx_fontbitmap_s *fbm;
@@ -351,18 +351,18 @@ static int nxcon_fontsize(NXHANDLE hfont, uint8_t ch, FAR struct nxgl_size_s *si
}
/****************************************************************************
- * Name: nxcon_getglyph
+ * Name: nxterm_getglyph
****************************************************************************/
-static FAR struct nxcon_glyph_s *
-nxcon_getglyph(NXHANDLE hfont, FAR struct nxcon_state_s *priv, uint8_t ch)
+static FAR struct nxterm_glyph_s *
+nxterm_getglyph(NXHANDLE hfont, FAR struct nxterm_state_s *priv, uint8_t ch)
{
- FAR struct nxcon_glyph_s *glyph;
+ FAR struct nxterm_glyph_s *glyph;
FAR const struct nx_fontbitmap_s *fbm;
/* First, try to find the glyph in the cache of pre-rendered glyphs */
- glyph = nxcon_findglyph(priv, ch);
+ glyph = nxterm_findglyph(priv, ch);
if (glyph)
{
/* We found it in the cache .. return the cached glyph */
@@ -377,7 +377,7 @@ nxcon_getglyph(NXHANDLE hfont, FAR struct nxcon_state_s *priv, uint8_t ch)
{
/* Yes.. render the glyph */
- glyph = nxcon_renderglyph(priv, fbm, ch);
+ glyph = nxterm_renderglyph(priv, fbm, ch);
}
return glyph;
@@ -388,19 +388,19 @@ nxcon_getglyph(NXHANDLE hfont, FAR struct nxcon_state_s *priv, uint8_t ch)
****************************************************************************/
/****************************************************************************
- * Name: nxcon_addchar
+ * Name: nxterm_addchar
*
* Description:
- * This is part of the nxcon_putc logic. It creates and positions a
+ * This is part of the nxterm_putc logic. It creates and positions a
* the character and renders (or re-uses) a glyph for font.
*
****************************************************************************/
-FAR const struct nxcon_bitmap_s *
-nxcon_addchar(NXHANDLE hfont, FAR struct nxcon_state_s *priv, uint8_t ch)
+FAR const struct nxterm_bitmap_s *
+nxterm_addchar(NXHANDLE hfont, FAR struct nxterm_state_s *priv, uint8_t ch)
{
- FAR struct nxcon_bitmap_s *bm = NULL;
- FAR struct nxcon_glyph_s *glyph;
+ FAR struct nxterm_bitmap_s *bm = NULL;
+ FAR struct nxterm_glyph_s *glyph;
/* Is there space for another character on the display? */
@@ -416,7 +416,7 @@ nxcon_addchar(NXHANDLE hfont, FAR struct nxcon_state_s *priv, uint8_t ch)
/* Find (or create) the matching glyph */
- glyph = nxcon_getglyph(hfont, priv, ch);
+ glyph = nxterm_getglyph(hfont, priv, ch);
if (!glyph)
{
/* No, there is no font for this code. Just mark this as a space. */
@@ -443,25 +443,25 @@ nxcon_addchar(NXHANDLE hfont, FAR struct nxcon_state_s *priv, uint8_t ch)
}
/****************************************************************************
- * Name: nxcon_hidechar
+ * Name: nxterm_hidechar
*
* Description:
* Erase a character from the window.
*
****************************************************************************/
-int nxcon_hidechar(FAR struct nxcon_state_s *priv,
- FAR const struct nxcon_bitmap_s *bm)
+int nxterm_hidechar(FAR struct nxterm_state_s *priv,
+ FAR const struct nxterm_bitmap_s *bm)
{
struct nxgl_rect_s bounds;
struct nxgl_size_s fsize;
int ret;
- /* Get the size of the font glyph. If nxcon_fontsize, then the
+ /* Get the size of the font glyph. If nxterm_fontsize, then the
* character will have been rendered as a space, and no display
* modification is required (not an error).
*/
- ret = nxcon_fontsize(priv->font, bm->code, &fsize);
+ ret = nxterm_fontsize(priv->font, bm->code, &fsize);
if (ret < 0)
{
/* It was rendered as a space. */
@@ -485,16 +485,16 @@ int nxcon_hidechar(FAR struct nxcon_state_s *priv,
}
/****************************************************************************
- * Name: nxcon_backspace
+ * Name: nxterm_backspace
*
* Description:
* Remove the last character from the window.
*
****************************************************************************/
-int nxcon_backspace(FAR struct nxcon_state_s *priv)
+int nxterm_backspace(FAR struct nxterm_state_s *priv)
{
- FAR struct nxcon_bitmap_s *bm;
+ FAR struct nxterm_bitmap_s *bm;
int ndx;
int ret = -ENOENT;
@@ -509,7 +509,7 @@ int nxcon_backspace(FAR struct nxcon_state_s *priv)
/* Erase the character from the display */
- ret = nxcon_hidechar(priv, bm);
+ ret = nxterm_hidechar(priv, bm);
/* The current position to the location where the last character was */
@@ -525,14 +525,14 @@ int nxcon_backspace(FAR struct nxcon_state_s *priv)
}
/****************************************************************************
- * Name: nxcon_home
+ * Name: nxterm_home
*
* Description:
* Set the next character position to the top-left corner of the display.
*
****************************************************************************/
-void nxcon_home(FAR struct nxcon_state_s *priv)
+void nxterm_home(FAR struct nxterm_state_s *priv)
{
/* The first character is one space from the left */
@@ -544,14 +544,14 @@ void nxcon_home(FAR struct nxcon_state_s *priv)
}
/****************************************************************************
- * Name: nxcon_newline
+ * Name: nxterm_newline
*
* Description:
* Set the next character position to the beginning of the next line.
*
****************************************************************************/
-void nxcon_newline(FAR struct nxcon_state_s *priv)
+void nxterm_newline(FAR struct nxterm_state_s *priv)
{
/* Carriage return: The first character is one space from the left */
@@ -563,19 +563,19 @@ void nxcon_newline(FAR struct nxcon_state_s *priv)
}
/****************************************************************************
- * Name: nxcon_fillchar
+ * Name: nxterm_fillchar
*
* Description:
- * This implements the character display. It is part of the nxcon_putc
+ * This implements the character display. It is part of the nxterm_putc
* operation but may also be used when redrawing an existing display.
*
****************************************************************************/
-void nxcon_fillchar(FAR struct nxcon_state_s *priv,
+void nxterm_fillchar(FAR struct nxterm_state_s *priv,
FAR const struct nxgl_rect_s *rect,
- FAR const struct nxcon_bitmap_s *bm)
+ FAR const struct nxterm_bitmap_s *bm)
{
- FAR struct nxcon_glyph_s *glyph;
+ FAR struct nxterm_glyph_s *glyph;
struct nxgl_rect_s bounds;
struct nxgl_rect_s intersection;
struct nxgl_size_s fsize;
@@ -590,7 +590,7 @@ void nxcon_fillchar(FAR struct nxcon_state_s *priv,
/* Get the size of the font glyph (which may not have been created yet) */
- ret = nxcon_fontsize(priv->font, bm->code, &fsize);
+ ret = nxterm_fontsize(priv->font, bm->code, &fsize);
if (ret < 0)
{
/* This would mean that there is no bitmap for the character code and
@@ -632,7 +632,7 @@ void nxcon_fillchar(FAR struct nxcon_state_s *priv,
/* Find (or create) the glyph that goes with this font */
- glyph = nxcon_getglyph(priv->font, priv, bm->code);
+ glyph = nxterm_getglyph(priv->font, priv, bm->code);
if (!glyph)
{
/* Shouldn't happen */
diff --git a/nuttx/graphics/nxterm/nxcon_kbdin.c b/nuttx/graphics/nxterm/nxterm_kbdin.c
index 4cac68edf..46c6e200b 100644
--- a/nuttx/graphics/nxterm/nxcon_kbdin.c
+++ b/nuttx/graphics/nxterm/nxterm_kbdin.c
@@ -1,5 +1,5 @@
/****************************************************************************
- * nuttx/graphics/nxterm/nxcon_kbdin.c
+ * nuttx/graphics/nxterm/nxterm_kbdin.c
*
* Copyright (C) 2012 Gregory Nutt. All rights reserved.
* Author: Gregory Nutt <gnutt@nuttx.org>
@@ -46,7 +46,7 @@
#include <errno.h>
#include <debug.h>
-#include "nxcon_internal.h"
+#include "nxterm.h"
#ifdef CONFIG_NXTERM_NXKBDIN
@@ -67,11 +67,11 @@
****************************************************************************/
/****************************************************************************
- * Name: nxcon_pollnotify
+ * Name: nxterm_pollnotify
****************************************************************************/
#ifndef CONFIG_DISABLE_POLL
-static void nxcon_pollnotify(FAR struct nxcon_state_s *priv, pollevent_t eventset)
+static void nxterm_pollnotify(FAR struct nxterm_state_s *priv, pollevent_t eventset)
{
FAR struct pollfd *fds;
irqstate_t flags;
@@ -95,7 +95,7 @@ static void nxcon_pollnotify(FAR struct nxcon_state_s *priv, pollevent_t eventse
}
}
#else
-# define nxcon_pollnotify(priv,event)
+# define nxterm_pollnotify(priv,event)
#endif
/****************************************************************************
@@ -103,16 +103,16 @@ static void nxcon_pollnotify(FAR struct nxcon_state_s *priv, pollevent_t eventse
****************************************************************************/
/****************************************************************************
- * Name: nxcon_read
+ * Name: nxterm_read
*
* Description:
* The optional NxTerm read method
*
****************************************************************************/
-ssize_t nxcon_read(FAR struct file *filep, FAR char *buffer, size_t len)
+ssize_t nxterm_read(FAR struct file *filep, FAR char *buffer, size_t len)
{
- FAR struct nxcon_state_s *priv;
+ FAR struct nxterm_state_s *priv;
ssize_t nread;
char ch;
int ret;
@@ -120,14 +120,14 @@ ssize_t nxcon_read(FAR struct file *filep, FAR char *buffer, size_t len)
/* Recover our private state structure */
DEBUGASSERT(filep && filep->f_priv);
- priv = (FAR struct nxcon_state_s *)filep->f_priv;
+ priv = (FAR struct nxterm_state_s *)filep->f_priv;
/* Get exclusive access to the driver structure */
- ret = nxcon_semwait(priv);
+ ret = nxterm_semwait(priv);
if (ret < 0)
{
- gdbg("ERROR: nxcon_semwait failed\n");
+ gdbg("ERROR: nxterm_semwait failed\n");
return ret;
}
@@ -159,13 +159,13 @@ ssize_t nxcon_read(FAR struct file *filep, FAR char *buffer, size_t len)
}
/* Otherwise, wait for something to be written to the circular
- * buffer. Increment the number of waiters so that the nxcon_write()
+ * buffer. Increment the number of waiters so that the nxterm_write()
* will not that it needs to post the semaphore to wake us up.
*/
sched_lock();
priv->nwaiters++;
- nxcon_sempost(priv);
+ nxterm_sempost(priv);
/* We may now be pre-empted! But that should be okay because we
* have already incremented nwaiters. Pre-emption is disabled
@@ -187,7 +187,7 @@ ssize_t nxcon_read(FAR struct file *filep, FAR char *buffer, size_t len)
{
/* Yes... then retake the mutual exclusion semaphore */
- ret = nxcon_semwait(priv);
+ ret = nxterm_semwait(priv);
}
/* Was the semaphore wait successful? Did we successful re-take the
@@ -200,7 +200,7 @@ ssize_t nxcon_read(FAR struct file *filep, FAR char *buffer, size_t len)
int errval = errno;
- gdbg("ERROR: nxcon_semwait failed\n");
+ gdbg("ERROR: nxterm_semwait failed\n");
/* Were we awakened by a signal? Did we read anything before
* we received the signal?
@@ -245,7 +245,7 @@ ssize_t nxcon_read(FAR struct file *filep, FAR char *buffer, size_t len)
/* Relinquish the mutual exclusion semaphore */
- nxcon_sempost(priv);
+ nxterm_sempost(priv);
/* Notify all poll/select waiters that they can write to the FIFO */
@@ -254,7 +254,7 @@ errout_without_sem:
#ifndef CONFIG_DISABLE_POLL
if (nread > 0)
{
- nxcon_pollnotify(priv, POLLOUT);
+ nxterm_pollnotify(priv, POLLOUT);
}
#endif
@@ -264,14 +264,14 @@ errout_without_sem:
}
/****************************************************************************
- * Name: nxcon_poll
+ * Name: nxterm_poll
****************************************************************************/
#ifndef CONFIG_DISABLE_POLL
-int nxcon_poll(FAR struct file *filep, FAR struct pollfd *fds, bool setup)
+int nxterm_poll(FAR struct file *filep, FAR struct pollfd *fds, bool setup)
{
FAR struct inode *inode = filep->f_inode;
- FAR struct nxcon_state_s *priv;
+ FAR struct nxterm_state_s *priv;
pollevent_t eventset;
int ret;
int i;
@@ -283,10 +283,10 @@ int nxcon_poll(FAR struct file *filep, FAR struct pollfd *fds, bool setup)
/* Get exclusive access to the driver structure */
- ret = nxcon_semwait(priv);
+ ret = nxterm_semwait(priv);
if (ret < 0)
{
- gdbg("ERROR: nxcon_semwait failed\n");
+ gdbg("ERROR: nxterm_semwait failed\n");
return ret;
}
@@ -336,7 +336,7 @@ int nxcon_poll(FAR struct file *filep, FAR struct pollfd *fds, bool setup)
if (eventset)
{
- nxcon_pollnotify(priv, eventset);
+ nxterm_pollnotify(priv, eventset);
}
}
@@ -363,13 +363,13 @@ int nxcon_poll(FAR struct file *filep, FAR struct pollfd *fds, bool setup)
}
errout:
- nxcon_sempost(priv);
+ nxterm_sempost(priv);
return ret;
}
#endif
/****************************************************************************
- * Name: nxcon_kbdin
+ * Name: nxterm_kbdin
*
* Description:
* This function should be driven by the window kbdin callback function
@@ -394,9 +394,9 @@ errout:
*
****************************************************************************/
-void nxcon_kbdin(NXTERM handle, FAR const uint8_t *buffer, uint8_t buflen)
+void nxterm_kbdin(NXTERM handle, FAR const uint8_t *buffer, uint8_t buflen)
{
- FAR struct nxcon_state_s *priv;
+ FAR struct nxterm_state_s *priv;
ssize_t nwritten;
int nexthead;
char ch;
@@ -407,14 +407,14 @@ void nxcon_kbdin(NXTERM handle, FAR const uint8_t *buffer, uint8_t buflen)
/* Get the reference to the driver structure from the handle */
- priv = (FAR struct nxcon_state_s *)handle;
+ priv = (FAR struct nxterm_state_s *)handle;
/* Get exclusive access to the driver structure */
- ret = nxcon_semwait(priv);
+ ret = nxterm_semwait(priv);
if (ret < 0)
{
- gdbg("ERROR: nxcon_semwait failed\n");
+ gdbg("ERROR: nxterm_semwait failed\n");
return;
}
@@ -478,12 +478,12 @@ void nxcon_kbdin(NXTERM handle, FAR const uint8_t *buffer, uint8_t buflen)
/* Notify all poll/select waiters that they can write to the FIFO */
#ifndef CONFIG_DISABLE_POLL
- nxcon_pollnotify(priv, POLLIN);
+ nxterm_pollnotify(priv, POLLIN);
#endif
sched_unlock();
}
- nxcon_sempost(priv);
+ nxterm_sempost(priv);
}
#endif /* CONFIG_NXTERM_NXKBDIN */
diff --git a/nuttx/graphics/nxterm/nxcon_putc.c b/nuttx/graphics/nxterm/nxterm_putc.c
index aa0c8f8a3..621f40664 100644
--- a/nuttx/graphics/nxterm/nxcon_putc.c
+++ b/nuttx/graphics/nxterm/nxterm_putc.c
@@ -1,5 +1,5 @@
/****************************************************************************
- * nuttx/graphics/nxterm/nxcon_putc.c
+ * nuttx/graphics/nxterm/nxterm_putc.c
*
* Copyright (C) 2012 Gregory Nutt. All rights reserved.
* Author: Gregory Nutt <gnutt@nuttx.org>
@@ -41,7 +41,7 @@
#include <nuttx/ascii.h>
-#include "nxcon_internal.h"
+#include "nxterm.h"
/****************************************************************************
* Definitions
@@ -68,16 +68,16 @@
****************************************************************************/
/****************************************************************************
- * Name: nxcon_putc
+ * Name: nxterm_putc
*
* Description:
* Render the specified character at the current display position.
*
****************************************************************************/
-void nxcon_putc(FAR struct nxcon_state_s *priv, uint8_t ch)
+void nxterm_putc(FAR struct nxterm_state_s *priv, uint8_t ch)
{
- FAR const struct nxcon_bitmap_s *bm;
+ FAR const struct nxterm_bitmap_s *bm;
int lineheight;
/* Ignore carriage returns */
@@ -91,7 +91,7 @@ void nxcon_putc(FAR struct nxcon_state_s *priv, uint8_t ch)
if (ch == ASCII_BS || ch == ASCII_DEL)
{
- nxcon_backspace(priv);
+ nxterm_backspace(priv);
return;
}
@@ -102,7 +102,7 @@ void nxcon_putc(FAR struct nxcon_state_s *priv, uint8_t ch)
#ifndef CONFIG_NXTERM_NOWRAP
/* No.. move to the next line */
- nxcon_newline(priv);
+ nxterm_newline(priv);
/* If we were about to output a newline character, then don't */
@@ -126,7 +126,7 @@ void nxcon_putc(FAR struct nxcon_state_s *priv, uint8_t ch)
if (ch == '\n')
{
- nxcon_newline(priv);
+ nxterm_newline(priv);
return;
}
@@ -135,29 +135,29 @@ void nxcon_putc(FAR struct nxcon_state_s *priv, uint8_t ch)
lineheight = (priv->fheight + CONFIG_NXTERM_LINESEPARATION);
while (priv->fpos.y >= priv->wndo.wsize.h - lineheight)
{
- nxcon_scroll(priv, lineheight);
+ nxterm_scroll(priv, lineheight);
}
/* Find the glyph associated with the character and render it onto the
* display.
*/
- bm = nxcon_addchar(priv->font, priv, ch);
+ bm = nxterm_addchar(priv->font, priv, ch);
if (bm)
{
- nxcon_fillchar(priv, NULL, bm);
+ nxterm_fillchar(priv, NULL, bm);
}
}
/****************************************************************************
- * Name: nxcon_showcursor
+ * Name: nxterm_showcursor
*
* Description:
* Render the cursor character at the current display position.
*
****************************************************************************/
-void nxcon_showcursor(FAR struct nxcon_state_s *priv)
+void nxterm_showcursor(FAR struct nxterm_state_s *priv)
{
int lineheight;
@@ -168,7 +168,7 @@ void nxcon_showcursor(FAR struct nxcon_state_s *priv)
#ifndef CONFIG_NXTERM_NOWRAP
/* No.. move to the next line */
- nxcon_newline(priv);
+ nxterm_newline(priv);
#else
return;
#endif
@@ -179,25 +179,25 @@ void nxcon_showcursor(FAR struct nxcon_state_s *priv)
lineheight = (priv->fheight + CONFIG_NXTERM_LINESEPARATION);
while (priv->fpos.y >= priv->wndo.wsize.h - lineheight)
{
- nxcon_scroll(priv, lineheight);
+ nxterm_scroll(priv, lineheight);
}
/* Render the cursor glyph onto the display. */
priv->cursor.pos.x = priv->fpos.x;
priv->cursor.pos.y = priv->fpos.y;
- nxcon_fillchar(priv, NULL, &priv->cursor);
+ nxterm_fillchar(priv, NULL, &priv->cursor);
}
/****************************************************************************
- * Name: nxcon_hidecursor
+ * Name: nxterm_hidecursor
*
* Description:
* Render the cursor cursor character from the display.
*
****************************************************************************/
-void nxcon_hidecursor(FAR struct nxcon_state_s *priv)
+void nxterm_hidecursor(FAR struct nxterm_state_s *priv)
{
- (void)nxcon_hidechar(priv, &priv->cursor);
+ (void)nxterm_hidechar(priv, &priv->cursor);
}
diff --git a/nuttx/graphics/nxterm/nxcon_redraw.c b/nuttx/graphics/nxterm/nxterm_redraw.c
index 5ecb4ed48..71e18fcce 100644
--- a/nuttx/graphics/nxterm/nxcon_redraw.c
+++ b/nuttx/graphics/nxterm/nxterm_redraw.c
@@ -1,5 +1,5 @@
/****************************************************************************
- * nuttx/graphics/nxterm/nxcon_bkgd.c
+ * nuttx/graphics/nxterm/nxterm_bkgd.c
*
* Copyright (C) 2012 Gregory Nutt. All rights reserved.
* Author: Gregory Nutt <gnutt@nuttx.org>
@@ -49,7 +49,7 @@
#include <nuttx/nx/nx.h>
#include <nuttx/nx/nxglib.h>
-#include "nxcon_internal.h"
+#include "nxterm.h"
/****************************************************************************
* Definitions
@@ -80,7 +80,7 @@
****************************************************************************/
/****************************************************************************
- * Name: nxcon_redraw
+ * Name: nxterm_redraw
*
* Description:
* Re-draw a portion of the NX console. This function should be called
@@ -98,9 +98,9 @@
*
****************************************************************************/
-void nxcon_redraw(NXTERM handle, FAR const struct nxgl_rect_s *rect, bool more)
+void nxterm_redraw(NXTERM handle, FAR const struct nxgl_rect_s *rect, bool more)
{
- FAR struct nxcon_state_s *priv;
+ FAR struct nxterm_state_s *priv;
int ret;
int i;
@@ -111,13 +111,13 @@ void nxcon_redraw(NXTERM handle, FAR const struct nxgl_rect_s *rect, bool more)
/* Recover our private state structure */
- priv = (FAR struct nxcon_state_s *)handle;
+ priv = (FAR struct nxterm_state_s *)handle;
/* Get exclusive access to the state structure */
do
{
- ret = nxcon_semwait(priv);
+ ret = nxterm_semwait(priv);
/* Check for errors */
@@ -146,8 +146,8 @@ void nxcon_redraw(NXTERM handle, FAR const struct nxgl_rect_s *rect, bool more)
for (i = 0; i < priv->nchars; i++)
{
- nxcon_fillchar(priv, rect, &priv->bm[i]);
+ nxterm_fillchar(priv, rect, &priv->bm[i]);
}
- (void)nxcon_sempost(priv);
+ (void)nxterm_sempost(priv);
}
diff --git a/nuttx/graphics/nxterm/nxcon_register.c b/nuttx/graphics/nxterm/nxterm_register.c
index c2ddca8f1..6a49e641c 100644
--- a/nuttx/graphics/nxterm/nxcon_register.c
+++ b/nuttx/graphics/nxterm/nxterm_register.c
@@ -1,5 +1,5 @@
/****************************************************************************
- * nuttx/graphics/nxterm/nxcon_register.c
+ * nuttx/graphics/nxterm/nxterm_register.c
*
* Copyright (C) 2012 Gregory Nutt. All rights reserved.
* Author: Gregory Nutt <gnutt@nuttx.org>
@@ -50,7 +50,7 @@
#include <nuttx/kmalloc.h>
#include <nuttx/fs/fs.h>
-#include "nxcon_internal.h"
+#include "nxterm.h"
/****************************************************************************
* Private Function Prototypes
@@ -69,14 +69,14 @@
****************************************************************************/
/****************************************************************************
- * Name: nxcon_allocate
+ * Name: nxterm_allocate
****************************************************************************/
-FAR struct nxcon_state_s *
- nxcon_register(NXTERM handle, FAR struct nxcon_window_s *wndo,
- FAR const struct nxcon_operations_s *ops, int minor)
+FAR struct nxterm_state_s *
+ nxterm_register(NXTERM handle, FAR struct nxterm_window_s *wndo,
+ FAR const struct nxterm_operations_s *ops, int minor)
{
- FAR struct nxcon_state_s *priv;
+ FAR struct nxterm_state_s *priv;
char devname[NX_DEVNAME_SIZE];
int ret;
@@ -84,7 +84,7 @@ FAR struct nxcon_state_s *
/* Allocate the driver structure */
- priv = (FAR struct nxcon_state_s *)kmm_zalloc(sizeof(struct nxcon_state_s));
+ priv = (FAR struct nxterm_state_s *)kmm_zalloc(sizeof(struct nxterm_state_s));
if (!priv)
{
gdbg("Failed to allocate the NX driver structure\n");
@@ -96,7 +96,7 @@ FAR struct nxcon_state_s *
priv->ops = ops;
priv->handle = handle;
priv->minor = minor;
- memcpy(&priv->wndo, wndo, sizeof( struct nxcon_window_s));
+ memcpy(&priv->wndo, wndo, sizeof( struct nxterm_window_s));
sem_init(&priv->exclsem, 0, 1);
#ifdef CONFIG_DEBUG
@@ -137,17 +137,17 @@ FAR struct nxcon_state_s *
/* Set the initial display position */
- nxcon_home(priv);
+ nxterm_home(priv);
/* Show the cursor */
priv->cursor.code = CONFIG_NXTERM_CURSORCHAR;
- nxcon_showcursor(priv);
+ nxterm_showcursor(priv);
/* Register the driver */
snprintf(devname, NX_DEVNAME_SIZE, NX_DEVNAME_FORMAT, minor);
- ret = register_driver(devname, &g_nxcon_drvrops, 0666, priv);
+ ret = register_driver(devname, &g_nxterm_drvrops, 0666, priv);
if (ret < 0)
{
gdbg("Failed to register %s\n", devname);
diff --git a/nuttx/graphics/nxterm/nxcon_scroll.c b/nuttx/graphics/nxterm/nxterm_scroll.c
index 508d26ec3..bb251ab1d 100644
--- a/nuttx/graphics/nxterm/nxcon_scroll.c
+++ b/nuttx/graphics/nxterm/nxterm_scroll.c
@@ -1,5 +1,5 @@
/****************************************************************************
- * nuttx/graphics/nxterm/nxcon_scroll.c
+ * nuttx/graphics/nxterm/nxterm_scroll.c
*
* Copyright (C) 2012, 2014 Gregory Nutt. All rights reserved.
* Author: Gregory Nutt <gnutt@nuttx.org>
@@ -51,7 +51,7 @@
#include <nuttx/nx/nx.h>
#include <nuttx/nx/nxfonts.h>
-#include "nxcon_internal.h"
+#include "nxterm.h"
/****************************************************************************
* Definitions
@@ -78,7 +78,7 @@
****************************************************************************/
/****************************************************************************
- * Name: nxcon_movedisplay
+ * Name: nxterm_movedisplay
*
* Description:
* This function implements the data movement for the scroll operation. If
@@ -88,17 +88,17 @@
****************************************************************************/
#ifdef CONFIG_NX_WRITEONLY
-static inline void nxcon_movedisplay(FAR struct nxcon_state_s *priv,
+static inline void nxterm_movedisplay(FAR struct nxterm_state_s *priv,
int bottom, int scrollheight)
{
- FAR struct nxcon_bitmap_s *bm;
+ FAR struct nxterm_bitmap_s *bm;
struct nxgl_rect_s rect;
nxgl_coord_t row;
int ret;
int i;
/* Move each row, one at a time. They could all be moved at once (by calling
- * nxcon_redraw), but the since the region is cleared, then re-written, the
+ * nxterm_redraw), but the since the region is cleared, then re-written, the
* effect would not be good. Below the region is also cleared and re-written,
* however, in much smaller chunks.
*/
@@ -128,7 +128,7 @@ static inline void nxcon_movedisplay(FAR struct nxcon_state_s *priv,
bm = &priv->bm[i];
if (bm->pos.y <= rect.pt2.y && bm->pos.y + priv->fheight >= rect.pt1.y)
{
- nxcon_fillchar(priv, &rect, bm);
+ nxterm_fillchar(priv, &rect, bm);
}
}
}
@@ -145,7 +145,7 @@ static inline void nxcon_movedisplay(FAR struct nxcon_state_s *priv,
}
}
#else
-static inline void nxcon_movedisplay(FAR struct nxcon_state_s *priv,
+static inline void nxterm_movedisplay(FAR struct nxterm_state_s *priv,
int bottom, int scrollheight)
{
struct nxgl_rect_s rect;
@@ -197,10 +197,10 @@ static inline void nxcon_movedisplay(FAR struct nxcon_state_s *priv,
****************************************************************************/
/****************************************************************************
- * Name: nxcon_scroll
+ * Name: nxterm_scroll
****************************************************************************/
-void nxcon_scroll(FAR struct nxcon_state_s *priv, int scrollheight)
+void nxterm_scroll(FAR struct nxterm_state_s *priv, int scrollheight)
{
int i;
int j;
@@ -209,7 +209,7 @@ void nxcon_scroll(FAR struct nxcon_state_s *priv, int scrollheight)
for (i = 0; i < priv->nchars; )
{
- FAR struct nxcon_bitmap_s *bm = &priv->bm[i];
+ FAR struct nxterm_bitmap_s *bm = &priv->bm[i];
/* Has any part of this character scrolled off the screen? */
@@ -219,7 +219,7 @@ void nxcon_scroll(FAR struct nxcon_state_s *priv, int scrollheight)
for (j = i; j < priv->nchars-1; j++)
{
- memcpy(&priv->bm[j], &priv->bm[j+1], sizeof(struct nxcon_bitmap_s));
+ memcpy(&priv->bm[j], &priv->bm[j+1], sizeof(struct nxterm_bitmap_s));
}
/* Decrement the number of cached characters ('i' is not incremented
@@ -249,5 +249,5 @@ void nxcon_scroll(FAR struct nxcon_state_s *priv, int scrollheight)
/* Move the display in the range of 0-height up one scrollheight. */
- nxcon_movedisplay(priv, priv->fpos.y, scrollheight);
+ nxterm_movedisplay(priv, priv->fpos.y, scrollheight);
}
diff --git a/nuttx/graphics/nxterm/nxcon_sem.c b/nuttx/graphics/nxterm/nxterm_sem.c
index 97d09c2b6..3bdbf8541 100644
--- a/nuttx/graphics/nxterm/nxcon_sem.c
+++ b/nuttx/graphics/nxterm/nxterm_sem.c
@@ -1,5 +1,5 @@
/****************************************************************************
- * nuttx/graphics/nxterm/nxcon_sem.c
+ * nuttx/graphics/nxterm/nxterm_sem.c
*
* Copyright (C) 2012 Gregory Nutt. All rights reserved.
* Author: Gregory Nutt <gnutt@nuttx.org>
@@ -44,7 +44,7 @@
#include <assert.h>
#include <errno.h>
-#include "nxcon_internal.h"
+#include "nxterm.h"
#ifdef CONFIG_DEBUG
@@ -69,7 +69,7 @@
****************************************************************************/
/****************************************************************************
- * Name: nxcon_semwait and nxcon_sempost
+ * Name: nxterm_semwait and nxterm_sempost
*
* Description:
* If debug is on, then lower level code may attempt console output while
@@ -84,7 +84,7 @@
*
****************************************************************************/
-int nxcon_semwait(FAR struct nxcon_state_s *priv)
+int nxterm_semwait(FAR struct nxterm_state_s *priv)
{
pid_t me;
int ret;
@@ -112,7 +112,7 @@ int nxcon_semwait(FAR struct nxcon_state_s *priv)
return ERROR;
}
-int nxcon_sempost(FAR struct nxcon_state_s *priv)
+int nxterm_sempost(FAR struct nxterm_state_s *priv)
{
pid_t me = getpid();
diff --git a/nuttx/graphics/nxterm/nxcon_unregister.c b/nuttx/graphics/nxterm/nxterm_unregister.c
index a502eadd4..e51e44c17 100644
--- a/nuttx/graphics/nxterm/nxcon_unregister.c
+++ b/nuttx/graphics/nxterm/nxterm_unregister.c
@@ -1,5 +1,5 @@
/****************************************************************************
- * nuttx/graphics/nxterm/nxcon_unregister.c
+ * nuttx/graphics/nxterm/nxterm_unregister.c
*
* Copyright (C) 2012 Gregory Nutt. All rights reserved.
* Author: Gregory Nutt <gnutt@nuttx.org>
@@ -48,7 +48,7 @@
#include <nuttx/kmalloc.h>
#include <nuttx/nx/nxterm.h>
-#include "nxcon_internal.h"
+#include "nxterm.h"
/****************************************************************************
* Pre-processor Definitions
@@ -71,7 +71,7 @@
****************************************************************************/
/****************************************************************************
- * Name: nxcon_unregister
+ * Name: nxterm_unregister
*
* Description:
* Un-register to NX console device.
@@ -85,9 +85,9 @@
*
****************************************************************************/
-void nxcon_unregister(NXTERM handle)
+void nxterm_unregister(NXTERM handle)
{
- FAR struct nxcon_state_s *priv;
+ FAR struct nxterm_state_s *priv;
char devname[NX_DEVNAME_SIZE];
int i;
@@ -95,7 +95,7 @@ void nxcon_unregister(NXTERM handle)
/* Get the reference to the driver structure from the handle */
- priv = (FAR struct nxcon_state_s *)handle;
+ priv = (FAR struct nxterm_state_s *)handle;
sem_destroy(&priv->exclsem);
#ifdef CONFIG_NXTERM_NXKBDIN
sem_destroy(&priv->waitsem);
@@ -105,7 +105,7 @@ void nxcon_unregister(NXTERM handle)
for (i = 0; i < CONFIG_NXTERM_CACHESIZE; i++)
{
- FAR struct nxcon_glyph_s *glyph = &priv->glyph[i];
+ FAR struct nxterm_glyph_s *glyph = &priv->glyph[i];
if (glyph->bitmap)
{
kmm_free(glyph->bitmap);
diff --git a/nuttx/graphics/nxterm/nxcon_vt100.c b/nuttx/graphics/nxterm/nxterm_vt100.c
index cc8796341..17e3356ca 100644
--- a/nuttx/graphics/nxterm/nxcon_vt100.c
+++ b/nuttx/graphics/nxterm/nxterm_vt100.c
@@ -1,5 +1,5 @@
/****************************************************************************
- * nuttx/graphics/nxterm/nxcon_vt100.c
+ * nuttx/graphics/nxterm/nxterm_vt100.c
*
* Copyright (C) 2012 Gregory Nutt. All rights reserved.
* Author: Gregory Nutt <gnutt@nuttx.org>
@@ -44,7 +44,7 @@
#include <nuttx/vt100.h>
-#include "nxcon_internal.h"
+#include "nxterm.h"
/****************************************************************************
* Pre-processor Definitions
@@ -54,7 +54,7 @@
* Private Types
****************************************************************************/
-typedef int (*seqhandler_t)(FAR struct nxcon_state_s *priv);
+typedef int (*seqhandler_t)(FAR struct nxterm_state_s *priv);
struct vt100_sequence_s
{
@@ -67,7 +67,7 @@ struct vt100_sequence_s
* Private Function Prototypes
****************************************************************************/
-static int nxcon_erasetoeol(FAR struct nxcon_state_s *priv);
+static int nxterm_erasetoeol(FAR struct nxterm_state_s *priv);
/****************************************************************************
* Private Data
@@ -85,7 +85,7 @@ static const char g_erasetoeol[] = VT100_CLEAREOL;
static const struct vt100_sequence_s g_vt100sequences[] =
{
- {g_erasetoeol, nxcon_erasetoeol, sizeof(g_erasetoeol)},
+ {g_erasetoeol, nxterm_erasetoeol, sizeof(g_erasetoeol)},
{NULL, NULL, 0}
};
@@ -94,7 +94,7 @@ static const struct vt100_sequence_s g_vt100sequences[] =
****************************************************************************/
/****************************************************************************
- * Name: nxcon_erasetoeol
+ * Name: nxterm_erasetoeol
*
* Description:
* Handle the erase-to-eol VT100 escapte sequence
@@ -107,7 +107,7 @@ static const struct vt100_sequence_s g_vt100sequences[] =
*
****************************************************************************/
-static int nxcon_erasetoeol(FAR struct nxcon_state_s *priv)
+static int nxterm_erasetoeol(FAR struct nxterm_state_s *priv)
{
/* Does nothing yet (other than consume the sequence) */
@@ -115,7 +115,7 @@ static int nxcon_erasetoeol(FAR struct nxcon_state_s *priv)
}
/****************************************************************************
- * Name: nxcon_vt100part
+ * Name: nxterm_vt100part
*
* Description:
* Return the next entry that is a partial match to the sequence.
@@ -131,7 +131,7 @@ static int nxcon_erasetoeol(FAR struct nxcon_state_s *priv)
****************************************************************************/
FAR const struct vt100_sequence_s *
-nxcon_vt100part(FAR struct nxcon_state_s *priv, int seqsize)
+nxterm_vt100part(FAR struct nxterm_state_s *priv, int seqsize)
{
FAR const struct vt100_sequence_s *seq;
int ndx;
@@ -159,7 +159,7 @@ nxcon_vt100part(FAR struct nxcon_state_s *priv, int seqsize)
}
/****************************************************************************
- * Name: nxcon_vt100seq
+ * Name: nxterm_vt100seq
*
* Description:
* Determine if the new sequence is a part of a supported VT100 escape
@@ -170,21 +170,21 @@ nxcon_vt100part(FAR struct nxcon_state_s *priv, int seqsize)
* seqsize - The number of bytes in the sequence
*
* Returned Value:
- * state - See enum nxcon_vt100state_e;
+ * state - See enum nxterm_vt100state_e;
*
****************************************************************************/
-static enum nxcon_vt100state_e nxcon_vt100seq(FAR struct nxcon_state_s *priv,
+static enum nxterm_vt100state_e nxterm_vt100seq(FAR struct nxterm_state_s *priv,
int seqsize)
{
FAR const struct vt100_sequence_s *seq;
- enum nxcon_vt100state_e ret;
+ enum nxterm_vt100state_e ret;
/* Is there any VT100 escape sequence that matches what we have
* buffered so far?
*/
- seq = nxcon_vt100part(priv, seqsize);
+ seq = nxterm_vt100part(priv, seqsize);
if (seq)
{
/* Yes.. if the size of that escape sequence is the same as what we
@@ -223,7 +223,7 @@ static enum nxcon_vt100state_e nxcon_vt100seq(FAR struct nxcon_state_s *priv,
****************************************************************************/
/****************************************************************************
- * Name: nxcon_vt100
+ * Name: nxterm_vt100
*
* Description:
* Test if the newly received byte is part of a VT100 escape sequence
@@ -233,13 +233,13 @@ static enum nxcon_vt100state_e nxcon_vt100seq(FAR struct nxcon_state_s *priv,
* ch - The newly received character
*
* Returned Value:
- * state - See enum nxcon_vt100state_e;
+ * state - See enum nxterm_vt100state_e;
*
****************************************************************************/
-enum nxcon_vt100state_e nxcon_vt100(FAR struct nxcon_state_s *priv, char ch)
+enum nxterm_vt100state_e nxterm_vt100(FAR struct nxterm_state_s *priv, char ch)
{
- enum nxcon_vt100state_e ret;
+ enum nxterm_vt100state_e ret;
int seqsize;
DEBUGASSERT(priv && priv->nseq < VT100_MAX_SEQUENCE);
@@ -276,7 +276,7 @@ enum nxcon_vt100state_e nxcon_vt100(FAR struct nxcon_state_s *priv, char ch)
/* Then check if this sequence is part of an a valid escape sequence */
seqsize++;
- ret = nxcon_vt100seq(priv, seqsize);
+ ret = nxterm_vt100seq(priv, seqsize);
if (ret == VT100_CONSUMED)
{
/* The newly added character is indeed part of a VT100 escape sequence
diff --git a/nuttx/graphics/nxterm/nxtk_register.c b/nuttx/graphics/nxterm/nxtk_register.c
index df392961e..c66b56a06 100644
--- a/nuttx/graphics/nxterm/nxtk_register.c
+++ b/nuttx/graphics/nxterm/nxtk_register.c
@@ -42,7 +42,7 @@
#include <nuttx/nx/nxtk.h>
#include <nuttx/nx/nxterm.h>
-#include "nxcon_internal.h"
+#include "nxterm.h"
/****************************************************************************
* Pre-processor Definitions
@@ -52,15 +52,15 @@
* Private Function Prototypes
****************************************************************************/
-static int nxtkcon_fill(FAR struct nxcon_state_s *priv,
+static int nxtkcon_fill(FAR struct nxterm_state_s *priv,
FAR const struct nxgl_rect_s *rect,
nxgl_mxpixel_t wcolor[CONFIG_NX_NPLANES]);
#ifndef CONFIG_NX_WRITEONLY
-static int nxtkcon_move(FAR struct nxcon_state_s *priv,
+static int nxtkcon_move(FAR struct nxterm_state_s *priv,
FAR const struct nxgl_rect_s *rect,
FAR const struct nxgl_point_s *offset);
#endif
-static int nxtkcon_bitmap(FAR struct nxcon_state_s *priv,
+static int nxtkcon_bitmap(FAR struct nxterm_state_s *priv,
FAR const struct nxgl_rect_s *dest,
FAR const void *src[CONFIG_NX_NPLANES],
FAR const struct nxgl_point_s *origin,
@@ -70,7 +70,7 @@ static int nxtkcon_bitmap(FAR struct nxcon_state_s *priv,
* Private Data
****************************************************************************/
-static const struct nxcon_operations_s g_nxtkops =
+static const struct nxterm_operations_s g_nxtkops =
{
nxtkcon_fill,
#ifndef CONFIG_NX_WRITEONLY
@@ -99,7 +99,7 @@ static const struct nxcon_operations_s g_nxtkops =
*
****************************************************************************/
-static int nxtkcon_fill(FAR struct nxcon_state_s *priv,
+static int nxtkcon_fill(FAR struct nxterm_state_s *priv,
FAR const struct nxgl_rect_s *rect,
nxgl_mxpixel_t wcolor[CONFIG_NX_NPLANES])
{
@@ -124,7 +124,7 @@ static int nxtkcon_fill(FAR struct nxcon_state_s *priv,
****************************************************************************/
#ifndef CONFIG_NX_WRITEONLY
-static int nxtkcon_move(FAR struct nxcon_state_s *priv,
+static int nxtkcon_move(FAR struct nxterm_state_s *priv,
FAR const struct nxgl_rect_s *rect,
FAR const struct nxgl_point_s *offset)
{
@@ -155,7 +155,7 @@ static int nxtkcon_move(FAR struct nxcon_state_s *priv,
*
****************************************************************************/
-static int nxtkcon_bitmap(FAR struct nxcon_state_s *priv,
+static int nxtkcon_bitmap(FAR struct nxterm_state_s *priv,
FAR const struct nxgl_rect_s *dest,
FAR const void *src[CONFIG_NX_NPLANES],
FAR const struct nxgl_point_s *origin,
@@ -186,7 +186,7 @@ static int nxtkcon_bitmap(FAR struct nxcon_state_s *priv,
*
****************************************************************************/
-NXTERM nxtk_register(NXTKWINDOW hfwnd, FAR struct nxcon_window_s *wndo, int minor)
+NXTERM nxtk_register(NXTKWINDOW hfwnd, FAR struct nxterm_window_s *wndo, int minor)
{
- return nxcon_register((NXTERM)hfwnd, wndo, &g_nxtkops, minor);
+ return nxterm_register((NXTERM)hfwnd, wndo, &g_nxtkops, minor);
}
diff --git a/nuttx/graphics/nxterm/nxtool_register.c b/nuttx/graphics/nxterm/nxtool_register.c
index 631339a17..f1618bd5b 100644
--- a/nuttx/graphics/nxterm/nxtool_register.c
+++ b/nuttx/graphics/nxterm/nxtool_register.c
@@ -42,7 +42,7 @@
#include <nuttx/nx/nxtk.h>
#include <nuttx/nx/nxterm.h>
-#include "nxcon_internal.h"
+#include "nxterm.h"
/****************************************************************************
* Pre-processor Definitions
@@ -52,15 +52,15 @@
* Private Function Prototypes
****************************************************************************/
-static int nxtool_fill(FAR struct nxcon_state_s *priv,
+static int nxtool_fill(FAR struct nxterm_state_s *priv,
FAR const struct nxgl_rect_s *rect,
nxgl_mxpixel_t wcolor[CONFIG_NX_NPLANES]);
#ifndef CONFIG_NX_WRITEONLY
-static int nxtool_move(FAR struct nxcon_state_s *priv,
+static int nxtool_move(FAR struct nxterm_state_s *priv,
FAR const struct nxgl_rect_s *rect,
FAR const struct nxgl_point_s *offset);
#endif
-static int nxtool_bitmap(FAR struct nxcon_state_s *priv,
+static int nxtool_bitmap(FAR struct nxterm_state_s *priv,
FAR const struct nxgl_rect_s *dest,
FAR const void *src[CONFIG_NX_NPLANES],
FAR const struct nxgl_point_s *origin,
@@ -70,7 +70,7 @@ static int nxtool_bitmap(FAR struct nxcon_state_s *priv,
* Private Data
****************************************************************************/
-static const struct nxcon_operations_s g_nxtoolops =
+static const struct nxterm_operations_s g_nxtoolops =
{
nxtool_fill,
#ifndef CONFIG_NX_WRITEONLY
@@ -99,7 +99,7 @@ static const struct nxcon_operations_s g_nxtoolops =
*
****************************************************************************/
-static int nxtool_fill(FAR struct nxcon_state_s *priv,
+static int nxtool_fill(FAR struct nxterm_state_s *priv,
FAR const struct nxgl_rect_s *rect,
nxgl_mxpixel_t wcolor[CONFIG_NX_NPLANES])
{
@@ -124,7 +124,7 @@ static int nxtool_fill(FAR struct nxcon_state_s *priv,
****************************************************************************/
#ifndef CONFIG_NX_WRITEONLY
-static int nxtool_move(FAR struct nxcon_state_s *priv,
+static int nxtool_move(FAR struct nxterm_state_s *priv,
FAR const struct nxgl_rect_s *rect,
FAR const struct nxgl_point_s *offset)
{
@@ -155,7 +155,7 @@ static int nxtool_move(FAR struct nxcon_state_s *priv,
*
****************************************************************************/
-static int nxtool_bitmap(FAR struct nxcon_state_s *priv,
+static int nxtool_bitmap(FAR struct nxterm_state_s *priv,
FAR const struct nxgl_rect_s *dest,
FAR const void *src[CONFIG_NX_NPLANES],
FAR const struct nxgl_point_s *origin,
@@ -188,8 +188,8 @@ static int nxtool_bitmap(FAR struct nxcon_state_s *priv,
*
****************************************************************************/
-NXTERM nxtool_register(NXTKWINDOW hfwnd, FAR struct nxcon_window_s *wndo, int minor)
+NXTERM nxtool_register(NXTKWINDOW hfwnd, FAR struct nxterm_window_s *wndo, int minor)
{
- return nxcon_register((NXTERM)hfwnd, wndo, &g_nxtoolops, minor);
+ return nxterm_register((NXTERM)hfwnd, wndo, &g_nxtoolops, minor);
}