• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    公众号

C++ display_message函数代码示例

原作者: [db:作者] 来自: [db:来源] 收藏 邀请

本文整理汇总了C++中display_message函数的典型用法代码示例。如果您正苦于以下问题:C++ display_message函数的具体用法?C++ display_message怎么用?C++ display_message使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。



在下文中一共展示了display_message函数的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的C++代码示例。

示例1: Computed_field_register_types_compose

int Computed_field_register_types_compose(
	struct Computed_field_package *computed_field_package,
	struct Cmiss_region *root_region)
/*******************************************************************************
LAST MODIFIED : 24 August 2006

DESCRIPTION :
==============================================================================*/
{
	int return_code;
	Computed_field_compose_package
		*computed_field_compose_package =
		new Computed_field_compose_package;

	ENTER(Computed_field_register_types_compose);
	if (computed_field_package && root_region)
	{
		computed_field_compose_package->root_region = root_region;
		return_code = Computed_field_package_add_type(computed_field_package,
			computed_field_compose_type_string,
			define_Computed_field_type_compose,
			computed_field_compose_package);
	}
	else
	{
		display_message(ERROR_MESSAGE,
			"Computed_field_register_types_compose.  Invalid argument(s)");
		return_code = 0;
	}
	LEAVE;

	return (return_code);
} /* Computed_field_register_types_compose */
开发者ID:A1kmm,项目名称:libzinc,代码行数:33,代码来源:computed_field_compose_app.cpp


示例2: do_cmd_message_one

/*
 * Recall the most recent message
 */
void do_cmd_message_one(void)
{
	cptr msg = format("> %s", message_str(0));

	/* Recall one message XXX XXX XXX */
	display_message(0, 0, strlen(msg), message_color(0), msg);
}
开发者ID:jcubic,项目名称:ToME,代码行数:10,代码来源:cmd4.c


示例3: do_init

static int do_init(void)
{
    int i, openerr;
    char *env;
    char searchdir[256], fname[256];

    openerr = 0;

    /* Find base directory for database.  If set, use WNSEARCHDIR.
       If not set, check for WNHOME/dict, otherwise use DEFAULTPATH. */

    if ((env = getenv("WNSEARCHDIR")) != NULL)
	strcpy(searchdir, env);
    else if ((env = getenv("WNHOME")) != NULL)
	sprintf(searchdir, "%s%s", env, DICTDIR);
    else
	strcpy(searchdir, DEFAULTPATH);

    for (i = 1; i <= NUMPARTS; i++) {
	sprintf(fname, EXCFILE, searchdir, partnames[i]);
	if ((exc_fps[i] = fopen(fname, "r")) == NULL) {
	    sprintf(msgbuf,
		    "WordNet library error: Can't open exception file(%s)\n\n",
		    fname);
	    display_message(msgbuf);
	    openerr = -1;
	}
    }
    return(openerr);
}
开发者ID:Arnukk,项目名称:TDS,代码行数:30,代码来源:morph.c


示例4: Computed_field_register_types_format_output

int Computed_field_register_types_format_output(
	struct Computed_field_package *computed_field_package)
/*******************************************************************************
LAST MODIFIED : 25 August 2006

DESCRIPTION :
==============================================================================*/
{
	int return_code;

	ENTER(Computed_field_register_types_format_output);
	if (computed_field_package)
	{
		return_code = Computed_field_package_add_type(computed_field_package,
			computed_field_format_output_type_string,
			define_Computed_field_type_format_output,
			Computed_field_package_get_simple_package(computed_field_package));
	}
	else
	{
		display_message(ERROR_MESSAGE,
			"Computed_field_register_types_format_output.  Invalid argument(s)");
		return_code = 0;
	}
	LEAVE;

	return (return_code);
} /* Computed_field_register_types_format_output */
开发者ID:A1kmm,项目名称:libzinc,代码行数:28,代码来源:computed_field_format_output_app.cpp


示例5: get_selected_features

/*************************************************************************
 *
 *N  get_selected_features
 *
 *::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::
 *
 *   Purpose:
 *P
 *    This function gets the selection set for a given theme of the
 *    specified view, either by querying the table, or by reading a
 *    previously saved selection set file.
 *E
 *::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::
 *
 *   Parameters:
 *A
 *     view     <input>==(view_type *) view structure.
 *     themenum <input>==(int) theme number.
 *     library  <input>==(library-type) VPF library structure.
 *     return  <output>==(set_type) set of selected features.
 *E
 *::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::
 *
 *   History:
 *H
 *    Barry Michaels   May 1991                           DOS Turbo C
 *E
 *************************************************************************/
