Telerik 控件事例(鼠标拖动行,拖动列,设置行对齐,行宽,是否显示)
People.cs
using System;
using System.Collections.Generic;
using System.Data;
using System.Linq;
using System.Text;
namespace RadGridViewControl
{
public class People
{
public Guid Id { get; set; }
public string FirstName { get; set; }
public string LastName { get; set; }
public string Sex { get; set; }
public string Tel { get; set; }
public string Address { get; set; }
public DateTime BirthDay { get; set; }
public string Note { get; set; }
public string Like { get; set; }
public string Work { get; set; }
public List<People> Init()
{
var list = new List<People>();
for (int i = 0; i < 20; i++)
{
var people = new People
{
Id = Guid.NewGuid(),
FirstName = "王",
LastName = "友",
Sex = "男",
Tel = "15209893158",
Address = "安徽省合肥市高新区",
BirthDay = DateTime.Now,
Note = "大家好我是王友",
Like = "我喜欢编程",
Work = "其实我是一名程序员"
};
list.Add(people);
}
return list;
}
public DataTable Data()
{
DataTable dt = new DataTable();
dt.Columns.Add("Id");
dt.Columns.Add("FirstName");
dt.Columns.Add("LastName");
dt.Columns.Add("Sex");
dt.Columns.Add("Tel");
dt.Columns.Add("Address");
dt.Columns.Add("BirthDay");
dt.Columns.Add("Note");
dt.Columns.Add("Like");
dt.Columns.Add("Work");
for (int i = 0; i < 20; i++)
{
DataRow dr = dt.NewRow();
dr["Id"] = i;
dr["FirstName"] = "王";
dr["LastName"] = "友"+i;
dr["Sex"] = "男";
dr["Tel"] = "1520989315"+i;
dr["Address"] = "安徽省合肥市高新区";
dr["BirthDay"] = DateTime.Now.AddDays(i);
dr["Note"] = "大家好我是王友"+i;
dr["Like"] = "我喜欢编程";
dr["Work"] = "其实我是一名程序员";
dt.Rows.Add(dr);
}
return dt;
}
}
}
RadGridViewUserControl.cs
using System;
using System.Collections.Generic;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Windows.Forms;
using Telerik.WinControls;
using Telerik.WinControls.Data;
using Telerik.WinControls.UI;
using Telerik.WinControls.UI.Localization;
using System.Xml;
namespace RadGridViewControl
{
public partial class RadGridViewUserControl : UserControl
{
/// <summary>
/// 数据源
/// </summary>
public DataTable Data;
private DataTable DataTableList { get; set; }
/// <summary>
/// 构造函数
/// </summary>
public RadGridViewUserControl()
{
InitializeComponent();
}
/// <summary>
/// 构造函数2
/// </summary>
/// <param name="xmlName">xml文件路径+名称</param>
public RadGridViewUserControl(string xmlName)
{
InitializeComponent();
_xmlName = xmlName;
}
#region 定义的接口
/// <summary>
/// 定义xml文件
/// </summary>
public string Xml { get; set; }
/// <summary>
/// xml文件路径+名称
/// </summary>
public List<SelectColumn> ReadXml()
{
List<SelectColumn> selectColumns = new List<SelectColumn>();
XmlDataDocument doc = new XmlDataDocument();
try
{
doc.Load(Xml);
XmlNode dataTableSettingsNode = doc.SelectSingleNode("DataTable_Settings");//根结点
XmlNode dataCellsNode = dataTableSettingsNode.SelectSingleNode("data_cells");
if (null == dataCellsNode) return null;
XmlNodeList dataCellNode = dataCellsNode.SelectNodes("data_cell");
foreach (XmlNode node in dataCellNode)
{
SelectColumn selectColumn = new SelectColumn();
selectColumn.ColumnName = node.SelectSingleNode("cell_name").InnerText;
selectColumn.ChineseColumnName = node.SelectSingleNode("chinese_name").InnerText;
selectColumn.IsVisible = bool.Parse(node.SelectSingleNode("visible").InnerText);
selectColumn.Width = int.Parse(node.SelectSingleNode("width").InnerText);
selectColumn.Align = int.Parse(node.SelectSingleNode("align").InnerText);
selectColumn.ShowIndex = int.Parse(node.SelectSingleNode("show_index").InnerText);
selectColumns.Add(selectColumn);
}
}
catch (Exception ex)
{
}
return selectColumns;
}
/// <summary>
/// 获取选中的数据
/// </summary>
/// <param name="indexList">获取选中的行</param>
/// <returns></returns>
public List<GridViewRowInfo> GetSelData(ref List<string> indexList)
{
var listRows = new List<GridViewRowInfo>();
foreach (var row in rgv_Control.Rows)
{
var value = row.Cells["ChkSelect"].Value.ToString();
var index = row.Cells["Num"].Value.ToString();
if (!value.Equals("True")) continue;
indexList.Add(index);
listRows.Add(row);
}
return listRows;
}
/// <summary>
/// 初始化用户控件
/// </summary>
public void RadGridViewControl_Init(DataTable dataTable)
{
DataTableList = dataTable;
SetRadGridViewProperty();
AddTwoColumn();
BindRadGridViewControl(dataTable);
WrapText();
SetColumnReadOnly();
RadGridLocalizationProvider.CurrentProvider = new ChineseRadGridLocalizationProvider();
rgv_Control.Rows.CollectionChanged += Rows_CollectionChanged;
SetRadGridViewForXml();
}
/// <summary>
/// 通过XML设置RadGridView控件
/// </summary>
private void SetRadGridViewForXml()
{
var list = ReadXml();
SetColumnWidth(list);
ConvertColumnNameToChinese(list);
ShowColumnName(list);
SetColumnAlign(list);
ShowColumnIndex(list);
}
/// <summary>
/// 获取拖动后的数据记录
/// </summary>
/// <returns></returns>
public DataTable GetAllGridViewData()
{
var dt = new DataTable();
foreach (var column in rgv_Control.Columns)
{
var dataColumn = new DataColumn
{
ColumnName = column.Name
};
if (!(column.Name.Equals("Num") || column.Name.Equals("ChkSelect")))
{
dt.Columns.Add(dataColumn);
}
}
foreach (GridViewRowInfo t in rgv_Control.Rows)
{
var datarow = dt.NewRow();
for (var j = 0; j < dt.Columns.Count; j++)
{
datarow[dt.Columns[j].ColumnName] = t.Cells[dt.Columns[j].ColumnName].Value;
}
dt.Rows.Add(datarow);
}
return dt;
}
/// <summary>
/// 获取按钮的句柄
/// </summary>
/// <returns></returns>
public IntPtr getBtHandler()
{
return this.btn_Select.Handle;
}
#endregion
/// <summary>
/// 如果像这样写分组的话那我要累死
/// </summary>
public bool EnableGrouping
{
get { return rgv_Control.EnableGrouping; }
set { rgv_Control.EnableGrouping = value; }
}
/// <summary>
/// 设置RadGridView控件属性
/// </summary>
private void SetRadGridViewProperty()
{
rgv_Control.EnableGrouping = false;//去掉分组
rgv_Control.AllowDrop = true;
rgv_Control.AllowRowReorder = true;
rgv_Control.AddNewRowPosition = SystemRowPosition.Bottom;
rgv_Control.ShowRowHeaderColumn = false;
rgv_Control.AutoSizeRows = true;
rgv_Control.AllowAddNewRow = false;
}
/// <summary>
/// 添加两个特殊列
/// </summary>
private void AddTwoColumn()
{
var numColumn = new GridViewDecimalColumn(typeof(int), "Num", "Num")
{
HeaderText = "序 号",
Width = 50,
ReadOnly = true,
IsPinned = true
};
rgv_Control.Columns.Add(numColumn);
var chkColumn = new GridViewCheckBoxColumn("ChkSelect", "ChkSelect")
{
HeaderText = "选 择",
Width = 50,
IsPinned = true
};
rgv_Control.Columns.Add(chkColumn);
}
/// <summary>
/// 设置表格只读
/// </summary>
private void SetColumnReadOnly()
{
for (var i = 0; i < rgv_Control.Columns.Count; i++)
{
rgv_Control.Columns[i].ReadOnly = true;
}
rgv_Control.Columns["ChkSelect"].ReadOnly = false;
}
/// <summary>
/// 显示列顺序
/// </summary>
/// <param name="list"></param>
private void ShowColumnIndex(IEnumerable<SelectColumn> list)
{
foreach (var i in list)
{
SelectColumn selectColumn = i;
foreach (var column in rgv_Control.Columns.Where(column => !column.Name.Equals("Num") && !column.Name.Equals("ChkSelect")).Where(column => selectColumn.ColumnName.Equals(column.Name)))
{
var oldIndex = column.Index;
var newIndex = i.ShowIndex;
if (oldIndex > newIndex)
{
rgv_Control.Columns.Move(oldIndex, newIndex);
rgv_Control.Columns.Move(newIndex + 1, oldIndex);
}
else if (oldIndex < newIndex)
{
rgv_Control.Columns.Move(oldIndex, newIndex);
rgv_Control.Columns.Move(newIndex - 1, oldIndex);
}
break;
}
}
}
/// <summary>
/// 设置列宽度
/// </summary>
private void SetColumnWidth(IEnumerable<SelectColumn> list)
{
foreach (var i in list)
{
rgv_Control.Columns[i.ColumnName].Width = i.Width;
}
}
/// <summary>
/// 将列名转化成中文
/// </summary>
public void ConvertColumnNameToChinese(List<SelectColumn> list)
{
foreach (var i in list)
{
rgv_Control.Columns[i.ColumnName].HeaderText = i.ChineseColumnName;
}
}
/// <summary>
/// Data中,是否显示列名称
/// </summary>
public void ShowColumnName(List<SelectColumn> list)
{
foreach (var i in list)
{
rgv_Control.Columns[i.ColumnName].IsVisible = i.IsVisible;
}
}
/// <summary>
/// 设置列对齐
/// </summary>
public void SetColumnAlign(List<SelectColumn> list)
{
foreach (var i in list)
{
switch (i.Align)
{
case 0:
rgv_Control.Columns[i.ColumnName].TextAlignment = ContentAlignment.MiddleCenter;
break;
case 1:
rgv_Control.Columns[i.ColumnName].TextAlignment = ContentAlignment.MiddleLeft;
break;
case 3:
rgv_Control.Columns[i.ColumnName].TextAlignment = ContentAlignment.MiddleRight;
break;
default:
break;
}
}
}
/// <summary>
/// 点击列选择按钮
/// </summary>
/// <param name="sender"></param>
/// <param name="e"></param>
private void btn_Select_Click(object sender, EventArgs e)
{
var selectColumnForm = new SelectColumnForm(Xml);
selectColumnForm.ShowDialog();
if (selectColumnForm.DialogResult == DialogResult.OK)
{
SetRadGridViewForXml();
}
}
/// <summary>
/// 设置右键菜单
/// </summary>
/// <param name="sender"></param>
/// <param name="e"></param>
private void rgv_Control_ContextMenuOpening(object sender, Telerik.WinControls.UI.ContextMenuOpeningEventArgs e)
{
for (var i = 0; i < e.ContextMenu.Items.Count; i++)
{
var contextMenuText = e.ContextMenu.Items[i].Text;
switch (contextMenuText)
{
case "条件格式":
e.ContextMenu.Items[i].Visibility = ElementVisibility.Collapsed;
e.ContextMenu.Items[i + 1].Visibility = ElementVisibility.Collapsed;
break;
case "隐 藏":
e.ContextMenu.Items[i].Visibility = ElementVisibility.Collapsed;
break;
case "锁定状态":
e.ContextMenu.Items[i].Visibility = ElementVisibility.Collapsed;
break;
case "自适应列宽":
e.ContextMenu.Items[i].Visibility = ElementVisibility.Collapsed;
break;
case "列选择":
e.ContextMenu.Items[i].Visibility = ElementVisibility.Collapsed;
break;
}
}
}
/// <summary>
/// 设置换行
/// </summary>
public void WrapText()
{
foreach (var obj in rgv_Control.Columns)
{
obj.WrapText = true;
}
}
/// <summary>
/// RadGridView控件绑定数据
/// </summary>
/// <param name="dt"></param>
public void BindRadGridViewControl(DataTable dt)
{
var num = 0;
foreach (var newColumn in from object column in dt.Columns select new GridViewTextBoxColumn(column.ToString(), column.ToString()))
{
rgv_Control.Columns.Add(newColumn);
}
for (var i = 0; i < dt.Rows.Count; i++)
{
var cellcount = 0;
var listRow = new object[dt.Rows.Count + 2];
listRow[cellcount++] = ++num;
listRow[cellcount++] = false;
for (var j = 0; j < dt.Columns.Count; j++)
{
listRow[cellcount++] = dt.Rows[i][j];
}
rgv_Control.Rows.Add(listRow);
}
}
/// <summary>
///
/// </summary>
/// <param name="sender"></param>
/// <param name="e"></param>
private void Rows_CollectionChanged(object sender, NotifyCollectionChangedEventArgs e)
{
if (e.Action != NotifyCollectionChangedAction.Move) return;
for (var i = 0; i < rgv_Control.Rows.Count; i++)
{
rgv_Control.Rows[i].Cells["Num"].Value = i + 1;
}
}
/// <summary>
/// 测试数据1
/// </summary>
/// <param name="sender"></param>
/// <param name="e"></param>
private void btn_Data_Click(object sender, EventArgs e)
{
var rowIndexList = new List<string>();
var rows = GetSelData(ref rowIndexList);//测试GetSelData方法
}
/// <summary>
/// 测试数据2
/// </summary>
/// <param name="sender"></param>
/// <param name="e"></param>
private void btn_GetAllData_Click(object sender, EventArgs e)
{
var dt = GetAllGridViewData();//测试GetAllGridViewData方法
}
}
}
SelectColumnForm.cs
using System;
using System.Collections.Generic;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Windows.Forms;
using Telerik.WinControls.Data;
using Telerik.WinControls.UI;
using System.Xml;
namespace RadGridViewControl
{
public partial class SelectColumnForm : Form
{
/// <summary>
/// 定义xml文件
/// </summary>
public string Xml { get; set; }
public SelectColumnForm()
{
InitializeComponent();
}
public SelectColumnForm(string xml)
{
InitializeComponent();
Xml = xml;
AddColumns();
SetRadGridViewProperty();
var list = ReadXml();
AddRows(list);
rgv_SelectColumn.Rows.CollectionChanged += Rows_CollectionChanged;
}
/// <summary>
/// 获取拖动后的数据记录
/// </summary>
/// <returns></returns>
public DataTable GetAllGridViewData()
{
var dt = new DataTable();
foreach (var column in rgv_SelectColumn.Columns)
{
var dataColumn = new DataColumn
{
ColumnName = column.Name
};
dt.Columns.Add(dataColumn);
}
foreach (GridViewRowInfo t in rgv_SelectColumn.Rows)
{
var datarow = dt.NewRow();
for (var j = 0; j < dt.Columns.Count; j++)
{
datarow[dt.Columns[j].ColumnName] = t.Cells[dt.Columns[j].ColumnName].Value;
}
dt.Rows.Add(datarow);
}
return dt;
}
/// <summary>
/// 修改xml文件
/// </summary>
/// <param name="dt"></param>
private void ModifyXml(DataTable dt)
{
XmlDataDocument doc = new XmlDataDocument();
try
{
doc.Load(Xml);
XmlNode dataTableSettingsNode = doc.SelectSingleNode("DataTable_Settings");//根结点
XmlNode dataCellsNode = dataTableSettingsNode.SelectSingleNode("data_cells");
if (null == dataCellsNode) return;
XmlNodeList dataCellNode = dataCellsNode.SelectNodes("data_cell");
foreach (XmlNode node in dataCellNode)
{
var chinesename = node.SelectSingleNode("chinese_name").InnerText;
var row = SearchRows(chinesename, dt);
node.SelectSingleNode("show_index").InnerText = (int.Parse(row[0].ToString()) + 1).ToString();
node.SelectSingleNode("visible").InnerText = row[1].ToString();
node.SelectSingleNode("width").InnerText = row[3].ToString();
switch (row[4].ToString())
{
case "左对齐":
node.SelectSingleNode("align").InnerText = "1";
break;
case "右对齐":
node.SelectSingleNode("align").InnerText = "2";
break;
case "居中对齐":
node.SelectSingleNode("align").InnerText = "0";
break;
default: break;
}
}
doc.Save(Xml);
}
catch (Exception ex)
{
}
}
private object[] SearchRows(string rowname, DataTable dt)
{
foreach (DataRow row in dt.Rows)
{
if (row["colname"].ToString() == rowname)
{
return row.ItemArray;
}
}
return null;
}
/// <summary>
/// 添加数据行
/// </summary>
/// <param name="list"></param>
private void AddRows(List<SelectColumn> list)
{
var count = 0;
var linqList = (from column in list
orderby column.ShowIndex
select column).ToList();
foreach (var selectColumn in linqList)
{
var obj = new object[list.Count];
obj[0] = ++count;
obj[1] = selectColumn.IsVisible;
obj[2] = selectColumn.ChineseColumnName;
obj[3] = selectColumn.Width;
switch (selectColumn.Align)
{
case 0:
obj[4] = "居中对齐";
break;
case 1:
obj[4] = "左对齐";
break;
case 2:
obj[4] = "右对齐";
break;
}
rgv_SelectColumn.Rows.Add(obj);
}
}
private void btn_Ok_Click(object sender, EventArgs e)
{
var dt = GetAllGridViewData();
ModifyXml(dt);
DialogResult=DialogResult.OK;
Close();
}
/// <summary>
/// 添加数据列
/// </summary>
private void AddColumns()
{
var num = new GridViewTextBoxColumn("Num", "Num");
num.HeaderText = "序 号";
num.ReadOnly = true;
num.Width = 50;
num.WrapText = false;
num.TextAlignment = ContentAlignment.MiddleCenter;
var chk = new GridViewCheckBoxColumn("Chk", "Chk");
chk.HeaderText = "选 择";
chk.ReadOnly = false;
chk.Width = 50;
chk.WrapText = false;
var colname = new GridViewTextBoxColumn("colname", "colname");
colname.HeaderText = "列 名";
colname.ReadOnly = true;
colname.Width = 100;
colname.WrapText = false;
colname.TextAlignment = ContentAlignment.MiddleCenter;
var colwidth = new GridViewDecimalColumn("colwidth", "colwidth");
colwidth.HeaderText = "列 宽";
colwidth.ReadOnly = false;
colwidth.DataType = typeof(int);
colwidth.Width = 80; ;
colwidth.WrapText = false;
colwidth.TextAlignment = ContentAlignment.MiddleCenter;
colwidth.FormatString = "{0:d}";
var colalign = new GridViewComboBoxColumn("colalign", "colalign");
colalign.HeaderText = "对齐方式";
colalign.DataSource = new[] { "左对齐", "居中对齐", "右对齐" };
colalign.Width = 100;
colalign.WrapText = false;
colalign.TextAlignment = ContentAlignment.MiddleCenter;
rgv_SelectColumn.Columns.Add(num);
rgv_SelectColumn.Columns.Add(chk);
rgv_SelectColumn.Columns.Add(colname);
rgv_SelectColumn.Columns.Add(colwidth);
rgv_SelectColumn.Columns.Add(colalign);
}
/// <summary>
/// 设置RadGridView控件属性
/// </summary>
private void SetRadGridViewProperty()
{
rgv_SelectColumn.EnableGrouping = false;//去掉分组
rgv_SelectColumn.AllowDrop = true;
rgv_SelectColumn.AllowRowReorder = true;
rgv_SelectColumn.AddNewRowPosition = SystemRowPosition.Bottom;
rgv_SelectColumn.ShowRowHeaderColumn = false;
rgv_SelectColumn.AllowColumnHeaderContextMenu = false;
rgv_SelectColumn.AllowColumnResize = false;
rgv_SelectColumn.AllowColumnReorder = false;
rgv_SelectColumn.EnableSorting = false;
rgv_SelectColumn.AllowAddNewRow = false;
rgv_SelectColumn.AllowRowResize = false;
}
/// <summary>
/// xml文件路径+名称
/// </summary>
public List<SelectColumn> ReadXml()
{
List<SelectColumn> selectColumns = new List<SelectColumn>();
XmlDataDocument doc = new XmlDataDocument();
try
{
doc.Load(Xml);
XmlNode dataTableSettingsNode = doc.SelectSingleNode("DataTable_Settings");//根结点
XmlNode dataCellsNode = dataTableSettingsNode.SelectSingleNode("data_cells");
if (null == dataCellsNode) return null;
XmlNodeList dataCellNode = dataCellsNode.SelectNodes("data_cell");
foreach (XmlNode node in dataCellNode)
{
SelectColumn selectColumn = new SelectColumn();
selectColumn.ColumnName = node.SelectSingleNode("cell_name").InnerText;
selectColumn.ChineseColumnName = node.SelectSingleNode("chinese_name").InnerText;
selectColumn.IsVisible = bool.Parse(node.SelectSingleNode("visible").InnerText);
selectColumn.Width = int.Parse(node.SelectSingleNode("width").InnerText);
selectColumn.Align = int.Parse(node.SelectSingleNode("align").InnerText);
selectColumn.ShowIndex = int.Parse(node.SelectSingleNode("show_index").InnerText);
selectColumns.Add(selectColumn);
}
}
catch (Exception ex)
{
}
return selectColumns;
}
/// <summary>
/// 行拖动时控件序号的显示
/// </summary>
/// <param name="sender"></param>
/// <param name="e"></param>
private void Rows_CollectionChanged(object sender, NotifyCollectionChangedEventArgs e)
{
if (e.Action != NotifyCollectionChangedAction.Move) return;
for (var i = 0; i < rgv_SelectColumn.Rows.Count; i++)
{
rgv_SelectColumn.Rows[i].Cells["Num"].Value = i + 1;
}
}
}
}
Telerik 控件事例(鼠标拖动行,拖动列,设置行对齐,行宽,是否显示)的更多相关文章
- C#设置一个控件可以鼠标拖动
C#设置一个控件可以鼠标拖动: 新建一个C#项目, 创建一个label控件, 设置label的鼠标按下和抬起事件分别为:label1_MouseDown和label1_MouseUp. 对代码进行如下 ...
- WPF ItemsControl 控件支持鼠标滚轮滑动
此文章意在解决在WPF中ItemsControl类型的集合控件支持鼠标滚轮操作,并可控制滚动的速度. 第一步:给ItemsControl添加滚轮事件. this.listBox.AddHandler( ...
- WinFrom 第三方控件 TeleRik控件
1.首先从工具-拓展与应用中下载安装 TeleRik WinFroms VsExtensions TeleRik dll文件 2.工具箱控件 将Telerik控件更新过来 3.新建一个 ...
- WPF 在image控件用鼠标拖拽出矩形
原文:WPF 在image控件用鼠标拖拽出矩形 版权声明:博客已迁移到 http://lindexi.gitee.io 欢迎访问.如果当前博客图片看不到,请到 http://lindexi.gitee ...
- 2018-11-19-WPF-在image控件用鼠标拖拽出矩形
title author date CreateTime categories WPF 在image控件用鼠标拖拽出矩形 lindexi 2018-11-19 15:35:13 +0800 2018- ...
- word-wrap&&word-break,奇偶行、列设置样式
1.word-wrap和word-break区分. 来源场景:机械租赁mvc驾驶员信息查看: 当备注的文字多的时候,第一列的值成这模样: 解决方案:设置table 的td可自动换行.首先table设置 ...
- Python+Appium自动化测试(10)-TouchAction类与MultiAction类(控件元素的滑动、拖动,九宫格解锁,手势操作等)
滑动屏幕方法swipe一般用于对页面进行上下左右滑动操作,但自动化过程中还会遇到其他情况,如对控件元素进行滑动.拖拽操作,九宫格解锁,手势操作,地图的放大与缩小等.这些需要针对控件元素的滑动操作,或者 ...
- 使用Telerik控件搭建Doubanfm频道部分
今天感觉好累啊..还是坚持记录下. 收集的API: https://github.com/HakurouKen/douban.fm-api https://github.com/zonyitoo/do ...
- winform Chart控件 获取鼠标处坐标值方法
Chart控件本身功能强大,应用广泛,因此其属性.方法也很多.此处介绍在很多应用中需要查看鼠标位置处坐标值的一些方法 1,调用Chart事件 GetToolTip 利用ToolTipEventArg ...
随机推荐
- 【转】istringstream、ostringstream、stringstream 类介绍 .
http://www.cnblogs.com/gamesky/archive/2013/01/09/2852356.html 好吧,懒死我算了
- Centos搭建nginx环境,编译,添加服务,开机启动。
首先安装所需的安装库,yum -y install gcc gcc-c++ autoconf libtool* openssl openssl-devel 编译的时候,若有提示错误,提示缺少某个库,y ...
- CSS3秘笈第三版涵盖HTML5学习笔记6~8章
第二部分----CSS实用技术 第6章,文本格式化 指定备用字体: font-family:Arial,Helvetica,sans-serif; 当访问者没有安装第一种字体时,浏览器会在列表中继续往 ...
- WCF配置文件详解 【转】
? 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 ...
- CSS3 box-flex属性和box-orient属性
比较有意思的是虽然目前没有浏览器支持box-flex,box-orient属性,但CSS3问世以来,这两个属性却一直很火.2014年阿里校招第5题要求使用CSS3中的功能实现三个矩形的布局,总的宽度为 ...
- Redis - 环境的安装配置
Redis 下载安装步骤: 下载 redis 源码: [huey@huey-K42JE ~]$ wget http://download.redis.io/releases/redis-x.y.z.t ...
- Nginx - SSI Module
SSI, for Server Side Includes, is actually a sort of server-side programming language interpreted by ...
- Android开发—— Native 与 Web 之架构抉择
前 言 移动App是对URL和搜索引擎的革命,当今移动App开发貌似出现两大阵营:Native 和 Web,各自都认为自己才是未来的趋势,Native操作流畅.迅速,Web开发周期相对较短,还能轻松跨 ...
- Java -- Thread中start和run方法的区别
一.认识Thread的 start() 和 run() 1.start(): 我们先来看看API中对于该方法的介绍: 使该线程开始执行:Java 虚拟机调用该线程的 run 方法. 结果是两个线程并发 ...
- 推荐一款App运营工具:AYL爱盈利App榜单监控
对包括开发者.产品运营.投资人在内的诸多移动互联网从业人员而言,国内Android应用市场和IOS应用市场的榜单变化数据时大家的必修功课之一:看看这段时间所关注的垂直领域里最火的是哪几款应用:看看竞争 ...