apps/graphics/nxglyphs: Fixes for more changes to cursor structures.

This commit is contained in:
Gregory Nutt 2019-04-07 17:41:45 -06:00
parent 7a7e86ac6c
commit aec954b9ec
7 changed files with 57 additions and 36 deletions

View File

@ -2,8 +2,8 @@
#include <stdint.h>
#include <nuttx/video/rgbcolors.h
#include <nuttx/video/cursor.h
#include <nuttx/video/rgbcolors.h>
#include <nuttx/nx/nxcursor.h>
#if CONFIG_NXWIDGETS_BPP == 8
# define FGCOLOR1 RGB8WHITE
@ -55,10 +55,13 @@ static const uint8_t g_arrow1Image[] =
0x00 0x00 0x00 0x00 0x00 0x00 0x80 0x00 /* Row 29 */
}
const struct cursor_image_s g_arrow1Cursor
const struct nx_cursorimage_s g_arrow1Cursor =
{
.width = 30
.height = 30
.size =
{
.w = 30
.h = 30
},
.color1 =
{
FGCOLOR1

View File

@ -2,8 +2,8 @@
#include <stdint.h>
#include <nuttx/video/rgbcolors.h
#include <nuttx/video/cursor.h
#include <nuttx/video/rgbcolors.h>
#include <nuttx/nx/nxcursor.h>
#if CONFIG_NXWIDGETS_BPP == 8
# define FGCOLOR1 RGB8WHITE
@ -55,10 +55,13 @@ static const uint8_t g_arrow2Image[] =
0x00 0x00 0x00 0xe0 0x00 0x00 0x00 0x00 /* Row 29 */
}
const struct cursor_image_s g_arrow2Cursor
const struct nx_cursorimage_s g_arrow2Cursor =
{
.width = 30
.height = 30
.size =
{
.w = 30
.h = 30
},
.color1 =
{
FGCOLOR1

View File

@ -2,8 +2,8 @@
#include <stdint.h>
#include <nuttx/video/rgbcolors.h
#include <nuttx/video/cursor.h
#include <nuttx/video/rgbcolors.h>
#include <nuttx/nx/nxcursor.h>
#if CONFIG_NXWIDGETS_BPP == 8
# define FGCOLOR1 RGB8WHITE
@ -55,10 +55,13 @@ static const uint8_t g_grabImage[] =
0x00 0x2a 0xaa 0xaa 0xaa 0xb0 0x00 /* Row 29 */
}
const struct cursor_image_s g_grabCursor
const struct nx_cursorimage_s g_grabCursor =
{
.width = 25
.height = 30
.size =
{
.w = 25
.h = 30
},
.color1 =
{
FGCOLOR1

View File

@ -2,8 +2,8 @@
#include <stdint.h>
#include <nuttx/video/rgbcolors.h
#include <nuttx/video/cursor.h
#include <nuttx/video/rgbcolors.h>
#include <nuttx/nx/nxcursor.h>
#if CONFIG_NXWIDGETS_BPP == 8
# define FGCOLOR1 RGB8WHITE
@ -55,10 +55,13 @@ static const uint8_t g_waitImage[] =
0xaa 0xaa 0xaa 0xaa 0xaa 0xa8 /* Row 29 */
}
const struct cursor_image_s g_waitCursor
const struct nx_cursorimage_s g_waitCursor =
{
.width = 23
.height = 30
.size =
{
.w = 23
.h = 30
},
.color1 =
{
FGCOLOR1

View File

@ -2,8 +2,8 @@
#include <stdint.h>
#include <nuttx/video/rgbcolors.h
#include <nuttx/video/cursor.h
#include <nuttx/video/rgbcolors.h>
#include <nuttx/nx/nxcursor.h>
#if CONFIG_NXWIDGETS_BPP == 8
# define FGCOLOR1 RGB8WHITE
@ -55,10 +55,13 @@ static const uint8_t g_zoomInImage[] =
0x00 0x00 0x00 0x00 0x00 0x00 0x2a 0x80 /* Row 29 */
}
const struct cursor_image_s g_zoomInCursor
const struct nx_cursorimage_s g_zoomInCursor =
{
.width = 30
.height = 30
.size =
{
.w = 30
.h = 30
},
.color1 =
{
FGCOLOR1

View File

@ -2,8 +2,8 @@
#include <stdint.h>
#include <nuttx/video/rgbcolors.h
#include <nuttx/video/cursor.h
#include <nuttx/video/rgbcolors.h>
#include <nuttx/nx/nxcursor.h>
#if CONFIG_NXWIDGETS_BPP == 8
# define FGCOLOR1 RGB8WHITE
@ -55,10 +55,13 @@ static const uint8_t g_zoomOutImage[] =
0x00 0x00 0x00 0x00 0x00 0x00 0x3a 0x80 /* Row 29 */
}
const struct cursor_image_s g_zoomOutCursor
const struct nx_cursorimage_s g_zoomOutCursor =
{
.width = 30
.height = 30
.size =
{
.w = 30
.h = 30
},
.color1 =
{
FGCOLOR1

View File

@ -104,8 +104,8 @@ int main(int argc, char **argv, char **envp)
printf("#include <nuttx/config.h>\n\n");
printf("#include <stdint.h>\n\n");
printf("#include <nuttx/video/rgbcolors.h\n");
printf("#include <nuttx/video/cursor.h\n\n");
printf("#include <nuttx/video/rgbcolors.h>\n");
printf("#include <nuttx/nx/nxcursor.h>\n\n");
printf("#if CONFIG_NXWIDGETS_BPP == 8\n");
printf("# define FGCOLOR1 RGB8WHITE\n");
@ -178,10 +178,13 @@ int main(int argc, char **argv, char **envp)
}
printf("}\n\n");
printf("const struct cursor_image_s g_cursor\n");
printf("const struct nx_cursorimage_s g_cursor =\n");
printf("{\n");
printf(" .width = %u\n", gimp_image.width);
printf(" .height = %u\n", gimp_image.height);
printf(" .size =\n");
printf(" {\n");
printf(" .w = %u\n", gimp_image.width);
printf(" .h = %u\n", gimp_image.height);
printf(" },\n");
printf(" .color1 =\n");
printf(" {\n");
printf(" FGCOLOR1\n");
@ -194,7 +197,7 @@ int main(int argc, char **argv, char **envp)
printf(" {\n");
printf(" FGCOLOR3\n");
printf(" },\n");
printf(" .image = g_cursorImage,\n");
printf(" .image = g_cursorImage\n");
printf("};\n\n");
return 0;