set_type get_selected_features( view_type *view, int themenum,
				library_type library )
{
   set_type selset;
   vpf_table_type ft;
   register int i;

   /* Read a selection set, if present */
   if (strcmp(view->name,"") != 0) {
      selset = read_selected_features( view, themenum );
      if (selset.size > 0) return selset;
   }

   /* No selection set... */

   /* Find the feature class for the theme */
   for (i=0;i<library.nfc;i++)
      if (strcasecmp(library.fc[i].name,view->theme[themenum].fc)==0) break;
   if (i>=library.nfc) {
      display_message("Invalid theme in view");
      return selset;
   }

   /* Query the feature table */
   ft = vpf_open_table( library.fc[i].table, disk, "rb", NULL );
   selset = query_table( view->theme[themenum].expression, ft );
   vpf_close_table( &ft );

   /* Save the selection set so we don't have to query again */
   if (strcmp(view->name,"") != 0) {
      save_selected_features( view, themenum, selset );
   }

   return selset;
}
开发者ID:vapd-radi,项目名称:rspf_v2.0,代码行数:63,代码来源:vpfselec.c


示例6: playlist_loadlist_mainload

unsigned int playlist_loadlist_mainload(struct playlist_side_info *psi,char *listname,unsigned int loadtype,char *filtermask)
{
 struct listhandler_s *listhand;
 struct playlist_entry_info *laste;
 char loaddir[MAX_PATHNAMELEN];

 display_clear_timed_message();

 display_message(0,0,"Loading list (press ESC to stop) ...");

 laste=psi->lastentry;

 if(loadtype&PLL_STDIN){
  load_m3u(psi,stdin,mpxplay_playlist_startdir(),filtermask);
 }else{
  listhand=select_listhandler_by_ext(listname);
  if(listhand){
   pds_getpath_from_fullname(loaddir,listname);
   listhand->loadlist(psi,listname,loaddir,filtermask);
  }
 }

 if(psi->lastentry>=psi->firstentry)
  playlist_enable_side(psi);
 else
  playlist_disable_side_full(psi);

 clear_message();

 if(psi->lastentry>laste)
  return 1;
 return 0;
}
开发者ID:en-vorobiov,项目名称:mpxplay,代码行数:33,代码来源:LOADLIST.C


示例7: print_skills

/*
 * Draw the skill tree
 */
void print_skills(s32b **table, s32b max, s32b sel, s32b start)
{
	s32b i, j;
	s32b wid, hgt;
	cptr keys;

	Term_clear();
	Term_get_size(&wid, &hgt);

	c_prt(TERM_WHITE, format("%s Skills Screen", game_module), 0, 28);
	keys = format("#BEnter#W to develop a branch, #Bup#W/#Bdown#W to move, #Bright#W/#Bleft#W to modify, #B?#W for help");
	display_message(0, 1, strlen(keys), TERM_WHITE, keys);
	c_prt((p_ptr->skill_points) ? TERM_L_BLUE : TERM_L_RED,
	      format("Skill points left: %d", p_ptr->skill_points), 2, 0);
	print_desc_aux(s_info[table[sel][0]].desc, 3, 0);

	for (j = start; j < start + (hgt - 7); j++)
	{
		byte color = TERM_WHITE;
		char deb = ' ', end = ' ';

		if (j >= max) break;

		i = table[j][0];

		if (get_skill(i) == 0)
		{
			if (s_info[i].mod == 0) color = TERM_L_DARK;
			else color = TERM_ORANGE;
		}
		else if (get_skill_raw(i) == SKILL_MAX) color = TERM_L_BLUE;
		if (s_info[i].hidden) color = TERM_L_RED;
		if (j == sel)
		{
			color = TERM_L_GREEN;
			deb = '[';
			end = ']';
		}
		if (!has_child(i))
		{
			c_prt(color, format("%c.%c%s", deb, end, s_info[i].name),
			      j + 7 - start, table[j][1] * 4);
		}
		else if (s_info[i].dev)
		{
			c_prt(color, format("%c-%c%s", deb, end, s_info[i].name),
			      j + 7 - start, table[j][1] * 4);
		}
		else
		{
			c_prt(color, format("%c+%c%s", deb, end, s_info[i].name),
				j + 7 - start, table[j][1] * 4);
		}
		c_prt(color,
			format("%c%02ld.%03ld [%01d.%03d]", (get_skill_raw(i) < 0) ? '-' : ' ',
				abs(get_skill_raw(i)) / SKILL_STEP, abs(get_skill_raw(i)) % SKILL_STEP,
				s_info[i].mod / 1000, s_info[i].mod % 1000),
			j + 7 - start, 60);
	}
}
开发者ID:jcubic,项目名称:ToME,代码行数:63,代码来源:skills.c


示例8: display_usertype

int display_usertype(char *buf) {
	char *orig_buf=buf;
	uint32_t size = *((uint32_t*)buf);
	size = ntohl(size);
	buf+=4;
	if(strcmp(buf, "NetworkId")==0 || strcmp(buf, "IdentityId")==0 || strcmp(buf, "BufferId")==0 || strcmp(buf, "MsgId")==0) {
		printf("%s(", buf);
		buf+=strlen(buf)+1;
		buf+=display_int(buf, 0);
		printf(")");
	} else if(strcmp(buf, "Identity")==0) {
		buf+=strlen(buf)+1;
		buf+=display_map(buf);
	} else if(strcmp(buf, "BufferInfo")==0) {
		buf+=strlen(buf)+1;
		buf+=display_bufferinfo(buf);
	} else if(strcmp(buf, "Message")==0) {
		buf+=strlen(buf)+1;
		buf+=display_message(buf);
	} else if(strcmp(buf, "Network::Server")==0) {
		buf+=strlen(buf)+1;
		buf+=display_map(buf);
	} else {
		printf(" Usertype('%s') \n", buf);
		printf("Unsupported.\n");
		exit(0);
	}
	return buf-orig_buf;
}
开发者ID:fuzzball81,项目名称:QuasselC,代码行数:29,代码来源:display.c


示例9: Option_table_add_set_Cmiss_region_path

int Option_table_add_set_Cmiss_region_path(struct Option_table *option_table,
	const char *entry_string, struct Cmiss_region *root_region, char **path_address)
/*******************************************************************************
LAST MODIFIED : 13 March 2003

DESCRIPTION :
Adds an entry to the <option_table> with name <entry_name> that returns a
region path in <path_address> relative to the <root_region>.
==============================================================================*/
{
	int return_code = 0;

	ENTER(Option_table_add_set_Cmiss_region_path);
	if (option_table && entry_string && root_region && path_address)
	{
		return_code = Option_table_add_entry(option_table, entry_string,
			(void *)path_address, (void *)root_region,
			set_Cmiss_region_path);
	}
	else
	{
		display_message(ERROR_MESSAGE,
			"Option_table_add_set_Cmiss_region_path.  Invalid argument(s)");
	}
	LEAVE;

	return (return_code);
} /* Option_table_add_set_Cmiss_region_path */
开发者ID:A1kmm,项目名称:libzinc,代码行数:28,代码来源:cmiss_region_app.cpp


示例10: Option_table_add_region_path_and_or_field_name_entry

int Option_table_add_region_path_and_or_field_name_entry(
	struct Option_table *option_table, char *token,
	struct Cmiss_region_path_and_name *region_path_and_name,
	struct Cmiss_region *root_region)
{
	int return_code;

	ENTER(Option_table_add_region_path_and_or_field_name_entry);
	if (option_table && region_path_and_name && root_region)
	{
		return_code = Option_table_add_entry(option_table, token,
			(void *)region_path_and_name, (void *)root_region,
			set_region_path_and_or_field_name);
	}
	else
	{
		display_message(ERROR_MESSAGE,
			"Option_table_add_region_path_and_or_field_name_entry.  "
			"Invalid argument(s)");
		return_code=0;
	}
	LEAVE;

	return (return_code);
} /* Option_table_add_region_path_and_or_field_name_entry */
开发者ID:A1kmm,项目名称:libzinc,代码行数:25,代码来源:cmiss_region_app.cpp


示例11: Computed_field_register_types_gradient_magnitude_recursive_gaussian_image_filter

int Computed_field_register_types_gradient_magnitude_recursive_gaussian_image_filter(
	struct Computed_field_package *computed_field_package)
/*******************************************************************************
LAST MODIFIED : 18 October 2006

DESCRIPTION :
==============================================================================*/
{
	int return_code;

	ENTER(Computed_field_register_types_gradient_magnitude_recursive_gaussian_image_filter);
	if (computed_field_package)
	{
		return_code = Computed_field_package_add_type(computed_field_package,
			computed_field_gradient_magnitude_recursive_gaussian_image_filter_type_string,
			define_Computed_field_type_gradient_magnitude_recursive_gaussian_image_filter,
			Computed_field_package_get_simple_package(computed_field_package));
	}
	else
	{
		display_message(ERROR_MESSAGE,
			"Computed_field_register_types_gradient_magnitude_recursive_gaussian_image_filter.  Invalid argument(s)");
		return_code = 0;
	}
	LEAVE;

	return (return_code);
} /* Computed_field_register_types_gradient_magnitude_recursive_gaussian_image_filter */
开发者ID:alan-wu,项目名称:cmgui,代码行数:28,代码来源:computed_field_gradient_magnitude_recursive_gaussian_image_filter_app.cpp


示例12: poll_mouse

int poll_mouse()
{
   static int _x = -1, _y = -1;
   int ret;
   int x, y;
   __dpmi_regs reg;

   if (!mouse_state)
      return FALSE;

   reg.x.ax = 3;
   __dpmi_int(0x33, &reg);

   m_b = reg.x.bx;
   x = reg.x.cx / 8;
   y = reg.x.dx / 8;

   ret = ((x != _x) || (y != _y) || (m_b));

   if (recording_macro()) {
      if (ret) {
	 strcpy(message, "Can't record mouse actions in a macro");
	 display_message(0);
      }
      m_b = 0;
      _x = x;
      _y = y;
      return FALSE;
   }

   m_x = _x = x;
   m_y = _y = y;
   return ret;
}
开发者ID:OrangeTide,项目名称:fed,代码行数:34,代码来源:iodjgpp.c


示例13: Computed_field_get_type_if

int Computed_field_get_type_if(struct Computed_field *field,
	struct Computed_field **source_field_one,
	struct Computed_field **source_field_two,
	struct Computed_field **source_field_three)
/*******************************************************************************
LAST MODIFIED : 27 July 2007

DESCRIPTION :
If the field is of type COMPUTED_FIELD_IF, the 
<source_field_one>, <source_field_two> and <source_field_three> used by it
are returned.
==============================================================================*/
{
	int return_code;

	ENTER(Computed_field_get_type_if);
	if (field&&(dynamic_cast<Computed_field_if*>(field->core)))
	{
		*source_field_one = field->source_fields[0];
		*source_field_two = field->source_fields[1];
		*source_field_three = field->source_fields[2];
		return_code=1;
	}
	else
	{
		display_message(ERROR_MESSAGE,
			"Computed_field_get_type_if.  Invalid argument(s)");
		return_code = 0;
	}
	LEAVE;

	return (return_code);
} /* Computed_field_get_type_if */
开发者ID:A1kmm,项目名称:libzinc,代码行数:33,代码来源:computed_field_conditional.cpp


示例14: Computed_field_register_types_canny_edge_detection_image_filter

int Computed_field_register_types_canny_edge_detection_image_filter(
	struct Computed_field_package *computed_field_package)
/*******************************************************************************
LAST MODIFIED : 30 August 2006

DESCRIPTION :
==============================================================================*/
{
	int return_code;

	ENTER(Computed_field_register_types_canny_edge_detection_image_filter);
	if (computed_field_package)
	{
		return_code = Computed_field_package_add_type(computed_field_package,
			computed_field_canny_edge_detection_image_filter_type_string,
			define_Computed_field_type_canny_edge_detection_image_filter,
			Computed_field_package_get_simple_package(computed_field_package));
	}
	else
	{
		display_message(ERROR_MESSAGE,
			"Computed_field_register_types_canny_edge_detection_image_filter.  Invalid argument(s)");
		return_code = 0;
	}
	LEAVE;

	return (return_code);
} /* Computed_field_register_types_canny_edge_detection_image_filter */
开发者ID:alan-wu,项目名称:cmgui,代码行数:28,代码来源:computed_field_canny_edge_detection_filter_app.cpp


示例15: Element_point_tool_reset

static void Element_point_tool_reset(void *element_point_tool_void)
/*******************************************************************************
LAST MODIFIED : 25 February 2008

DESCRIPTION :
Resets current edit. Called on button release or when tool deactivated.
==============================================================================*/
{
	struct Element_point_tool *element_point_tool;

	ENTER(Element_point_tool_reset);
	element_point_tool = (struct Element_point_tool *)element_point_tool_void;
	if (element_point_tool != 0)
	{
		REACCESS(Element_point_ranges)(
			&(element_point_tool->last_picked_element_point),
			(struct Element_point_ranges *)NULL);
		REACCESS(Interaction_volume)(
			&(element_point_tool->last_interaction_volume),
			(struct Interaction_volume *)NULL);
	}
	else
	{
		display_message(ERROR_MESSAGE,"Node_tool_reset.  Invalid argument(s)");
	}
	LEAVE;
} /* Element_point_tool_reset */
开发者ID:alan-wu,项目名称:cmgui,代码行数:27,代码来源:element_point_tool.cpp


示例16: PROTOTYPE_MANAGER_COPY_WITH_IDENTIFIER_FUNCTION

PROTOTYPE_MANAGER_COPY_WITH_IDENTIFIER_FUNCTION(Cmiss_graphics_font,name)
{
	char *name;
	int return_code;

	ENTER(MANAGER_COPY_WITH_IDENTIFIER(Cmiss_graphics_font,name));
	/* check arguments */
	if (source&&destination)
	{
		if (source->name)
		{
			if (ALLOCATE(name,char,strlen(source->name)+1))
			{
				strcpy(name,source->name);
				return_code=1;
			}
			else
			{
				display_message(ERROR_MESSAGE,
"MANAGER_COPY_WITH_IDENTIFIER(Cmiss_graphics_font,name).  Insufficient memory");
				return_code=0;
			}
		}
		else
		{
开发者ID:A1kmm,项目名称:libzinc,代码行数:25,代码来源:font.cpp


示例17: Computed_field_register_types_fibres

int Computed_field_register_types_fibres(
	struct Computed_field_package *computed_field_package)
/*******************************************************************************
LAST MODIFIED : 24 August 2006

DESCRIPTION :
==============================================================================*/
{
	int return_code;
	Computed_field_fibres_package
		*computed_field_fibres_package =
		new Computed_field_fibres_package;

	ENTER(Computed_field_register_types_fibres);
	if (computed_field_package)
	{
		return_code = Computed_field_package_add_type(computed_field_package,
			computed_field_fibre_axes_type_string,
			define_Computed_field_type_fibre_axes,
			computed_field_fibres_package);
	}
	else
	{
		display_message(ERROR_MESSAGE,
			"Computed_field_register_types_fibres.  Invalid argument(s)");
		return_code=0;
	}
	LEAVE;

	return (return_code);
} /* Computed_field_register_types_fibres */
开发者ID:A1kmm,项目名称:libzinc,代码行数:31,代码来源:computed_field_fibres_app.cpp


示例18: line_segment_distance

double line_segment_distance(double k,double *p1,double *p2,double *p,double q1,
	double q2)
/*******************************************************************************
LAST MODIFIED : 30 August 1996

DESCRIPTION :
Calculates distance potential at a point p from a line segment p1-p2 of charge
(q1,q2)
==============================================================================*/
{
	double a = 0.0,a1,b[3],dist,r[3],return_code,v[3];
	int i;

	ENTER(line_segment_distance);
	/* default return value */
	return_code=0.0;
	/* checking arguments */
	if (p1&&p2&&p)
	{
		for (i=0;i<3;i++)
		{
			b[i]=p[i]-p1[i];
			v[i]=p2[i]-p1[i];
		}
		if (0!=(a1=dot_product3(v,v)))
		{
			a=dot_product3(b,v)/a1;
		}
		if ((a>=0.0)&&(a<=1.0))
		{
			/* point does not extend further than line segment */
			for(i=0;i<3;i++)
			{
				r[i]=b[i]-a*v[i];
			}
			if ((dist=norm3(r)) != 0)
			{
				return_code=k/(dist*dist)*(q1+a*(q2-q1));
			}
			else
			{
				return_code=TEXTURE_LINE_INFINITY;
			}
		}
		else
		{
			return_code=0.0;
		}
	}
	else
	{
		display_message(ERROR_MESSAGE,
			"line_segment_distance.  Invalid argument(s)");
		return_code=0.0;
	}
	LEAVE;

	return (return_code);
} /* line_segment_distance */
开发者ID:A1kmm,项目名称:libzinc,代码行数:59,代码来源:texture_line.cpp


示例19: display_message

void TMesh::end_progress()
{
 if (quiet) return;
 if (display_message != NULL) 
  display_message("\n", DISPMSG_ACTION_PUTNEWLINE);
 else
  printf("\n");
}
开发者ID:MarcoAttene,项目名称:MeshFix-V2.0,代码行数:8,代码来源:tmesh.cpp


示例20: bell_message

/**
 * Flush the output before displaying for emphasis
 */
void bell_message(game_event_type unused, game_event_data *data, void *user)
{
    /* Flush the output */
    Term_fresh();

    display_message(unused, data, user);
    player->upkeep->redraw |= PR_MESSAGE;
}
开发者ID:pete-mack,项目名称:angband,代码行数:11,代码来源:ui-input.c



注:本文中的display_message函数示例由纯净天空整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。


鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
C++ display_string函数代码示例发布时间:2022-05-30
下一篇:
C++ display_menu函数代码示例发布时间:2022-05-30
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap