code stringlengths 4 1.01M | language stringclasses 2 values |
|---|---|
/*
* Hibernate, Relational Persistence for Idiomatic Java
*
* License: GNU Lesser General Public License (LGPL), version 2.1 or later.
* See the lgpl.txt file in the root directory or <http://www.gnu.org/licenses/lgpl-2.1.html>.
*/
package org.hibernate.dialect.identity;
import java.sql.PreparedStatement;
import java.sql.SQLException;
import org.hibernate.HibernateException;
import org.hibernate.dialect.Dialect;
import org.hibernate.dialect.identity.GetGeneratedKeysDelegate;
import org.hibernate.engine.spi.SessionImplementor;
import org.hibernate.id.PostInsertIdentityPersister;
/**
* @author Andrea Boriero
*/
public class Oracle12cGetGeneratedKeysDelegate extends GetGeneratedKeysDelegate {
private String[] keyColumns;
public Oracle12cGetGeneratedKeysDelegate(PostInsertIdentityPersister persister, Dialect dialect) {
super( persister, dialect );
this.keyColumns = getPersister().getRootTableKeyColumnNames();
if ( keyColumns.length > 1 ) {
throw new HibernateException( "Identity generator cannot be used with multi-column keys" );
}
}
@Override
protected PreparedStatement prepare(String insertSQL, SessionImplementor session) throws SQLException {
return session
.getJdbcCoordinator()
.getStatementPreparer()
.prepareStatement( insertSQL, keyColumns );
}
}
| Java |
/*******************************************************************************
* Copyright (c) 2012 Scott Ross.
* All rights reserved. This program and the accompanying materials
* are made available under the terms of the GNU Lesser Public License v2.1
* which accompanies this distribution, and is available at
* http://www.gnu.org/licenses/old-licenses/gpl-2.0.html
*
* Contributors:
* Scott Ross - initial API and implementation
******************************************************************************/
package org.alms.messages;
import org.alms.beans.*;
import javax.ws.rs.core.HttpHeaders;
public interface IMsg
{
public void setHeader(HttpHeaders msgHeaders);
public void setIncomingMessage(String incomingMessage);
public Boolean checkMessageVocubulary();
public RelatedParty getMsgDestination();
public RelatedParty getMsgSending();
public String getMsgId();
public String getUserName();
public String getPassword();
public String getXSDLocation();
public String getIncomingMessage();
public String receiverTransmissionType();
}
| Java |
<?php
// (c) Copyright 2002-2016 by authors of the Tiki Wiki CMS Groupware Project
//
// All Rights Reserved. See copyright.txt for details and a complete list of authors.
// Licensed under the GNU LESSER GENERAL PUBLIC LICENSE. See license.txt for details.
// $Id: ks_prefreport.php 57954 2016-03-17 19:34:29Z jyhem $
// outputs the prefreport as a pipe delimited file
// Usage: From the command line:
// php doc/devtools/prefreport.php
// resulting file can be found at dump/prefreport.txt
//
// also check out doc/devtools/securitycheck.php to see in which files are
// used each pref (and permission name too)
//
$ourFileName = "dump/prefreport.txt";
require_once 'tiki-setup.php';
$prefslib = TikiLib::lib('prefs');
$defaultValues = get_default_prefs();
$fields = array(
'preference' => '',
'name' => '',
'description' => '',
'default' => '',
'help' => '',
'hard_to_search' => false,
'duplicate_name' => 0,
'duplicate_description' => 0,
'word_count' => 0,
'filter' => '',
'locations' => '',
'dependencies' => '',
'type' => '',
'options' => '',
'admin' => '',
'module' => '',
'view' => '',
'permission' => '',
'plugin' => '',
'extensions' => '',
'tags' => '',
'parameters' => '',
'detail' => '',
'warning' => '',
'hint' => '',
'shorthint' => '',
'perspective' => '',
'separator' => '',
);
$stopWords = array('', 'in', 'and', 'a', 'to', 'be', 'of', 'on', 'the', 'for', 'as', 'it', 'or', 'with', 'by', 'is', 'an');
$data = array();
error_reporting(E_ALL);ini_set('display_errors', 'on');
$data = collect_raw_data($fields);
remove_fake_descriptions($data);
set_default_values($data, $defaultValues);
collect_locations($data);
$index = array(
'name' => index_data($data, 'name'),
'description' => index_data($data, 'description'),
);
update_search_flag($data, $index, $stopWords);
$ourFileHandle = fopen($ourFileName, 'w+') or die("can't open file");
// Output results
fputcsv($ourFileHandle, array_keys($fields), '|');
foreach ($data as $values) {
fputcsv($ourFileHandle, array_values($values), '|');
}
fclose($ourFileHandle);
/**
* @param $fields
* @return array
*/
function collect_raw_data($fields)
{
$data = array();
foreach (glob('lib/prefs/*.php') as $file) {
$name = substr(basename($file), 0, -4);
$function = "prefs_{$name}_list";
if ($name == 'index') {
continue;
}
include $file;
$list = $function();
foreach ($list as $name => $raw) {
$entry = $fields;
$entry['preference'] = $name;
$entry['name'] = isset($raw['name']) ? $raw['name'] : '';
$entry['description'] = isset($raw['description']) ? $raw['description'] : '';
$entry['filter'] = isset($raw['filter']) ? $raw['filter'] : '';
$entry['help'] = isset($raw['help']) ? $raw['help'] : '';
$entry['dependencies'] = !empty($raw['dependencies']) ? implode(',', (array) $raw['dependencies']) : '';
$entry['type'] = isset($raw['type']) ? $raw['type'] : '';
$entry['options'] = isset($raw['options']) ? implode(',', $raw['options']) : '';
$entry['admin'] = isset($raw['admin']) ? $raw['admin'] : '';
$entry['module'] = isset($raw['module']) ? $raw['module'] : '';
$entry['view'] = isset($raw['view']) ? $raw['view'] : '';
$entry['permission'] = isset($raw['permission']) ? implode(',', $raw['permission']) : '';
$entry['plugin'] = isset($raw['plugin']) ? $raw['plugin'] : '';
$entry['extensions'] = isset($raw['extensions']) ? implode(',', $raw['extensions']) : '';
$entry['tags'] = isset($raw['tags']) ? implode(',', $raw['tags']) : '';
$entry['parameters'] = isset($raw['parameters']) ? implode(',', $raw['parameters']) : '';
$entry['detail'] = isset($raw['detail']) ? $raw['detail'] : '';
$entry['warning'] = isset($raw['warning']) ? $raw['warning'] : '';
$entry['hint'] = isset($raw['hint']) ? $raw['hint'] : '';
$entry['shorthint'] = isset($raw['shorthint']) ? $raw['shorthint'] : '';
$entry['perspective'] = isset($raw['perspective']) ? $raw['perspective'] ? 'true' : 'false' : '';
$entry['separator'] = isset($raw['separator']) ? $raw['separator'] : '';
$data[] = $entry;
}
}
return $data;
}
/**
* @param $data
*/
function remove_fake_descriptions(& $data)
{
foreach ($data as & $row) {
if ($row['name'] == $row['description']) {
$row['description'] = '';
}
}
}
/**
* @param $data
* @param $prefs
*/
function set_default_values(& $data, $prefs)
{
foreach ($data as & $row) {
$row['default'] = isset($prefs[$row['preference']]) ? $prefs[$row['preference']] : '';
if (is_array($row['default'])) {
$row['default'] = implode($row['separator'], $row['default']);
}
}
}
/**
* @param $data
* @param $field
* @return array
*/
function index_data($data, $field)
{
$index = array();
foreach ($data as $row) {
$value = strtolower($row[$field]);
if (! isset($index[$value])) {
$index[$value] = 0;
}
$index[$value]++;
}
return $index;
}
/**
* @param $data
*/
function collect_locations(& $data)
{
$prefslib = TikiLib::lib('prefs');
foreach ($data as & $row) {
$pages = $prefslib->getPreferenceLocations($row['preference']);
foreach ($pages as & $page) {
$page = $page[0] . '/' . $page[1];
}
$row['locations'] = implode(', ', $pages);
}
}
/**
* @param $data
* @param $index
* @param $stopWords
*/
function update_search_flag(& $data, $index, $stopWords)
{
foreach ($data as & $row) {
$name = strtolower($row['name']);
$description = strtolower($row['description']);
$words = array_diff(explode(' ', $name . ' ' . $description), $stopWords);
$row['duplicate_name'] = $index['name'][$name];
if (! empty($description)) {
$row['duplicate_description'] = $index['description'][$description];
}
$row['word_count'] = count($words);
if (count($words) < 5) {
$row['hard_to_search'] = 'X';
} elseif ($index['name'][$name] > 2) {
$row['hard_to_search'] = 'X';
} elseif ($index['description'][$description] > 2) {
$row['hard_to_search'] = 'X';
}
}
}
| Java |
/*******************************************************************************
* File Name: HW_V1_config.h
*******************************************************************************/
#ifndef __HWV1_CONFIG_H
#define __HWV1_CONFIG_H
#include "usb_type.h"
#define BULK_MAX_PACKET_SIZE 0x00000040
#define TIM1_CR1 (*((vu32 *)(TIM1_BASE+0x00)))
#define TIM1_CR2 (*((vu32 *)(TIM1_BASE+0x04)))
#define TIM1_DIER (*((vu32 *)(TIM1_BASE+0x0C)))
#define TIM1_SR (*((vu32 *)(TIM1_BASE+0x10)))
#define TIM1_CCMR1 (*((vu32 *)(TIM1_BASE+0x18)))
#define TIM1_CCER (*((vu32 *)(TIM1_BASE+0x20)))
#define TIM1_PSC (*((vu32 *)(TIM1_BASE+0x28)))
#define TIM1_ARR (*((vu32 *)(TIM1_BASE+0x2C)))
#define TIM1_RCR (*((vu32 *)(TIM1_BASE+0x30)))
#define TIM1_CCR1 (*((vu32 *)(TIM1_BASE+0x34)))
#define TIM1_BDTR (*((vu32 *)(TIM1_BASE+0x44)))
#define TIM2_CR1 (*((vu32 *)(TIM2_BASE+0x00)))
#define TIM2_DIER (*((vu32 *)(TIM2_BASE+0x0C)))
#define TIM2_SR (*((vu32 *)(TIM2_BASE+0x10)))
#define TIM2_CCMR2 (*((vu32 *)(TIM2_BASE+0x1C)))
#define TIM2_CCER (*((vu32 *)(TIM2_BASE+0x20)))
#define TIM2_PSC (*((vu32 *)(TIM2_BASE+0x28)))
#define TIM2_ARR (*((vu32 *)(TIM2_BASE+0x2C)))
#define TIM2_CCR4 (*((vu32 *)(TIM2_BASE+0x40)))
#define TIM3_CR1 (*((vu32 *)(TIM3_BASE+0x00)))
#define TIM3_DIER (*((vu32 *)(TIM3_BASE+0x0C)))
#define TIM3_SR (*((vu32 *)(TIM3_BASE+0x10)))
#define TIM3_CCMR2 (*((vu32 *)(TIM3_BASE+0x1C)))
#define TIM3_CCER (*((vu32 *)(TIM3_BASE+0x20)))
#define TIM3_PSC (*((vu32 *)(TIM3_BASE+0x28)))
#define TIM3_ARR (*((vu32 *)(TIM3_BASE+0x2C)))
#define TIM3_CCR1 (*((vu32 *)(TIM3_BASE+0x34)))
#define TIM4_CR1 (*((vu32 *)(TIM4_BASE+0x00)))
#define TIM4_DIER (*((vu32 *)(TIM4_BASE+0x0C)))
#define TIM4_SR (*((vu32 *)(TIM4_BASE+0x10)))
#define TIM4_CCMR1 (*((vu32 *)(TIM4_BASE+0x18)))
#define TIM4_CCMR2 (*((vu32 *)(TIM4_BASE+0x1C)))
#define TIM4_CCER (*((vu32 *)(TIM4_BASE+0x20)))
#define TIM4_PSC (*((vu32 *)(TIM4_BASE+0x28)))
#define TIM4_ARR (*((vu32 *)(TIM4_BASE+0x2C)))
#define TIM4_CCR1 (*((vu32 *)(TIM4_BASE+0x34)))
typedef enum {
BEEP_1MHz,
BEEP_500kHz,
BEEP_200kHz,
BEEP_100kHz,
BEEP_50kHz,
BEEP_20kHz,
BEEP_10kHz,
BEEP_5kHz,
BEEP_2kHz,
BEEP_1kHz,
BEEP_500Hz,
BEEP_200Hz,
BEEP_100Hz,
BEEP_50Hz,
BEEP_20Hz,
BEEP_10Hz} beep_t;
#define ADC2_CR1 (*((vu32 *)(ADC2_BASE+0x04)))
#define ADC2_CR2 (*((vu32 *)(ADC2_BASE+0x08)))
#define ADC2_SMPR1 (*((vu32 *)(ADC2_BASE+0x0C)))
#define ADC2_SMPR2 (*((vu32 *)(ADC2_BASE+0x10)))
#define ADC2_SQR1 (*((vu32 *)(ADC2_BASE+0x2C)))
#define ADC2_SQR3 (*((vu32 *)(ADC2_BASE+0x34)))
#define ADC1_CR1 (*((vu32 *)(0x40012400+0x04)))
#define ADC1_CR2 (*((vu32 *)(0x40012400+0x08)))
#define ADC1_SMPR1 (*((vu32 *)(0x40012400+0x0C)))
#define ADC1_SMPR2 (*((vu32 *)(0x40012400+0x10)))
#define ADC1_SQR1 (*((vu32 *)(0x40012400+0x2C)))
#define ADC1_SQR3 (*((vu32 *)(0x40012400+0x34)))
#define ADC_DR (*((vu32 *)(0x40012400+0x4C)))
#define DMA_ISR (*((vu32 *)(0x40020000+0x00)))
#define DMA_IFCR (*((vu32 *)(0x40020000+0x04)))
#define DMA_CCR1 (*((vu32 *)(0x40020000+0x08)))
#define DMA_CNDTR1 (*((vu32 *)(0x40020000+0x0C)))
#define DMA_CPAR1 (*((vu32 *)(0x40020000+0x10)))
#define DMA_CMAR1 (*((vu32 *)(0x40020000+0x14)))
#define DMA_CCR2 (*((vu32 *)(0x40020000+0x1C)))
#define DMA_CNDTR2 (*((vu32 *)(0x40020000+0x20)))
#define DMA_CPAR2 (*((vu32 *)(0x40020000+0x24)))
#define DMA_CMAR2 (*((vu32 *)(0x40020000+0x28)))
#define ADC1_DR_ADDR ((u32)0x4001244C)
#define GPIOA_CRL (*((vu32 *)(GPIOA_BASE+0x00)))
#define GPIOB_CRL (*((vu32 *)(GPIOB_BASE+0x00)))
#define GPIOC_CRL (*((vu32 *)(GPIOC_BASE+0x00)))
#define GPIOD_CRL (*((vu32 *)(GPIOD_BASE+0x00)))
#define GPIOE_CRL (*((vu32 *)(GPIOE_BASE+0x00)))
#define GPIOA_CRH (*((vu32 *)(GPIOA_BASE+0x04)))
#define GPIOB_CRH (*((vu32 *)(GPIOB_BASE+0x04)))
#define GPIOC_CRH (*((vu32 *)(GPIOC_BASE+0x04)))
#define GPIOD_CRH (*((vu32 *)(GPIOD_BASE+0x04)))
#define GPIOE_CRH (*((vu32 *)(GPIOE_BASE+0x04)))
#define GPIOA_ODR (*((vu32 *)(GPIOA_BASE+0x0C)))
#define GPIOB_ODR (*((vu32 *)(GPIOB_BASE+0x0C)))
#define GPIOC_ODR (*((vu32 *)(GPIOC_BASE+0x0C)))
#define GPIOD_ODR (*((vu32 *)(GPIOD_BASE+0x0C)))
#define GPIOE_ODR (*((vu32 *)(GPIOE_BASE+0x0C)))
#define GPIOA_IDR (*((vu32 *)(GPIOA_BASE+0x08)))
#define GPIOB_IDR (*((vu32 *)(GPIOB_BASE+0x08)))
#define GPIOC_IDR (*((vu32 *)(GPIOC_BASE+0x08)))
#define GPIOD_IDR (*((vu32 *)(GPIOD_BASE+0x08)))
#define GPIOE_IDR (*((vu32 *)(GPIOE_BASE+0x08)))
#define GPIOA_BSRR (*((vu32 *)(GPIOA_BASE+0x10)))
#define GPIOB_BSRR (*((vu32 *)(GPIOB_BASE+0x10)))
#define GPIOC_BSRR (*((vu32 *)(GPIOC_BASE+0x10)))
#define GPIOD_BSRR (*((vu32 *)(GPIOD_BASE+0x10)))
#define GPIOE_BSRR (*((vu32 *)(GPIOE_BASE+0x10)))
#define GPIOA_BRR (*((vu32 *)(GPIOA_BASE+0x14)))
#define GPIOB_BRR (*((vu32 *)(GPIOB_BASE+0x14)))
#define GPIOC_BRR (*((vu32 *)(GPIOC_BASE+0x14)))
#define GPIOD_BRR (*((vu32 *)(GPIOD_BASE+0x14)))
#define GPIOE_BRR (*((vu32 *)(GPIOE_BASE+0x14)))
#define AFIO_MAPR (*((vu32 *)(AFIO_BASE+0x04)))
//These bits are written by software to select the source input for EXTIx external interrupt.
#define PA_x_PIN 0000
#define PB_x_PIN 0001
#define PC_x_PIN 0010
#define PD_x_PIN 0011
#define PE_x_PIN 0100
#define PF_x_PIN 0101
#define PG_x_PIN 0110
#define AFIO_EXTICR1 (*((vu32 *)(AFIO_BASE+0x08))) //EXTI x configuration (x= 0 to 3)
#define AFIO_EXTICR2 (*((vu32 *)(AFIO_BASE+0x0C))) //EXTI x configuration (x= 4 to 7)
#define AFIO_EXTICR3 (*((vu32 *)(AFIO_BASE+0x10))) //EXTI x configuration (x= 8 to 11)
#define AFIO_EXTICR4 (*((vu32 *)(AFIO_BASE+0x14))) //EXTI x configuration (x= 12 to 15)
#define SCS_BASE ((u32)0xE000E000)
#define SysTick_BASE (SCS_BASE + 0x0010)
#define MSD_CS_LOW() GPIOB_BRR = GPIO_Pin_12 //Select MSD Card
#define MSD_CS_HIGH() GPIOB_BSRR = GPIO_Pin_12 //Deselect MSD Card
#define KEY_UP (GPIO_Pin_6) //GPIOA6 (PA_x_PIN << 8)
#define KEY_DOWN (GPIO_Pin_9) //GPIOD9 (PD_x_PIN << 4)
#define KEY_LEFT (GPIO_Pin_5) //GPIOA5 (PA_x_PIN << 4)
#define KEY_RIGHT (GPIO_Pin_7) //GPIOA7 (PA_x_PIN << 12)
#define KEY_PLAY (GPIO_Pin_4) //GPIOA4 (PA_x_PIN << 0)
#define KEY_M (GPIO_Pin_11) //GPIOD11 (PD_x_PIN << 12)
#define KEY_B (GPIO_Pin_3) //GPIOA3 (PA_x_PIN << 12)
typedef enum {
KEYCODE_VOID,
KEYCODE_PLAY,
KEYCODE_M,
KEYCODE_B,
KEYCODE_UP,
KEYCODE_DOWN,
KEYCODE_LEFT,
KEYCODE_RIGHT} KeyCode_t;
#define LDC_DATA_OUT GPIOE_ODR
#define LDC_DATA_INP GPIOE_IDR
#define LCD_DATA_BUS_INP() GPIOC_CRH = 0x44444444; GPIOE_CRL = 0x44444444
#define LCD_DATA_BUS_OUT() GPIOC_CRH = 0x33333333; GPIOE_CRL = 0x33333333
#define LCD_nRST_LOW() GPIOC_BRR = GPIO_Pin_0
#define LCD_nRST_HIGH() GPIOC_BSRR = GPIO_Pin_0
#define LCD_RS_LOW() GPIOD_BRR = GPIO_Pin_1
#define LCD_RS_HIGH() GPIOD_BSRR = GPIO_Pin_1
#define LCD_nWR_LOW() GPIOD_BRR = GPIO_Pin_5
#define LCD_nWR_HIGH() GPIOD_BSRR = GPIO_Pin_5
#define LCD_nWR_ACT() GPIOD_BRR = GPIO_Pin_5; GPIOD_BSRR = GPIO_Pin_5
#define LCD_nRD_LOW() GPIOD_BRR = GPIO_Pin_4
#define LCD_nRD_HIGH() GPIOD_BSRR = GPIO_Pin_4
#define LCD_nRD_ACT() GPIOB_BRR = GPIO_Pin_4; GPIOD_BSRR = GPIO_Pin_4
#define RANGE_A_LOW() GPIOB_BRR = GPIO_Pin_0
#define RANGE_A_HIGH() GPIOB_BSRR = GPIO_Pin_0
#define RANGE_B_LOW() GPIOC_BRR = GPIO_Pin_5
#define RANGE_B_HIGH() GPIOC_BSRR = GPIO_Pin_5
#define RANGE_C_LOW() GPIOC_BRR = GPIO_Pin_4
#define RANGE_C_HIGH() GPIOC_BSRR = GPIO_Pin_4
#define RANGE_D_LOW() GPIOB_BRR = GPIO_Pin_1
#define RANGE_D_HIGH() GPIOB_BSRR = GPIO_Pin_1
void Set_System(void);
void NVIC_Configuration(void);
void GPIO_Config(void);
void Get_Medium_Characteristics(void);
void SPI_Config(void);
void DMA_Configuration(void);
void ADC_Configuration(void);
void Timer_Configuration(void);
char KeyScan(void);
unsigned char MSD_WriteByte(u8 byte);
unsigned char MSD_ReadByte(void);
void Battery_Detect(void);
void Set_Range(char Range);
void Set_Base(char Base);
void ADC_Start(void);
void Set_Y_Pos(unsigned short Y0);
char Test_USB_ON(void);
char SD_Card_ON(void);
void Delayms(unsigned short delay);
void WaitForKey(void);
extern volatile unsigned short DelayCounter;
extern volatile unsigned short BeepCounter;
extern volatile KeyCode_t KeyBuffer;
void Display_Info(char *Pre, unsigned long Num);
#endif
/****************************** END OF FILE ***********************************/
| Java |
#include "sparrowPrimitives.h"
| Java |
package jastadd.soot.JastAddJ;
import java.util.HashSet;import java.util.LinkedHashSet;import java.io.File;import java.util.*;import jastadd.beaver.*;import java.util.ArrayList;import java.util.zip.*;import java.io.*;import java.io.FileNotFoundException;import java.util.Collection;import soot.*;import soot.util.*;import soot.jimple.*;import soot.coffi.ClassFile;import soot.coffi.method_info;import soot.coffi.CONSTANT_Utf8_info;import soot.tagkit.SourceFileTag;import soot.coffi.CoffiMethodSource;
public class ParClassInstanceExpr extends ClassInstanceExpr implements Cloneable {
public void flushCache() {
super.flushCache();
}
public void flushCollectionCache() {
super.flushCollectionCache();
}
@SuppressWarnings({"unchecked", "cast"}) public ParClassInstanceExpr clone() throws CloneNotSupportedException {
ParClassInstanceExpr node = (ParClassInstanceExpr)super.clone();
node.in$Circle(false);
node.is$Final(false);
return node;
}
@SuppressWarnings({"unchecked", "cast"}) public ParClassInstanceExpr copy() {
try {
ParClassInstanceExpr node = clone();
if(children != null) node.children = children.clone();
return node;
} catch (CloneNotSupportedException e) {
}
System.err.println("Error: Could not clone node of type " + getClass().getName() + "!");
return null;
}
@SuppressWarnings({"unchecked", "cast"}) public ParClassInstanceExpr fullCopy() {
ParClassInstanceExpr res = copy();
for(int i = 0; i < getNumChildNoTransform(); i++) {
ASTNode node = getChildNoTransform(i);
if(node != null) node = node.fullCopy();
res.setChild(node, i);
}
return res;
}
// Declared in GenericMethods.jrag at line 160
public void toString(StringBuffer s) {
s.append("<");
for(int i = 0; i < getNumTypeArgument(); i++) {
if(i != 0) s.append(", ");
getTypeArgument(i).toString(s);
}
s.append(">");
super.toString(s);
}
// Declared in GenericMethods.ast at line 3
// Declared in GenericMethods.ast line 15
public ParClassInstanceExpr() {
super();
setChild(new List(), 1);
setChild(new Opt(), 2);
setChild(new List(), 3);
}
// Declared in GenericMethods.ast at line 13
// Declared in GenericMethods.ast line 15
public ParClassInstanceExpr(Access p0, List<Expr> p1, Opt<TypeDecl> p2, List<Access> p3) {
setChild(p0, 0);
setChild(p1, 1);
setChild(p2, 2);
setChild(p3, 3);
}
// Declared in GenericMethods.ast at line 20
protected int numChildren() {
return 4;
}
// Declared in GenericMethods.ast at line 23
public boolean mayHaveRewrite() {
return false;
}
// Declared in java.ast at line 2
// Declared in java.ast line 34
public void setAccess(Access node) {
setChild(node, 0);
}
// Declared in java.ast at line 5
public Access getAccess() {
return (Access)getChild(0);
}
// Declared in java.ast at line 9
public Access getAccessNoTransform() {
return (Access)getChildNoTransform(0);
}
// Declared in java.ast at line 2
// Declared in java.ast line 34
public void setArgList(List<Expr> list) {
setChild(list, 1);
}
// Declared in java.ast at line 6
public int getNumArg() {
return getArgList().getNumChild();
}
// Declared in java.ast at line 10
@SuppressWarnings({"unchecked", "cast"}) public Expr getArg(int i) {
return getArgList().getChild(i);
}
// Declared in java.ast at line 14
public void addArg(Expr node) {
List<Expr> list = (parent == null || state == null) ? getArgListNoTransform() : getArgList();
list.addChild(node);
}
// Declared in java.ast at line 19
public void addArgNoTransform(Expr node) {
List<Expr> list = getArgListNoTransform();
list.addChild(node);
}
// Declared in java.ast at line 24
public void setArg(Expr node, int i) {
List<Expr> list = getArgList();
list.setChild(node, i);
}
// Declared in java.ast at line 28
public List<Expr> getArgs() {
return getArgList();
}
// Declared in java.ast at line 31
public List<Expr> getArgsNoTransform() {
return getArgListNoTransform();
}
// Declared in java.ast at line 35
@SuppressWarnings({"unchecked", "cast"}) public List<Expr> getArgList() {
List<Expr> list = (List<Expr>)getChild(1);
list.getNumChild();
return list;
}
// Declared in java.ast at line 41
@SuppressWarnings({"unchecked", "cast"}) public List<Expr> getArgListNoTransform() {
return (List<Expr>)getChildNoTransform(1);
}
// Declared in java.ast at line 2
// Declared in java.ast line 34
public void setTypeDeclOpt(Opt<TypeDecl> opt) {
setChild(opt, 2);
}
// Declared in java.ast at line 6
public boolean hasTypeDecl() {
return getTypeDeclOpt().getNumChild() != 0;
}
// Declared in java.ast at line 10
@SuppressWarnings({"unchecked", "cast"}) public TypeDecl getTypeDecl() {
return getTypeDeclOpt().getChild(0);
}
// Declared in java.ast at line 14
public void setTypeDecl(TypeDecl node) {
getTypeDeclOpt().setChild(node, 0);
}
// Declared in java.ast at line 17
@SuppressWarnings({"unchecked", "cast"}) public Opt<TypeDecl> getTypeDeclOpt() {
return (Opt<TypeDecl>)getChild(2);
}
// Declared in java.ast at line 21
@SuppressWarnings({"unchecked", "cast"}) public Opt<TypeDecl> getTypeDeclOptNoTransform() {
return (Opt<TypeDecl>)getChildNoTransform(2);
}
// Declared in GenericMethods.ast at line 2
// Declared in GenericMethods.ast line 15
public void setTypeArgumentList(List<Access> list) {
setChild(list, 3);
}
// Declared in GenericMethods.ast at line 6
public int getNumTypeArgument() {
return getTypeArgumentList().getNumChild();
}
// Declared in GenericMethods.ast at line 10
@SuppressWarnings({"unchecked", "cast"}) public Access getTypeArgument(int i) {
return getTypeArgumentList().getChild(i);
}
// Declared in GenericMethods.ast at line 14
public void addTypeArgument(Access node) {
List<Access> list = (parent == null || state == null) ? getTypeArgumentListNoTransform() : getTypeArgumentList();
list.addChild(node);
}
// Declared in GenericMethods.ast at line 19
public void addTypeArgumentNoTransform(Access node) {
List<Access> list = getTypeArgumentListNoTransform();
list.addChild(node);
}
// Declared in GenericMethods.ast at line 24
public void setTypeArgument(Access node, int i) {
List<Access> list = getTypeArgumentList();
list.setChild(node, i);
}
// Declared in GenericMethods.ast at line 28
public List<Access> getTypeArguments() {
return getTypeArgumentList();
}
// Declared in GenericMethods.ast at line 31
public List<Access> getTypeArgumentsNoTransform() {
return getTypeArgumentListNoTransform();
}
// Declared in GenericMethods.ast at line 35
@SuppressWarnings({"unchecked", "cast"}) public List<Access> getTypeArgumentList() {
List<Access> list = (List<Access>)getChild(3);
list.getNumChild();
return list;
}
// Declared in GenericMethods.ast at line 41
@SuppressWarnings({"unchecked", "cast"}) public List<Access> getTypeArgumentListNoTransform() {
return (List<Access>)getChildNoTransform(3);
}
// Declared in GenericMethods.jrag at line 126
public NameType Define_NameType_nameType(ASTNode caller, ASTNode child) {
if(caller == getTypeArgumentListNoTransform()) {
int childIndex = caller.getIndexOfChild(child);
return NameType.TYPE_NAME;
}
return super.Define_NameType_nameType(caller, child);
}
// Declared in GenericMethods.jrag at line 127
public SimpleSet Define_SimpleSet_lookupType(ASTNode caller, ASTNode child, String name) {
if(caller == getTypeArgumentListNoTransform()) {
int childIndex = caller.getIndexOfChild(child);
return unqualifiedScope().lookupType(name);
}
return super.Define_SimpleSet_lookupType(caller, child, name);
}
public ASTNode rewriteTo() {
return super.rewriteTo();
}
}
| Java |
/*
* filter_glsl_manager.cpp
* Copyright (C) 2011-2012 Christophe Thommeret <hftom@free.fr>
* Copyright (C) 2013 Dan Dennedy <dan@dennedy.org>
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software Foundation,
* Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
*/
#include <stdlib.h>
#include <string>
#include "filter_glsl_manager.h"
#include <movit/init.h>
#include <movit/util.h>
#include <movit/effect_chain.h>
#include <movit/resource_pool.h>
#include "mlt_movit_input.h"
#include "mlt_flip_effect.h"
#include <mlt++/MltEvent.h>
#include <mlt++/MltProducer.h>
extern "C" {
#include <framework/mlt_factory.h>
}
#if defined(__APPLE__)
#include <OpenGL/OpenGL.h>
#elif defined(_WIN32)
#include <windows.h>
#include <wingdi.h>
#else
#include <GL/glx.h>
#endif
using namespace movit;
void dec_ref_and_delete(GlslManager *p)
{
if (p->dec_ref() == 0) {
delete p;
}
}
GlslManager::GlslManager()
: Mlt::Filter( mlt_filter_new() )
, resource_pool(new ResourcePool())
, pbo(0)
, initEvent(0)
, closeEvent(0)
, prev_sync(NULL)
{
mlt_filter filter = get_filter();
if ( filter ) {
// Set the mlt_filter child in case we choose to override virtual functions.
filter->child = this;
add_ref(mlt_global_properties());
mlt_events_register( get_properties(), "init glsl", NULL );
mlt_events_register( get_properties(), "close glsl", NULL );
initEvent = listen("init glsl", this, (mlt_listener) GlslManager::onInit);
closeEvent = listen("close glsl", this, (mlt_listener) GlslManager::onClose);
}
}
GlslManager::~GlslManager()
{
mlt_log_debug(get_service(), "%s\n", __FUNCTION__);
cleanupContext();
// XXX If there is still a frame holding a reference to a texture after this
// destructor is called, then it will crash in release_texture().
// while (texture_list.peek_back())
// delete (glsl_texture) texture_list.pop_back();
delete initEvent;
delete closeEvent;
if (prev_sync != NULL) {
glDeleteSync( prev_sync );
}
while (syncs_to_delete.count() > 0) {
GLsync sync = (GLsync) syncs_to_delete.pop_front();
glDeleteSync( sync );
}
delete resource_pool;
}
void GlslManager::add_ref(mlt_properties properties)
{
inc_ref();
mlt_properties_set_data(properties, "glslManager", this, 0,
(mlt_destructor) dec_ref_and_delete, NULL);
}
GlslManager* GlslManager::get_instance()
{
return (GlslManager*) mlt_properties_get_data(mlt_global_properties(), "glslManager", 0);
}
glsl_texture GlslManager::get_texture(int width, int height, GLint internal_format)
{
lock();
for (int i = 0; i < texture_list.count(); ++i) {
glsl_texture tex = (glsl_texture) texture_list.peek(i);
if (!tex->used && (tex->width == width) && (tex->height == height) && (tex->internal_format == internal_format)) {
glBindTexture(GL_TEXTURE_2D, tex->texture);
glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MIN_FILTER, GL_NEAREST);
glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MAG_FILTER, GL_NEAREST);
glBindTexture( GL_TEXTURE_2D, 0);
tex->used = 1;
unlock();
return tex;
}
}
unlock();
GLuint tex = 0;
glGenTextures(1, &tex);
if (!tex) {
return NULL;
}
glsl_texture gtex = new glsl_texture_s;
if (!gtex) {
glDeleteTextures(1, &tex);
return NULL;
}
glBindTexture( GL_TEXTURE_2D, tex );
glTexImage2D( GL_TEXTURE_2D, 0, internal_format, width, height, 0, GL_RGBA, GL_UNSIGNED_BYTE, NULL );
glTexParameterf( GL_TEXTURE_2D, GL_TEXTURE_WRAP_S, GL_CLAMP_TO_EDGE );
glTexParameterf( GL_TEXTURE_2D, GL_TEXTURE_WRAP_T, GL_CLAMP_TO_EDGE );
glTexParameteri( GL_TEXTURE_2D, GL_TEXTURE_MIN_FILTER, GL_NEAREST );
glTexParameteri( GL_TEXTURE_2D, GL_TEXTURE_MAG_FILTER, GL_NEAREST );
glBindTexture( GL_TEXTURE_2D, 0 );
gtex->texture = tex;
gtex->width = width;
gtex->height = height;
gtex->internal_format = internal_format;
gtex->used = 1;
lock();
texture_list.push_back(gtex);
unlock();
return gtex;
}
void GlslManager::release_texture(glsl_texture texture)
{
texture->used = 0;
}
void GlslManager::delete_sync(GLsync sync)
{
// We do not know which thread we are called from, and we can only
// delete this if we are in one with a valid OpenGL context.
// Thus, store it for later deletion in render_frame_texture().
GlslManager* g = GlslManager::get_instance();
g->lock();
g->syncs_to_delete.push_back(sync);
g->unlock();
}
glsl_pbo GlslManager::get_pbo(int size)
{
lock();
if (!pbo) {
GLuint pb = 0;
glGenBuffers(1, &pb);
if (!pb) {
unlock();
return NULL;
}
pbo = new glsl_pbo_s;
if (!pbo) {
glDeleteBuffers(1, &pb);
unlock();
return NULL;
}
pbo->pbo = pb;
pbo->size = 0;
}
if (size > pbo->size) {
glBindBuffer(GL_PIXEL_UNPACK_BUFFER_ARB, pbo->pbo);
glBufferData(GL_PIXEL_UNPACK_BUFFER_ARB, size, NULL, GL_STREAM_DRAW);
glBindBuffer(GL_PIXEL_UNPACK_BUFFER_ARB, 0);
pbo->size = size;
}
unlock();
return pbo;
}
void GlslManager::cleanupContext()
{
lock();
while (texture_list.peek_back()) {
glsl_texture texture = (glsl_texture) texture_list.peek_back();
glDeleteTextures(1, &texture->texture);
delete texture;
texture_list.pop_back();
}
if (pbo) {
glDeleteBuffers(1, &pbo->pbo);
delete pbo;
pbo = 0;
}
unlock();
}
void GlslManager::onInit( mlt_properties owner, GlslManager* filter )
{
mlt_log_debug( filter->get_service(), "%s\n", __FUNCTION__ );
#ifdef _WIN32
std::string path = std::string(mlt_environment("MLT_APPDIR")).append("\\share\\movit");
#elif defined(__APPLE__) && defined(RELOCATABLE)
std::string path = std::string(mlt_environment("MLT_APPDIR")).append("/share/movit");
#else
std::string path = std::string(getenv("MLT_MOVIT_PATH") ? getenv("MLT_MOVIT_PATH") : SHADERDIR);
#endif
bool success = init_movit( path, mlt_log_get_level() == MLT_LOG_DEBUG? MOVIT_DEBUG_ON : MOVIT_DEBUG_OFF );
filter->set( "glsl_supported", success );
}
void GlslManager::onClose( mlt_properties owner, GlslManager *filter )
{
filter->cleanupContext();
}
void GlslManager::onServiceChanged( mlt_properties owner, mlt_service aservice )
{
Mlt::Service service( aservice );
service.lock();
service.set( "movit chain", NULL, 0 );
service.unlock();
}
void GlslManager::onPropertyChanged( mlt_properties owner, mlt_service service, const char* property )
{
if ( property && std::string( property ) == "disable" )
onServiceChanged( owner, service );
}
extern "C" {
mlt_filter filter_glsl_manager_init( mlt_profile profile, mlt_service_type type, const char *id, char *arg )
{
GlslManager* g = GlslManager::get_instance();
if (g)
g->inc_ref();
else
g = new GlslManager();
return g->get_filter();
}
} // extern "C"
static void deleteChain( GlslChain* chain )
{
// The Input* is owned by the EffectChain, but the MltInput* is not.
// Thus, we have to delete it here.
for (std::map<mlt_producer, MltInput*>::iterator input_it = chain->inputs.begin();
input_it != chain->inputs.end();
++input_it) {
delete input_it->second;
}
delete chain->effect_chain;
delete chain;
}
void* GlslManager::get_frame_specific_data( mlt_service service, mlt_frame frame, const char *key, int *length )
{
const char *unique_id = mlt_properties_get( MLT_SERVICE_PROPERTIES(service), "_unique_id" );
char buf[256];
snprintf( buf, sizeof(buf), "%s_%s", key, unique_id );
return mlt_properties_get_data( MLT_FRAME_PROPERTIES(frame), buf, length );
}
int GlslManager::set_frame_specific_data( mlt_service service, mlt_frame frame, const char *key, void *value, int length, mlt_destructor destroy, mlt_serialiser serialise )
{
const char *unique_id = mlt_properties_get( MLT_SERVICE_PROPERTIES(service), "_unique_id" );
char buf[256];
snprintf( buf, sizeof(buf), "%s_%s", key, unique_id );
return mlt_properties_set_data( MLT_FRAME_PROPERTIES(frame), buf, value, length, destroy, serialise );
}
void GlslManager::set_chain( mlt_service service, GlslChain* chain )
{
mlt_properties_set_data( MLT_SERVICE_PROPERTIES(service), "_movit chain", chain, 0, (mlt_destructor) deleteChain, NULL );
}
GlslChain* GlslManager::get_chain( mlt_service service )
{
return (GlslChain*) mlt_properties_get_data( MLT_SERVICE_PROPERTIES(service), "_movit chain", NULL );
}
Effect* GlslManager::get_effect( mlt_service service, mlt_frame frame )
{
return (Effect*) get_frame_specific_data( service, frame, "_movit effect", NULL );
}
Effect* GlslManager::set_effect( mlt_service service, mlt_frame frame, Effect* effect )
{
set_frame_specific_data( service, frame, "_movit effect", effect, 0, NULL, NULL );
return effect;
}
MltInput* GlslManager::get_input( mlt_producer producer, mlt_frame frame )
{
return (MltInput*) get_frame_specific_data( MLT_PRODUCER_SERVICE(producer), frame, "_movit input", NULL );
}
MltInput* GlslManager::set_input( mlt_producer producer, mlt_frame frame, MltInput* input )
{
set_frame_specific_data( MLT_PRODUCER_SERVICE(producer), frame, "_movit input", input, 0, NULL, NULL );
return input;
}
uint8_t* GlslManager::get_input_pixel_pointer( mlt_producer producer, mlt_frame frame )
{
return (uint8_t*) get_frame_specific_data( MLT_PRODUCER_SERVICE(producer), frame, "_movit input pp", NULL );
}
uint8_t* GlslManager::set_input_pixel_pointer( mlt_producer producer, mlt_frame frame, uint8_t* image )
{
set_frame_specific_data( MLT_PRODUCER_SERVICE(producer), frame, "_movit input pp", image, 0, NULL, NULL );
return image;
}
mlt_service GlslManager::get_effect_input( mlt_service service, mlt_frame frame )
{
return (mlt_service) get_frame_specific_data( service, frame, "_movit effect input", NULL );
}
void GlslManager::set_effect_input( mlt_service service, mlt_frame frame, mlt_service input_service )
{
set_frame_specific_data( service, frame, "_movit effect input", input_service, 0, NULL, NULL );
}
void GlslManager::get_effect_secondary_input( mlt_service service, mlt_frame frame, mlt_service *input_service, mlt_frame *input_frame)
{
*input_service = (mlt_service) get_frame_specific_data( service, frame, "_movit effect secondary input", NULL );
*input_frame = (mlt_frame) get_frame_specific_data( service, frame, "_movit effect secondary input frame", NULL );
}
void GlslManager::set_effect_secondary_input( mlt_service service, mlt_frame frame, mlt_service input_service, mlt_frame input_frame )
{
set_frame_specific_data( service, frame, "_movit effect secondary input", input_service, 0, NULL, NULL );
set_frame_specific_data( service, frame, "_movit effect secondary input frame", input_frame, 0, NULL, NULL );
}
void GlslManager::get_effect_third_input( mlt_service service, mlt_frame frame, mlt_service *input_service, mlt_frame *input_frame)
{
*input_service = (mlt_service) get_frame_specific_data( service, frame, "_movit effect third input", NULL );
*input_frame = (mlt_frame) get_frame_specific_data( service, frame, "_movit effect third input frame", NULL );
}
void GlslManager::set_effect_third_input( mlt_service service, mlt_frame frame, mlt_service input_service, mlt_frame input_frame )
{
set_frame_specific_data( service, frame, "_movit effect third input", input_service, 0, NULL, NULL );
set_frame_specific_data( service, frame, "_movit effect third input frame", input_frame, 0, NULL, NULL );
}
int GlslManager::render_frame_texture(EffectChain *chain, mlt_frame frame, int width, int height, uint8_t **image)
{
glsl_texture texture = get_texture( width, height, GL_RGBA8 );
if (!texture) {
return 1;
}
GLuint fbo;
glGenFramebuffers( 1, &fbo );
check_error();
glBindFramebuffer( GL_FRAMEBUFFER, fbo );
check_error();
glFramebufferTexture2D( GL_FRAMEBUFFER, GL_COLOR_ATTACHMENT0, GL_TEXTURE_2D, texture->texture, 0 );
check_error();
glBindFramebuffer( GL_FRAMEBUFFER, 0 );
check_error();
lock();
while (syncs_to_delete.count() > 0) {
GLsync sync = (GLsync) syncs_to_delete.pop_front();
glDeleteSync( sync );
}
unlock();
// Make sure we never have more than one frame pending at any time.
// This ensures we do not swamp the GPU with so much work
// that we cannot actually display the frames we generate.
if (prev_sync != NULL) {
glFlush();
glClientWaitSync( prev_sync, 0, GL_TIMEOUT_IGNORED );
glDeleteSync( prev_sync );
}
chain->render_to_fbo( fbo, width, height );
prev_sync = glFenceSync( GL_SYNC_GPU_COMMANDS_COMPLETE, 0 );
GLsync sync = glFenceSync( GL_SYNC_GPU_COMMANDS_COMPLETE, 0 );
check_error();
glBindFramebuffer( GL_FRAMEBUFFER, 0 );
check_error();
glDeleteFramebuffers( 1, &fbo );
check_error();
*image = (uint8_t*) &texture->texture;
mlt_frame_set_image( frame, *image, 0, NULL );
mlt_properties_set_data( MLT_FRAME_PROPERTIES(frame), "movit.convert.texture", texture, 0,
(mlt_destructor) GlslManager::release_texture, NULL );
mlt_properties_set_data( MLT_FRAME_PROPERTIES(frame), "movit.convert.fence", sync, 0,
(mlt_destructor) GlslManager::delete_sync, NULL );
return 0;
}
int GlslManager::render_frame_rgba(EffectChain *chain, mlt_frame frame, int width, int height, uint8_t **image)
{
glsl_texture texture = get_texture( width, height, GL_RGBA8 );
if (!texture) {
return 1;
}
// Use a PBO to hold the data we read back with glReadPixels().
// (Intel/DRI goes into a slow path if we don't read to PBO.)
int img_size = width * height * 4;
glsl_pbo pbo = get_pbo( img_size );
if (!pbo) {
release_texture(texture);
return 1;
}
// Set the FBO
GLuint fbo;
glGenFramebuffers( 1, &fbo );
check_error();
glBindFramebuffer( GL_FRAMEBUFFER, fbo );
check_error();
glFramebufferTexture2D( GL_FRAMEBUFFER, GL_COLOR_ATTACHMENT0, GL_TEXTURE_2D, texture->texture, 0 );
check_error();
glBindFramebuffer( GL_FRAMEBUFFER, 0 );
check_error();
chain->render_to_fbo( fbo, width, height );
// Read FBO into PBO
glBindFramebuffer( GL_FRAMEBUFFER, fbo );
check_error();
glBindBuffer( GL_PIXEL_PACK_BUFFER_ARB, pbo->pbo );
check_error();
glBufferData( GL_PIXEL_PACK_BUFFER_ARB, img_size, NULL, GL_STREAM_READ );
check_error();
glReadPixels( 0, 0, width, height, GL_BGRA, GL_UNSIGNED_BYTE, BUFFER_OFFSET(0) );
check_error();
// Copy from PBO
uint8_t* buf = (uint8_t*) glMapBuffer( GL_PIXEL_PACK_BUFFER_ARB, GL_READ_ONLY );
check_error();
*image = (uint8_t*) mlt_pool_alloc( img_size );
mlt_frame_set_image( frame, *image, img_size, mlt_pool_release );
memcpy( *image, buf, img_size );
// Convert BGRA to RGBA
register uint8_t *p = *image;
register int n = width * height + 1;
while ( --n ) {
uint8_t b = p[0];
*p = p[2]; p += 2;
*p = b; p += 2;
}
// Release PBO and FBO
glUnmapBuffer( GL_PIXEL_PACK_BUFFER_ARB );
check_error();
glBindBuffer( GL_PIXEL_PACK_BUFFER_ARB, 0 );
check_error();
glBindFramebuffer( GL_FRAMEBUFFER, 0 );
check_error();
glBindTexture( GL_TEXTURE_2D, 0 );
check_error();
mlt_properties_set_data( MLT_FRAME_PROPERTIES(frame), "movit.convert.texture", texture, 0,
(mlt_destructor) GlslManager::release_texture, NULL);
glDeleteFramebuffers( 1, &fbo );
check_error();
return 0;
}
void GlslManager::lock_service( mlt_frame frame )
{
Mlt::Producer producer( mlt_producer_cut_parent( mlt_frame_get_original_producer( frame ) ) );
producer.lock();
}
void GlslManager::unlock_service( mlt_frame frame )
{
Mlt::Producer producer( mlt_producer_cut_parent( mlt_frame_get_original_producer( frame ) ) );
producer.unlock();
}
| Java |
package org.wingx;
import java.awt.Color;
import org.wings.*;
import org.wings.style.CSSAttributeSet;
import org.wings.style.CSSProperty;
import org.wings.style.CSSStyle;
import org.wings.style.CSSStyleSheet;
import org.wings.style.Selector;
import org.wings.style.Style;
public class XDivision
extends SContainer
implements LowLevelEventListener
{
String title;
SIcon icon;
/**
* Is the XDivision shaded?
*/
boolean shaded;
/**
* Is the title clickable? Default is false.
*/
protected boolean isTitleClickable = false;
public static final Selector SELECTOR_TITLE = new Selector("xdiv.title");
/**
* Creates a XDivision instance with the specified LayoutManager
* @param l the LayoutManager
*/
public XDivision(SLayoutManager l) {
super(l);
}
/**
* Creates a XDivision instance
*/
public XDivision() {
}
public XDivision(String title) {
this.title = title;
}
/**
* Returns the title of the XDivision.
* @return String the title
*/
public String getTitle() {
return title;
}
/**
* Sets the title of the XDivision.
* @param title the title
*/
public void setTitle(String title) {
String oldVal = this.title;
reloadIfChange(this.title, title);
this.title = title;
propertyChangeSupport.firePropertyChange("title", oldVal, this.title);
}
/**
* Sets the title-font of the XDivision.
* @param titleFont the font for the title
*/
public void setTitleFont( org.wings.SFont titleFont) {
SFont oldVal = this.getTitleFont();
CSSAttributeSet attributes = CSSStyleSheet.getAttributes(titleFont);
Style style = getDynamicStyle(SELECTOR_TITLE);
if (style == null) {
addDynamicStyle(new CSSStyle(SELECTOR_TITLE, attributes));
}
else {
style.remove(CSSProperty.FONT);
style.remove(CSSProperty.FONT_FAMILY);
style.remove(CSSProperty.FONT_SIZE);
style.remove(CSSProperty.FONT_STYLE);
style.remove(CSSProperty.FONT_WEIGHT);
style.putAll(attributes);
}
propertyChangeSupport.firePropertyChange("titleFont", oldVal, this.getTitleFont());
}
/**
* Returns the title-font of the XDivision.
* @return SFont the font for the title
*/
public SFont getTitleFont() {
return dynamicStyles == null || dynamicStyles.get(SELECTOR_TITLE) == null ? null : CSSStyleSheet.getFont((CSSAttributeSet) dynamicStyles.get(SELECTOR_TITLE));
}
/**
* Sets the title-color of the XDivision.
* @param titleColor the color for the title
*/
public void setTitleColor( Color titleColor ) {
Color oldVal = this.getTitleColor();
setAttribute( SELECTOR_TITLE, CSSProperty.COLOR, CSSStyleSheet.getAttribute( titleColor ) );
propertyChangeSupport.firePropertyChange("titleColor", oldVal, this.getTitleColor());
}
/**
* Returns the title-color of the XDivision.
* @return titleColor the color for the title
*/
public Color getTitleColor() {
return dynamicStyles == null || dynamicStyles.get(SELECTOR_TITLE) == null ? null : CSSStyleSheet.getForeground((CSSAttributeSet) dynamicStyles.get(SELECTOR_TITLE));
}
/**
* Determines whether or not the title is clickable.
* @param clickable true if the title is clickable
*/
public void setTitleClickable( boolean clickable ) {
boolean oldVal = this.isTitleClickable;
this.isTitleClickable = clickable;
propertyChangeSupport.firePropertyChange("titleClickable", oldVal, this.isTitleClickable);
}
/**
* Returns true if the title is clickable.
* @return boolean true if the title is clickable
*/
public boolean isTitleClickable() {
return this.isTitleClickable;
}
public SIcon getIcon() {
return icon;
}
public void setIcon(SIcon icon) {
SIcon oldVal = this.icon;
reloadIfChange(this.icon, icon);
this.icon = icon;
propertyChangeSupport.firePropertyChange("icon", oldVal, this.icon);
}
/**
* Returns true if the XDivision is shaded.
* @return boolean true if the XDivision is shaded
*/
public boolean isShaded() {
return shaded;
}
/**
* Determines whether or not the XDivision is shaded.
* @param shaded true if the XDivision is shaded
*/
public void setShaded(boolean shaded) {
if (this.shaded != shaded) {
reload();
this.shaded = shaded;
propertyChangeSupport.firePropertyChange("shaded", !this.shaded, this.shaded);
setRecursivelyVisible(isRecursivelyVisible());
}
}
@Override
public void processLowLevelEvent(String name, String... values) {
if (values.length == 1 && "t".equals(values[0])) {
setShaded(!shaded);
}
/*
TODO: first focusable component
if (!shaded && getComponentCount() > 0)
getComponent(0).requestFocus();
else
requestFocus();
*/
}
@Override
public void fireIntermediateEvents() {
}
@Override
public boolean isEpochCheckEnabled() {
return false;
}
@Override
protected boolean isShowingChildren() {
return !shaded;
}
}
| Java |
/*
* $Id: IpWatch.java 3905 2008-07-28 13:55:03Z uckelman $
*
* Copyright (c) 2007-2008 by Rodney Kinney
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Library General Public
* License (LGPL) as published by the Free Software Foundation.
*
* This library is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
* Library General Public License for more details.
*
* You should have received a copy of the GNU Library General Public
* License along with this library; if not, copies are available
* at http://www.opensource.org.
*/
package VASSAL.chat.peer2peer;
import java.beans.PropertyChangeEvent;
import java.beans.PropertyChangeListener;
import java.beans.PropertyChangeSupport;
import java.net.InetAddress;
import java.net.UnknownHostException;
public class IpWatch implements Runnable {
private PropertyChangeSupport propSupport = new PropertyChangeSupport(this);
private String currentIp;
private long wait = 1000;
public IpWatch(long waitInterval) {
wait = waitInterval;
currentIp = findIp();
}
public IpWatch() {
this(1000);
}
public void addPropertyChangeListener(PropertyChangeListener l) {
propSupport.addPropertyChangeListener(l);
}
public void run() {
while (true) {
String newIp = findIp();
propSupport.firePropertyChange("address", currentIp, newIp); //$NON-NLS-1$
currentIp = newIp;
try {
Thread.sleep(wait);
}
catch (InterruptedException ex) {
}
}
}
public String getCurrentIp() {
return currentIp;
}
private String findIp() {
try {
InetAddress a[] = InetAddress.getAllByName(InetAddress.getLocalHost().getHostName());
final StringBuilder buff = new StringBuilder();
for (int i = 0; i < a.length; ++i) {
buff.append(a[i].getHostAddress());
if (i < a.length - 1) {
buff.append(","); //$NON-NLS-1$
}
}
return buff.toString();
}
// FIXME: review error message
catch (UnknownHostException e) {
return null;
}
}
public static void main(String[] args) {
IpWatch w = new IpWatch();
w.addPropertyChangeListener(new PropertyChangeListener() {
public void propertyChange(PropertyChangeEvent evt) {
System.out.println("Address = " + evt.getNewValue()); //$NON-NLS-1$
}
});
System.out.println("Address = " + w.getCurrentIp()); //$NON-NLS-1$
new Thread(w).start();
}
}
| Java |
/**
* Copyright (C) 2013 Rohan Padhye
*
* This library is free software: you can redistribute it and/or modify
* it under the terms of the GNU Lesser General Public License as
* published by the Free Software Foundation, either version 2.1 of the
* License, or (at your option) any later version.
*
* This library is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU Lesser General Public License for more details.
*
* You should have received a copy of the GNU Lesser General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*
*/
package vasco.soot.examples;
import java.util.Map;
import org.junit.Test;
import soot.Local;
import soot.PackManager;
import soot.SceneTransformer;
import soot.SootMethod;
import soot.Transform;
import soot.Unit;
import vasco.DataFlowSolution;
import vasco.soot.examples.SignAnalysis.Sign;
/**
* A Soot {@link SceneTransformer} for performing {@link SignAnalysis}.
*
* @author Rohan Padhye
*/
public class SignTest extends SceneTransformer {
private SignAnalysis analysis;
@Override
protected void internalTransform(String arg0, @SuppressWarnings("rawtypes") Map arg1) {
analysis = new SignAnalysis();
analysis.doAnalysis();
DataFlowSolution<Unit,Map<Local,Sign>> solution = analysis.getMeetOverValidPathsSolution();
System.out.println("----------------------------------------------------------------");
for (SootMethod sootMethod : analysis.getMethods()) {
System.out.println(sootMethod);
for (Unit unit : sootMethod.getActiveBody().getUnits()) {
System.out.println("----------------------------------------------------------------");
System.out.println(unit);
System.out.println("IN: " + formatConstants(solution.getValueBefore(unit)));
System.out.println("OUT: " + formatConstants(solution.getValueAfter(unit)));
}
System.out.println("----------------------------------------------------------------");
}
}
public static String formatConstants(Map<Local, Sign> value) {
if (value == null) {
return "";
}
StringBuffer sb = new StringBuffer();
for (Map.Entry<Local,Sign> entry : value.entrySet()) {
Local local = entry.getKey();
Sign sign = entry.getValue();
if (sign != null) {
sb.append("(").append(local).append(": ").append(sign.toString()).append(") ");
}
}
return sb.toString();
}
public SignAnalysis getAnalysis() {
return analysis;
}
public static void main(String args[]) {
String classPath = System.getProperty("java.class.path");
String mainClass = null;
/* ------------------- OPTIONS ---------------------- */
try {
int i=0;
while(true){
if (args[i].equals("-cp")) {
classPath = args[i+1];
i += 2;
} else {
mainClass = args[i];
i++;
break;
}
}
if (i != args.length || mainClass == null)
throw new Exception();
} catch (Exception e) {
System.err.println("Usage: java SignTest [-cp CLASSPATH] MAIN_CLASS");
System.exit(1);
}
String[] sootArgs = {
"-cp", classPath, "-pp",
"-w", "-app",
"-keep-line-number",
"-keep-bytecode-offset",
"-p", "jb", "use-original-names",
"-p", "cg", "implicit-entry:false",
"-p", "cg.spark", "enabled",
"-p", "cg.spark", "simulate-natives",
"-p", "cg", "safe-forname",
"-p", "cg", "safe-newinstance",
"-main-class", mainClass,
"-f", "none", mainClass
};
SignTest sgn = new SignTest();
PackManager.v().getPack("wjtp").add(new Transform("wjtp.sgn", sgn));
soot.Main.main(sootArgs);
}
@Test
public void testSignAnalysis() {
// TODO: Compare output with an ideal (expected) output
SignTest.main(new String[]{"vasco.tests.SignTestCase"});
}
}
| Java |
/****************************************************************************
**
** Copyright (C) 2009 Nokia Corporation and/or its subsidiary(-ies).
** All rights reserved.
** Contact: Nokia Corporation (qt-info@nokia.com)
**
** This file is part of the Qt Mobility Components.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial Usage
** Licensees holding valid Qt Commercial licenses may use this file in
** accordance with the Qt Commercial License Agreement provided with
** the Software or, alternatively, in accordance with the terms
** contained in a written agreement between you and Nokia.
**
** GNU Lesser General Public License Usage
** Alternatively, this file may be used under the terms of the GNU Lesser
** General Public License version 2.1 as published by the Free Software
** Foundation and appearing in the file LICENSE.LGPL included in the
** packaging of this file. Please review the following information to
** ensure the GNU Lesser General Public License version 2.1 requirements
** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
**
** In addition, as a special exception, Nokia gives you certain additional
** rights. These rights are described in the Nokia Qt LGPL Exception
** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
**
** GNU General Public License Usage
** Alternatively, this file may be used under the terms of the GNU
** General Public License version 3.0 as published by the Free Software
** Foundation and appearing in the file LICENSE.GPL included in the
** packaging of this file. Please review the following information to
** ensure the GNU General Public License version 3.0 requirements will be
** met: http://www.gnu.org/copyleft/gpl.html.
**
** If you are unsure which license is appropriate for your use, please
** contact the sales department at qt-sales@nokia.com.
** $QT_END_LICENSE$
**
****************************************************************************/
#ifndef S60CCAMERAENGINE_H
#define S60CCAMERAENGINE_H
// INCLUDES
#include <e32base.h>
#include <ecam.h> // for MCameraObserver(2)
#ifdef S60_CAM_AUTOFOCUS_SUPPORT
#include <ccamautofocus.h> // for CCamAutoFocus, MCamAutoFocusObserver
#endif
// FORWARD DECLARATIONS
class MCameraEngineObserver;
class MCameraEngineImageCaptureObserver;
class MAdvancedSettingsObserver;
class MCameraViewfinderObserver;
/*
* CameraEngine handling ECam operations needed.
*/
NONSHARABLE_CLASS( CCameraEngine ) : public CBase,
public MCameraObserver,
public MCameraObserver2
#ifdef S60_CAM_AUTOFOCUS_SUPPORT
,public MCamAutoFocusObserver
#endif
{
public: // Enums
enum TCameraEngineState
{
EEngineNotReady = 0, // 0 - No resources reserved
EEngineInitializing, // 1 - Reserving and Powering On
EEngineIdle, // 2 - Reseved and Powered On
EEngineCapturing, // 3 - Capturing Still Image
EEngineFocusing // 4 - Focusing
};
public: // Constructor & Destructor
static CCameraEngine* NewL( TInt aCameraHandle,
TInt aPriority,
MCameraEngineObserver* aObserver );
~CCameraEngine();
public:
/**
* External Advanced Settings callback observer.
*/
void SetAdvancedObserver(MAdvancedSettingsObserver *aAdvancedSettingsObserver);
/**
* External Image Capture callback observer.
*/
void SetImageCaptureObserver(MCameraEngineImageCaptureObserver *aImageCaptureObserver);
/**
* External Viewfinder callback observer.
*/
void SetViewfinderObserver(MCameraViewfinderObserver *aViewfinderObserver);
/**
* Static function that returns the number of cameras on the device.
*/
static TInt CamerasAvailable();
/**
* Returns the index of the currently active camera device
*/
TInt currentCameraIndex() const { return iCameraIndex; }
/**
* Returns the current state (TCameraEngineState)
* of the camera engine.
*/
TCameraEngineState State() const { return iEngineState; }
/**
* Returns true if the camera has been reserved and
* powered on, and not recording or capturing image
*/
TBool IsCameraReady() const;
/**
* Returns whether DirectScreen ViewFinder is supported by the platform
*/
TBool IsDirectViewFinderSupported() const;
/**
* Returns true if the camera supports AutoFocus.
*/
TBool IsAutoFocusSupported() const;
/**
* Returns camera info
*/
TCameraInfo *cameraInfo();
/**
* Captures an image. When complete, observer will receive
* MceoCapturedDataReady() or MceoCapturedBitmapReady() callback,
* depending on which image format was used in PrepareL().
* @leave May leave with KErrNotReady if camera is not
* reserved or prepared for capture.
*/
void CaptureL();
/**
* Cancels ongoing image capture
*/
void cancelCapture();
/**
* Reserves and powers on the camera. When complete,
* observer will receive MceoCameraReady() callback
*
*/
void ReserveAndPowerOn();
/**
* Releases and powers off the camera
*
*/
void ReleaseAndPowerOff();
/**
* Prepares for image capture.
* @param aCaptureSize requested capture size. On return,
* contains the selected size (closest match)
* @param aFormat Image format to use. Default is JPEG with
* EXIF information as provided by the camera module
* @leave KErrNotSupported, KErrNoMemory, KErrNotReady
*/
void PrepareL( TSize& aCaptureSize,
CCamera::TFormat aFormat = CCamera::EFormatExif );
/**
* Starts the viewfinder. Observer will receive
* MceoViewFinderFrameReady() callbacks periodically.
* @param aSize requested viewfinder size. On return,
* contains the selected size.
*
* @leave KErrNotSupported is viewfinding with bitmaps is not
* supported, KErrNotReady
*/
void StartViewFinderL( TSize& aSize );
/**
* Stops the viewfinder if active.
*/
void StopViewFinder();
void StartDirectViewFinderL(RWsSession& aSession,
CWsScreenDevice& aScreenDevice,
RWindowBase& aWindow,
TRect& aSize);
/**
* Releases memory for the last received viewfinder frame.
* Client must call this in response to MceoViewFinderFrameReady()
* callback, after drawing the viewfinder frame is complete.
*/
void ReleaseViewFinderBuffer();
/**
* Releases memory for the last captured image.
* Client must call this in response to MceoCapturedDataReady()
* or MceoCapturedBitmapReady()callback, after processing the
* data/bitmap is complete.
*/
void ReleaseImageBuffer();
/**
* Starts focusing. Does nothing if AutoFocus is not supported.
* When complete, observer will receive MceoFocusComplete()
* callback.
* @leave KErrInUse, KErrNotReady
*/
void StartFocusL();
/**
* Cancels the ongoing focusing operation.
*/
void FocusCancel();
/**
* Gets a bitfield of supported focus ranges.
* @param aSupportedRanges a bitfield of either TAutoFocusRange
* (S60 3.0/3.1 devices) or TFocusRange (S60 3.2 and onwards) values
*/
void SupportedFocusRanges( TInt& aSupportedRanges ) const;
/**
* Sets the focus range
* @param aFocusRange one of the values returned by
* SupportedFocusRanges().
*/
void SetFocusRange( TInt aFocusRange );
/**
* Returns a pointer to CCamera object used by the engine.
* Allows getting access to additional functionality
* from CCamera - do not use for functionality already provided
* by CCameraEngine methods.
*/
CCamera* Camera() { return iCamera; }
protected: // Protected constructors
CCameraEngine();
CCameraEngine( TInt aCameraHandle,
TInt aPriority,
MCameraEngineObserver* aObserver );
void ConstructL();
protected: // MCameraObserver
/**
* From MCameraObserver
* Gets called when CCamera::Reserve() is completed.
* (V2: Called internally from HandleEvent)
*/
virtual void ReserveComplete(TInt aError);
/**
* From MCameraObserver.
* Gets called when CCamera::PowerOn() is completed.
* (V2: Called internally from HandleEvent)
*/
virtual void PowerOnComplete(TInt aError);
/**
* From MCameraObserver.
* Gets called when CCamera::StartViewFinderBitmapsL() is completed.
* (V2: Called internally from ViewFinderReady)
*/
virtual void ViewFinderFrameReady( CFbsBitmap& aFrame );
/**
* From MCameraObserver.
* Gets called when CCamera::CaptureImage() is completed.
*/
virtual void ImageReady( CFbsBitmap* aBitmap, HBufC8* aData, TInt aError );
/**
* From MCameraObserver.
* Video capture not implemented.
*/
virtual void FrameBufferReady( MFrameBuffer* /*aFrameBuffer*/, TInt /*aError*/ ) {}
protected: // MCameraObserver2
/**
* From MCameraObserver2
* Camera event handler
*/
virtual void HandleEvent(const TECAMEvent &aEvent);
/**
* From MCameraObserver2
* Notifies the client of new viewfinder data
*/
virtual void ViewFinderReady(MCameraBuffer &aCameraBuffer, TInt aError);
/**
* From MCameraObserver2
* Notifies the client of a new captured image
*/
virtual void ImageBufferReady(MCameraBuffer &aCameraBuffer, TInt aError);
/**
* From MCameraObserver2
* Video capture not implemented.
*/
virtual void VideoBufferReady(MCameraBuffer& /*aCameraBuffer*/, TInt /*aError*/) {}
protected: // MCamAutoFocusObserver
/**
* From MCamAutoFocusObserver.
* Delivers notification of completion of auto focus initialisation to
* an interested party.
* @param aError Reason for completion of focus request.
*/
virtual void InitComplete( TInt aError );
/**
* From MCamAutoFocusObserver.
* Gets called when CCamAutoFocus::AttemptOptimisedFocusL() is
* completed.
* (V2: Called internally from HandleEvent)
*/
virtual void OptimisedFocusComplete( TInt aError );
private: // Internal functions
/**
* Internal function to handle ImageReady callbacks from
* both observer (V1 & V2) interfaces
*/
void HandleImageReady(const TInt aError, const bool isBitmap);
private: // Data
CCamera *iCamera;
MCameraEngineObserver *iObserver;
MCameraEngineImageCaptureObserver *iImageCaptureObserver;
MAdvancedSettingsObserver *iAdvancedSettingsObserver;
MCameraViewfinderObserver *iViewfinderObserver;
MCameraBuffer *iViewFinderBuffer;
/*
* Following pointers are for the image buffers:
* * Makes buffering of 2 concurrent image buffers possible
*/
MCameraBuffer *iImageBuffer1;
MCameraBuffer *iImageBuffer2;
TDesC8 *iImageData1;
TDesC8 *iImageData2;
CFbsBitmap *iImageBitmap1;
CFbsBitmap *iImageBitmap2;
TInt iCameraIndex;
TInt iPriority;
TCameraEngineState iEngineState;
TCameraInfo iCameraInfo;
CCamera::TFormat iImageCaptureFormat;
bool iNew2LImplementation;
int iLatestImageBufferIndex; // 0 = Buffer1, 1 = Buffer2
#ifdef S60_CAM_AUTOFOCUS_SUPPORT
CCamAutoFocus* iAutoFocus;
CCamAutoFocus::TAutoFocusRange iAFRange;
#endif // S60_CAM_AUTOFOCUS_SUPPORT
};
#endif // S60CCAMERAENGINE_H
| Java |
<?php return header("HTTP/1.0 404 Not Found"); exit(); //Negar navegação | Deny navigation ?>{"who":"self","uniqid":"112155911efbb463150.09462133","number":74,"group":{"a":"8.61714409","b":"0.21359590","c":"2.62739917"},"unid":15,"collection":{"item":{"group":{"test":{"0":51,"1":2,"2":5,"gnulid":999}},"id":"$2y$10$b6bdf540lpjxsd0hgrtlx.emg\/pkce5laa.ul\/n1cc5qhl4voffou"}},"id":95} | Java |
#include "clar_libgit2.h"
#include "git2/sys/repository.h"
#include "fileops.h"
#include "ignore.h"
#include "status_helpers.h"
#include "posix.h"
#include "util.h"
#include "path.h"
static void cleanup_new_repo(void *path)
{
cl_fixture_cleanup((char *)path);
}
void test_status_worktree_init__cannot_retrieve_the_status_of_a_bare_repository(void)
{
git_repository *repo;
unsigned int status = 0;
cl_git_pass(git_repository_open(&repo, cl_fixture("testrepo.git")));
cl_assert_equal_i(GIT_EBAREREPO, git_status_file(&status, repo, "dummy"));
git_repository_free(repo);
}
void test_status_worktree_init__first_commit_in_progress(void)
{
git_repository *repo;
git_index *index;
status_entry_single result;
cl_set_cleanup(&cleanup_new_repo, "getting_started");
cl_git_pass(git_repository_init(&repo, "getting_started", 0));
cl_git_mkfile("getting_started/testfile.txt", "content\n");
memset(&result, 0, sizeof(result));
cl_git_pass(git_status_foreach(repo, cb_status__single, &result));
cl_assert_equal_i(1, result.count);
cl_assert(result.status == GIT_STATUS_WT_NEW);
cl_git_pass(git_repository_index(&index, repo));
cl_git_pass(git_index_add_bypath(index, "testfile.txt"));
cl_git_pass(git_index_write(index));
memset(&result, 0, sizeof(result));
cl_git_pass(git_status_foreach(repo, cb_status__single, &result));
cl_assert_equal_i(1, result.count);
cl_assert(result.status == GIT_STATUS_INDEX_NEW);
git_index_free(index);
git_repository_free(repo);
}
void test_status_worktree_init__status_file_without_index_or_workdir(void)
{
git_repository *repo;
unsigned int status = 0;
git_index *index;
cl_git_pass(p_mkdir("wd", 0777));
cl_git_pass(git_repository_open(&repo, cl_fixture("testrepo.git")));
cl_git_pass(git_repository_set_workdir(repo, "wd", false));
cl_git_pass(git_index_open(&index, "empty-index"));
cl_assert_equal_i(0, (int)git_index_entrycount(index));
git_repository_set_index(repo, index);
cl_git_pass(git_status_file(&status, repo, "branch_file.txt"));
cl_assert_equal_i(GIT_STATUS_INDEX_DELETED, status);
git_repository_free(repo);
git_index_free(index);
cl_git_pass(p_rmdir("wd"));
}
static void fill_index_wth_head_entries(git_repository *repo, git_index *index)
{
git_oid oid;
git_commit *commit;
git_tree *tree;
cl_git_pass(git_reference_name_to_id(&oid, repo, "HEAD"));
cl_git_pass(git_commit_lookup(&commit, repo, &oid));
cl_git_pass(git_commit_tree(&tree, commit));
cl_git_pass(git_index_read_tree(index, tree));
cl_git_pass(git_index_write(index));
git_tree_free(tree);
git_commit_free(commit);
}
void test_status_worktree_init__status_file_with_clean_index_and_empty_workdir(void)
{
git_repository *repo;
unsigned int status = 0;
git_index *index;
cl_git_pass(p_mkdir("wd", 0777));
cl_git_pass(git_repository_open(&repo, cl_fixture("testrepo.git")));
cl_git_pass(git_repository_set_workdir(repo, "wd", false));
cl_git_pass(git_index_open(&index, "my-index"));
fill_index_wth_head_entries(repo, index);
git_repository_set_index(repo, index);
cl_git_pass(git_status_file(&status, repo, "branch_file.txt"));
cl_assert_equal_i(GIT_STATUS_WT_DELETED, status);
git_repository_free(repo);
git_index_free(index);
cl_git_pass(p_rmdir("wd"));
cl_git_pass(p_unlink("my-index"));
}
void test_status_worktree_init__bracket_in_filename(void)
{
git_repository *repo;
git_index *index;
status_entry_single result;
unsigned int status_flags;
int error;
#define FILE_WITH_BRACKET "LICENSE[1].md"
#define FILE_WITHOUT_BRACKET "LICENSE1.md"
cl_set_cleanup(&cleanup_new_repo, "with_bracket");
cl_git_pass(git_repository_init(&repo, "with_bracket", 0));
cl_git_mkfile("with_bracket/" FILE_WITH_BRACKET, "I have a bracket in my name\n");
/* file is new to working directory */
memset(&result, 0, sizeof(result));
cl_git_pass(git_status_foreach(repo, cb_status__single, &result));
cl_assert_equal_i(1, result.count);
cl_assert(result.status == GIT_STATUS_WT_NEW);
cl_git_pass(git_status_file(&status_flags, repo, FILE_WITH_BRACKET));
cl_assert(status_flags == GIT_STATUS_WT_NEW);
/* ignore the file */
cl_git_rewritefile("with_bracket/.gitignore", "*.md\n.gitignore\n");
memset(&result, 0, sizeof(result));
cl_git_pass(git_status_foreach(repo, cb_status__single, &result));
cl_assert_equal_i(2, result.count);
cl_assert(result.status == GIT_STATUS_IGNORED);
cl_git_pass(git_status_file(&status_flags, repo, FILE_WITH_BRACKET));
cl_assert(status_flags == GIT_STATUS_IGNORED);
/* don't ignore the file */
cl_git_rewritefile("with_bracket/.gitignore", ".gitignore\n");
memset(&result, 0, sizeof(result));
cl_git_pass(git_status_foreach(repo, cb_status__single, &result));
cl_assert_equal_i(2, result.count);
cl_assert(result.status == GIT_STATUS_WT_NEW);
cl_git_pass(git_status_file(&status_flags, repo, FILE_WITH_BRACKET));
cl_assert(status_flags == GIT_STATUS_WT_NEW);
/* add the file to the index */
cl_git_pass(git_repository_index(&index, repo));
cl_git_pass(git_index_add_bypath(index, FILE_WITH_BRACKET));
cl_git_pass(git_index_write(index));
memset(&result, 0, sizeof(result));
cl_git_pass(git_status_foreach(repo, cb_status__single, &result));
cl_assert_equal_i(2, result.count);
cl_assert(result.status == GIT_STATUS_INDEX_NEW);
cl_git_pass(git_status_file(&status_flags, repo, FILE_WITH_BRACKET));
cl_assert(status_flags == GIT_STATUS_INDEX_NEW);
/* Create file without bracket */
cl_git_mkfile("with_bracket/" FILE_WITHOUT_BRACKET, "I have no bracket in my name!\n");
cl_git_pass(git_status_file(&status_flags, repo, FILE_WITHOUT_BRACKET));
cl_assert(status_flags == GIT_STATUS_WT_NEW);
cl_git_pass(git_status_file(&status_flags, repo, "LICENSE\\[1\\].md"));
cl_assert(status_flags == GIT_STATUS_INDEX_NEW);
cl_git_pass(git_status_file(&status_flags, repo, FILE_WITH_BRACKET));
git_index_free(index);
git_repository_free(repo);
}
void test_status_worktree_init__space_in_filename(void)
{
git_repository *repo;
git_index *index;
status_entry_single result;
unsigned int status_flags;
#define FILE_WITH_SPACE "LICENSE - copy.md"
cl_set_cleanup(&cleanup_new_repo, "with_space");
cl_git_pass(git_repository_init(&repo, "with_space", 0));
cl_git_mkfile("with_space/" FILE_WITH_SPACE, "I have a space in my name\n");
/* file is new to working directory */
memset(&result, 0, sizeof(result));
cl_git_pass(git_status_foreach(repo, cb_status__single, &result));
cl_assert_equal_i(1, result.count);
cl_assert(result.status == GIT_STATUS_WT_NEW);
cl_git_pass(git_status_file(&status_flags, repo, FILE_WITH_SPACE));
cl_assert(status_flags == GIT_STATUS_WT_NEW);
/* ignore the file */
cl_git_rewritefile("with_space/.gitignore", "*.md\n.gitignore\n");
memset(&result, 0, sizeof(result));
cl_git_pass(git_status_foreach(repo, cb_status__single, &result));
cl_assert_equal_i(2, result.count);
cl_assert(result.status == GIT_STATUS_IGNORED);
cl_git_pass(git_status_file(&status_flags, repo, FILE_WITH_SPACE));
cl_assert(status_flags == GIT_STATUS_IGNORED);
/* don't ignore the file */
cl_git_rewritefile("with_space/.gitignore", ".gitignore\n");
memset(&result, 0, sizeof(result));
cl_git_pass(git_status_foreach(repo, cb_status__single, &result));
cl_assert_equal_i(2, result.count);
cl_assert(result.status == GIT_STATUS_WT_NEW);
cl_git_pass(git_status_file(&status_flags, repo, FILE_WITH_SPACE));
cl_assert(status_flags == GIT_STATUS_WT_NEW);
/* add the file to the index */
cl_git_pass(git_repository_index(&index, repo));
cl_git_pass(git_index_add_bypath(index, FILE_WITH_SPACE));
cl_git_pass(git_index_write(index));
memset(&result, 0, sizeof(result));
cl_git_pass(git_status_foreach(repo, cb_status__single, &result));
cl_assert_equal_i(2, result.count);
cl_assert(result.status == GIT_STATUS_INDEX_NEW);
cl_git_pass(git_status_file(&status_flags, repo, FILE_WITH_SPACE));
cl_assert(status_flags == GIT_STATUS_INDEX_NEW);
git_index_free(index);
git_repository_free(repo);
}
static int cb_status__expected_path(const char *p, unsigned int s, void *payload)
{
const char *expected_path = (const char *)payload;
GIT_UNUSED(s);
if (payload == NULL)
cl_fail("Unexpected path");
cl_assert_equal_s(expected_path, p);
return 0;
}
void test_status_worktree_init__disable_pathspec_match(void)
{
git_repository *repo;
git_status_options opts = GIT_STATUS_OPTIONS_INIT;
char *file_with_bracket = "LICENSE[1].md",
*imaginary_file_with_bracket = "LICENSE[1-2].md";
cl_set_cleanup(&cleanup_new_repo, "pathspec");
cl_git_pass(git_repository_init(&repo, "pathspec", 0));
cl_git_mkfile("pathspec/LICENSE[1].md", "screaming bracket\n");
cl_git_mkfile("pathspec/LICENSE1.md", "no bracket\n");
opts.flags = GIT_STATUS_OPT_INCLUDE_UNTRACKED |
GIT_STATUS_OPT_DISABLE_PATHSPEC_MATCH;
opts.pathspec.count = 1;
opts.pathspec.strings = &file_with_bracket;
cl_git_pass(
git_status_foreach_ext(repo, &opts, cb_status__expected_path,
file_with_bracket)
);
/* Test passing a pathspec matching files in the workdir. */
/* Must not match because pathspecs are disabled. */
opts.pathspec.strings = &imaginary_file_with_bracket;
cl_git_pass(
git_status_foreach_ext(repo, &opts, cb_status__expected_path, NULL)
);
git_repository_free(repo);
}
void test_status_worktree_init__new_staged_file_must_handle_crlf(void)
{
git_repository *repo;
git_index *index;
unsigned int status;
cl_set_cleanup(&cleanup_new_repo, "getting_started");
cl_git_pass(git_repository_init(&repo, "getting_started", 0));
/* Ensure that repo has core.autocrlf=true */
cl_repo_set_bool(repo, "core.autocrlf", true);
cl_git_mkfile("getting_started/testfile.txt", "content\r\n"); /* Content with CRLF */
cl_git_pass(git_repository_index(&index, repo));
cl_git_pass(git_index_add_bypath(index, "testfile.txt"));
cl_git_pass(git_index_write(index));
cl_git_pass(git_status_file(&status, repo, "testfile.txt"));
cl_assert_equal_i(GIT_STATUS_INDEX_NEW, status);
git_index_free(index);
git_repository_free(repo);
}
| Java |
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<!-- NewPage -->
<html lang="en">
<head>
<!-- Generated by javadoc (1.8.0_40) on Wed Feb 10 11:30:31 CST 2016 -->
<title>CurrentTenantIdentifierResolver (Hibernate JavaDocs)</title>
<meta name="date" content="2016-02-10">
<link rel="stylesheet" type="text/css" href="../../../../stylesheet.css" title="Style">
<script type="text/javascript" src="../../../../script.js"></script>
</head>
<body>
<script type="text/javascript"><!--
try {
if (location.href.indexOf('is-external=true') == -1) {
parent.document.title="CurrentTenantIdentifierResolver (Hibernate JavaDocs)";
}
}
catch(err) {
}
//-->
var methods = {"i0":6,"i1":6};
var tabs = {65535:["t0","All Methods"],2:["t2","Instance Methods"],4:["t3","Abstract Methods"]};
var altColor = "altColor";
var rowColor = "rowColor";
var tableTab = "tableTab";
var activeTableTab = "activeTableTab";
</script>
<noscript>
<div>JavaScript is disabled on your browser.</div>
</noscript>
<!-- ========= START OF TOP NAVBAR ======= -->
<div class="topNav"><a name="navbar.top">
<!-- -->
</a>
<div class="skipNav"><a href="#skip.navbar.top" title="Skip navigation links">Skip navigation links</a></div>
<a name="navbar.top.firstrow">
<!-- -->
</a>
<ul class="navList" title="Navigation">
<li><a href="../../../../overview-summary.html">Overview</a></li>
<li><a href="package-summary.html">Package</a></li>
<li class="navBarCell1Rev">Class</li>
<li><a href="class-use/CurrentTenantIdentifierResolver.html">Use</a></li>
<li><a href="package-tree.html">Tree</a></li>
<li><a href="../../../../deprecated-list.html">Deprecated</a></li>
<li><a href="../../../../index-all.html">Index</a></li>
<li><a href="../../../../help-doc.html">Help</a></li>
</ul>
</div>
<div class="subNav">
<ul class="navList">
<li><a href="../../../../org/hibernate/context/spi/CurrentSessionContext.html" title="interface in org.hibernate.context.spi"><span class="typeNameLink">Prev Class</span></a></li>
<li>Next Class</li>
</ul>
<ul class="navList">
<li><a href="../../../../index.html?org/hibernate/context/spi/CurrentTenantIdentifierResolver.html" target="_top">Frames</a></li>
<li><a href="CurrentTenantIdentifierResolver.html" target="_top">No Frames</a></li>
</ul>
<ul class="navList" id="allclasses_navbar_top">
<li><a href="../../../../allclasses-noframe.html">All Classes</a></li>
</ul>
<div>
<script type="text/javascript"><!--
allClassesLink = document.getElementById("allclasses_navbar_top");
if(window==top) {
allClassesLink.style.display = "block";
}
else {
allClassesLink.style.display = "none";
}
//-->
</script>
</div>
<div>
<ul class="subNavList">
<li>Summary: </li>
<li>Nested | </li>
<li>Field | </li>
<li>Constr | </li>
<li><a href="#method.summary">Method</a></li>
</ul>
<ul class="subNavList">
<li>Detail: </li>
<li>Field | </li>
<li>Constr | </li>
<li><a href="#method.detail">Method</a></li>
</ul>
</div>
<a name="skip.navbar.top">
<!-- -->
</a></div>
<!-- ========= END OF TOP NAVBAR ========= -->
<!-- ======== START OF CLASS DATA ======== -->
<div class="header">
<div class="subTitle">org.hibernate.context.spi</div>
<h2 title="Interface CurrentTenantIdentifierResolver" class="title">Interface CurrentTenantIdentifierResolver</h2>
</div>
<div class="contentContainer">
<div class="description">
<ul class="blockList">
<li class="blockList">
<hr>
<br>
<pre>public interface <span class="typeNameLabel">CurrentTenantIdentifierResolver</span></pre>
<div class="block">A callback registered with the <a href="../../../../org/hibernate/SessionFactory.html" title="interface in org.hibernate"><code>SessionFactory</code></a> that is responsible for resolving the
current tenant identifier for use with <a href="../../../../org/hibernate/context/spi/CurrentSessionContext.html" title="interface in org.hibernate.context.spi"><code>CurrentSessionContext</code></a> and
<a href="../../../../org/hibernate/SessionFactory.html#getCurrentSession--"><code>SessionFactory.getCurrentSession()</code></a></div>
</li>
</ul>
</div>
<div class="summary">
<ul class="blockList">
<li class="blockList">
<!-- ========== METHOD SUMMARY =========== -->
<ul class="blockList">
<li class="blockList"><a name="method.summary">
<!-- -->
</a>
<h3>Method Summary</h3>
<table class="memberSummary" border="0" cellpadding="3" cellspacing="0" summary="Method Summary table, listing methods, and an explanation">
<caption><span id="t0" class="activeTableTab"><span>All Methods</span><span class="tabEnd"> </span></span><span id="t2" class="tableTab"><span><a href="javascript:show(2);">Instance Methods</a></span><span class="tabEnd"> </span></span><span id="t3" class="tableTab"><span><a href="javascript:show(4);">Abstract Methods</a></span><span class="tabEnd"> </span></span></caption>
<tr>
<th class="colFirst" scope="col">Modifier and Type</th>
<th class="colLast" scope="col">Method and Description</th>
</tr>
<tr id="i0" class="altColor">
<td class="colFirst"><code><a href="http://download.oracle.com/javase/6/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a></code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/hibernate/context/spi/CurrentTenantIdentifierResolver.html#resolveCurrentTenantIdentifier--">resolveCurrentTenantIdentifier</a></span>()</code>
<div class="block">Resolve the current tenant identifier.</div>
</td>
</tr>
<tr id="i1" class="rowColor">
<td class="colFirst"><code>boolean</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/hibernate/context/spi/CurrentTenantIdentifierResolver.html#validateExistingCurrentSessions--">validateExistingCurrentSessions</a></span>()</code>
<div class="block">Should we validate that the tenant identifier on "current sessions" that already exist when
<a href="../../../../org/hibernate/context/spi/CurrentSessionContext.html#currentSession--"><code>CurrentSessionContext.currentSession()</code></a> is called matches the value returned here from
<a href="../../../../org/hibernate/context/spi/CurrentTenantIdentifierResolver.html#resolveCurrentTenantIdentifier--"><code>resolveCurrentTenantIdentifier()</code></a>?</div>
</td>
</tr>
</table>
</li>
</ul>
</li>
</ul>
</div>
<div class="details">
<ul class="blockList">
<li class="blockList">
<!-- ============ METHOD DETAIL ========== -->
<ul class="blockList">
<li class="blockList"><a name="method.detail">
<!-- -->
</a>
<h3>Method Detail</h3>
<a name="resolveCurrentTenantIdentifier--">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>resolveCurrentTenantIdentifier</h4>
<pre><a href="http://download.oracle.com/javase/6/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> resolveCurrentTenantIdentifier()</pre>
<div class="block">Resolve the current tenant identifier.</div>
<dl>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>The current tenant identifier</dd>
</dl>
</li>
</ul>
<a name="validateExistingCurrentSessions--">
<!-- -->
</a>
<ul class="blockListLast">
<li class="blockList">
<h4>validateExistingCurrentSessions</h4>
<pre>boolean validateExistingCurrentSessions()</pre>
<div class="block">Should we validate that the tenant identifier on "current sessions" that already exist when
<a href="../../../../org/hibernate/context/spi/CurrentSessionContext.html#currentSession--"><code>CurrentSessionContext.currentSession()</code></a> is called matches the value returned here from
<a href="../../../../org/hibernate/context/spi/CurrentTenantIdentifierResolver.html#resolveCurrentTenantIdentifier--"><code>resolveCurrentTenantIdentifier()</code></a>?</div>
<dl>
<dt><span class="returnLabel">Returns:</span></dt>
<dd><code>true</code> indicates that the extra validation will be performed; <code>false</code> indicates it will not.</dd>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../../../../org/hibernate/context/TenantIdentifierMismatchException.html" title="class in org.hibernate.context"><code>TenantIdentifierMismatchException</code></a></dd>
</dl>
</li>
</ul>
</li>
</ul>
</li>
</ul>
</div>
</div>
<!-- ========= END OF CLASS DATA ========= -->
<!-- ======= START OF BOTTOM NAVBAR ====== -->
<div class="bottomNav"><a name="navbar.bottom">
<!-- -->
</a>
<div class="skipNav"><a href="#skip.navbar.bottom" title="Skip navigation links">Skip navigation links</a></div>
<a name="navbar.bottom.firstrow">
<!-- -->
</a>
<ul class="navList" title="Navigation">
<li><a href="../../../../overview-summary.html">Overview</a></li>
<li><a href="package-summary.html">Package</a></li>
<li class="navBarCell1Rev">Class</li>
<li><a href="class-use/CurrentTenantIdentifierResolver.html">Use</a></li>
<li><a href="package-tree.html">Tree</a></li>
<li><a href="../../../../deprecated-list.html">Deprecated</a></li>
<li><a href="../../../../index-all.html">Index</a></li>
<li><a href="../../../../help-doc.html">Help</a></li>
</ul>
</div>
<div class="subNav">
<ul class="navList">
<li><a href="../../../../org/hibernate/context/spi/CurrentSessionContext.html" title="interface in org.hibernate.context.spi"><span class="typeNameLink">Prev Class</span></a></li>
<li>Next Class</li>
</ul>
<ul class="navList">
<li><a href="../../../../index.html?org/hibernate/context/spi/CurrentTenantIdentifierResolver.html" target="_top">Frames</a></li>
<li><a href="CurrentTenantIdentifierResolver.html" target="_top">No Frames</a></li>
</ul>
<ul class="navList" id="allclasses_navbar_bottom">
<li><a href="../../../../allclasses-noframe.html">All Classes</a></li>
</ul>
<div>
<script type="text/javascript"><!--
allClassesLink = document.getElementById("allclasses_navbar_bottom");
if(window==top) {
allClassesLink.style.display = "block";
}
else {
allClassesLink.style.display = "none";
}
//-->
</script>
</div>
<div>
<ul class="subNavList">
<li>Summary: </li>
<li>Nested | </li>
<li>Field | </li>
<li>Constr | </li>
<li><a href="#method.summary">Method</a></li>
</ul>
<ul class="subNavList">
<li>Detail: </li>
<li>Field | </li>
<li>Constr | </li>
<li><a href="#method.detail">Method</a></li>
</ul>
</div>
<a name="skip.navbar.bottom">
<!-- -->
</a></div>
<!-- ======== END OF BOTTOM NAVBAR ======= -->
<p class="legalCopy"><small>Copyright © 2001-2016 <a href="http://redhat.com">Red Hat, Inc.</a> All Rights Reserved.</small></p>
</body>
</html>
| Java |
/***************************************************************************
**
** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies).
** All rights reserved.
** Contact: Nokia Corporation (directui@nokia.com)
**
** This file is part of libmeegotouch.
**
** If you have questions regarding the use of this file, please contact
** Nokia at directui@nokia.com.
**
** This library is free software; you can redistribute it and/or
** modify it under the terms of the GNU Lesser General Public
** License version 2.1 as published by the Free Software Foundation
** and appearing in the file LICENSE.LGPL included in the packaging
** of this file.
**
****************************************************************************/
#ifndef MABSTRACTWIDGETANIMATION_H
#define MABSTRACTWIDGETANIMATION_H
#include <mabstractwidgetanimationstyle.h>
#include <mparallelanimationgroup.h>
class MAbstractWidgetAnimationPrivate;
/*!
\class MAbstractWidgetAnimation
\brief MAbstractWidgetAnimation class is a base class for all widget animations.
*/
class M_CORE_EXPORT MAbstractWidgetAnimation : public MParallelAnimationGroup
{
Q_OBJECT
Q_DECLARE_PRIVATE(MAbstractWidgetAnimation)
M_ANIMATION_GROUP(MAbstractWidgetAnimationStyle)
protected:
/*!
\brief Constructs the widget animation.
This constructor is meant to be used inside the libmeegotouch to share the
private data class pointer.
*/
MAbstractWidgetAnimation(MAbstractWidgetAnimationPrivate *dd, QObject *parent);
public:
/*!
* This enum defines the direction of the widget animation.
*/
enum TransitionDirection {
In, //!< transitioning into the screen/display
Out //!< transitioning out of the screen/display
};
/*!
\brief Constructs the widget animation.
*/
MAbstractWidgetAnimation(QObject *parent = NULL);
/*!
\brief Destructs the widget animation.
*/
virtual ~MAbstractWidgetAnimation();
/*!
Restores the properties of the target widget back to their
original state, before the animation changed them.
*/
virtual void restoreTargetWidgetState() = 0;
virtual void setTargetWidget(MWidgetController *widget);
virtual void setTransitionDirection(MAbstractWidgetAnimation::TransitionDirection direction) = 0;
MWidgetController *targetWidget();
const MWidgetController *targetWidget() const;
};
#endif
| Java |
/**************************************************************************
**
** This file is part of Qt Creator
**
** Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies).
**
** Contact: Nokia Corporation (qt-info@nokia.com)
**
** Commercial Usage
**
** Licensees holding valid Qt Commercial licenses may use this file in
** accordance with the Qt Commercial License Agreement provided with the
** Software or, alternatively, in accordance with the terms contained in
** a written agreement between you and Nokia.
**
** GNU Lesser General Public License Usage
**
** Alternatively, this file may be used under the terms of the GNU Lesser
** General Public License version 2.1 as published by the Free Software
** Foundation and appearing in the file LICENSE.LGPL included in the
** packaging of this file. Please review the following information to
** ensure the GNU Lesser General Public License version 2.1 requirements
** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
**
** If you are unsure which license is appropriate for your use, please
** contact the sales department at http://qt.nokia.com/contact.
**
**************************************************************************/
#ifndef OPENWITHDIALOG_H
#define OPENWITHDIALOG_H
#include <QtGui/QDialog>
#include "ui_openwithdialog.h"
namespace Core {
class ICore;
namespace Internal {
// Present the user with a file name and a list of available
// editor kinds to choose from.
class OpenWithDialog : public QDialog, public Ui::OpenWithDialog
{
Q_OBJECT
public:
OpenWithDialog(const QString &fileName, QWidget *parent);
void setEditors(const QStringList &);
QString editor() const;
void setCurrentEditor(int index);
private slots:
void currentItemChanged(QListWidgetItem *, QListWidgetItem *);
private:
void setOkButtonEnabled(bool);
};
} // namespace Internal
} // namespace Core
#endif // OPENWITHDIALOG_H
| Java |
/*****************************************************************
JADE - Java Agent DEvelopment Framework is a framework to develop
multi-agent systems in compliance with the FIPA specifications.
Copyright (C) 2000 CSELT S.p.A.
GNU Lesser General Public License
This library is free software; you can redistribute it and/or
modify it under the terms of the GNU Lesser General Public
License as published by the Free Software Foundation,
version 2.1 of the License.
This library is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
Lesser General Public License for more details.
You should have received a copy of the GNU Lesser General Public
License along with this library; if not, write to the
Free Software Foundation, Inc., 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA.
*****************************************************************/
package examples.O2AInterface;
import jade.core.Runtime;
import jade.core.Profile;
import jade.core.ProfileImpl;
import jade.wrapper.*;
/**
* This class shows an example of how to run JADE as a library from an external program
* and in particular how to start an agent and interact with it by means of the
* Object-to-Agent (O2A) interface.
*
* @author Giovanni Iavarone - Michele Izzo
*/
public class O2AInterfaceExample {
public static void main(String[] args) throws StaleProxyException, InterruptedException {
// Get a hold to the JADE runtime
Runtime rt = Runtime.instance();
// Launch the Main Container (with the administration GUI on top) listening on port 8888
System.out.println(">>>>>>>>>>>>>>> Launching the platform Main Container...");
Profile pMain = new ProfileImpl(null, 8888, null);
pMain.setParameter(Profile.GUI, "true");
ContainerController mainCtrl = rt.createMainContainer(pMain);
// Create and start an agent of class CounterAgent
System.out.println(">>>>>>>>>>>>>>> Starting up a CounterAgent...");
AgentController agentCtrl = mainCtrl.createNewAgent("CounterAgent", CounterAgent.class.getName(), new Object[0]);
agentCtrl.start();
// Wait a bit
System.out.println(">>>>>>>>>>>>>>> Wait a bit...");
Thread.sleep(10000);
try {
// Retrieve O2A interface CounterManager1 exposed by the agent to make it activate the counter
System.out.println(">>>>>>>>>>>>>>> Activate counter");
CounterManager1 o2a1 = agentCtrl.getO2AInterface(CounterManager1.class);
o2a1.activateCounter();
// Wait a bit
System.out.println(">>>>>>>>>>>>>>> Wait a bit...");
Thread.sleep(30000);
// Retrieve O2A interface CounterManager2 exposed by the agent to make it de-activate the counter
System.out.println(">>>>>>>>>>>>>>> Deactivate counter");
CounterManager2 o2a2 = agentCtrl.getO2AInterface(CounterManager2.class);
o2a2.deactivateCounter();
}
catch (StaleProxyException e) {
e.printStackTrace();
}
}
} | Java |
using Microsoft.VisualStudio.TestTools.UnitTesting;
using System;
using System.Collections.Generic;
using System.Diagnostics;
using System.Linq;
using System.Threading;
using System.Threading.Tasks;
namespace PubComp.Caching.Core.UnitTests
{
// http://softwareonastring.com/502/testing-every-implementer-of-an-interface-with-the-same-tests-using-mstest
[TestClass]
public abstract class CacheInterfaceTests
{
protected abstract ICache GetCache(string name);
protected abstract ICache GetCacheWithSlidingExpiration(string name, TimeSpan slidingExpiration);
protected abstract ICache GetCacheWithExpirationFromAdd(string name, TimeSpan expirationFromAdd);
protected abstract ICache GetCacheWithAbsoluteExpiration(string name, DateTimeOffset expireAt);
private IDisposable cacheDirectives;
[TestInitialize]
public void TestInitialize()
{
cacheDirectives = CacheDirectives.SetScope(CacheMethod.GetOrSet, DateTimeOffset.UtcNow);
}
[TestCleanup]
public void TestCleanup()
{
cacheDirectives?.Dispose();
cacheDirectives = null;
}
[TestMethod]
public void TestCacheStruct()
{
var cache = GetCacheWithSlidingExpiration("cache1", TimeSpan.FromMinutes(2));
cache.ClearAll();
int hits = 0;
Func<int> getter = () => { hits++; return hits; };
int result;
result = cache.Get("key", getter);
Assert.AreEqual(1, hits);
Assert.AreEqual(1, result);
result = cache.Get("key", getter);
Assert.AreEqual(1, hits);
Assert.AreEqual(1, result);
}
[TestMethod]
public void TestCacheObject()
{
var cache = GetCacheWithSlidingExpiration("cache1", TimeSpan.FromMinutes(2));
cache.ClearAll();
int hits = 0;
Func<string> getter = () => { hits++; return hits.ToString(); };
string result;
result = cache.Get("key", getter);
Assert.AreEqual(1, hits);
Assert.AreEqual("1", result);
result = cache.Get("key", getter);
Assert.AreEqual(1, hits);
Assert.AreEqual("1", result);
}
[TestMethod]
public async Task TestCacheObjectAsync()
{
var cache = GetCacheWithSlidingExpiration("cache1", TimeSpan.FromMinutes(2));
cache.ClearAll();
int hits = 0;
Func<Task<string>> getter = async () => { hits++; return hits.ToString(); };
string result;
result = await cache.GetAsync("key", getter);
Assert.AreEqual(1, hits);
Assert.AreEqual("1", result);
result = await cache.GetAsync("key", getter);
Assert.AreEqual(1, hits);
Assert.AreEqual("1", result);
}
[TestMethod]
public void TestCacheNull()
{
var cache = GetCacheWithSlidingExpiration("cache1", TimeSpan.FromMinutes(2));
cache.ClearAll();
int misses = 0;
Func<string> getter = () => { misses++; return null; };
string result;
result = cache.Get("key", getter);
Assert.AreEqual(1, misses);
Assert.AreEqual(null, result);
result = cache.Get("key", getter);
Assert.AreEqual(1, misses);
Assert.AreEqual(null, result);
}
[TestMethod]
public void TestCacheTimeToLive_FromInsert()
{
var ttl = 3;
int misses = 0;
string result;
var stopwatch = new Stopwatch();
Func<string> getter = () => { misses++; return misses.ToString(); };
var cache = GetCacheWithExpirationFromAdd("insert-expire-cache", TimeSpan.FromSeconds(ttl));
cache.ClearAll();
stopwatch.Start();
result = cache.Get("key", getter);
Assert.AreEqual(1, misses);
Assert.AreEqual("1", result);
result = cache.Get("key", getter);
Assert.AreEqual(1, misses);
Assert.AreEqual("1", result);
CacheTestTools.AssertValueDoesntChangeWithin(cache, "key", "1", getter, stopwatch, ttl);
// Should expire within TTL+60sec from insert
CacheTestTools.AssertValueDoesChangeWithin(cache, "key", "1", getter, stopwatch, 60.1);
result = cache.Get("key", getter);
Assert.AreNotEqual(1, misses);
Assert.AreNotEqual("1", result);
}
[TestMethod]
public void TestCacheTimeToLive_Sliding()
{
return;
var ttl = 3;
int misses = 0;
string result;
var stopwatch = new Stopwatch();
Func<string> getter = () => { misses++; return misses.ToString(); };
var cache = GetCacheWithSlidingExpiration("sliding-expire-cache", TimeSpan.FromSeconds(ttl));
cache.ClearAll();
stopwatch.Start();
result = cache.Get("key", getter);
DateTime insertTime = DateTime.Now;
Assert.AreEqual(1, misses);
Assert.AreEqual("1", result);
result = cache.Get("key", getter);
Assert.AreEqual(1, misses);
Assert.AreEqual("1", result);
CacheTestTools.AssertValueDoesntChangeWithin(cache, "key", "1", getter, stopwatch, ttl + 60);
// Should expire within TTL+60sec from last access
CacheTestTools.AssertValueDoesChangeAfter(cache, "key", "1", getter, stopwatch, ttl + 60.1);
result = cache.Get("key", getter);
Assert.AreNotEqual(1, misses);
Assert.AreNotEqual("1", result);
}
[TestMethod]
public void TestCacheTimeToLive_Constant()
{
var ttl = 3;
int misses = 0;
string result;
var stopwatch = new Stopwatch();
Func<string> getter = () => { misses++; return misses.ToString(); };
var expireAt = DateTime.Now.AddSeconds(ttl);
stopwatch.Start();
var cache = GetCacheWithAbsoluteExpiration("constant-expire", expireAt);
cache.ClearAll();
result = cache.Get("key", getter);
DateTime insertTime = DateTime.Now;
Assert.AreEqual(1, misses);
Assert.AreEqual("1", result);
result = cache.Get("key", getter);
Assert.AreEqual(1, misses);
Assert.AreEqual("1", result);
CacheTestTools.AssertValueDoesntChangeWithin(cache, "key", "1", getter, stopwatch, ttl);
// Should expire within TTL+60sec from insert
CacheTestTools.AssertValueDoesChangeWithin(cache, "key", "1", getter, stopwatch, 60.1);
result = cache.Get("key", getter);
Assert.AreNotEqual(1, misses);
Assert.AreNotEqual("1", result);
}
[TestMethod]
[Ignore("Diagnose manually the memory consumption")]
public void LotsOfClearAll()
{
var cache = GetCache("cache1");
for (var i = 0; i < 5000; i++)
{
cache.ClearAll();
}
Thread.Sleep(1000);
GC.Collect();
Thread.Sleep(1000);
for (var i = 0; i < 5000; i++)
{
cache.ClearAll();
}
}
[TestMethod]
[Ignore("Diagnose manually the memory consumption")]
public async Task LotsOfClearAsyncAll()
{
var cache = GetCache("cache1");
for (var i = 0; i < 5000; i++)
{
await cache.ClearAllAsync().ConfigureAwait(false);
}
await Task.Delay(1000);
GC.Collect();
await Task.Delay(1000);
for (var i = 0; i < 5000; i++)
{
await cache.ClearAllAsync().ConfigureAwait(false);
}
}
[TestMethod]
public void TestCacheTryGet()
{
var cache = GetCache("cache1");
cache.ClearAll();
cache.Set("key", "1");
var result = cache.TryGet<string>("key", out var value);
Assert.AreEqual("1", value);
Assert.IsTrue(result);
}
[TestMethod]
public void TestCacheTryGet_NotFound()
{
var cache = GetCache("cache1");
cache.ClearAll();
cache.Set("key", "1");
var result = cache.TryGet<string>("wrongKey", out var value);
Assert.AreEqual(null, value);
Assert.IsFalse(result);
}
[TestMethod]
public async Task TestCacheTryGetAsync()
{
var cache = GetCache("cache1");
cache.ClearAll();
cache.Set("key", "1");
var result = await cache.TryGetAsync<string>("key");
Assert.AreEqual("1", result.Value);
Assert.IsTrue(result.WasFound);
}
[TestMethod]
public async Task TestCacheTryGetAsync_NotFound()
{
var cache = GetCache("cache1");
cache.ClearAll();
cache.Set("key", "1");
var result = await cache.TryGetAsync<string>("wrongKey");
Assert.AreEqual(null, result.Value);
Assert.IsFalse(result.WasFound);
}
[TestMethod]
public void TestCacheGetTwice()
{
var cache = GetCache("cache1");
cache.ClearAll();
int misses = 0;
Func<string> getter = () => { misses++; return misses.ToString(); };
string result;
result = cache.Get("key", getter);
Assert.AreEqual("1", result);
result = cache.Get("key", getter);
Assert.AreEqual("1", result);
}
[TestMethod]
public void TestCacheSetTwice()
{
var cache = GetCache("cache1");
cache.ClearAll();
int misses = 0;
Func<string> getter = () => { misses++; return misses.ToString(); };
string result;
bool wasFound;
cache.Set("key", getter());
wasFound = cache.TryGet("key", out result);
Assert.AreEqual(true, wasFound);
Assert.AreEqual("1", result);
cache.Set("key", getter());
wasFound = cache.TryGet("key", out result);
Assert.AreEqual(true, wasFound);
Assert.AreEqual("2", result);
}
[TestMethod]
public void TestCacheUpdated()
{
var cache = GetCacheWithSlidingExpiration("cache1", TimeSpan.FromMinutes(2));
cache.ClearAll();
cache.Set("key", 1);
var result = cache.Get("key", () => 0);
Assert.AreEqual(1, result);
cache.Set("key", 2);
result = cache.Get("key", () => 0);
Assert.AreEqual(2, result);
}
[TestMethod]
public void TestCacheBasic()
{
var cache = GetCacheWithSlidingExpiration("cache1", TimeSpan.FromMinutes(2));
cache.ClearAll();
int misses = 0;
Func<string> getter = () => { misses++; return misses.ToString(); };
string result;
result = cache.Get("key1", getter);
Assert.AreEqual(1, misses);
Assert.AreEqual("1", result);
result = cache.Get("key2", getter);
Assert.AreEqual(2, misses);
Assert.AreEqual("2", result);
cache.ClearAll();
result = cache.Get("key1", getter);
Assert.AreEqual(3, misses);
Assert.AreEqual("3", result);
result = cache.Get("key2", getter);
Assert.AreEqual(4, misses);
Assert.AreEqual("4", result);
}
[TestMethod]
public void TestCacheTwoCaches()
{
var cache1 = GetCacheWithSlidingExpiration("cache1", TimeSpan.FromMinutes(2));
cache1.ClearAll();
var cache2 = GetCacheWithSlidingExpiration("cache2", TimeSpan.FromMinutes(2));
cache2.ClearAll();
int misses1 = 0;
Func<string> getter1 = () => { misses1++; return misses1.ToString(); };
int misses2 = 0;
Func<string> getter2 = () => { misses2++; return misses2.ToString(); };
string result;
result = cache1.Get("key1", getter1);
Assert.AreEqual(1, misses1);
Assert.AreEqual("1", result);
result = cache1.Get("key2", getter1);
Assert.AreEqual(2, misses1);
Assert.AreEqual("2", result);
result = cache2.Get("key1", getter2);
Assert.AreEqual(1, misses2);
Assert.AreEqual("1", result);
result = cache2.Get("key2", getter2);
Assert.AreEqual(2, misses2);
Assert.AreEqual("2", result);
cache1.ClearAll();
result = cache1.Get("key1", getter1);
Assert.AreEqual(3, misses1);
Assert.AreEqual("3", result);
result = cache1.Get("key2", getter1);
Assert.AreEqual(4, misses1);
Assert.AreEqual("4", result);
result = cache2.Get("key1", getter2);
Assert.AreEqual(2, misses2);
Assert.AreEqual("1", result);
result = cache2.Get("key2", getter2);
Assert.AreEqual(2, misses2);
Assert.AreEqual("2", result);
}
}
}
| Java |
import sys
import time
sleep = time.sleep
if sys.platform == 'win32':
time = time.clock
else:
time = time.time
| Java |
/*
* Copyright (C) 2007 Sebastian Sauer <mail@dipe.org>
*
* This file is part of SuperKaramba.
*
* SuperKaramba is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
* (at your option) any later version.
*
* SuperKaramba is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with SuperKaramba; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
*/
#include "plasmaengine.h"
#include <kdebug.h>
#include <plasma/dataenginemanager.h>
#if 0
#include <QFile>
#include <QTextStream>
#endif
/// \internal helper function that translates plasma data into a QVariantMap.
QVariantMap dataToMap(Plasma::DataEngine::Data data)
{
QVariantMap map;
Plasma::DataEngine::DataIterator it(data);
while( it.hasNext() ) {
it.next();
map.insert(it.key(), it.value());
}
return map;
}
/*
/// \internal helper function that translates a QVariantMap into plasma data.
Plasma::DataEngine::Data mapToData(QVariantMap map)
{
Plasma::DataEngine::Data data;
for(QVariantMap::Iterator it = map.begin(); it != map.end(); ++it)
data.insert(it.key(), it.value());
return data;
}
*/
/*****************************************************************************************
* PlasmaSensorConnector
*/
/// \internal d-pointer class.
class PlasmaSensorConnector::Private
{
public:
Meter* meter;
QString source;
QString format;
};
PlasmaSensorConnector::PlasmaSensorConnector(Meter *meter, const QString& source) : QObject(meter), d(new Private)
{
//kDebug()<<"PlasmaSensorConnector Ctor"<<endl;
setObjectName(source);
d->meter = meter;
d->source = source;
}
PlasmaSensorConnector::~PlasmaSensorConnector()
{
//kDebug()<<"PlasmaSensorConnector Dtor"<<endl;
delete d;
}
Meter* PlasmaSensorConnector::meter() const
{
return d->meter;
}
QString PlasmaSensorConnector::source() const
{
return d->source;
}
void PlasmaSensorConnector::setSource(const QString& source)
{
d->source = source;
}
QString PlasmaSensorConnector::format() const
{
return d->format;
}
void PlasmaSensorConnector::setFormat(const QString& format)
{
d->format = format;
}
void PlasmaSensorConnector::dataUpdated(const QString& source, const Plasma::DataEngine::Data &data)
{
//kDebug()<<"PlasmaSensorConnector::dataUpdated d->source="<<d->source<<" source="<<source<<endl;
if( d->source.isEmpty() ) {
emit sourceUpdated(source, dataToMap(data));
return;
}
if( source != d->source ) {
return;
}
QString v = d->format;
Plasma::DataEngine::DataIterator it(data);
while( it.hasNext() ) {
it.next();
QString s = QString("%%1").arg( it.key() );
v.replace(s,it.value().toString());
}
d->meter->setValue(v);
}
/*****************************************************************************************
* PlasmaSensor
*/
/// \internal d-pointer class.
class PlasmaSensor::Private
{
public:
Plasma::DataEngine* engine;
QString engineName;
explicit Private() : engine(0) {}
};
PlasmaSensor::PlasmaSensor(int msec) : Sensor(msec), d(new Private)
{
kDebug()<<"PlasmaSensor Ctor"<<endl;
}
PlasmaSensor::~PlasmaSensor()
{
kDebug()<<"PlasmaSensor Dtor"<<endl;
delete d;
}
Plasma::DataEngine* PlasmaSensor::engineImpl() const
{
return d->engine;
}
void PlasmaSensor::setEngineImpl(Plasma::DataEngine* engine, const QString& engineName)
{
d->engine = engine;
d->engineName = engineName;
}
QString PlasmaSensor::engine()
{
return d->engine ? d->engineName : QString();
}
void PlasmaSensor::setEngine(const QString& name)
{
//kDebug()<<"PlasmaSensor::setEngine name="<<name<<endl;
if( d->engine ) {
disconnect(d->engine, SIGNAL(newSource(QString)), this, SIGNAL(sourceAdded(QString)));
disconnect(d->engine, SIGNAL(sourceRemoved(QString)), this, SIGNAL(sourceRemoved(QString)));
Plasma::DataEngineManager::self()->unloadEngine(d->engineName);
}
d->engineName.clear();
d->engine = Plasma::DataEngineManager::self()->engine(name);
if( ! d->engine || ! d->engine->isValid() ) {
d->engine = Plasma::DataEngineManager::self()->loadEngine(name);
if( ! d->engine || ! d->engine->isValid() ) {
kWarning()<<"PlasmaSensor::setEngine: No such engine: "<<name<<endl;
return;
}
}
d->engineName = name;
connect(d->engine, SIGNAL(newSource(QString)), this, SIGNAL(sourceAdded(QString)));
connect(d->engine, SIGNAL(sourceRemoved(QString)), this, SIGNAL(sourceRemoved(QString)));
//d->engine->setProperty("reportSeconds", true);
}
bool PlasmaSensor::isValid() const
{
return d->engine && d->engine->isValid();
}
QStringList PlasmaSensor::sources() const
{
return d->engine ? d->engine->sources() : QStringList();
}
QVariant PlasmaSensor::property(const QByteArray& name) const
{
return d->engine ? d->engine->property(name) : QVariant();
}
void PlasmaSensor::setProperty(const QByteArray& name, const QVariant& value)
{
if( d->engine )
d->engine->setProperty(name, value);
}
QVariantMap PlasmaSensor::query(const QString& source)
{
//kDebug()<<"PlasmaSensor::query"<<endl;
return d->engine ? dataToMap(d->engine->query(source)) : QVariantMap();
}
QObject* PlasmaSensor::connectSource(const QString& source, QObject* visualization)
{
//kDebug()<<"PlasmaSensor::connectSource source="<<source<<endl;
if( ! d->engine ) {
kWarning()<<"PlasmaSensor::connectSource: No engine"<<endl;
return 0;
}
if( Meter* m = dynamic_cast<Meter*>(visualization) ) {
PlasmaSensorConnector* c = new PlasmaSensorConnector(m, source);
d->engine->connectSource(source, c);
kDebug()<<"PlasmaSensor::connectSource meter, engine isValid="<<d->engine->isValid();
return c;
}
d->engine->connectSource(source, visualization ? visualization : this);
return 0;
}
void PlasmaSensor::disconnectSource(const QString& source, QObject* visualization)
{
//kDebug()<<"PlasmaSensor::disconnectSource"<<endl;
if( Meter* m = dynamic_cast<Meter*>(visualization) ) {
foreach(PlasmaSensorConnector* c, m->findChildren<PlasmaSensorConnector*>(source))
if( c->meter() == m )
delete c;
}
else if( d->engine ) {
d->engine->disconnectSource(source, visualization ? visualization : this);
}
else
kWarning()<<"PlasmaSensor::disconnectSource: No engine"<<endl;
}
void PlasmaSensor::update()
{
kDebug()<<"PlasmaSensor::update"<<endl;
/*TODO
foreach(QObject *it, *objList) {
SensorParams *sp = qobject_cast<SensorParams*>(it);
Meter *meter = sp->getMeter();
const QString format = sp->getParam("FORMAT");
//if (format.length() == 0) format = "%um";
//format.replace(QRegExp("%fmb", Qt::CaseInsensitive),QString::number((int)((totalMem - usedMemNoBuffers) / 1024.0 + 0.5)));
//meter->setValue(format);
}
*/
}
void PlasmaSensor::dataUpdated(const QString& source, Plasma::DataEngine::Data data)
{
//kDebug()<<"PlasmaSensor::dataUpdated source="<<source<<endl;
emit sourceUpdated(source, dataToMap(data));
}
#include "plasmaengine.moc"
| Java |
body {
font-family: verdana, arial, helvetica, sans-serif;
font-size: 63.125%; /* translate 1.0em to 10px, 1.5em to 15px, etc. */
}
#content {
margin:0 auto;
width: 980px;
text-align: left;
}
#identity {
padding: 25px 0;
}
#identity h1 {
font-size: 2.4em;
font-weight: normal;
color: #73736c;
}
p {
margin: 0 0 1em 0;
font-size: 1.3em;
line-height: 1.4em;
}
a {
color: #b31b1b;
text-decoration: none;
font-size: .9em;
}
a:visited {
color: #b37474;
}
a:hover {
color: #f00;
border-color: #f00;
}
a:active {
color: #b31b1b;
border-color: #e5cfcf;
}
hr {
display: none;
}
form {
margin: 0 0 15px 0;
padding: 0;
float: left;
}
.form-submit {
border: 1px solid #dbdbd2;
margin: 8px;
}
fieldset {
float: left;
margin: 0 auto;
padding: 1em 0 1.5em 0;
width: 35em;
}
.form-pair {
display: inline;
float: left;
margin: .5em .5em 0 .4em;
width: 28em;
}
.form-item {
float: left;
margin-top: 5px;
width: 8em;
font-size: 1.2em;
font-family: verdana, arial, helvetica, sans-serif;
line-height: 1.5em;
text-align: right;
}
.form-value {
float: right;
margin-top: 3px;
width: 16em;
font-size: 1.1em;
font-family: verdana, arial, helvetica, sans-serif;
line-height: 1.5em;
margin-right: 0px;
}
.input-submit, .input-reset {
font-family: verdana, arial, helvetica, sans-serif;
font-size: 1.1em;
border: 1px solid;
background: #f0eee4;
margin-top:0px;
}
.input-submit:hover{
background:#dbdbd2;
}
#offsetlinks ul {
float: left;
margin: 0 0 0 0;
padding: 0px 0 10px 0;
font-size: 1.3em;
line-height: 1.4em;
}
#offsetlinks ul li {
margin: 0 0 0 30em;
padding: 0 0 0 15px;/*was 30*/
list-style: none;
}
#footer {
margin: 0 auto;
padding: 5px 0 1em 0;
width: 68em;
font-size: .9em;
color: #73736c;
float: left;
margin-top: .5em;
}
#footer a {
font-size: 1.0em;
}
| Java |
tinymce.addI18n('it',{
"Cut": "Taglia",
"Heading 5": "Intestazione 5",
"Header 2": "Header 2",
"Your browser doesn't support direct access to the clipboard. Please use the Ctrl+X\/C\/V keyboard shortcuts instead.": "Il tuo browser non supporta l'accesso diretto negli Appunti. Per favore usa i tasti di scelta rapida Ctrl+X\/C\/V.",
"Heading 4": "Intestazione 4",
"Div": "Div",
"Heading 2": "Intestazione 2",
"Paste": "Incolla",
"Close": "Chiudi",
"Font Family": "Famiglia font",
"Pre": "Pre",
"Align right": "Allinea a Destra",
"New document": "Nuovo Documento",
"Blockquote": "Blockquote",
"Numbered list": "Elenchi Numerati",
"Heading 1": "Intestazione 1",
"Headings": "Intestazioni",
"Increase indent": "Aumenta Rientro",
"Formats": "Formattazioni",
"Headers": "Intestazioni",
"Select all": "Seleziona Tutto",
"Header 3": "Intestazione 3",
"Blocks": "Blocchi",
"Undo": "Indietro",
"Strikethrough": "Barrato",
"Bullet list": "Elenchi Puntati",
"Header 1": "Intestazione 1",
"Superscript": "Apice",
"Clear formatting": "Cancella Formattazione",
"Font Sizes": "Dimensioni font",
"Subscript": "Pedice",
"Header 6": "Intestazione 6",
"Redo": "Ripeti",
"Paragraph": "Paragrafo",
"Ok": "Ok",
"Bold": "Grassetto",
"Code": "Codice",
"Italic": "Corsivo",
"Align center": "Allinea al Cento",
"Header 5": "Intestazione 5",
"Heading 6": "Intestazione 6",
"Heading 3": "Intestazione 3",
"Decrease indent": "Riduci Rientro",
"Header 4": "Intestazione 4",
"Paste is now in plain text mode. Contents will now be pasted as plain text until you toggle this option off.": "Incolla \u00e8 in modalit\u00e0 testo normale. I contenuti sono incollati come testo normale se non disattivi l'opzione.",
"Underline": "Sottolineato",
"Cancel": "Annulla",
"Justify": "Giustifica",
"Inline": "Inlinea",
"Copy": "Copia",
"Align left": "Allinea a Sinistra",
"Visual aids": "Elementi Visivi",
"Lower Greek": "Greek Minore",
"Square": "Quadrato",
"Default": "Default",
"Lower Alpha": "Alpha Minore",
"Circle": "Cerchio",
"Disc": "Disco",
"Upper Alpha": "Alpha Superiore",
"Upper Roman": "Roman Superiore",
"Lower Roman": "Roman Minore",
"Name": "Nome",
"Anchor": "Fissa",
"You have unsaved changes are you sure you want to navigate away?": "Non hai salvato delle modifiche, sei sicuro di andartene?",
"Restore last draft": "Ripristina l'ultima bozza.",
"Special character": "Carattere Speciale",
"Source code": "Codice Sorgente",
"B": "B",
"R": "R",
"G": "G",
"Color": "Colore",
"Right to left": "Da Destra a Sinistra",
"Left to right": "Da Sinistra a Destra",
"Emoticons": "Emoction",
"Robots": "Robot",
"Document properties": "Propriet\u00e0 Documento",
"Title": "Titolo",
"Keywords": "Parola Chiave",
"Encoding": "Codifica",
"Description": "Descrizione",
"Author": "Autore",
"Fullscreen": "Schermo Intero",
"Horizontal line": "Linea Orizzontale",
"Horizontal space": "Spazio Orizzontale",
"Insert\/edit image": "Aggiungi\/Modifica Immagine",
"General": "Generale",
"Advanced": "Avanzato",
"Source": "Fonte",
"Border": "Bordo",
"Constrain proportions": "Mantieni Proporzioni",
"Vertical space": "Spazio Verticale",
"Image description": "Descrizione Immagine",
"Style": "Stile",
"Dimensions": "Dimenzioni",
"Insert image": "Inserisci immagine",
"Zoom in": "Ingrandisci",
"Contrast": "Contrasto",
"Back": "Indietro",
"Gamma": "Gamma",
"Flip horizontally": "Rifletti orizzontalmente",
"Resize": "Ridimensiona",
"Sharpen": "Contrasta",
"Zoom out": "Rimpicciolisci",
"Image options": "Opzioni immagine",
"Apply": "Applica",
"Brightness": "Luminosit\u00e0",
"Rotate clockwise": "Ruota in senso orario",
"Rotate counterclockwise": "Ruota in senso antiorario",
"Edit image": "Modifica immagine",
"Color levels": "Livelli colore",
"Crop": "Taglia",
"Orientation": "Orientamento",
"Flip vertically": "Rifletti verticalmente",
"Invert": "Inverti",
"Insert date\/time": "Inserisci Data\/Ora",
"Remove link": "Rimuovi link",
"Url": "Url",
"Text to display": "Testo da Visualizzare",
"Anchors": "Anchors",
"Insert link": "Inserisci il Link",
"New window": "Nuova Finestra",
"None": "No",
"The URL you entered seems to be an external link. Do you want to add the required http:\/\/ prefix?": "L'URL inserito sembra essere un collegamento esterno. Vuoi aggiungere il prefisso necessario http:\/\/?",
"Target": "Target",
"The URL you entered seems to be an email address. Do you want to add the required mailto: prefix?": "L'URL inserito sembra essere un indirizzo email. Vuoi aggiungere il prefisso necessario mailto:?",
"Insert\/edit link": "Inserisci\/Modifica Link",
"Insert\/edit video": "Inserisci\/Modifica Video",
"Poster": "Anteprima",
"Alternative source": "Alternativo",
"Paste your embed code below:": "Incolla il codice d'incorporamento qui:",
"Insert video": "Inserisci Video",
"Embed": "Incorporare",
"Nonbreaking space": "Spazio unificatore",
"Page break": "Interruzione di pagina",
"Paste as text": "incolla come testo",
"Preview": "Anteprima",
"Print": "Stampa",
"Save": "Salva",
"Could not find the specified string.": "Impossibile trovare la parola specifica.",
"Replace": "Sostituisci",
"Next": "Successivo",
"Whole words": "Parole Sbagliate",
"Find and replace": "Trova e Sostituisci",
"Replace with": "Sostituisci Con",
"Find": "Trova",
"Replace all": "Sostituisci Tutto",
"Match case": "Maiuscole\/Minuscole ",
"Prev": "Precedente",
"Spellcheck": "Controllo ortografico",
"Finish": "Termina",
"Ignore all": "Ignora Tutto",
"Ignore": "Ignora",
"Add to Dictionary": "Aggiungi al Dizionario",
"Insert row before": "Inserisci una Riga Prima",
"Rows": "Righe",
"Height": "Altezza",
"Paste row after": "Incolla una Riga Dopo",
"Alignment": "Allineamento",
"Border color": "Colore bordo",
"Column group": "Gruppo di Colonne",
"Row": "Riga",
"Insert column before": "Inserisci una Colonna Prima",
"Split cell": "Dividi Cella",
"Cell padding": "Padding della Cella",
"Cell spacing": "Spaziatura della Cella",
"Row type": "Tipo di Riga",
"Insert table": "Inserisci Tabella",
"Body": "Body",
"Caption": "Didascalia",
"Footer": "Footer",
"Delete row": "Cancella Riga",
"Paste row before": "Incolla una Riga Prima",
"Scope": "Campo",
"Delete table": "Cancella Tabella",
"H Align": "Allineamento H",
"Top": "In alto",
"Header cell": "cella d'intestazione",
"Column": "Colonna",
"Row group": "Gruppo di Righe",
"Cell": "Cella",
"Middle": "In mezzo",
"Cell type": "Tipo di Cella",
"Copy row": "Copia Riga",
"Row properties": "Propriet\u00e0 della Riga",
"Table properties": "Propiet\u00e0 della Tabella",
"Bottom": "In fondo",
"V Align": "Allineamento V",
"Header": "Header",
"Right": "Destra",
"Insert column after": "Inserisci una Colonna Dopo",
"Cols": "Colonne",
"Insert row after": "Inserisci una Riga Dopo",
"Width": "Larghezza",
"Cell properties": "Propiet\u00e0 della Cella",
"Left": "Sinistra",
"Cut row": "Taglia Riga",
"Delete column": "Cancella Colonna",
"Center": "Centro",
"Merge cells": "Unisci Cella",
"Insert template": "Inserisci Template",
"Templates": "Template",
"Background color": "Colore Background",
"Custom...": "Personalizzato...",
"Custom color": "Colore personalizzato",
"No color": "Nessun colore",
"Text color": "Colore Testo",
"Show blocks": "Mostra Blocchi",
"Show invisible characters": "Mostra Caratteri Invisibili",
"Words: {0}": "Parole: {0}",
"Insert": "Inserisci",
"File": "File",
"Edit": "Modifica",
"Rich Text Area. Press ALT-F9 for menu. Press ALT-F10 for toolbar. Press ALT-0 for help": "Rich Text Area. Premi ALT-F9 per il men\u00f9. Premi ALT-F10 per la barra degli strumenti. Premi ALT-0 per l'aiuto.",
"Tools": "Strumenti",
"View": "Visualizza",
"Table": "Tabella",
"Format": "Formato"
});
| Java |
/****************************************************************************
**
** Copyright (C) 2015 The Qt Company Ltd.
** Contact: http://www.qt.io/licensing
**
** This file is part of Qt Creator.
**
** Commercial License Usage
** Licensees holding valid commercial Qt licenses may use this file in
** accordance with the commercial license agreement provided with the
** Software or, alternatively, in accordance with the terms contained in
** a written agreement between you and The Qt Company. For licensing terms and
** conditions see http://www.qt.io/terms-conditions. For further information
** use the contact form at http://www.qt.io/contact-us.
**
** GNU Lesser General Public License Usage
** Alternatively, this file may be used under the terms of the GNU Lesser
** General Public License version 2.1 or version 3 as published by the Free
** Software Foundation and appearing in the file LICENSE.LGPLv21 and
** LICENSE.LGPLv3 included in the packaging of this file. Please review the
** following information to ensure the GNU Lesser General Public License
** requirements will be met: https://www.gnu.org/licenses/lgpl.html and
** http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
**
** In addition, as a special exception, The Qt Company gives you certain additional
** rights. These rights are described in The Qt Company LGPL Exception
** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
**
****************************************************************************/
#ifndef DIFFUTILS_H
#define DIFFUTILS_H
#include "diffeditor_global.h"
#include <QString>
#include <QMap>
#include <QTextEdit>
#include "texteditor/texteditorconstants.h"
namespace TextEditor { class FontSettings; }
namespace DiffEditor {
class Diff;
class DIFFEDITOR_EXPORT DiffFileInfo {
public:
DiffFileInfo() {}
DiffFileInfo(const QString &file) : fileName(file) {}
DiffFileInfo(const QString &file, const QString &type)
: fileName(file), typeInfo(type) {}
QString fileName;
QString typeInfo;
};
class DIFFEDITOR_EXPORT TextLineData {
public:
enum TextLineType {
TextLine,
Separator,
Invalid
};
TextLineData() : textLineType(Invalid) {}
TextLineData(const QString &txt) : textLineType(TextLine), text(txt) {}
TextLineData(TextLineType t) : textLineType(t) {}
TextLineType textLineType;
QString text;
/*
* <start position, end position>
* <-1, n> means this is a continuation from the previous line
* <n, -1> means this will be continued in the next line
* <-1, -1> the whole line is a continuation (from the previous line to the next line)
*/
QMap<int, int> changedPositions; // counting from the beginning of the line
};
class DIFFEDITOR_EXPORT RowData {
public:
RowData() : equal(false) {}
RowData(const TextLineData &l)
: leftLine(l), rightLine(l), equal(true) {}
RowData(const TextLineData &l, const TextLineData &r)
: leftLine(l), rightLine(r), equal(false) {}
TextLineData leftLine;
TextLineData rightLine;
bool equal;
};
class DIFFEDITOR_EXPORT ChunkData {
public:
ChunkData() : contextChunk(false),
leftStartingLineNumber(0), rightStartingLineNumber(0) {}
QList<RowData> rows;
bool contextChunk;
int leftStartingLineNumber;
int rightStartingLineNumber;
QString contextInfo;
};
class DIFFEDITOR_EXPORT FileData {
public:
enum FileOperation {
ChangeFile,
NewFile,
DeleteFile,
CopyFile,
RenameFile
};
FileData()
: fileOperation(ChangeFile),
binaryFiles(false),
lastChunkAtTheEndOfFile(false),
contextChunksIncluded(false) {}
FileData(const ChunkData &chunkData)
: fileOperation(ChangeFile),
binaryFiles(false),
lastChunkAtTheEndOfFile(false),
contextChunksIncluded(false) { chunks.append(chunkData); }
QList<ChunkData> chunks;
DiffFileInfo leftFileInfo;
DiffFileInfo rightFileInfo;
FileOperation fileOperation;
bool binaryFiles;
bool lastChunkAtTheEndOfFile;
bool contextChunksIncluded;
};
class DIFFEDITOR_EXPORT DiffUtils {
public:
enum PatchFormattingFlags {
AddLevel = 0x1, // Add 'a/' , '/b' for git am
GitFormat = AddLevel | 0x2, // Add line 'diff ..' as git does
};
static ChunkData calculateOriginalData(const QList<Diff> &leftDiffList,
const QList<Diff> &rightDiffList);
static FileData calculateContextData(const ChunkData &originalData,
int contextLinesNumber,
int joinChunkThreshold = 1);
static QString makePatchLine(const QChar &startLineCharacter,
const QString &textLine,
bool lastChunk,
bool lastLine);
static QString makePatch(const ChunkData &chunkData,
bool lastChunk = false);
static QString makePatch(const ChunkData &chunkData,
const QString &leftFileName,
const QString &rightFileName,
bool lastChunk = false);
static QString makePatch(const QList<FileData> &fileDataList,
unsigned formatFlags = 0);
static QList<FileData> readPatch(const QString &patch,
bool *ok = 0);
};
} // namespace DiffEditor
#endif // DIFFUTILS_H
| Java |
<html dir="LTR" xmlns:ndoc="urn:ndoc-schema">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<meta content="history" name="save" />
<meta name="vs_targetSchema" content="http://schemas.microsoft.com/intellisense/ie5" />
<title>EntLibLogger Constructor</title>
<xml>
</xml>
<link rel="stylesheet" type="text/css" href="MSDN.css" />
</head>
<body id="bodyID" class="dtBODY">
<div id="nsbanner">
<div id="bannerrow1">
<table class="bannerparthead" cellspacing="0">
<tr id="hdr">
<td class="runninghead">Common Logging 2.0 API Reference</td>
<td class="product">
</td>
</tr>
</table>
</div>
<div id="TitleRow">
<h1 class="dtH1">EntLibLogger Constructor</h1>
</div>
</div>
<div id="nstext">
<p> Initializes a new instance of the <a href="Common.Logging.EntLib41~Common.Logging.EntLib.EntLibLogger.html">EntLibLogger</a> class. </p>
<div class="syntax">
<span class="lang">[Visual Basic]</span>
<br />Public Sub New( _<br /> ByVal <i>category</i> As <a href="">String</a>, _<br /> ByVal <i>logWriter</i> As <a href="">LogWriter</a>, _<br /> ByVal <i>settings</i> As <a href="Common.Logging.EntLib41~Common.Logging.EntLib.EntLibLoggerSettings.html">EntLibLoggerSettings</a> _<br />)</div>
<div class="syntax">
<span class="lang">[C#]</span>
<br />
<a href="Common.Logging.EntLib41~Common.Logging.EntLib.EntLibLogger.html">EntLibLogger</a>(<br /> <a href="">string</a> <i>category</i>,<br /> <a href="">LogWriter</a> <i>logWriter</i>,<br /> <a href="Common.Logging.EntLib41~Common.Logging.EntLib.EntLibLoggerSettings.html">EntLibLoggerSettings</a> <i>settings</i><br />);</div>
<h4 class="dtH4">Parameters</h4>
<dl>
<dt>
<i>category</i>
</dt>
<dd>The category.</dd>
<dt>
<i>logWriter</i>
</dt>
<dd>the <a href="Common.Logging.EntLib41~Common.Logging.EntLib.EntLibLogger.LogWriter.html">LogWriter</a> to write log events to.</dd>
<dt>
<i>settings</i>
</dt>
<dd>the logger settings</dd>
</dl>
<h4 class="dtH4">See Also</h4>
<p>
<a href="Common.Logging.EntLib41~Common.Logging.EntLib.EntLibLogger.html">EntLibLogger Class</a> | <a href="Common.Logging.EntLib41~Common.Logging.EntLib.html">Common.Logging.EntLib Namespace</a></p>
<object type="application/x-oleobject" classid="clsid:1e2a7bd0-dab9-11d0-b93a-00c04fc99f9e" viewastext="true" style="display: none;">
<param name="Keyword" value="EntLibLogger class, constructor
 ">
</param>
</object>
<hr />
<div id="footer">
<p>
<a href="mailto:netcommon-developer@lists.sourceforge.net?subject=Common%20Logging%202.0%20API%20Reference%20Documentation%20Feedback:%20EntLibLogger Constructor ">Send comments on this topic.</a>
</p>
<p>
<a>© The Common Infrastructure Libraries for .NET Team 2009 All Rights Reserved.</a>
</p>
<p>Generated from assembly Common.Logging.EntLib41 [2.0.0.0] by <a href="http://ndoc3.sourceforget.net">NDoc3</a></p>
</div>
</div>
</body>
</html> | Java |
<?php
/**
* Naked Php is a framework that implements the Naked Objects pattern.
* @copyright Copyright (C) 2009 Giorgio Sironi
* @license http://www.gnu.org/licenses/lgpl-2.1.txt
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
* version 2.1 of the License, or (at your option) any later version.
*
* @category NakedPhp
* @package NakedPhp_MetaModel
*/
namespace NakedPhp\MetaModel;
class NakedObjectFeatureTypeTest extends \PHPUnit_Framework_TestCase
{
public function testOnlyEnumeratedValuesAreAllowed()
{
$this->assertEquals('OBJECT', NakedObjectFeatureType::OBJECT);
}
}
| Java |
# Authors: David Goodger; Gunnar Schwant
# Contact: goodger@users.sourceforge.net
# Revision: $Revision: 21817 $
# Date: $Date: 2005-07-21 13:39:57 -0700 (Thu, 21 Jul 2005) $
# Copyright: This module has been placed in the public domain.
# New language mappings are welcome. Before doing a new translation, please
# read <http://docutils.sf.net/docs/howto/i18n.html>. Two files must be
# translated for each language: one in docutils/languages, the other in
# docutils/parsers/rst/languages.
"""
German language mappings for language-dependent features of Docutils.
"""
__docformat__ = 'reStructuredText'
labels = {
'author': 'Autor',
'authors': 'Autoren',
'organization': 'Organisation',
'address': 'Adresse',
'contact': 'Kontakt',
'version': 'Version',
'revision': 'Revision',
'status': 'Status',
'date': 'Datum',
'dedication': 'Widmung',
'copyright': 'Copyright',
'abstract': 'Zusammenfassung',
'attention': 'Achtung!',
'caution': 'Vorsicht!',
'danger': '!GEFAHR!',
'error': 'Fehler',
'hint': 'Hinweis',
'important': 'Wichtig',
'note': 'Bemerkung',
'tip': 'Tipp',
'warning': 'Warnung',
'contents': 'Inhalt'}
"""Mapping of node class name to label text."""
bibliographic_fields = {
'autor': 'author',
'autoren': 'authors',
'organisation': 'organization',
'adresse': 'address',
'kontakt': 'contact',
'version': 'version',
'revision': 'revision',
'status': 'status',
'datum': 'date',
'copyright': 'copyright',
'widmung': 'dedication',
'zusammenfassung': 'abstract'}
"""German (lowcased) to canonical name mapping for bibliographic fields."""
author_separators = [';', ',']
"""List of separator strings for the 'Authors' bibliographic field. Tried in
order."""
| Java |
<?php
/**
* PHPExcel 读取插件类
*/
class PHPExcelReaderChajian extends Chajian{
protected function initChajian()
{
$this->Astr = 'A,B,C,D,E,F,G,H,I,J,K,L,M,N,O,P,Q,R,S,T,U,V,W,X,Y,Z,AA,AB,AC,AD,AE,AF,AG,AH,AI,AJ,AK,AL,AM,AN,AO,AP,AQ,AR,AS,AT,AU,AV,AW,AX,AY,AZ,BA,BB,BC,BD,BE,BF,BG,BH,BI,BJ,BK,BL,BM,BN,BO,BP,BQ,BR,BS,BT,BU,BV,BW,BX,BY,BZ,CA,CB,CC,CD,CE,CF,CG,CH,CI,CJ,CK,CL,CM,CN,CO,CP,CQ,CR,CS,CT,CU,CV,CW,CX,CY,CZ';
$this->A = explode(',', $this->Astr);
$this->AT = array('A'=>0,'B'=>1,'C'=>2,'D'=>3,'E'=>4,'F'=>5,'G'=>6,'H'=>7,'I'=>8,'J'=>9,'K'=>10,'L'=>11,'M'=>12,'N'=>13,'O'=>14,'P'=>15,'Q'=>16,'R'=>17,'S'=>18,'T'=>19,'U'=>20,'V'=>21,'W'=>22,'X'=>23,'Y'=>24,'Z'=>25,'AA'=>26,'AB'=>27,'AC'=>28,'AD'=>29,'AE'=>30,'AF'=>31,'AG'=>32,'AH'=>33,'AI'=>34,'AJ'=>35,'AK'=>36,'AL'=>37,'AM'=>38,'AN'=>39,'AO'=>40,'AP'=>41,'AQ'=>42,'AR'=>43,'AS'=>44,'AT'=>45,'AU'=>46,'AV'=>47,'AW'=>48,'AX'=>49,'AY'=>50,'AZ'=>51,'BA'=>52,'BB'=>53,'BC'=>54,'BD'=>55,'BE'=>56,'BF'=>57,'BG'=>58,'BH'=>59,'BI'=>60,'BJ'=>61,'BK'=>62,'BL'=>63,'BM'=>64,'BN'=>65,'BO'=>66,'BP'=>67,'BQ'=>68,'BR'=>69,'BS'=>70,'BT'=>71,'BU'=>72,'BV'=>73,'BW'=>74,'BX'=>75,'BY'=>76,'BZ'=>77,'CA'=>78,'CB'=>79,'CC'=>80,'CD'=>81,'CE'=>82,'CF'=>83,'CG'=>84,'CH'=>85,'CI'=>86,'CJ'=>87,'CK'=>88,'CL'=>89,'CM'=>90,'CN'=>91,'CO'=>92,'CP'=>93,'CQ'=>94,'CR'=>95,'CS'=>96,'CT'=>97,'CU'=>98,'CV'=>99,'CW'=>100,'CX'=>101,'CY'=>102,'CZ'=>103);
}
public function reader($filePath=null, $index=2)
{
if(file_exists(ROOT_PATH.'/include/PHPExcel/Reader/Excel2007.php'))include_once(ROOT_PATH.'/include/PHPExcel/Reader/Excel2007.php');
if(file_exists(ROOT_PATH.'/include/PHPExcel/Reader/Excel5.php'))include_once(ROOT_PATH.'/include/PHPExcel/Reader/Excel5.php');
$help = c('xinhu')->helpstr('phpexcel');
if(!class_exists('PHPExcel_Reader_Excel2007'))return '没有安装PHPExcel插件'.$help.'';
if($filePath==null)$filePath = $_FILES['file']['tmp_name'];
$PHPReader = new PHPExcel_Reader_Excel2007();
if(!$PHPReader->canRead($filePath)){
$PHPReader = new PHPExcel_Reader_Excel5();
if(!$PHPReader->canRead($filePath)){
return '不是正规的Excel文件'.$help.'';
}
}
$PHPExcel = $PHPReader->load($filePath);
$rows = array();
$sheet = $PHPExcel->getSheet(0); //第一个表
$allColumn = $sheet->getHighestColumn();
$allRow = $sheet->getHighestRow();
$allCell = $this->AT[$allColumn];
for($row = $index; $row <= $allRow; $row++){
$arr = array();
for($cell= 0; $cell<= $allCell; $cell++){
$val = $sheet->getCellByColumnAndRow($cell, $row)->getValue();
$arr[$this->A[$cell]] = $val;
}
$rows[] = $arr;
}
return $rows;
}
/**
导入到表
*/
public function importTable($table, $rows, $fields)
{
}
} | Java |
<!doctype html public "-//w3c//dtd html 4.0 transitional//en">
<html>
<head>
<meta http-equiv="Content-Type" content="Text/html; charset=iso-8859-1">
<meta name="Author" content = "misho" >
<meta name="GENERATOR" content="VBDOX [1.0.24]" >
<script SRC="linkcss.js"></script>
<script SRC="langref.js"></script>
<title>dx_GFX_class: DRAW_AdvMap</title>
</head>
<BODY TOPMARGIN="0">
<TABLE CLASS="buttonbarshade" CELLSPACING=0><TR><TD> </TD></TR></TABLE>
<TABLE CLASS="buttonbartable" CELLSPACING=0>
<TR ID="hdr"><TD CLASS="runninghead" NOWRAP>dx_GFX_class: DRAW_AdvMap</TD></TR>
</TABLE>
<!-- ============ METHOD ENTRY ============ -->
<H1>DRAW_AdvMap</H1>
<P>Función avanzada de <a href="dx_GFX_class.DRAW_MapEx.html">DRAW_MapEx</a>. Dibuja un
<a href="REF_Maps.html">grafico</a> con efectos
aplicándole perspectiva.
<PRE class=syntax><B><font color="darkblue"> Public</font><font color="darkblue"> Sub</font><b><i> DRAW_AdvMap</i></b>(
<b><i> Map</i></b><font color="darkblue"> As</font><font color="darkblue"> Long</font>,
<b><i> X</i></b><font color="darkblue"> As</font><font color="darkblue"> Long</font>,
<b><i> Y</i></b><font color="darkblue"> As</font><font color="darkblue"> Long</font>,
<b><i> Z</i></b><font color="darkblue"> As</font><font color="darkblue"> Long</font>,
<b><i> Width</i></b><font color="darkblue"> As</font><font color="darkblue"> Long</font>,
<i> Height</i><font color="darkblue"> As Long</font>,
<b><i> AlphaBlendMode</i></b><font color="darkblue"> As</font><b><i> Blit_Alpha</i></b>,
<b><i> Color</i></b><font color="darkblue"> As</font><font color="darkblue"> Long</font>,
<b><i> Mirror</i></b><font color="darkblue"> As</font><b><i> Blit_Mirror</i></b>,
<b><i> Filter</i></b><font color="darkblue"> As</font><b><i> Blit_Filter</i></b>,
<b><i> Perspective</i></b><font color="darkblue"> As</font><b><i> Blit_Perspective</i></b>,
<font color="darkblue"> Optional</font><b><i> Factor</i></b><font color="darkblue"> As</font><font color="darkblue"> Long</font> )</B></PRE>
<H4>Argumentos</H4>
<DL>
<DT><I>Map</I></TD>
<DD>
<B>Long</B>.
Identificador del grafico.
</DD>
<DT><I>X</I></TD>
<DD>
<B>Long</B>.
Coordenada horizontal de dibujo.
</DD>
<DT><I>Y</I></TD>
<DD>
<B>Long</B>.
Coordenada vertical de dibujo.
</DD>
<DT><I>Z</I></TD>
<DD>
<B>Long</B>.
Coordenada de profundidad de dibujo.
Para saber como funciona este parámetro leer información acerca del
<a href="REF_ZBuffer.html">ZBuffer</a>.</DD>
<DT><I>Width</I></TD>
<DD>
<B>Long</B>.
Anchura con la que se dibujara el grafico. Si el valor es 0 se toma las dimensiones originales del grafico, si el valor es -1 se toma la dimensiones del grafico en memoria.
</DD>
<DT><I>Height</I></TD>
<DD>
<B>Long</B>.
Altura con la que se dibujara el grafico. Si el valor es 0 se toma las dimensiones originales del grafico, si el valor es -1 se toma la dimensiones del grafico en memoria.
</DD>
<DT><I>AlphaBlendMode</I></TD>
<DD>
<B><A href="dx_GFX_class.Blit_Alpha.html">Blit_Alpha</A></B>.
Modo de opacidad.
</DD>
<DT><I>Color</I></TD>
<DD>
<B>Long</B>.
Color <a href="REF_ARGB.html">ARGB</a> que se aplicara para realizar la
operación de dibujo. Para que el grafico se dibuje con los colores originales el
valor debe ser blanco puro <i>(&HFFFFFFFF o ARGB 255, 255, 255, 255). </i>El componente Alpha del color no se aplicara en los modos de opacidad
<a href="dx_GFX_class.Blit_Alpha.html">BlendOp_Aditive</a> y
<a href="dx_GFX_class.Blit_Alpha.html">BlendOp_Sustrative</a>.
</DD>
<DT><I>Mirror</I></TD>
<DD>
<B><A href="dx_GFX_class.Blit_Mirror.html">Blit_Mirror</A></B>.
Modo de espejado.
</DD>
<DT><I>Filter</I></TD>
<DD>
<B><A href="dx_GFX_class.Blit_Filter.html">Blit_Filter</A></B>.
Filtro de suavizado que se utilizara para dibujar el grafico.
</DD>
<DT><I>Perspective</I></TD>
<DD>
<B><A href="dx_GFX_class.Blit_Perspective.html">Blit_Perspective</A></B>.
Especifica el modo de perspectiva que tendrá el grafico en pantalla.</DD>
<DT><I>Factor</I></TD>
<DD>
Optional.
<B>Long</B>.
Parámetro opcional que permite introducir un valor para alterar la perspectiva final.
Este parametro no afecta a la constante
<a href="dx_GFX_class.Blit_Perspective.html">Isometric_Base</a></DD>
</DL>
<H4>Comentarios</H4>
<P>Esta función añade extras a la versión de
<a href="dx_GFX_class.DRAW_Map.html">DRAW_Map</a> permitiendo operaciones de espejados, opacidad (Alpha Blending), filtrado para suavizar los
píxeles del grafico en pantalla y posibilidad de proyectar un grafico en perspectiva tanto caballera como isométrica.
</P>
<H4>Vea también</H4>
<P>
<A HREF="dx_lib32.html">Proyecto dx_lib32 Descripción</A>
<A HREF="dx_GFX_class.html">Clase dx_GFX_class Descripción</A>
<A HREF="dx_GFX_class.html#public_props">dx_GFX_class Propiedades</A>
<A HREF="dx_GFX_class.html#public_methods">dx_GFX_class Metodos</A>
<B><A HREF="dx_GFX_class.DRAW_AdvBox.html">DRAW_AdvBox</A></B>
<B><A HREF="dx_GFX_class.DRAW_Box.html">DRAW_Box</A></B>
<DIV class=footer>dx_lib32 © 2004 - 2009 José Miguel Sánchez Fernández <P>Generado el viernes 02 de enero del 2009 con VBDOX 1.0.34 (<A href="http://vbdox.sourceforge.net/">http://vbdox.sourceforge.net</A>)<BR>Copyright © 2000 - 2001 M.Stamenov</DIV>
<DIV class=footer style="COLOR: #000000; FONT-SIZE: 90%">
</body>
</html>
| Java |
//----------------------------------------------------------------------------
// This is autogenerated code by CppSharp.
// Do not edit this file or all your changes will be lost after re-generation.
//----------------------------------------------------------------------------
using System;
using System.Runtime.InteropServices;
using System.Security;
namespace Webbed.Scripting.Interop
{
// DEBUG: typedef struct _WebKitIconDatabasePrivate WebKitIconDatabasePrivate
// DEBUG: struct _WebKitIconDatabasePrivate
[StructLayout(LayoutKind.Explicit, Size = 0)]
public unsafe struct _cPrivate
{
}
// DEBUG: struct _WebKitIconDatabase { GObject parent_instance; /*< private >*/ WebKitIconDatabasePrivate* priv;}
[StructLayout(LayoutKind.Explicit, Size = 16)]
public unsafe struct _WebKitIconDatabase
{
// DEBUG: GObject parent_instance
[FieldOffset(0)]
public _GObject parent_instance;
// DEBUG: WebKitIconDatabasePrivate* priv
[FieldOffset(12)]
public global::System.IntPtr priv;
}
// DEBUG: struct _WebKitIconDatabaseClass { GObjectClass parent_class; /* Padding for future expansion */ void (*_webkit_reserved1) (void); void (*_webkit_reserved2) (void); void (*_webkit_reserved3) (void); void (*_webkit_reserved4) (void);}
[StructLayout(LayoutKind.Explicit, Size = 84)]
public unsafe struct _WebKitIconDatabaseClass
{
// DEBUG: GObjectClass parent_class
[FieldOffset(0)]
public _GObjectClass parent_class;
}
public unsafe partial class WebKitIconDatabase : GLib.Object
{
public WebKitIconDatabase(IntPtr handle):base(handle){};
// DEBUG: WEBKIT_API GTypewebkit_icon_database_get_type (void)
[SuppressUnmanagedCodeSecurity]
[DllImport("webkitgtk-1.0", CallingConvention = global::System.Runtime.InteropServices.CallingConvention.Cdecl,
EntryPoint="webkit_icon_database_get_type")]
internal static extern uint webkit_icon_database_get_type();
public GLib.GType Type
{
get
{
return new GLib.GType((IntPtr)webkit_icon_database_get_type());
}
}
// DEBUG: WEBKIT_API const gchar*webkit_icon_database_get_path (WebKitIconDatabase* database)
[SuppressUnmanagedCodeSecurity]
[DllImport("webkitgtk-1.0", CallingConvention = global::System.Runtime.InteropServices.CallingConvention.Cdecl, CharSet = CharSet.Ansi
EntryPoint="webkit_icon_database_get_path")]
internal static extern string webkit_icon_database_get_path(global::System.IntPtr database);
public string Path
{
get
{
return webkit_icon_database_get_path(this.Handle);
}
set{
webkit_icon_database_set_path(this.Handle, value);
}
}
// DEBUG: WEBKIT_API voidwebkit_icon_database_set_path (WebKitIconDatabase* database, const gchar* path)
[SuppressUnmanagedCodeSecurity]
[DllImport("webkitgtk-1.0", CallingConvention = global::System.Runtime.InteropServices.CallingConvention.Cdecl, CharSet = CharSet.Ansi
EntryPoint="webkit_icon_database_set_path")]
internal static extern void webkit_icon_database_set_path(global::System.IntPtr database, string path);
// DEBUG: WEBKIT_API gchar*webkit_icon_database_get_icon_uri (WebKitIconDatabase* database, const gchar* page_uri)
[SuppressUnmanagedCodeSecurity]
[DllImport("webkitgtk-1.0", CallingConvention = global::System.Runtime.InteropServices.CallingConvention.Cdecl, CharSet = CharSet.Ansi
EntryPoint="webkit_icon_database_get_icon_uri")]
internal static extern string webkit_icon_database_get_icon_uri(global::System.IntPtr database, string page_uri);
public string GetIconUri(string page_uri){
return webkit_icon_database_get_icon_uri(this.Handle,page_uri);
}
// DEBUG: WEBKIT_API GdkPixbuf*webkit_icon_database_get_icon_pixbuf (WebKitIconDatabase* database, const gchar* page_uri)
[SuppressUnmanagedCodeSecurity]
[DllImport("webkitgtk-1.0", CallingConvention = global::System.Runtime.InteropServices.CallingConvention.Cdecl, CharSet = CharSet.Ansi
EntryPoint="webkit_icon_database_get_icon_pixbuf")]
internal static extern global::System.IntPtr webkit_icon_database_get_icon_pixbuf(global::System.IntPtr database, string page_uri);
public Gdk.Pixbuf GetIconPixbuf(string page_uri){
return new Gdk.Pixbuf( webkit_icon_database_get_icon_pixbuf(this.Handle,page_uri));
}
// DEBUG: WEBKIT_API voidwebkit_icon_database_clear (WebKitIconDatabase* database)
[SuppressUnmanagedCodeSecurity]
[DllImport("webkitgtk-1.0", CallingConvention = global::System.Runtime.InteropServices.CallingConvention.Cdecl,
EntryPoint="webkit_icon_database_clear")]
internal static extern void webkit_icon_database_clear(global::System.IntPtr database);
public void Clear(){
webkit_icon_database_clear(this.Handle);
}
}
}
| Java |
#include "nova_renderer/util/platform.hpp"
#ifdef NOVA_LINUX
#include "x11_window.hpp"
namespace nova::renderer {
x11_window::x11_window(uint32_t width, uint32_t height, const std::string& title) {
display = XOpenDisplay(nullptr);
if(display == nullptr) {
throw window_creation_error("Failed to open XDisplay");
}
// NOLINTNEXTLINE(cppcoreguidelines-pro-type-cstyle-cast)
int screen = DefaultScreen(display);
window = XCreateSimpleWindow(display,
RootWindow(display, screen), // NOLINT(cppcoreguidelines-pro-type-cstyle-cast)
50,
50,
width,
height,
1,
BlackPixel(display, screen), // NOLINT(cppcoreguidelines-pro-type-cstyle-cast)
WhitePixel(display, screen)); // NOLINT(cppcoreguidelines-pro-type-cstyle-cast)
XStoreName(display, window, title.c_str());
wm_protocols = XInternAtom(display, "WM_PROTOCOLS", 0);
wm_delete_window = XInternAtom(display, "WM_DELETE_WINDOW", 0);
XSetWMProtocols(display, window, &wm_delete_window, 1);
XSelectInput(display, window, ExposureMask | ButtonPressMask | KeyPressMask);
XMapWindow(display, window);
}
x11_window::~x11_window() {
XUnmapWindow(display, window);
XDestroyWindow(display, window);
XCloseDisplay(display);
}
Window& x11_window::get_x11_window() { return window; }
Display* x11_window::get_display() { return display; }
void x11_window::on_frame_end() {
XEvent event;
while(XPending(display) != 0) {
XNextEvent(display, &event);
switch(event.type) {
case ClientMessage: {
if(event.xclient.message_type == wm_protocols && event.xclient.data.l[0] == static_cast<long>(wm_delete_window)) {
should_window_close = true;
}
break;
}
default:
break;
}
}
}
bool x11_window::should_close() const { return should_window_close; }
glm::uvec2 x11_window::get_window_size() const {
Window root_window;
int x_pos;
int y_pos;
uint32_t width;
uint32_t height;
uint32_t border_width;
uint32_t depth;
XGetGeometry(display, window, &root_window, &x_pos, &y_pos, &width, &height, &border_width, &depth);
return {width, height};
}
} // namespace nova::renderer
#endif
| Java |
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en_US" lang="en_US">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Qt 4.8: wateringconfigdialog.h Example File (help/contextsensitivehelp/wateringconfigdialog.h)</title>
<link rel="stylesheet" type="text/css" href="style/style.css" />
<script src="scripts/jquery.js" type="text/javascript"></script>
<script src="scripts/functions.js" type="text/javascript"></script>
<link rel="stylesheet" type="text/css" href="style/superfish.css" />
<link rel="stylesheet" type="text/css" href="style/narrow.css" />
<!--[if IE]>
<meta name="MSSmartTagsPreventParsing" content="true">
<meta http-equiv="imagetoolbar" content="no">
<![endif]-->
<!--[if lt IE 7]>
<link rel="stylesheet" type="text/css" href="style/style_ie6.css">
<![endif]-->
<!--[if IE 7]>
<link rel="stylesheet" type="text/css" href="style/style_ie7.css">
<![endif]-->
<!--[if IE 8]>
<link rel="stylesheet" type="text/css" href="style/style_ie8.css">
<![endif]-->
<script src="scripts/superfish.js" type="text/javascript"></script>
<script src="scripts/narrow.js" type="text/javascript"></script>
</head>
<body class="" onload="CheckEmptyAndLoadList();">
<div class="header" id="qtdocheader">
<div class="content">
<div id="nav-logo">
<a href="index.html">Home</a></div>
<a href="index.html" class="qtref"><span>Qt Reference Documentation</span></a>
<div id="narrowsearch"></div>
<div id="nav-topright">
<ul>
<li class="nav-topright-home"><a href="http://qt.digia.com/">Qt HOME</a></li>
<li class="nav-topright-dev"><a href="http://qt-project.org/">DEV</a></li>
<li class="nav-topright-doc nav-topright-doc-active"><a href="http://qt-project.org/doc/">
DOC</a></li>
<li class="nav-topright-blog"><a href="http://blog.qt.digia.com/">BLOG</a></li>
</ul>
</div>
<div id="shortCut">
<ul>
<li class="shortCut-topleft-inactive"><span><a href="index.html">Qt 4.8</a></span></li>
<li class="shortCut-topleft-active"><a href="http://qt-project.org/doc/">ALL VERSIONS </a></li>
</ul>
</div>
<ul class="sf-menu" id="narrowmenu">
<li><a href="#">API Lookup</a>
<ul>
<li><a href="classes.html">Class index</a></li>
<li><a href="functions.html">Function index</a></li>
<li><a href="modules.html">Modules</a></li>
<li><a href="namespaces.html">Namespaces</a></li>
<li><a href="qtglobal.html">Global Declarations</a></li>
<li><a href="qdeclarativeelements.html">QML elements</a></li>
</ul>
</li>
<li><a href="#">Qt Topics</a>
<ul>
<li><a href="qt-basic-concepts.html">Programming with Qt</a></li>
<li><a href="qtquick.html">Device UIs & Qt Quick</a></li>
<li><a href="qt-gui-concepts.html">UI Design with Qt</a></li>
<li><a href="supported-platforms.html">Supported Platforms</a></li>
<li><a href="technology-apis.html">Qt and Key Technologies</a></li>
<li><a href="best-practices.html">How-To's and Best Practices</a></li>
</ul>
</li>
<li><a href="#">Examples</a>
<ul>
<li><a href="all-examples.html">Examples</a></li>
<li><a href="tutorials.html">Tutorials</a></li>
<li><a href="demos.html">Demos</a></li>
<li><a href="qdeclarativeexamples.html">QML Examples</a></li>
</ul>
</li>
</ul>
</div>
</div>
<div class="wrapper">
<div class="hd">
<span></span>
</div>
<div class="bd group">
<div class="sidebar">
<div class="searchlabel">
Search index:</div>
<div class="search" id="sidebarsearch">
<form id="qtdocsearch" action="" onsubmit="return false;">
<fieldset>
<input type="text" name="searchstring" id="pageType" value="" />
<div id="resultdialog">
<a href="#" id="resultclose">Close</a>
<p id="resultlinks" class="all"><a href="#" id="showallresults">All</a> | <a href="#" id="showapiresults">API</a> | <a href="#" id="showarticleresults">Articles</a> | <a href="#" id="showexampleresults">Examples</a></p>
<p id="searchcount" class="all"><span id="resultcount"></span><span id="apicount"></span><span id="articlecount"></span><span id="examplecount"></span> results:</p>
<ul id="resultlist" class="all">
</ul>
</div>
</fieldset>
</form>
</div>
<div class="box first bottombar" id="lookup">
<h2 title="API Lookup"><span></span>
API Lookup</h2>
<div id="list001" class="list">
<ul id="ul001" >
<li class="defaultLink"><a href="classes.html">Class index</a></li>
<li class="defaultLink"><a href="functions.html">Function index</a></li>
<li class="defaultLink"><a href="modules.html">Modules</a></li>
<li class="defaultLink"><a href="namespaces.html">Namespaces</a></li>
<li class="defaultLink"><a href="qtglobal.html">Global Declarations</a></li>
<li class="defaultLink"><a href="qdeclarativeelements.html">QML elements</a></li>
</ul>
</div>
</div>
<div class="box bottombar" id="topics">
<h2 title="Qt Topics"><span></span>
Qt Topics</h2>
<div id="list002" class="list">
<ul id="ul002" >
<li class="defaultLink"><a href="qt-basic-concepts.html">Programming with Qt</a></li>
<li class="defaultLink"><a href="qtquick.html">Device UIs & Qt Quick</a></li>
<li class="defaultLink"><a href="qt-gui-concepts.html">UI Design with Qt</a></li>
<li class="defaultLink"><a href="supported-platforms.html">Supported Platforms</a></li>
<li class="defaultLink"><a href="technology-apis.html">Qt and Key Technologies</a></li>
<li class="defaultLink"><a href="best-practices.html">How-To's and Best Practices</a></li>
</ul>
</div>
</div>
<div class="box" id="examples">
<h2 title="Examples"><span></span>
Examples</h2>
<div id="list003" class="list">
<ul id="ul003">
<li class="defaultLink"><a href="all-examples.html">Examples</a></li>
<li class="defaultLink"><a href="tutorials.html">Tutorials</a></li>
<li class="defaultLink"><a href="demos.html">Demos</a></li>
<li class="defaultLink"><a href="qdeclarativeexamples.html">QML Examples</a></li>
</ul>
</div>
</div>
</div>
<div class="wrap">
<div class="toolbar">
<div class="breadcrumb toolblock">
<ul>
<li class="first"><a href="index.html">Home</a></li>
<!-- Breadcrumbs go here -->
</ul>
</div>
<div class="toolbuttons toolblock">
<ul>
<li id="smallA" class="t_button">A</li>
<li id="medA" class="t_button active">A</li>
<li id="bigA" class="t_button">A</li>
<li id="print" class="t_button"><a href="javascript:this.print();">
<span>Print</span></a></li>
</ul>
</div>
</div>
<div class="content mainContent">
<h1 class="title">wateringconfigdialog.h Example File</h1>
<span class="small-subtitle">help/contextsensitivehelp/wateringconfigdialog.h</span>
<!-- $$$help/contextsensitivehelp/wateringconfigdialog.h-description -->
<div class="descr"> <a name="details"></a>
<pre class="cpp"> <span class="comment">/****************************************************************************
**
** Copyright (C) 2012 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
** This file is part of the examples of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:BSD$
** You may use this file under the terms of the BSD license as follows:
**
** "Redistribution and use in source and binary forms, with or without
** modification, are permitted provided that the following conditions are
** met:
** * Redistributions of source code must retain the above copyright
** notice, this list of conditions and the following disclaimer.
** * Redistributions in binary form must reproduce the above copyright
** notice, this list of conditions and the following disclaimer in
** the documentation and/or other materials provided with the
** distribution.
** * Neither the name of Digia Plc and its Subsidiary(-ies) nor the names
** of its contributors may be used to endorse or promote products derived
** from this software without specific prior written permission.
**
**
** THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
** "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
** LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
** A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
** OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
** SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
** LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
** DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
** THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
** (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
** OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE."
**
** $QT_END_LICENSE$
**
****************************************************************************/</span>
<span class="preprocessor">#ifndef WATERINGCONFIGDIALOG_H</span>
<span class="preprocessor">#define WATERINGCONFIGDIALOG_H</span>
<span class="preprocessor">#include <QtGui/QDialog></span>
<span class="preprocessor">#include "ui_wateringconfigdialog.h"</span>
<span class="keyword">class</span> WateringConfigDialog : <span class="keyword">public</span> <span class="type"><a href="qdialog.html">QDialog</a></span>
{
Q_OBJECT
<span class="keyword">public</span>:
WateringConfigDialog();
<span class="keyword">private</span> <span class="keyword">slots</span>:
<span class="type">void</span> focusChanged(<span class="type"><a href="qwidget.html">QWidget</a></span> <span class="operator">*</span>old<span class="operator">,</span> <span class="type"><a href="qwidget.html">QWidget</a></span> <span class="operator">*</span>now);
<span class="keyword">private</span>:
Ui<span class="operator">::</span>WateringConfigDialog m_ui;
<span class="type"><a href="qmap.html">QMap</a></span><span class="operator"><</span><span class="type"><a href="qwidget.html">QWidget</a></span><span class="operator">*</span><span class="operator">,</span> <span class="type"><a href="qstring.html">QString</a></span><span class="operator">></span> m_widgetInfo;
};
<span class="preprocessor">#endif</span></pre>
</div>
<!-- @@@help/contextsensitivehelp/wateringconfigdialog.h -->
</div>
</div>
</div>
<div class="ft">
<span></span>
</div>
</div>
<div class="footer">
<p>
<acronym title="Copyright">©</acronym> 2012 Digia Plc and/or its
subsidiaries. Documentation contributions included herein are the copyrights of
their respective owners.</p>
<br />
<p>
The documentation provided herein is licensed under the terms of the
<a href="http://www.gnu.org/licenses/fdl.html">GNU Free Documentation
License version 1.3</a> as published by the Free Software Foundation.</p>
<p>
Documentation sources may be obtained from <a href="http://www.qt-project.org">
www.qt-project.org</a>.</p>
<br />
<p>
Digia, Qt and their respective logos are trademarks of Digia Plc
in Finland and/or other countries worldwide. All other trademarks are property
of their respective owners. <a title="Privacy Policy"
href="http://en.gitorious.org/privacy_policy/">Privacy Policy</a></p>
</div>
<script src="scripts/functions.js" type="text/javascript"></script>
</body>
</html>
| Java |
package codechicken.lib.math;
import net.minecraft.util.math.BlockPos;
//TODO cleanup.
public class MathHelper {
public static final double phi = 1.618033988749894;
public static final double pi = Math.PI;
public static final double todeg = 57.29577951308232;
public static final double torad = 0.017453292519943;
public static final double sqrt2 = 1.414213562373095;
public static double[] SIN_TABLE = new double[65536];
static {
for (int i = 0; i < 65536; ++i) {
SIN_TABLE[i] = Math.sin(i / 65536D * 2 * Math.PI);
}
SIN_TABLE[0] = 0;
SIN_TABLE[16384] = 1;
SIN_TABLE[32768] = 0;
SIN_TABLE[49152] = 1;
}
public static double sin(double d) {
return SIN_TABLE[(int) ((float) d * 10430.378F) & 65535];
}
public static double cos(double d) {
return SIN_TABLE[(int) ((float) d * 10430.378F + 16384.0F) & 65535];
}
/**
* @param a The value
* @param b The value to approach
* @param max The maximum step
* @return the closed value to b no less than max from a
*/
public static float approachLinear(float a, float b, float max) {
return (a > b) ? (a - b < max ? b : a - max) : (b - a < max ? b : a + max);
}
/**
* @param a The value
* @param b The value to approach
* @param max The maximum step
* @return the closed value to b no less than max from a
*/
public static double approachLinear(double a, double b, double max) {
return (a > b) ? (a - b < max ? b : a - max) : (b - a < max ? b : a + max);
}
/**
* @param a The first value
* @param b The second value
* @param d The interpolation factor, between 0 and 1
* @return a+(b-a)*d
*/
public static float interpolate(float a, float b, float d) {
return a + (b - a) * d;
}
/**
* @param a The first value
* @param b The second value
* @param d The interpolation factor, between 0 and 1
* @return a+(b-a)*d
*/
public static double interpolate(double a, double b, double d) {
return a + (b - a) * d;
}
/**
* @param a The value
* @param b The value to approach
* @param ratio The ratio to reduce the difference by
* @return a+(b-a)*ratio
*/
public static double approachExp(double a, double b, double ratio) {
return a + (b - a) * ratio;
}
/**
* @param a The value
* @param b The value to approach
* @param ratio The ratio to reduce the difference by
* @param cap The maximum amount to advance by
* @return a+(b-a)*ratio
*/
public static double approachExp(double a, double b, double ratio, double cap) {
double d = (b - a) * ratio;
if (Math.abs(d) > cap) {
d = Math.signum(d) * cap;
}
return a + d;
}
/**
* @param a The value
* @param b The value to approach
* @param ratio The ratio to reduce the difference by
* @param c The value to retreat from
* @param kick The difference when a == c
* @return
*/
public static double retreatExp(double a, double b, double c, double ratio, double kick) {
double d = (Math.abs(c - a) + kick) * ratio;
if (d > Math.abs(b - a)) {
return b;
}
return a + Math.signum(b - a) * d;
}
/**
* @param value The value
* @param min The min value
* @param max The max value
* @return The clipped value between min and max
*/
public static double clip(double value, double min, double max) {
if (value > max) {
value = max;
}
if (value < min) {
value = min;
}
return value;
}
/**
* @param value The value
* @param min The min value
* @param max The max value
* @return The clipped value between min and max
*/
public static float clip(float value, float min, float max) {
if (value > max) {
value = max;
}
if (value < min) {
value = min;
}
return value;
}
/**
* @param value The value
* @param min The min value
* @param max The max value
* @return The clipped value between min and max
*/
public static int clip(int value, int min, int max) {
if (value > max) {
value = max;
}
if (value < min) {
value = min;
}
return value;
}
/**
* Maps a value range to another value range.
*
* @param valueIn The value to map.
* @param inMin The minimum of the input value range.
* @param inMax The maximum of the input value range
* @param outMin The minimum of the output value range.
* @param outMax The maximum of the output value range.
* @return The mapped value.
*/
public static double map(double valueIn, double inMin, double inMax, double outMin, double outMax) {
return (valueIn - inMin) * (outMax - outMin) / (inMax - inMin) + outMin;
}
/**
* Maps a value range to another value range.
*
* @param valueIn The value to map.
* @param inMin The minimum of the input value range.
* @param inMax The maximum of the input value range
* @param outMin The minimum of the output value range.
* @param outMax The maximum of the output value range.
* @return The mapped value.
*/
public static float map(float valueIn, float inMin, float inMax, float outMin, float outMax) {
return (valueIn - inMin) * (outMax - outMin) / (inMax - inMin) + outMin;
}
/**
* Rounds the number of decimal places based on the given multiplier.<br>
* e.g.<br>
* Input: 17.5245743<br>
* multiplier: 1000<br>
* Output: 17.534<br>
* multiplier: 10<br>
* Output 17.5<br><br>
*
* @param number The input value.
* @param multiplier The multiplier.
* @return The input rounded to a number of decimal places based on the multiplier.
*/
public static double round(double number, double multiplier) {
return Math.round(number * multiplier) / multiplier;
}
/**
* Rounds the number of decimal places based on the given multiplier.<br>
* e.g.<br>
* Input: 17.5245743<br>
* multiplier: 1000<br>
* Output: 17.534<br>
* multiplier: 10<br>
* Output 17.5<br><br>
*
* @param number The input value.
* @param multiplier The multiplier.
* @return The input rounded to a number of decimal places based on the multiplier.
*/
public static float round(float number, float multiplier) {
return Math.round(number * multiplier) / multiplier;
}
/**
* @return min <= value <= max
*/
public static boolean between(double min, double value, double max) {
return min <= value && value <= max;
}
public static int approachExpI(int a, int b, double ratio) {
int r = (int) Math.round(approachExp(a, b, ratio));
return r == a ? b : r;
}
public static int retreatExpI(int a, int b, int c, double ratio, int kick) {
int r = (int) Math.round(retreatExp(a, b, c, ratio, kick));
return r == a ? b : r;
}
public static int floor(double d) {
return net.minecraft.util.math.MathHelper.floor_double(d);
}
public static int floor(float d) {
return net.minecraft.util.math.MathHelper.floor_float(d);
}
public static int ceil(double d) {
return net.minecraft.util.math.MathHelper.ceiling_double_int(d);
}
public static int ceil(float d) {
return net.minecraft.util.math.MathHelper.ceiling_float_int(d);
}
public static float sqrt(float f) {
return net.minecraft.util.math.MathHelper.sqrt_float(f);
}
public static float sqrt(double f) {
return net.minecraft.util.math.MathHelper.sqrt_double(f);
}
public static int roundAway(double d) {
return (int) (d < 0 ? Math.floor(d) : Math.ceil(d));
}
public static int compare(int a, int b) {
return a == b ? 0 : a < b ? -1 : 1;
}
public static int compare(double a, double b) {
return a == b ? 0 : a < b ? -1 : 1;
}
public static int absSum(BlockPos pos) {
return (pos.getX() < 0 ? -pos.getX() : pos.getX()) + (pos.getY() < 0 ? -pos.getY() : pos.getY()) + (pos.getZ() < 0 ? -pos.getZ() : pos.getZ());
}
public static boolean isAxial(BlockPos pos) {
return pos.getX() == 0 ? (pos.getY() == 0 || pos.getZ() == 0) : (pos.getY() == 0 && pos.getZ() == 0);
}
public static int toSide(BlockPos pos) {
if (!isAxial(pos)) {
return -1;
}
if (pos.getY() < 0) {
return 0;
}
if (pos.getY() > 0) {
return 1;
}
if (pos.getZ() < 0) {
return 2;
}
if (pos.getZ() > 0) {
return 3;
}
if (pos.getX() < 0) {
return 4;
}
if (pos.getX() > 0) {
return 5;
}
return -1;
}
}
| Java |
@import url("https://fonts.googleapis.com/css?family=Roboto:300,400,500,700");
/*!
* Bootstrap v3.3.7 (http://getbootstrap.com)
* Copyright 2011-2016 Twitter, Inc.
* Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE)
*/
/*! normalize.css v3.0.3 | MIT License | github.com/necolas/normalize.css */
html {
font-family: sans-serif;
-ms-text-size-adjust: 100%;
-webkit-text-size-adjust: 100%;
}
body {
margin: 0;
}
article,
aside,
details,
figcaption,
figure,
footer,
header,
hgroup,
main,
menu,
nav,
section,
summary {
display: block;
}
audio,
canvas,
progress,
video {
display: inline-block;
vertical-align: baseline;
}
audio:not([controls]) {
display: none;
height: 0;
}
[hidden],
template {
display: none;
}
a {
background-color: transparent;
}
a:active,
a:hover {
outline: 0;
}
abbr[title] {
border-bottom: 1px dotted;
}
b,
strong {
font-weight: bold;
}
dfn {
font-style: italic;
}
h1 {
font-size: 2em;
margin: 0.67em 0;
}
mark {
background: #ff0;
color: #000;
}
small {
font-size: 80%;
}
sub,
sup {
font-size: 75%;
line-height: 0;
position: relative;
vertical-align: baseline;
}
sup {
top: -0.5em;
}
sub {
bottom: -0.25em;
}
img {
border: 0;
}
svg:not(:root) {
overflow: hidden;
}
figure {
margin: 1em 40px;
}
hr {
box-sizing: content-box;
height: 0;
}
pre {
overflow: auto;
}
code,
kbd,
pre,
samp {
font-family: monospace, monospace;
font-size: 1em;
}
button,
input,
optgroup,
select,
textarea {
color: inherit;
font: inherit;
margin: 0;
}
button {
overflow: visible;
}
button,
select {
text-transform: none;
}
button,
html input[type="button"],
input[type="reset"],
input[type="submit"] {
-webkit-appearance: button;
cursor: pointer;
}
button[disabled],
html input[disabled] {
cursor: default;
}
button::-moz-focus-inner,
input::-moz-focus-inner {
border: 0;
padding: 0;
}
input {
line-height: normal;
}
input[type="checkbox"],
input[type="radio"] {
box-sizing: border-box;
padding: 0;
}
input[type="number"]::-webkit-inner-spin-button,
input[type="number"]::-webkit-outer-spin-button {
height: auto;
}
input[type="search"] {
-webkit-appearance: textfield;
box-sizing: content-box;
}
input[type="search"]::-webkit-search-cancel-button,
input[type="search"]::-webkit-search-decoration {
-webkit-appearance: none;
}
fieldset {
border: 1px solid #c0c0c0;
margin: 0 2px;
padding: 0.35em 0.625em 0.75em;
}
legend {
border: 0;
padding: 0;
}
textarea {
overflow: auto;
}
optgroup {
font-weight: bold;
}
table {
border-collapse: collapse;
border-spacing: 0;
}
td,
th {
padding: 0;
}
/*! Source: https://github.com/h5bp/html5-boilerplate/blob/master/src/css/main.css */
@media print {
*,
*:before,
*:after {
background: transparent !important;
color: #000 !important;
box-shadow: none !important;
text-shadow: none !important;
}
a,
a:visited {
text-decoration: underline;
}
a[href]:after {
content: " (" attr(href) ")";
}
abbr[title]:after {
content: " (" attr(title) ")";
}
a[href^="#"]:after,
a[href^="javascript:"]:after {
content: "";
}
pre,
blockquote {
border: 1px solid #999;
page-break-inside: avoid;
}
thead {
display: table-header-group;
}
tr,
img {
page-break-inside: avoid;
}
img {
max-width: 100% !important;
}
p,
h2,
h3 {
orphans: 3;
widows: 3;
}
h2,
h3 {
page-break-after: avoid;
}
.navbar {
display: none;
}
.btn > .caret,
.dropup > .btn > .caret {
border-top-color: #000 !important;
}
.label {
border: 1px solid #000;
}
.table {
border-collapse: collapse !important;
}
.table td,
.table th {
background-color: #fff !important;
}
.table-bordered th,
.table-bordered td {
border: 1px solid #ddd !important;
}
}
@font-face {
font-family: 'Glyphicons Halflings';
src: url('../../../vendor_bundled/vendor/twitter/bootstrap/fonts/glyphicons-halflings-regular.eot');
src: url('../../../vendor_bundled/vendor/twitter/bootstrap/fonts/glyphicons-halflings-regular.eot?#iefix') format('embedded-opentype'), url('../../../vendor_bundled/vendor/twitter/bootstrap/fonts/glyphicons-halflings-regular.woff2') format('woff2'), url('../../../vendor_bundled/vendor/twitter/bootstrap/fonts/glyphicons-halflings-regular.woff') format('woff'), url('../../../vendor_bundled/vendor/twitter/bootstrap/fonts/glyphicons-halflings-regular.ttf') format('truetype'), url('../../../vendor_bundled/vendor/twitter/bootstrap/fonts/glyphicons-halflings-regular.svg#glyphicons_halflingsregular') format('svg');
}
.glyphicon {
position: relative;
top: 1px;
display: inline-block;
font-family: 'Glyphicons Halflings';
font-style: normal;
font-weight: normal;
line-height: 1;
-webkit-font-smoothing: antialiased;
-moz-osx-font-smoothing: grayscale;
}
.glyphicon-asterisk:before {
content: "\002a";
}
.glyphicon-plus:before {
content: "\002b";
}
.glyphicon-euro:before,
.glyphicon-eur:before {
content: "\20ac";
}
.glyphicon-minus:before {
content: "\2212";
}
.glyphicon-cloud:before {
content: "\2601";
}
.glyphicon-envelope:before {
content: "\2709";
}
.glyphicon-pencil:before {
content: "\270f";
}
.glyphicon-glass:before {
content: "\e001";
}
.glyphicon-music:before {
content: "\e002";
}
.glyphicon-search:before {
content: "\e003";
}
.glyphicon-heart:before {
content: "\e005";
}
.glyphicon-star:before {
content: "\e006";
}
.glyphicon-star-empty:before {
content: "\e007";
}
.glyphicon-user:before {
content: "\e008";
}
.glyphicon-film:before {
content: "\e009";
}
.glyphicon-th-large:before {
content: "\e010";
}
.glyphicon-th:before {
content: "\e011";
}
.glyphicon-th-list:before {
content: "\e012";
}
.glyphicon-ok:before {
content: "\e013";
}
.glyphicon-remove:before {
content: "\e014";
}
.glyphicon-zoom-in:before {
content: "\e015";
}
.glyphicon-zoom-out:before {
content: "\e016";
}
.glyphicon-off:before {
content: "\e017";
}
.glyphicon-signal:before {
content: "\e018";
}
.glyphicon-cog:before {
content: "\e019";
}
.glyphicon-trash:before {
content: "\e020";
}
.glyphicon-home:before {
content: "\e021";
}
.glyphicon-file:before {
content: "\e022";
}
.glyphicon-time:before {
content: "\e023";
}
.glyphicon-road:before {
content: "\e024";
}
.glyphicon-download-alt:before {
content: "\e025";
}
.glyphicon-download:before {
content: "\e026";
}
.glyphicon-upload:before {
content: "\e027";
}
.glyphicon-inbox:before {
content: "\e028";
}
.glyphicon-play-circle:before {
content: "\e029";
}
.glyphicon-repeat:before {
content: "\e030";
}
.glyphicon-refresh:before {
content: "\e031";
}
.glyphicon-list-alt:before {
content: "\e032";
}
.glyphicon-lock:before {
content: "\e033";
}
.glyphicon-flag:before {
content: "\e034";
}
.glyphicon-headphones:before {
content: "\e035";
}
.glyphicon-volume-off:before {
content: "\e036";
}
.glyphicon-volume-down:before {
content: "\e037";
}
.glyphicon-volume-up:before {
content: "\e038";
}
.glyphicon-qrcode:before {
content: "\e039";
}
.glyphicon-barcode:before {
content: "\e040";
}
.glyphicon-tag:before {
content: "\e041";
}
.glyphicon-tags:before {
content: "\e042";
}
.glyphicon-book:before {
content: "\e043";
}
.glyphicon-bookmark:before {
content: "\e044";
}
.glyphicon-print:before {
content: "\e045";
}
.glyphicon-camera:before {
content: "\e046";
}
.glyphicon-font:before {
content: "\e047";
}
.glyphicon-bold:before {
content: "\e048";
}
.glyphicon-italic:before {
content: "\e049";
}
.glyphicon-text-height:before {
content: "\e050";
}
.glyphicon-text-width:before {
content: "\e051";
}
.glyphicon-align-left:before {
content: "\e052";
}
.glyphicon-align-center:before {
content: "\e053";
}
.glyphicon-align-right:before {
content: "\e054";
}
.glyphicon-align-justify:before {
content: "\e055";
}
.glyphicon-list:before {
content: "\e056";
}
.glyphicon-indent-left:before {
content: "\e057";
}
.glyphicon-indent-right:before {
content: "\e058";
}
.glyphicon-facetime-video:before {
content: "\e059";
}
.glyphicon-picture:before {
content: "\e060";
}
.glyphicon-map-marker:before {
content: "\e062";
}
.glyphicon-adjust:before {
content: "\e063";
}
.glyphicon-tint:before {
content: "\e064";
}
.glyphicon-edit:before {
content: "\e065";
}
.glyphicon-share:before {
content: "\e066";
}
.glyphicon-check:before {
content: "\e067";
}
.glyphicon-move:before {
content: "\e068";
}
.glyphicon-step-backward:before {
content: "\e069";
}
.glyphicon-fast-backward:before {
content: "\e070";
}
.glyphicon-backward:before {
content: "\e071";
}
.glyphicon-play:before {
content: "\e072";
}
.glyphicon-pause:before {
content: "\e073";
}
.glyphicon-stop:before {
content: "\e074";
}
.glyphicon-forward:before {
content: "\e075";
}
.glyphicon-fast-forward:before {
content: "\e076";
}
.glyphicon-step-forward:before {
content: "\e077";
}
.glyphicon-eject:before {
content: "\e078";
}
.glyphicon-chevron-left:before {
content: "\e079";
}
.glyphicon-chevron-right:before {
content: "\e080";
}
.glyphicon-plus-sign:before {
content: "\e081";
}
.glyphicon-minus-sign:before {
content: "\e082";
}
.glyphicon-remove-sign:before {
content: "\e083";
}
.glyphicon-ok-sign:before {
content: "\e084";
}
.glyphicon-question-sign:before {
content: "\e085";
}
.glyphicon-info-sign:before {
content: "\e086";
}
.glyphicon-screenshot:before {
content: "\e087";
}
.glyphicon-remove-circle:before {
content: "\e088";
}
.glyphicon-ok-circle:before {
content: "\e089";
}
.glyphicon-ban-circle:before {
content: "\e090";
}
.glyphicon-arrow-left:before {
content: "\e091";
}
.glyphicon-arrow-right:before {
content: "\e092";
}
.glyphicon-arrow-up:before {
content: "\e093";
}
.glyphicon-arrow-down:before {
content: "\e094";
}
.glyphicon-share-alt:before {
content: "\e095";
}
.glyphicon-resize-full:before {
content: "\e096";
}
.glyphicon-resize-small:before {
content: "\e097";
}
.glyphicon-exclamation-sign:before {
content: "\e101";
}
.glyphicon-gift:before {
content: "\e102";
}
.glyphicon-leaf:before {
content: "\e103";
}
.glyphicon-fire:before {
content: "\e104";
}
.glyphicon-eye-open:before {
content: "\e105";
}
.glyphicon-eye-close:before {
content: "\e106";
}
.glyphicon-warning-sign:before {
content: "\e107";
}
.glyphicon-plane:before {
content: "\e108";
}
.glyphicon-calendar:before {
content: "\e109";
}
.glyphicon-random:before {
content: "\e110";
}
.glyphicon-comment:before {
content: "\e111";
}
.glyphicon-magnet:before {
content: "\e112";
}
.glyphicon-chevron-up:before {
content: "\e113";
}
.glyphicon-chevron-down:before {
content: "\e114";
}
.glyphicon-retweet:before {
content: "\e115";
}
.glyphicon-shopping-cart:before {
content: "\e116";
}
.glyphicon-folder-close:before {
content: "\e117";
}
.glyphicon-folder-open:before {
content: "\e118";
}
.glyphicon-resize-vertical:before {
content: "\e119";
}
.glyphicon-resize-horizontal:before {
content: "\e120";
}
.glyphicon-hdd:before {
content: "\e121";
}
.glyphicon-bullhorn:before {
content: "\e122";
}
.glyphicon-bell:before {
content: "\e123";
}
.glyphicon-certificate:before {
content: "\e124";
}
.glyphicon-thumbs-up:before {
content: "\e125";
}
.glyphicon-thumbs-down:before {
content: "\e126";
}
.glyphicon-hand-right:before {
content: "\e127";
}
.glyphicon-hand-left:before {
content: "\e128";
}
.glyphicon-hand-up:before {
content: "\e129";
}
.glyphicon-hand-down:before {
content: "\e130";
}
.glyphicon-circle-arrow-right:before {
content: "\e131";
}
.glyphicon-circle-arrow-left:before {
content: "\e132";
}
.glyphicon-circle-arrow-up:before {
content: "\e133";
}
.glyphicon-circle-arrow-down:before {
content: "\e134";
}
.glyphicon-globe:before {
content: "\e135";
}
.glyphicon-wrench:before {
content: "\e136";
}
.glyphicon-tasks:before {
content: "\e137";
}
.glyphicon-filter:before {
content: "\e138";
}
.glyphicon-briefcase:before {
content: "\e139";
}
.glyphicon-fullscreen:before {
content: "\e140";
}
.glyphicon-dashboard:before {
content: "\e141";
}
.glyphicon-paperclip:before {
content: "\e142";
}
.glyphicon-heart-empty:before {
content: "\e143";
}
.glyphicon-link:before {
content: "\e144";
}
.glyphicon-phone:before {
content: "\e145";
}
.glyphicon-pushpin:before {
content: "\e146";
}
.glyphicon-usd:before {
content: "\e148";
}
.glyphicon-gbp:before {
content: "\e149";
}
.glyphicon-sort:before {
content: "\e150";
}
.glyphicon-sort-by-alphabet:before {
content: "\e151";
}
.glyphicon-sort-by-alphabet-alt:before {
content: "\e152";
}
.glyphicon-sort-by-order:before {
content: "\e153";
}
.glyphicon-sort-by-order-alt:before {
content: "\e154";
}
.glyphicon-sort-by-attributes:before {
content: "\e155";
}
.glyphicon-sort-by-attributes-alt:before {
content: "\e156";
}
.glyphicon-unchecked:before {
content: "\e157";
}
.glyphicon-expand:before {
content: "\e158";
}
.glyphicon-collapse-down:before {
content: "\e159";
}
.glyphicon-collapse-up:before {
content: "\e160";
}
.glyphicon-log-in:before {
content: "\e161";
}
.glyphicon-flash:before {
content: "\e162";
}
.glyphicon-log-out:before {
content: "\e163";
}
.glyphicon-new-window:before {
content: "\e164";
}
.glyphicon-record:before {
content: "\e165";
}
.glyphicon-save:before {
content: "\e166";
}
.glyphicon-open:before {
content: "\e167";
}
.glyphicon-saved:before {
content: "\e168";
}
.glyphicon-import:before {
content: "\e169";
}
.glyphicon-export:before {
content: "\e170";
}
.glyphicon-send:before {
content: "\e171";
}
.glyphicon-floppy-disk:before {
content: "\e172";
}
.glyphicon-floppy-saved:before {
content: "\e173";
}
.glyphicon-floppy-remove:before {
content: "\e174";
}
.glyphicon-floppy-save:before {
content: "\e175";
}
.glyphicon-floppy-open:before {
content: "\e176";
}
.glyphicon-credit-card:before {
content: "\e177";
}
.glyphicon-transfer:before {
content: "\e178";
}
.glyphicon-cutlery:before {
content: "\e179";
}
.glyphicon-header:before {
content: "\e180";
}
.glyphicon-compressed:before {
content: "\e181";
}
.glyphicon-earphone:before {
content: "\e182";
}
.glyphicon-phone-alt:before {
content: "\e183";
}
.glyphicon-tower:before {
content: "\e184";
}
.glyphicon-stats:before {
content: "\e185";
}
.glyphicon-sd-video:before {
content: "\e186";
}
.glyphicon-hd-video:before {
content: "\e187";
}
.glyphicon-subtitles:before {
content: "\e188";
}
.glyphicon-sound-stereo:before {
content: "\e189";
}
.glyphicon-sound-dolby:before {
content: "\e190";
}
.glyphicon-sound-5-1:before {
content: "\e191";
}
.glyphicon-sound-6-1:before {
content: "\e192";
}
.glyphicon-sound-7-1:before {
content: "\e193";
}
.glyphicon-copyright-mark:before {
content: "\e194";
}
.glyphicon-registration-mark:before {
content: "\e195";
}
.glyphicon-cloud-download:before {
content: "\e197";
}
.glyphicon-cloud-upload:before {
content: "\e198";
}
.glyphicon-tree-conifer:before {
content: "\e199";
}
.glyphicon-tree-deciduous:before {
content: "\e200";
}
.glyphicon-cd:before {
content: "\e201";
}
.glyphicon-save-file:before {
content: "\e202";
}
.glyphicon-open-file:before {
content: "\e203";
}
.glyphicon-level-up:before {
content: "\e204";
}
.glyphicon-copy:before {
content: "\e205";
}
.glyphicon-paste:before {
content: "\e206";
}
.glyphicon-alert:before {
content: "\e209";
}
.glyphicon-equalizer:before {
content: "\e210";
}
.glyphicon-king:before {
content: "\e211";
}
.glyphicon-queen:before {
content: "\e212";
}
.glyphicon-pawn:before {
content: "\e213";
}
.glyphicon-bishop:before {
content: "\e214";
}
.glyphicon-knight:before {
content: "\e215";
}
.glyphicon-baby-formula:before {
content: "\e216";
}
.glyphicon-tent:before {
content: "\26fa";
}
.glyphicon-blackboard:before {
content: "\e218";
}
.glyphicon-bed:before {
content: "\e219";
}
.glyphicon-apple:before {
content: "\f8ff";
}
.glyphicon-erase:before {
content: "\e221";
}
.glyphicon-hourglass:before {
content: "\231b";
}
.glyphicon-lamp:before {
content: "\e223";
}
.glyphicon-duplicate:before {
content: "\e224";
}
.glyphicon-piggy-bank:before {
content: "\e225";
}
.glyphicon-scissors:before {
content: "\e226";
}
.glyphicon-bitcoin:before {
content: "\e227";
}
.glyphicon-btc:before {
content: "\e227";
}
.glyphicon-xbt:before {
content: "\e227";
}
.glyphicon-yen:before {
content: "\00a5";
}
.glyphicon-jpy:before {
content: "\00a5";
}
.glyphicon-ruble:before {
content: "\20bd";
}
.glyphicon-rub:before {
content: "\20bd";
}
.glyphicon-scale:before {
content: "\e230";
}
.glyphicon-ice-lolly:before {
content: "\e231";
}
.glyphicon-ice-lolly-tasted:before {
content: "\e232";
}
.glyphicon-education:before {
content: "\e233";
}
.glyphicon-option-horizontal:before {
content: "\e234";
}
.glyphicon-option-vertical:before {
content: "\e235";
}
.glyphicon-menu-hamburger:before {
content: "\e236";
}
.glyphicon-modal-window:before {
content: "\e237";
}
.glyphicon-oil:before {
content: "\e238";
}
.glyphicon-grain:before {
content: "\e239";
}
.glyphicon-sunglasses:before {
content: "\e240";
}
.glyphicon-text-size:before {
content: "\e241";
}
.glyphicon-text-color:before {
content: "\e242";
}
.glyphicon-text-background:before {
content: "\e243";
}
.glyphicon-object-align-top:before {
content: "\e244";
}
.glyphicon-object-align-bottom:before {
content: "\e245";
}
.glyphicon-object-align-horizontal:before {
content: "\e246";
}
.glyphicon-object-align-left:before {
content: "\e247";
}
.glyphicon-object-align-vertical:before {
content: "\e248";
}
.glyphicon-object-align-right:before {
content: "\e249";
}
.glyphicon-triangle-right:before {
content: "\e250";
}
.glyphicon-triangle-left:before {
content: "\e251";
}
.glyphicon-triangle-bottom:before {
content: "\e252";
}
.glyphicon-triangle-top:before {
content: "\e253";
}
.glyphicon-console:before {
content: "\e254";
}
.glyphicon-superscript:before {
content: "\e255";
}
.glyphicon-subscript:before {
content: "\e256";
}
.glyphicon-menu-left:before {
content: "\e257";
}
.glyphicon-menu-right:before {
content: "\e258";
}
.glyphicon-menu-down:before {
content: "\e259";
}
.glyphicon-menu-up:before {
content: "\e260";
}
* {
-webkit-box-sizing: border-box;
-moz-box-sizing: border-box;
box-sizing: border-box;
}
*:before,
*:after {
-webkit-box-sizing: border-box;
-moz-box-sizing: border-box;
box-sizing: border-box;
}
html {
font-size: 10px;
-webkit-tap-highlight-color: rgba(0, 0, 0, 0);
}
body {
font-family: "Roboto", "Helvetica Neue", Helvetica, Arial, sans-serif;
font-size: 13px;
line-height: 1.846;
color: #666666;
background-color: #ffffff;
}
input,
button,
select,
textarea {
font-family: inherit;
font-size: inherit;
line-height: inherit;
}
a {
color: #2196f3;
text-decoration: none;
}
a:hover,
a:focus {
color: #0a6ebd;
text-decoration: underline;
}
a:focus {
outline: 5px auto -webkit-focus-ring-color;
outline-offset: -2px;
}
figure {
margin: 0;
}
img {
vertical-align: middle;
}
.img-responsive,
.thumbnail > img,
.thumbnail a > img,
.carousel-inner > .item > img,
.carousel-inner > .item > a > img {
display: block;
max-width: 100%;
height: auto;
}
.img-rounded {
border-radius: 3px;
}
.img-thumbnail {
padding: 4px;
line-height: 1.846;
background-color: #ffffff;
border: 1px solid #dddddd;
border-radius: 3px;
-webkit-transition: all 0.2s ease-in-out;
-o-transition: all 0.2s ease-in-out;
transition: all 0.2s ease-in-out;
display: inline-block;
max-width: 100%;
height: auto;
}
.img-circle {
border-radius: 50%;
}
hr {
margin-top: 23px;
margin-bottom: 23px;
border: 0;
border-top: 1px solid #eeeeee;
}
.sr-only {
position: absolute;
width: 1px;
height: 1px;
margin: -1px;
padding: 0;
overflow: hidden;
clip: rect(0, 0, 0, 0);
border: 0;
}
.sr-only-focusable:active,
.sr-only-focusable:focus {
position: static;
width: auto;
height: auto;
margin: 0;
overflow: visible;
clip: auto;
}
[role="button"] {
cursor: pointer;
}
h1,
h2,
h3,
h4,
h5,
h6,
.h1,
.h2,
.h3,
.h4,
.h5,
.h6 {
font-family: inherit;
font-weight: 400;
line-height: 1.1;
color: #444444;
}
h1 small,
h2 small,
h3 small,
h4 small,
h5 small,
h6 small,
.h1 small,
.h2 small,
.h3 small,
.h4 small,
.h5 small,
.h6 small,
h1 .small,
h2 .small,
h3 .small,
h4 .small,
h5 .small,
h6 .small,
.h1 .small,
.h2 .small,
.h3 .small,
.h4 .small,
.h5 .small,
.h6 .small {
font-weight: normal;
line-height: 1;
color: #bbbbbb;
}
h1,
.h1,
h2,
.h2,
h3,
.h3 {
margin-top: 23px;
margin-bottom: 11.5px;
}
h1 small,
.h1 small,
h2 small,
.h2 small,
h3 small,
.h3 small,
h1 .small,
.h1 .small,
h2 .small,
.h2 .small,
h3 .small,
.h3 .small {
font-size: 65%;
}
h4,
.h4,
h5,
.h5,
h6,
.h6 {
margin-top: 11.5px;
margin-bottom: 11.5px;
}
h4 small,
.h4 small,
h5 small,
.h5 small,
h6 small,
.h6 small,
h4 .small,
.h4 .small,
h5 .small,
.h5 .small,
h6 .small,
.h6 .small {
font-size: 75%;
}
h1,
.h1 {
font-size: 56px;
}
h2,
.h2 {
font-size: 45px;
}
h3,
.h3 {
font-size: 34px;
}
h4,
.h4 {
font-size: 24px;
}
h5,
.h5 {
font-size: 20px;
}
h6,
.h6 {
font-size: 14px;
}
p {
margin: 0 0 11.5px;
}
.lead {
margin-bottom: 23px;
font-size: 14px;
font-weight: 300;
line-height: 1.4;
}
@media (min-width: 768px) {
.lead {
font-size: 19.5px;
}
}
small,
.small {
font-size: 92%;
}
mark,
.mark {
background-color: #ffe0b2;
padding: .2em;
}
.text-left {
text-align: left;
}
.text-right {
text-align: right;
}
.text-center {
text-align: center;
}
.text-justify {
text-align: justify;
}
.text-nowrap {
white-space: nowrap;
}
.text-lowercase {
text-transform: lowercase;
}
.text-uppercase {
text-transform: uppercase;
}
.text-capitalize {
text-transform: capitalize;
}
.text-muted {
color: #bbbbbb;
}
.text-primary {
color: #2196f3;
}
a.text-primary:hover,
a.text-primary:focus {
color: #0c7cd5;
}
.text-success {
color: #4caf50;
}
a.text-success:hover,
a.text-success:focus {
color: #3d8b40;
}
.text-info {
color: #9c27b0;
}
a.text-info:hover,
a.text-info:focus {
color: #771e86;
}
.text-warning {
color: #ff9800;
}
a.text-warning:hover,
a.text-warning:focus {
color: #cc7a00;
}
.text-danger {
color: #e51c23;
}
a.text-danger:hover,
a.text-danger:focus {
color: #b9151b;
}
.bg-primary {
color: #fff;
background-color: #2196f3;
}
a.bg-primary:hover,
a.bg-primary:focus {
background-color: #0c7cd5;
}
.bg-success {
background-color: #dff0d8;
}
a.bg-success:hover,
a.bg-success:focus {
background-color: #c1e2b3;
}
.bg-info {
background-color: #e1bee7;
}
a.bg-info:hover,
a.bg-info:focus {
background-color: #d099d9;
}
.bg-warning {
background-color: #ffe0b2;
}
a.bg-warning:hover,
a.bg-warning:focus {
background-color: #ffcb7f;
}
.bg-danger {
background-color: #f9bdbb;
}
a.bg-danger:hover,
a.bg-danger:focus {
background-color: #f5908c;
}
.page-header {
padding-bottom: 10.5px;
margin: 46px 0 23px;
border-bottom: 1px solid #eeeeee;
}
ul,
ol {
margin-top: 0;
margin-bottom: 11.5px;
}
ul ul,
ol ul,
ul ol,
ol ol {
margin-bottom: 0;
}
.list-unstyled {
padding-left: 0;
list-style: none;
}
.list-inline {
padding-left: 0;
list-style: none;
margin-left: -5px;
}
.list-inline > li {
display: inline-block;
padding-left: 5px;
padding-right: 5px;
}
dl {
margin-top: 0;
margin-bottom: 23px;
}
dt,
dd {
line-height: 1.846;
}
dt {
font-weight: bold;
}
dd {
margin-left: 0;
}
@media (min-width: 768px) {
.dl-horizontal dt {
float: left;
width: 160px;
clear: left;
text-align: right;
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
}
.dl-horizontal dd {
margin-left: 180px;
}
}
abbr[title],
abbr[data-original-title] {
cursor: help;
border-bottom: 1px dotted #bbbbbb;
}
.initialism {
font-size: 90%;
text-transform: uppercase;
}
blockquote {
padding: 11.5px 23px;
margin: 0 0 23px;
font-size: 16.25px;
border-left: 5px solid #eeeeee;
}
blockquote p:last-child,
blockquote ul:last-child,
blockquote ol:last-child {
margin-bottom: 0;
}
blockquote footer,
blockquote small,
blockquote .small {
display: block;
font-size: 80%;
line-height: 1.846;
color: #bbbbbb;
}
blockquote footer:before,
blockquote small:before,
blockquote .small:before {
content: '\2014 \00A0';
}
.blockquote-reverse,
blockquote.pull-right {
padding-right: 15px;
padding-left: 0;
border-right: 5px solid #eeeeee;
border-left: 0;
text-align: right;
}
.blockquote-reverse footer:before,
blockquote.pull-right footer:before,
.blockquote-reverse small:before,
blockquote.pull-right small:before,
.blockquote-reverse .small:before,
blockquote.pull-right .small:before {
content: '';
}
.blockquote-reverse footer:after,
blockquote.pull-right footer:after,
.blockquote-reverse small:after,
blockquote.pull-right small:after,
.blockquote-reverse .small:after,
blockquote.pull-right .small:after {
content: '\00A0 \2014';
}
address {
margin-bottom: 23px;
font-style: normal;
line-height: 1.846;
}
code,
kbd,
pre,
samp {
font-family: Menlo, Monaco, Consolas, "Courier New", monospace;
}
code {
padding: 2px 4px;
font-size: 90%;
color: #444444;
background-color: #f8f8f8;
border-radius: 3px;
}
kbd {
padding: 2px 4px;
font-size: 90%;
color: #ffffff;
background-color: #333333;
border-radius: 3px;
box-shadow: inset 0 -1px 0 rgba(0, 0, 0, 0.25);
}
kbd kbd {
padding: 0;
font-size: 100%;
font-weight: bold;
box-shadow: none;
}
pre {
display: block;
padding: 11px;
margin: 0 0 11.5px;
font-size: 12px;
line-height: 1.846;
word-break: break-all;
word-wrap: break-word;
color: #212121;
background-color: #f5f5f5;
border: 1px solid #cccccc;
border-radius: 3px;
}
pre code {
padding: 0;
font-size: inherit;
color: inherit;
white-space: pre-wrap;
background-color: transparent;
border-radius: 0;
}
.pre-scrollable {
max-height: 340px;
overflow-y: scroll;
}
.container {
margin-right: auto;
margin-left: auto;
padding-left: 15px;
padding-right: 15px;
}
@media (min-width: 768px) {
.container {
width: 750px;
}
}
@media (min-width: 992px) {
.container {
width: 970px;
}
}
@media (min-width: 1200px) {
.container {
width: 1170px;
}
}
.container-fluid {
margin-right: auto;
margin-left: auto;
padding-left: 15px;
padding-right: 15px;
}
.row {
margin-left: -15px;
margin-right: -15px;
}
.col-xs-1, .col-sm-1, .col-md-1, .col-lg-1, .col-xs-2, .col-sm-2, .col-md-2, .col-lg-2, .col-xs-3, .col-sm-3, .col-md-3, .col-lg-3, .col-xs-4, .col-sm-4, .col-md-4, .col-lg-4, .col-xs-5, .col-sm-5, .col-md-5, .col-lg-5, .col-xs-6, .col-sm-6, .col-md-6, .col-lg-6, .col-xs-7, .col-sm-7, .col-md-7, .col-lg-7, .col-xs-8, .col-sm-8, .col-md-8, .col-lg-8, .col-xs-9, .col-sm-9, .col-md-9, .col-lg-9, .col-xs-10, .col-sm-10, .col-md-10, .col-lg-10, .col-xs-11, .col-sm-11, .col-md-11, .col-lg-11, .col-xs-12, .col-sm-12, .col-md-12, .col-lg-12 {
position: relative;
min-height: 1px;
padding-left: 15px;
padding-right: 15px;
}
.col-xs-1, .col-xs-2, .col-xs-3, .col-xs-4, .col-xs-5, .col-xs-6, .col-xs-7, .col-xs-8, .col-xs-9, .col-xs-10, .col-xs-11, .col-xs-12 {
float: left;
}
.col-xs-12 {
width: 100%;
}
.col-xs-11 {
width: 91.66666667%;
}
.col-xs-10 {
width: 83.33333333%;
}
.col-xs-9 {
width: 75%;
}
.col-xs-8 {
width: 66.66666667%;
}
.col-xs-7 {
width: 58.33333333%;
}
.col-xs-6 {
width: 50%;
}
.col-xs-5 {
width: 41.66666667%;
}
.col-xs-4 {
width: 33.33333333%;
}
.col-xs-3 {
width: 25%;
}
.col-xs-2 {
width: 16.66666667%;
}
.col-xs-1 {
width: 8.33333333%;
}
.col-xs-pull-12 {
right: 100%;
}
.col-xs-pull-11 {
right: 91.66666667%;
}
.col-xs-pull-10 {
right: 83.33333333%;
}
.col-xs-pull-9 {
right: 75%;
}
.col-xs-pull-8 {
right: 66.66666667%;
}
.col-xs-pull-7 {
right: 58.33333333%;
}
.col-xs-pull-6 {
right: 50%;
}
.col-xs-pull-5 {
right: 41.66666667%;
}
.col-xs-pull-4 {
right: 33.33333333%;
}
.col-xs-pull-3 {
right: 25%;
}
.col-xs-pull-2 {
right: 16.66666667%;
}
.col-xs-pull-1 {
right: 8.33333333%;
}
.col-xs-pull-0 {
right: auto;
}
.col-xs-push-12 {
left: 100%;
}
.col-xs-push-11 {
left: 91.66666667%;
}
.col-xs-push-10 {
left: 83.33333333%;
}
.col-xs-push-9 {
left: 75%;
}
.col-xs-push-8 {
left: 66.66666667%;
}
.col-xs-push-7 {
left: 58.33333333%;
}
.col-xs-push-6 {
left: 50%;
}
.col-xs-push-5 {
left: 41.66666667%;
}
.col-xs-push-4 {
left: 33.33333333%;
}
.col-xs-push-3 {
left: 25%;
}
.col-xs-push-2 {
left: 16.66666667%;
}
.col-xs-push-1 {
left: 8.33333333%;
}
.col-xs-push-0 {
left: auto;
}
.col-xs-offset-12 {
margin-left: 100%;
}
.col-xs-offset-11 {
margin-left: 91.66666667%;
}
.col-xs-offset-10 {
margin-left: 83.33333333%;
}
.col-xs-offset-9 {
margin-left: 75%;
}
.col-xs-offset-8 {
margin-left: 66.66666667%;
}
.col-xs-offset-7 {
margin-left: 58.33333333%;
}
.col-xs-offset-6 {
margin-left: 50%;
}
.col-xs-offset-5 {
margin-left: 41.66666667%;
}
.col-xs-offset-4 {
margin-left: 33.33333333%;
}
.col-xs-offset-3 {
margin-left: 25%;
}
.col-xs-offset-2 {
margin-left: 16.66666667%;
}
.col-xs-offset-1 {
margin-left: 8.33333333%;
}
.col-xs-offset-0 {
margin-left: 0%;
}
@media (min-width: 768px) {
.col-sm-1, .col-sm-2, .col-sm-3, .col-sm-4, .col-sm-5, .col-sm-6, .col-sm-7, .col-sm-8, .col-sm-9, .col-sm-10, .col-sm-11, .col-sm-12 {
float: left;
}
.col-sm-12 {
width: 100%;
}
.col-sm-11 {
width: 91.66666667%;
}
.col-sm-10 {
width: 83.33333333%;
}
.col-sm-9 {
width: 75%;
}
.col-sm-8 {
width: 66.66666667%;
}
.col-sm-7 {
width: 58.33333333%;
}
.col-sm-6 {
width: 50%;
}
.col-sm-5 {
width: 41.66666667%;
}
.col-sm-4 {
width: 33.33333333%;
}
.col-sm-3 {
width: 25%;
}
.col-sm-2 {
width: 16.66666667%;
}
.col-sm-1 {
width: 8.33333333%;
}
.col-sm-pull-12 {
right: 100%;
}
.col-sm-pull-11 {
right: 91.66666667%;
}
.col-sm-pull-10 {
right: 83.33333333%;
}
.col-sm-pull-9 {
right: 75%;
}
.col-sm-pull-8 {
right: 66.66666667%;
}
.col-sm-pull-7 {
right: 58.33333333%;
}
.col-sm-pull-6 {
right: 50%;
}
.col-sm-pull-5 {
right: 41.66666667%;
}
.col-sm-pull-4 {
right: 33.33333333%;
}
.col-sm-pull-3 {
right: 25%;
}
.col-sm-pull-2 {
right: 16.66666667%;
}
.col-sm-pull-1 {
right: 8.33333333%;
}
.col-sm-pull-0 {
right: auto;
}
.col-sm-push-12 {
left: 100%;
}
.col-sm-push-11 {
left: 91.66666667%;
}
.col-sm-push-10 {
left: 83.33333333%;
}
.col-sm-push-9 {
left: 75%;
}
.col-sm-push-8 {
left: 66.66666667%;
}
.col-sm-push-7 {
left: 58.33333333%;
}
.col-sm-push-6 {
left: 50%;
}
.col-sm-push-5 {
left: 41.66666667%;
}
.col-sm-push-4 {
left: 33.33333333%;
}
.col-sm-push-3 {
left: 25%;
}
.col-sm-push-2 {
left: 16.66666667%;
}
.col-sm-push-1 {
left: 8.33333333%;
}
.col-sm-push-0 {
left: auto;
}
.col-sm-offset-12 {
margin-left: 100%;
}
.col-sm-offset-11 {
margin-left: 91.66666667%;
}
.col-sm-offset-10 {
margin-left: 83.33333333%;
}
.col-sm-offset-9 {
margin-left: 75%;
}
.col-sm-offset-8 {
margin-left: 66.66666667%;
}
.col-sm-offset-7 {
margin-left: 58.33333333%;
}
.col-sm-offset-6 {
margin-left: 50%;
}
.col-sm-offset-5 {
margin-left: 41.66666667%;
}
.col-sm-offset-4 {
margin-left: 33.33333333%;
}
.col-sm-offset-3 {
margin-left: 25%;
}
.col-sm-offset-2 {
margin-left: 16.66666667%;
}
.col-sm-offset-1 {
margin-left: 8.33333333%;
}
.col-sm-offset-0 {
margin-left: 0%;
}
}
@media (min-width: 992px) {
.col-md-1, .col-md-2, .col-md-3, .col-md-4, .col-md-5, .col-md-6, .col-md-7, .col-md-8, .col-md-9, .col-md-10, .col-md-11, .col-md-12 {
float: left;
}
.col-md-12 {
width: 100%;
}
.col-md-11 {
width: 91.66666667%;
}
.col-md-10 {
width: 83.33333333%;
}
.col-md-9 {
width: 75%;
}
.col-md-8 {
width: 66.66666667%;
}
.col-md-7 {
width: 58.33333333%;
}
.col-md-6 {
width: 50%;
}
.col-md-5 {
width: 41.66666667%;
}
.col-md-4 {
width: 33.33333333%;
}
.col-md-3 {
width: 25%;
}
.col-md-2 {
width: 16.66666667%;
}
.col-md-1 {
width: 8.33333333%;
}
.col-md-pull-12 {
right: 100%;
}
.col-md-pull-11 {
right: 91.66666667%;
}
.col-md-pull-10 {
right: 83.33333333%;
}
.col-md-pull-9 {
right: 75%;
}
.col-md-pull-8 {
right: 66.66666667%;
}
.col-md-pull-7 {
right: 58.33333333%;
}
.col-md-pull-6 {
right: 50%;
}
.col-md-pull-5 {
right: 41.66666667%;
}
.col-md-pull-4 {
right: 33.33333333%;
}
.col-md-pull-3 {
right: 25%;
}
.col-md-pull-2 {
right: 16.66666667%;
}
.col-md-pull-1 {
right: 8.33333333%;
}
.col-md-pull-0 {
right: auto;
}
.col-md-push-12 {
left: 100%;
}
.col-md-push-11 {
left: 91.66666667%;
}
.col-md-push-10 {
left: 83.33333333%;
}
.col-md-push-9 {
left: 75%;
}
.col-md-push-8 {
left: 66.66666667%;
}
.col-md-push-7 {
left: 58.33333333%;
}
.col-md-push-6 {
left: 50%;
}
.col-md-push-5 {
left: 41.66666667%;
}
.col-md-push-4 {
left: 33.33333333%;
}
.col-md-push-3 {
left: 25%;
}
.col-md-push-2 {
left: 16.66666667%;
}
.col-md-push-1 {
left: 8.33333333%;
}
.col-md-push-0 {
left: auto;
}
.col-md-offset-12 {
margin-left: 100%;
}
.col-md-offset-11 {
margin-left: 91.66666667%;
}
.col-md-offset-10 {
margin-left: 83.33333333%;
}
.col-md-offset-9 {
margin-left: 75%;
}
.col-md-offset-8 {
margin-left: 66.66666667%;
}
.col-md-offset-7 {
margin-left: 58.33333333%;
}
.col-md-offset-6 {
margin-left: 50%;
}
.col-md-offset-5 {
margin-left: 41.66666667%;
}
.col-md-offset-4 {
margin-left: 33.33333333%;
}
.col-md-offset-3 {
margin-left: 25%;
}
.col-md-offset-2 {
margin-left: 16.66666667%;
}
.col-md-offset-1 {
margin-left: 8.33333333%;
}
.col-md-offset-0 {
margin-left: 0%;
}
}
@media (min-width: 1200px) {
.col-lg-1, .col-lg-2, .col-lg-3, .col-lg-4, .col-lg-5, .col-lg-6, .col-lg-7, .col-lg-8, .col-lg-9, .col-lg-10, .col-lg-11, .col-lg-12 {
float: left;
}
.col-lg-12 {
width: 100%;
}
.col-lg-11 {
width: 91.66666667%;
}
.col-lg-10 {
width: 83.33333333%;
}
.col-lg-9 {
width: 75%;
}
.col-lg-8 {
width: 66.66666667%;
}
.col-lg-7 {
width: 58.33333333%;
}
.col-lg-6 {
width: 50%;
}
.col-lg-5 {
width: 41.66666667%;
}
.col-lg-4 {
width: 33.33333333%;
}
.col-lg-3 {
width: 25%;
}
.col-lg-2 {
width: 16.66666667%;
}
.col-lg-1 {
width: 8.33333333%;
}
.col-lg-pull-12 {
right: 100%;
}
.col-lg-pull-11 {
right: 91.66666667%;
}
.col-lg-pull-10 {
right: 83.33333333%;
}
.col-lg-pull-9 {
right: 75%;
}
.col-lg-pull-8 {
right: 66.66666667%;
}
.col-lg-pull-7 {
right: 58.33333333%;
}
.col-lg-pull-6 {
right: 50%;
}
.col-lg-pull-5 {
right: 41.66666667%;
}
.col-lg-pull-4 {
right: 33.33333333%;
}
.col-lg-pull-3 {
right: 25%;
}
.col-lg-pull-2 {
right: 16.66666667%;
}
.col-lg-pull-1 {
right: 8.33333333%;
}
.col-lg-pull-0 {
right: auto;
}
.col-lg-push-12 {
left: 100%;
}
.col-lg-push-11 {
left: 91.66666667%;
}
.col-lg-push-10 {
left: 83.33333333%;
}
.col-lg-push-9 {
left: 75%;
}
.col-lg-push-8 {
left: 66.66666667%;
}
.col-lg-push-7 {
left: 58.33333333%;
}
.col-lg-push-6 {
left: 50%;
}
.col-lg-push-5 {
left: 41.66666667%;
}
.col-lg-push-4 {
left: 33.33333333%;
}
.col-lg-push-3 {
left: 25%;
}
.col-lg-push-2 {
left: 16.66666667%;
}
.col-lg-push-1 {
left: 8.33333333%;
}
.col-lg-push-0 {
left: auto;
}
.col-lg-offset-12 {
margin-left: 100%;
}
.col-lg-offset-11 {
margin-left: 91.66666667%;
}
.col-lg-offset-10 {
margin-left: 83.33333333%;
}
.col-lg-offset-9 {
margin-left: 75%;
}
.col-lg-offset-8 {
margin-left: 66.66666667%;
}
.col-lg-offset-7 {
margin-left: 58.33333333%;
}
.col-lg-offset-6 {
margin-left: 50%;
}
.col-lg-offset-5 {
margin-left: 41.66666667%;
}
.col-lg-offset-4 {
margin-left: 33.33333333%;
}
.col-lg-offset-3 {
margin-left: 25%;
}
.col-lg-offset-2 {
margin-left: 16.66666667%;
}
.col-lg-offset-1 {
margin-left: 8.33333333%;
}
.col-lg-offset-0 {
margin-left: 0%;
}
}
table {
background-color: transparent;
}
caption {
padding-top: 8px;
padding-bottom: 8px;
color: #bbbbbb;
text-align: left;
}
th {
text-align: left;
}
.table {
width: 100%;
max-width: 100%;
margin-bottom: 23px;
}
.table > thead > tr > th,
.table > tbody > tr > th,
.table > tfoot > tr > th,
.table > thead > tr > td,
.table > tbody > tr > td,
.table > tfoot > tr > td {
padding: 8px;
line-height: 1.846;
vertical-align: top;
border-top: 1px solid #dddddd;
}
.table > thead > tr > th {
vertical-align: bottom;
border-bottom: 2px solid #dddddd;
}
.table > caption + thead > tr:first-child > th,
.table > colgroup + thead > tr:first-child > th,
.table > thead:first-child > tr:first-child > th,
.table > caption + thead > tr:first-child > td,
.table > colgroup + thead > tr:first-child > td,
.table > thead:first-child > tr:first-child > td {
border-top: 0;
}
.table > tbody + tbody {
border-top: 2px solid #dddddd;
}
.table .table {
background-color: #ffffff;
}
.table-condensed > thead > tr > th,
.table-condensed > tbody > tr > th,
.table-condensed > tfoot > tr > th,
.table-condensed > thead > tr > td,
.table-condensed > tbody > tr > td,
.table-condensed > tfoot > tr > td {
padding: 5px;
}
.table-bordered {
border: 1px solid #dddddd;
}
.table-bordered > thead > tr > th,
.table-bordered > tbody > tr > th,
.table-bordered > tfoot > tr > th,
.table-bordered > thead > tr > td,
.table-bordered > tbody > tr > td,
.table-bordered > tfoot > tr > td {
border: 1px solid #dddddd;
}
.table-bordered > thead > tr > th,
.table-bordered > thead > tr > td {
border-bottom-width: 2px;
}
.table-striped > tbody > tr:nth-of-type(odd) {
background-color: #f9f9f9;
}
.table-hover > tbody > tr:hover {
background-color: #f5f5f5;
}
table col[class*="col-"] {
position: static;
float: none;
display: table-column;
}
table td[class*="col-"],
table th[class*="col-"] {
position: static;
float: none;
display: table-cell;
}
.table > thead > tr > td.active,
.table > tbody > tr > td.active,
.table > tfoot > tr > td.active,
.table > thead > tr > th.active,
.table > tbody > tr > th.active,
.table > tfoot > tr > th.active,
.table > thead > tr.active > td,
.table > tbody > tr.active > td,
.table > tfoot > tr.active > td,
.table > thead > tr.active > th,
.table > tbody > tr.active > th,
.table > tfoot > tr.active > th {
background-color: #f5f5f5;
}
.table-hover > tbody > tr > td.active:hover,
.table-hover > tbody > tr > th.active:hover,
.table-hover > tbody > tr.active:hover > td,
.table-hover > tbody > tr:hover > .active,
.table-hover > tbody > tr.active:hover > th {
background-color: #e8e8e8;
}
.table > thead > tr > td.success,
.table > tbody > tr > td.success,
.table > tfoot > tr > td.success,
.table > thead > tr > th.success,
.table > tbody > tr > th.success,
.table > tfoot > tr > th.success,
.table > thead > tr.success > td,
.table > tbody > tr.success > td,
.table > tfoot > tr.success > td,
.table > thead > tr.success > th,
.table > tbody > tr.success > th,
.table > tfoot > tr.success > th {
background-color: #dff0d8;
}
.table-hover > tbody > tr > td.success:hover,
.table-hover > tbody > tr > th.success:hover,
.table-hover > tbody > tr.success:hover > td,
.table-hover > tbody > tr:hover > .success,
.table-hover > tbody > tr.success:hover > th {
background-color: #d0e9c6;
}
.table > thead > tr > td.info,
.table > tbody > tr > td.info,
.table > tfoot > tr > td.info,
.table > thead > tr > th.info,
.table > tbody > tr > th.info,
.table > tfoot > tr > th.info,
.table > thead > tr.info > td,
.table > tbody > tr.info > td,
.table > tfoot > tr.info > td,
.table > thead > tr.info > th,
.table > tbody > tr.info > th,
.table > tfoot > tr.info > th {
background-color: #e1bee7;
}
.table-hover > tbody > tr > td.info:hover,
.table-hover > tbody > tr > th.info:hover,
.table-hover > tbody > tr.info:hover > td,
.table-hover > tbody > tr:hover > .info,
.table-hover > tbody > tr.info:hover > th {
background-color: #d8abe0;
}
.table > thead > tr > td.warning,
.table > tbody > tr > td.warning,
.table > tfoot > tr > td.warning,
.table > thead > tr > th.warning,
.table > tbody > tr > th.warning,
.table > tfoot > tr > th.warning,
.table > thead > tr.warning > td,
.table > tbody > tr.warning > td,
.table > tfoot > tr.warning > td,
.table > thead > tr.warning > th,
.table > tbody > tr.warning > th,
.table > tfoot > tr.warning > th {
background-color: #ffe0b2;
}
.table-hover > tbody > tr > td.warning:hover,
.table-hover > tbody > tr > th.warning:hover,
.table-hover > tbody > tr.warning:hover > td,
.table-hover > tbody > tr:hover > .warning,
.table-hover > tbody > tr.warning:hover > th {
background-color: #ffd699;
}
.table > thead > tr > td.danger,
.table > tbody > tr > td.danger,
.table > tfoot > tr > td.danger,
.table > thead > tr > th.danger,
.table > tbody > tr > th.danger,
.table > tfoot > tr > th.danger,
.table > thead > tr.danger > td,
.table > tbody > tr.danger > td,
.table > tfoot > tr.danger > td,
.table > thead > tr.danger > th,
.table > tbody > tr.danger > th,
.table > tfoot > tr.danger > th {
background-color: #f9bdbb;
}
.table-hover > tbody > tr > td.danger:hover,
.table-hover > tbody > tr > th.danger:hover,
.table-hover > tbody > tr.danger:hover > td,
.table-hover > tbody > tr:hover > .danger,
.table-hover > tbody > tr.danger:hover > th {
background-color: #f7a6a4;
}
.table-responsive {
overflow-x: auto;
min-height: 0.01%;
}
@media screen and (max-width: 767px) {
.table-responsive {
width: 100%;
margin-bottom: 17.25px;
overflow-y: hidden;
-ms-overflow-style: -ms-autohiding-scrollbar;
border: 1px solid #dddddd;
}
.table-responsive > .table {
margin-bottom: 0;
}
.table-responsive > .table > thead > tr > th,
.table-responsive > .table > tbody > tr > th,
.table-responsive > .table > tfoot > tr > th,
.table-responsive > .table > thead > tr > td,
.table-responsive > .table > tbody > tr > td,
.table-responsive > .table > tfoot > tr > td {
white-space: nowrap;
}
.table-responsive > .table-bordered {
border: 0;
}
.table-responsive > .table-bordered > thead > tr > th:first-child,
.table-responsive > .table-bordered > tbody > tr > th:first-child,
.table-responsive > .table-bordered > tfoot > tr > th:first-child,
.table-responsive > .table-bordered > thead > tr > td:first-child,
.table-responsive > .table-bordered > tbody > tr > td:first-child,
.table-responsive > .table-bordered > tfoot > tr > td:first-child {
border-left: 0;
}
.table-responsive > .table-bordered > thead > tr > th:last-child,
.table-responsive > .table-bordered > tbody > tr > th:last-child,
.table-responsive > .table-bordered > tfoot > tr > th:last-child,
.table-responsive > .table-bordered > thead > tr > td:last-child,
.table-responsive > .table-bordered > tbody > tr > td:last-child,
.table-responsive > .table-bordered > tfoot > tr > td:last-child {
border-right: 0;
}
.table-responsive > .table-bordered > tbody > tr:last-child > th,
.table-responsive > .table-bordered > tfoot > tr:last-child > th,
.table-responsive > .table-bordered > tbody > tr:last-child > td,
.table-responsive > .table-bordered > tfoot > tr:last-child > td {
border-bottom: 0;
}
}
fieldset {
padding: 0;
margin: 0;
border: 0;
min-width: 0;
}
legend {
display: block;
width: 100%;
padding: 0;
margin-bottom: 23px;
font-size: 19.5px;
line-height: inherit;
color: #212121;
border: 0;
border-bottom: 1px solid #e5e5e5;
}
label {
display: inline-block;
max-width: 100%;
margin-bottom: 5px;
font-weight: bold;
}
input[type="search"] {
-webkit-box-sizing: border-box;
-moz-box-sizing: border-box;
box-sizing: border-box;
}
input[type="radio"],
input[type="checkbox"] {
margin: 4px 0 0;
margin-top: 1px \9;
line-height: normal;
}
input[type="file"] {
display: block;
}
input[type="range"] {
display: block;
width: 100%;
}
select[multiple],
select[size] {
height: auto;
}
input[type="file"]:focus,
input[type="radio"]:focus,
input[type="checkbox"]:focus {
outline: 5px auto -webkit-focus-ring-color;
outline-offset: -2px;
}
output {
display: block;
padding-top: 7px;
font-size: 13px;
line-height: 1.846;
color: #666666;
}
.form-control {
display: block;
width: 100%;
height: 37px;
padding: 6px 16px;
font-size: 13px;
line-height: 1.846;
color: #666666;
background-color: transparent;
background-image: none;
border: 1px solid transparent;
border-radius: 3px;
-webkit-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075);
box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075);
-webkit-transition: border-color ease-in-out .15s, box-shadow ease-in-out .15s;
-o-transition: border-color ease-in-out .15s, box-shadow ease-in-out .15s;
transition: border-color ease-in-out .15s, box-shadow ease-in-out .15s;
}
.form-control:focus {
border-color: #66afe9;
outline: 0;
-webkit-box-shadow: inset 0 1px 1px rgba(0,0,0,.075), 0 0 8px rgba(102, 175, 233, 0.6);
box-shadow: inset 0 1px 1px rgba(0,0,0,.075), 0 0 8px rgba(102, 175, 233, 0.6);
}
.form-control::-moz-placeholder {
color: #bbbbbb;
opacity: 1;
}
.form-control:-ms-input-placeholder {
color: #bbbbbb;
}
.form-control::-webkit-input-placeholder {
color: #bbbbbb;
}
.form-control::-ms-expand {
border: 0;
background-color: transparent;
}
.form-control[disabled],
.form-control[readonly],
fieldset[disabled] .form-control {
background-color: transparent;
opacity: 1;
}
.form-control[disabled],
fieldset[disabled] .form-control {
cursor: not-allowed;
}
textarea.form-control {
height: auto;
}
input[type="search"] {
-webkit-appearance: none;
}
@media screen and (-webkit-min-device-pixel-ratio: 0) {
input[type="date"].form-control,
input[type="time"].form-control,
input[type="datetime-local"].form-control,
input[type="month"].form-control {
line-height: 37px;
}
input[type="date"].input-sm,
input[type="time"].input-sm,
input[type="datetime-local"].input-sm,
input[type="month"].input-sm,
.input-group-sm input[type="date"],
.input-group-sm input[type="time"],
.input-group-sm input[type="datetime-local"],
.input-group-sm input[type="month"] {
line-height: 30px;
}
input[type="date"].input-lg,
input[type="time"].input-lg,
input[type="datetime-local"].input-lg,
input[type="month"].input-lg,
.input-group-lg input[type="date"],
.input-group-lg input[type="time"],
.input-group-lg input[type="datetime-local"],
.input-group-lg input[type="month"] {
line-height: 45px;
}
}
.form-group {
margin-bottom: 15px;
}
.radio,
.checkbox {
position: relative;
display: block;
margin-top: 10px;
margin-bottom: 10px;
}
.radio label,
.checkbox label {
min-height: 23px;
padding-left: 20px;
margin-bottom: 0;
font-weight: normal;
cursor: pointer;
}
.radio input[type="radio"],
.radio-inline input[type="radio"],
.checkbox input[type="checkbox"],
.checkbox-inline input[type="checkbox"] {
position: absolute;
margin-left: -20px;
margin-top: 4px \9;
}
.radio + .radio,
.checkbox + .checkbox {
margin-top: -5px;
}
.radio-inline,
.checkbox-inline {
position: relative;
display: inline-block;
padding-left: 20px;
margin-bottom: 0;
vertical-align: middle;
font-weight: normal;
cursor: pointer;
}
.radio-inline + .radio-inline,
.checkbox-inline + .checkbox-inline {
margin-top: 0;
margin-left: 10px;
}
input[type="radio"][disabled],
input[type="checkbox"][disabled],
input[type="radio"].disabled,
input[type="checkbox"].disabled,
fieldset[disabled] input[type="radio"],
fieldset[disabled] input[type="checkbox"] {
cursor: not-allowed;
}
.radio-inline.disabled,
.checkbox-inline.disabled,
fieldset[disabled] .radio-inline,
fieldset[disabled] .checkbox-inline {
cursor: not-allowed;
}
.radio.disabled label,
.checkbox.disabled label,
fieldset[disabled] .radio label,
fieldset[disabled] .checkbox label {
cursor: not-allowed;
}
.form-control-static {
padding-top: 7px;
padding-bottom: 7px;
margin-bottom: 0;
min-height: 36px;
}
.form-control-static.input-lg,
.form-control-static.input-sm {
padding-left: 0;
padding-right: 0;
}
.input-sm {
height: 30px;
padding: 5px 10px;
font-size: 12px;
line-height: 1.5;
border-radius: 3px;
}
select.input-sm {
height: 30px;
line-height: 30px;
}
textarea.input-sm,
select[multiple].input-sm {
height: auto;
}
.form-group-sm .form-control {
height: 30px;
padding: 5px 10px;
font-size: 12px;
line-height: 1.5;
border-radius: 3px;
}
.form-group-sm select.form-control {
height: 30px;
line-height: 30px;
}
.form-group-sm textarea.form-control,
.form-group-sm select[multiple].form-control {
height: auto;
}
.form-group-sm .form-control-static {
height: 30px;
min-height: 35px;
padding: 6px 10px;
font-size: 12px;
line-height: 1.5;
}
.input-lg {
height: 45px;
padding: 10px 16px;
font-size: 17px;
line-height: 1.3333333;
border-radius: 3px;
}
select.input-lg {
height: 45px;
line-height: 45px;
}
textarea.input-lg,
select[multiple].input-lg {
height: auto;
}
.form-group-lg .form-control {
height: 45px;
padding: 10px 16px;
font-size: 17px;
line-height: 1.3333333;
border-radius: 3px;
}
.form-group-lg select.form-control {
height: 45px;
line-height: 45px;
}
.form-group-lg textarea.form-control,
.form-group-lg select[multiple].form-control {
height: auto;
}
.form-group-lg .form-control-static {
height: 45px;
min-height: 40px;
padding: 11px 16px;
font-size: 17px;
line-height: 1.3333333;
}
.has-feedback {
position: relative;
}
.has-feedback .form-control {
padding-right: 46.25px;
}
.form-control-feedback {
position: absolute;
top: 0;
right: 0;
z-index: 2;
display: block;
width: 37px;
height: 37px;
line-height: 37px;
text-align: center;
pointer-events: none;
}
.input-lg + .form-control-feedback,
.input-group-lg + .form-control-feedback,
.form-group-lg .form-control + .form-control-feedback {
width: 45px;
height: 45px;
line-height: 45px;
}
.input-sm + .form-control-feedback,
.input-group-sm + .form-control-feedback,
.form-group-sm .form-control + .form-control-feedback {
width: 30px;
height: 30px;
line-height: 30px;
}
.has-success .help-block,
.has-success .control-label,
.has-success .radio,
.has-success .checkbox,
.has-success .radio-inline,
.has-success .checkbox-inline,
.has-success.radio label,
.has-success.checkbox label,
.has-success.radio-inline label,
.has-success.checkbox-inline label {
color: #4caf50;
}
.has-success .form-control {
border-color: #4caf50;
-webkit-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075);
box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075);
}
.has-success .form-control:focus {
border-color: #3d8b40;
-webkit-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075), 0 0 6px #92cf94;
box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075), 0 0 6px #92cf94;
}
.has-success .input-group-addon {
color: #4caf50;
border-color: #4caf50;
background-color: #dff0d8;
}
.has-success .form-control-feedback {
color: #4caf50;
}
.has-warning .help-block,
.has-warning .control-label,
.has-warning .radio,
.has-warning .checkbox,
.has-warning .radio-inline,
.has-warning .checkbox-inline,
.has-warning.radio label,
.has-warning.checkbox label,
.has-warning.radio-inline label,
.has-warning.checkbox-inline label {
color: #ff9800;
}
.has-warning .form-control {
border-color: #ff9800;
-webkit-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075);
box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075);
}
.has-warning .form-control:focus {
border-color: #cc7a00;
-webkit-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075), 0 0 6px #ffc166;
box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075), 0 0 6px #ffc166;
}
.has-warning .input-group-addon {
color: #ff9800;
border-color: #ff9800;
background-color: #ffe0b2;
}
.has-warning .form-control-feedback {
color: #ff9800;
}
.has-error .help-block,
.has-error .control-label,
.has-error .radio,
.has-error .checkbox,
.has-error .radio-inline,
.has-error .checkbox-inline,
.has-error.radio label,
.has-error.checkbox label,
.has-error.radio-inline label,
.has-error.checkbox-inline label {
color: #e51c23;
}
.has-error .form-control {
border-color: #e51c23;
-webkit-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075);
box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075);
}
.has-error .form-control:focus {
border-color: #b9151b;
-webkit-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075), 0 0 6px #ef787c;
box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075), 0 0 6px #ef787c;
}
.has-error .input-group-addon {
color: #e51c23;
border-color: #e51c23;
background-color: #f9bdbb;
}
.has-error .form-control-feedback {
color: #e51c23;
}
.has-feedback label ~ .form-control-feedback {
top: 28px;
}
.has-feedback label.sr-only ~ .form-control-feedback {
top: 0;
}
.help-block {
display: block;
margin-top: 5px;
margin-bottom: 10px;
color: #a6a6a6;
}
@media (min-width: 768px) {
.form-inline .form-group {
display: inline-block;
margin-bottom: 0;
vertical-align: middle;
}
.form-inline .form-control {
display: inline-block;
width: auto;
vertical-align: middle;
}
.form-inline .form-control-static {
display: inline-block;
}
.form-inline .input-group {
display: inline-table;
vertical-align: middle;
}
.form-inline .input-group .input-group-addon,
.form-inline .input-group .input-group-btn,
.form-inline .input-group .form-control {
width: auto;
}
.form-inline .input-group > .form-control {
width: 100%;
}
.form-inline .control-label {
margin-bottom: 0;
vertical-align: middle;
}
.form-inline .radio,
.form-inline .checkbox {
display: inline-block;
margin-top: 0;
margin-bottom: 0;
vertical-align: middle;
}
.form-inline .radio label,
.form-inline .checkbox label {
padding-left: 0;
}
.form-inline .radio input[type="radio"],
.form-inline .checkbox input[type="checkbox"] {
position: relative;
margin-left: 0;
}
.form-inline .has-feedback .form-control-feedback {
top: 0;
}
}
.form-horizontal .radio,
.form-horizontal .checkbox,
.form-horizontal .radio-inline,
.form-horizontal .checkbox-inline {
margin-top: 0;
margin-bottom: 0;
padding-top: 7px;
}
.form-horizontal .radio,
.form-horizontal .checkbox {
min-height: 30px;
}
.form-horizontal .form-group {
margin-left: -15px;
margin-right: -15px;
}
@media (min-width: 768px) {
.form-horizontal .control-label {
text-align: right;
margin-bottom: 0;
padding-top: 7px;
}
}
.form-horizontal .has-feedback .form-control-feedback {
right: 15px;
}
@media (min-width: 768px) {
.form-horizontal .form-group-lg .control-label {
padding-top: 11px;
font-size: 17px;
}
}
@media (min-width: 768px) {
.form-horizontal .form-group-sm .control-label {
padding-top: 6px;
font-size: 12px;
}
}
.btn {
display: inline-block;
margin-bottom: 0;
font-weight: normal;
text-align: center;
vertical-align: middle;
touch-action: manipulation;
cursor: pointer;
background-image: none;
border: 1px solid transparent;
white-space: nowrap;
padding: 6px 16px;
font-size: 13px;
line-height: 1.846;
border-radius: 3px;
-webkit-user-select: none;
-moz-user-select: none;
-ms-user-select: none;
user-select: none;
}
.btn:focus,
.btn:active:focus,
.btn.active:focus,
.btn.focus,
.btn:active.focus,
.btn.active.focus {
outline: 5px auto -webkit-focus-ring-color;
outline-offset: -2px;
}
.btn:hover,
.btn:focus,
.btn.focus {
color: #444444;
text-decoration: none;
}
.btn:active,
.btn.active {
outline: 0;
background-image: none;
-webkit-box-shadow: inset 0 3px 5px rgba(0, 0, 0, 0.125);
box-shadow: inset 0 3px 5px rgba(0, 0, 0, 0.125);
}
.btn.disabled,
.btn[disabled],
fieldset[disabled] .btn {
cursor: not-allowed;
opacity: 0.65;
filter: alpha(opacity=65);
-webkit-box-shadow: none;
box-shadow: none;
}
a.btn.disabled,
fieldset[disabled] a.btn {
pointer-events: none;
}
.btn-default {
color: #444444;
background-color: #ffffff;
border-color: transparent;
}
.btn-default:focus,
.btn-default.focus {
color: #444444;
background-color: #e6e6e6;
border-color: rgba(0, 0, 0, 0);
}
.btn-default:hover {
color: #444444;
background-color: #e6e6e6;
border-color: rgba(0, 0, 0, 0);
}
.btn-default:active,
.btn-default.active,
.open > .dropdown-toggle.btn-default {
color: #444444;
background-color: #e6e6e6;
border-color: rgba(0, 0, 0, 0);
}
.btn-default:active:hover,
.btn-default.active:hover,
.open > .dropdown-toggle.btn-default:hover,
.btn-default:active:focus,
.btn-default.active:focus,
.open > .dropdown-toggle.btn-default:focus,
.btn-default:active.focus,
.btn-default.active.focus,
.open > .dropdown-toggle.btn-default.focus {
color: #444444;
background-color: #d4d4d4;
border-color: rgba(0, 0, 0, 0);
}
.btn-default:active,
.btn-default.active,
.open > .dropdown-toggle.btn-default {
background-image: none;
}
.btn-default.disabled:hover,
.btn-default[disabled]:hover,
fieldset[disabled] .btn-default:hover,
.btn-default.disabled:focus,
.btn-default[disabled]:focus,
fieldset[disabled] .btn-default:focus,
.btn-default.disabled.focus,
.btn-default[disabled].focus,
fieldset[disabled] .btn-default.focus {
background-color: #ffffff;
border-color: transparent;
}
.btn-default .badge {
color: #ffffff;
background-color: #444444;
}
.btn-primary {
color: #ffffff;
background-color: #2196f3;
border-color: transparent;
}
.btn-primary:focus,
.btn-primary.focus {
color: #ffffff;
background-color: #0c7cd5;
border-color: rgba(0, 0, 0, 0);
}
.btn-primary:hover {
color: #ffffff;
background-color: #0c7cd5;
border-color: rgba(0, 0, 0, 0);
}
.btn-primary:active,
.btn-primary.active,
.open > .dropdown-toggle.btn-primary {
color: #ffffff;
background-color: #0c7cd5;
border-color: rgba(0, 0, 0, 0);
}
.btn-primary:active:hover,
.btn-primary.active:hover,
.open > .dropdown-toggle.btn-primary:hover,
.btn-primary:active:focus,
.btn-primary.active:focus,
.open > .dropdown-toggle.btn-primary:focus,
.btn-primary:active.focus,
.btn-primary.active.focus,
.open > .dropdown-toggle.btn-primary.focus {
color: #ffffff;
background-color: #0a68b4;
border-color: rgba(0, 0, 0, 0);
}
.btn-primary:active,
.btn-primary.active,
.open > .dropdown-toggle.btn-primary {
background-image: none;
}
.btn-primary.disabled:hover,
.btn-primary[disabled]:hover,
fieldset[disabled] .btn-primary:hover,
.btn-primary.disabled:focus,
.btn-primary[disabled]:focus,
fieldset[disabled] .btn-primary:focus,
.btn-primary.disabled.focus,
.btn-primary[disabled].focus,
fieldset[disabled] .btn-primary.focus {
background-color: #2196f3;
border-color: transparent;
}
.btn-primary .badge {
color: #2196f3;
background-color: #ffffff;
}
.btn-success {
color: #ffffff;
background-color: #4caf50;
border-color: transparent;
}
.btn-success:focus,
.btn-success.focus {
color: #ffffff;
background-color: #3d8b40;
border-color: rgba(0, 0, 0, 0);
}
.btn-success:hover {
color: #ffffff;
background-color: #3d8b40;
border-color: rgba(0, 0, 0, 0);
}
.btn-success:active,
.btn-success.active,
.open > .dropdown-toggle.btn-success {
color: #ffffff;
background-color: #3d8b40;
border-color: rgba(0, 0, 0, 0);
}
.btn-success:active:hover,
.btn-success.active:hover,
.open > .dropdown-toggle.btn-success:hover,
.btn-success:active:focus,
.btn-success.active:focus,
.open > .dropdown-toggle.btn-success:focus,
.btn-success:active.focus,
.btn-success.active.focus,
.open > .dropdown-toggle.btn-success.focus {
color: #ffffff;
background-color: #327334;
border-color: rgba(0, 0, 0, 0);
}
.btn-success:active,
.btn-success.active,
.open > .dropdown-toggle.btn-success {
background-image: none;
}
.btn-success.disabled:hover,
.btn-success[disabled]:hover,
fieldset[disabled] .btn-success:hover,
.btn-success.disabled:focus,
.btn-success[disabled]:focus,
fieldset[disabled] .btn-success:focus,
.btn-success.disabled.focus,
.btn-success[disabled].focus,
fieldset[disabled] .btn-success.focus {
background-color: #4caf50;
border-color: transparent;
}
.btn-success .badge {
color: #4caf50;
background-color: #ffffff;
}
.btn-info {
color: #ffffff;
background-color: #9c27b0;
border-color: transparent;
}
.btn-info:focus,
.btn-info.focus {
color: #ffffff;
background-color: #771e86;
border-color: rgba(0, 0, 0, 0);
}
.btn-info:hover {
color: #ffffff;
background-color: #771e86;
border-color: rgba(0, 0, 0, 0);
}
.btn-info:active,
.btn-info.active,
.open > .dropdown-toggle.btn-info {
color: #ffffff;
background-color: #771e86;
border-color: rgba(0, 0, 0, 0);
}
.btn-info:active:hover,
.btn-info.active:hover,
.open > .dropdown-toggle.btn-info:hover,
.btn-info:active:focus,
.btn-info.active:focus,
.open > .dropdown-toggle.btn-info:focus,
.btn-info:active.focus,
.btn-info.active.focus,
.open > .dropdown-toggle.btn-info.focus {
color: #ffffff;
background-color: #5d1769;
border-color: rgba(0, 0, 0, 0);
}
.btn-info:active,
.btn-info.active,
.open > .dropdown-toggle.btn-info {
background-image: none;
}
.btn-info.disabled:hover,
.btn-info[disabled]:hover,
fieldset[disabled] .btn-info:hover,
.btn-info.disabled:focus,
.btn-info[disabled]:focus,
fieldset[disabled] .btn-info:focus,
.btn-info.disabled.focus,
.btn-info[disabled].focus,
fieldset[disabled] .btn-info.focus {
background-color: #9c27b0;
border-color: transparent;
}
.btn-info .badge {
color: #9c27b0;
background-color: #ffffff;
}
.btn-warning {
color: #ffffff;
background-color: #ff9800;
border-color: transparent;
}
.btn-warning:focus,
.btn-warning.focus {
color: #ffffff;
background-color: #cc7a00;
border-color: rgba(0, 0, 0, 0);
}
.btn-warning:hover {
color: #ffffff;
background-color: #cc7a00;
border-color: rgba(0, 0, 0, 0);
}
.btn-warning:active,
.btn-warning.active,
.open > .dropdown-toggle.btn-warning {
color: #ffffff;
background-color: #cc7a00;
border-color: rgba(0, 0, 0, 0);
}
.btn-warning:active:hover,
.btn-warning.active:hover,
.open > .dropdown-toggle.btn-warning:hover,
.btn-warning:active:focus,
.btn-warning.active:focus,
.open > .dropdown-toggle.btn-warning:focus,
.btn-warning:active.focus,
.btn-warning.active.focus,
.open > .dropdown-toggle.btn-warning.focus {
color: #ffffff;
background-color: #a86400;
border-color: rgba(0, 0, 0, 0);
}
.btn-warning:active,
.btn-warning.active,
.open > .dropdown-toggle.btn-warning {
background-image: none;
}
.btn-warning.disabled:hover,
.btn-warning[disabled]:hover,
fieldset[disabled] .btn-warning:hover,
.btn-warning.disabled:focus,
.btn-warning[disabled]:focus,
fieldset[disabled] .btn-warning:focus,
.btn-warning.disabled.focus,
.btn-warning[disabled].focus,
fieldset[disabled] .btn-warning.focus {
background-color: #ff9800;
border-color: transparent;
}
.btn-warning .badge {
color: #ff9800;
background-color: #ffffff;
}
.btn-danger {
color: #ffffff;
background-color: #e51c23;
border-color: transparent;
}
.btn-danger:focus,
.btn-danger.focus {
color: #ffffff;
background-color: #b9151b;
border-color: rgba(0, 0, 0, 0);
}
.btn-danger:hover {
color: #ffffff;
background-color: #b9151b;
border-color: rgba(0, 0, 0, 0);
}
.btn-danger:active,
.btn-danger.active,
.open > .dropdown-toggle.btn-danger {
color: #ffffff;
background-color: #b9151b;
border-color: rgba(0, 0, 0, 0);
}
.btn-danger:active:hover,
.btn-danger.active:hover,
.open > .dropdown-toggle.btn-danger:hover,
.btn-danger:active:focus,
.btn-danger.active:focus,
.open > .dropdown-toggle.btn-danger:focus,
.btn-danger:active.focus,
.btn-danger.active.focus,
.open > .dropdown-toggle.btn-danger.focus {
color: #ffffff;
background-color: #991216;
border-color: rgba(0, 0, 0, 0);
}
.btn-danger:active,
.btn-danger.active,
.open > .dropdown-toggle.btn-danger {
background-image: none;
}
.btn-danger.disabled:hover,
.btn-danger[disabled]:hover,
fieldset[disabled] .btn-danger:hover,
.btn-danger.disabled:focus,
.btn-danger[disabled]:focus,
fieldset[disabled] .btn-danger:focus,
.btn-danger.disabled.focus,
.btn-danger[disabled].focus,
fieldset[disabled] .btn-danger.focus {
background-color: #e51c23;
border-color: transparent;
}
.btn-danger .badge {
color: #e51c23;
background-color: #ffffff;
}
.btn-link {
color: #2196f3;
font-weight: normal;
border-radius: 0;
}
.btn-link,
.btn-link:active,
.btn-link.active,
.btn-link[disabled],
fieldset[disabled] .btn-link {
background-color: transparent;
-webkit-box-shadow: none;
box-shadow: none;
}
.btn-link,
.btn-link:hover,
.btn-link:focus,
.btn-link:active {
border-color: transparent;
}
.btn-link:hover,
.btn-link:focus {
color: #0a6ebd;
text-decoration: underline;
background-color: transparent;
}
.btn-link[disabled]:hover,
fieldset[disabled] .btn-link:hover,
.btn-link[disabled]:focus,
fieldset[disabled] .btn-link:focus {
color: #bbbbbb;
text-decoration: none;
}
.btn-lg,
.btn-group-lg > .btn {
padding: 10px 16px;
font-size: 17px;
line-height: 1.3333333;
border-radius: 3px;
}
.btn-sm,
.btn-group-sm > .btn {
padding: 5px 10px;
font-size: 12px;
line-height: 1.5;
border-radius: 3px;
}
.btn-xs,
.btn-group-xs > .btn {
padding: 1px 5px;
font-size: 12px;
line-height: 1.5;
border-radius: 3px;
}
.btn-block {
display: block;
width: 100%;
}
.btn-block + .btn-block {
margin-top: 5px;
}
input[type="submit"].btn-block,
input[type="reset"].btn-block,
input[type="button"].btn-block {
width: 100%;
}
.fade {
opacity: 0;
-webkit-transition: opacity 0.15s linear;
-o-transition: opacity 0.15s linear;
transition: opacity 0.15s linear;
}
.fade.in {
opacity: 1;
}
.collapse {
display: none;
}
.collapse.in {
display: block;
}
tr.collapse.in {
display: table-row;
}
tbody.collapse.in {
display: table-row-group;
}
.collapsing {
position: relative;
height: 0;
overflow: hidden;
-webkit-transition-property: height, visibility;
transition-property: height, visibility;
-webkit-transition-duration: 0.35s;
transition-duration: 0.35s;
-webkit-transition-timing-function: ease;
transition-timing-function: ease;
}
.caret {
display: inline-block;
width: 0;
height: 0;
margin-left: 2px;
vertical-align: middle;
border-top: 4px dashed;
border-top: 4px solid \9;
border-right: 4px solid transparent;
border-left: 4px solid transparent;
}
.dropup,
.dropdown {
position: relative;
}
.dropdown-toggle:focus {
outline: 0;
}
.dropdown-menu {
position: absolute;
top: 100%;
left: 0;
z-index: 1000;
display: none;
float: left;
min-width: 160px;
padding: 5px 0;
margin: 2px 0 0;
list-style: none;
font-size: 13px;
text-align: left;
background-color: #ffffff;
border: 1px solid #cccccc;
border: 1px solid rgba(0, 0, 0, 0.15);
border-radius: 3px;
-webkit-box-shadow: 0 6px 12px rgba(0, 0, 0, 0.175);
box-shadow: 0 6px 12px rgba(0, 0, 0, 0.175);
background-clip: padding-box;
}
.dropdown-menu.pull-right {
right: 0;
left: auto;
}
.dropdown-menu .divider {
height: 1px;
margin: 10.5px 0;
overflow: hidden;
background-color: #e5e5e5;
}
.dropdown-menu > li > a {
display: block;
padding: 3px 20px;
clear: both;
font-weight: normal;
line-height: 1.846;
color: #666666;
white-space: nowrap;
}
.dropdown-menu > li > a:hover,
.dropdown-menu > li > a:focus {
text-decoration: none;
color: #141414;
background-color: #eeeeee;
}
.dropdown-menu > .active > a,
.dropdown-menu > .active > a:hover,
.dropdown-menu > .active > a:focus {
color: #ffffff;
text-decoration: none;
outline: 0;
background-color: #2196f3;
}
.dropdown-menu > .disabled > a,
.dropdown-menu > .disabled > a:hover,
.dropdown-menu > .disabled > a:focus {
color: #bbbbbb;
}
.dropdown-menu > .disabled > a:hover,
.dropdown-menu > .disabled > a:focus {
text-decoration: none;
background-color: transparent;
background-image: none;
filter: progid:DXImageTransform.Microsoft.gradient(enabled = false);
cursor: not-allowed;
}
.open > .dropdown-menu {
display: block;
}
.open > a {
outline: 0;
}
.dropdown-menu-right {
left: auto;
right: 0;
}
.dropdown-menu-left {
left: 0;
right: auto;
}
.dropdown-header {
display: block;
padding: 3px 20px;
font-size: 12px;
line-height: 1.846;
color: #bbbbbb;
white-space: nowrap;
}
.dropdown-backdrop {
position: fixed;
left: 0;
right: 0;
bottom: 0;
top: 0;
z-index: 990;
}
.pull-right > .dropdown-menu {
right: 0;
left: auto;
}
.dropup .caret,
.navbar-fixed-bottom .dropdown .caret {
border-top: 0;
border-bottom: 4px dashed;
border-bottom: 4px solid \9;
content: "";
}
.dropup .dropdown-menu,
.navbar-fixed-bottom .dropdown .dropdown-menu {
top: auto;
bottom: 100%;
margin-bottom: 2px;
}
@media (min-width: 768px) {
.navbar-right .dropdown-menu {
left: auto;
right: 0;
}
.navbar-right .dropdown-menu-left {
left: 0;
right: auto;
}
}
.btn-group,
.btn-group-vertical {
position: relative;
display: inline-block;
vertical-align: middle;
}
.btn-group > .btn,
.btn-group-vertical > .btn {
position: relative;
float: left;
}
.btn-group > .btn:hover,
.btn-group-vertical > .btn:hover,
.btn-group > .btn:focus,
.btn-group-vertical > .btn:focus,
.btn-group > .btn:active,
.btn-group-vertical > .btn:active,
.btn-group > .btn.active,
.btn-group-vertical > .btn.active {
z-index: 2;
}
.btn-group .btn + .btn,
.btn-group .btn + .btn-group,
.btn-group .btn-group + .btn,
.btn-group .btn-group + .btn-group {
margin-left: -1px;
}
.btn-toolbar {
margin-left: -5px;
}
.btn-toolbar .btn,
.btn-toolbar .btn-group,
.btn-toolbar .input-group {
float: left;
}
.btn-toolbar > .btn,
.btn-toolbar > .btn-group,
.btn-toolbar > .input-group {
margin-left: 5px;
}
.btn-group > .btn:not(:first-child):not(:last-child):not(.dropdown-toggle) {
border-radius: 0;
}
.btn-group > .btn:first-child {
margin-left: 0;
}
.btn-group > .btn:first-child:not(:last-child):not(.dropdown-toggle) {
border-bottom-right-radius: 0;
border-top-right-radius: 0;
}
.btn-group > .btn:last-child:not(:first-child),
.btn-group > .dropdown-toggle:not(:first-child) {
border-bottom-left-radius: 0;
border-top-left-radius: 0;
}
.btn-group > .btn-group {
float: left;
}
.btn-group > .btn-group:not(:first-child):not(:last-child) > .btn {
border-radius: 0;
}
.btn-group > .btn-group:first-child:not(:last-child) > .btn:last-child,
.btn-group > .btn-group:first-child:not(:last-child) > .dropdown-toggle {
border-bottom-right-radius: 0;
border-top-right-radius: 0;
}
.btn-group > .btn-group:last-child:not(:first-child) > .btn:first-child {
border-bottom-left-radius: 0;
border-top-left-radius: 0;
}
.btn-group .dropdown-toggle:active,
.btn-group.open .dropdown-toggle {
outline: 0;
}
.btn-group > .btn + .dropdown-toggle {
padding-left: 8px;
padding-right: 8px;
}
.btn-group > .btn-lg + .dropdown-toggle {
padding-left: 12px;
padding-right: 12px;
}
.btn-group.open .dropdown-toggle {
-webkit-box-shadow: inset 0 3px 5px rgba(0, 0, 0, 0.125);
box-shadow: inset 0 3px 5px rgba(0, 0, 0, 0.125);
}
.btn-group.open .dropdown-toggle.btn-link {
-webkit-box-shadow: none;
box-shadow: none;
}
.btn .caret {
margin-left: 0;
}
.btn-lg .caret {
border-width: 5px 5px 0;
border-bottom-width: 0;
}
.dropup .btn-lg .caret {
border-width: 0 5px 5px;
}
.btn-group-vertical > .btn,
.btn-group-vertical > .btn-group,
.btn-group-vertical > .btn-group > .btn {
display: block;
float: none;
width: 100%;
max-width: 100%;
}
.btn-group-vertical > .btn-group > .btn {
float: none;
}
.btn-group-vertical > .btn + .btn,
.btn-group-vertical > .btn + .btn-group,
.btn-group-vertical > .btn-group + .btn,
.btn-group-vertical > .btn-group + .btn-group {
margin-top: -1px;
margin-left: 0;
}
.btn-group-vertical > .btn:not(:first-child):not(:last-child) {
border-radius: 0;
}
.btn-group-vertical > .btn:first-child:not(:last-child) {
border-top-right-radius: 3px;
border-top-left-radius: 3px;
border-bottom-right-radius: 0;
border-bottom-left-radius: 0;
}
.btn-group-vertical > .btn:last-child:not(:first-child) {
border-top-right-radius: 0;
border-top-left-radius: 0;
border-bottom-right-radius: 3px;
border-bottom-left-radius: 3px;
}
.btn-group-vertical > .btn-group:not(:first-child):not(:last-child) > .btn {
border-radius: 0;
}
.btn-group-vertical > .btn-group:first-child:not(:last-child) > .btn:last-child,
.btn-group-vertical > .btn-group:first-child:not(:last-child) > .dropdown-toggle {
border-bottom-right-radius: 0;
border-bottom-left-radius: 0;
}
.btn-group-vertical > .btn-group:last-child:not(:first-child) > .btn:first-child {
border-top-right-radius: 0;
border-top-left-radius: 0;
}
.btn-group-justified {
display: table;
width: 100%;
table-layout: fixed;
border-collapse: separate;
}
.btn-group-justified > .btn,
.btn-group-justified > .btn-group {
float: none;
display: table-cell;
width: 1%;
}
.btn-group-justified > .btn-group .btn {
width: 100%;
}
.btn-group-justified > .btn-group .dropdown-menu {
left: auto;
}
[data-toggle="buttons"] > .btn input[type="radio"],
[data-toggle="buttons"] > .btn-group > .btn input[type="radio"],
[data-toggle="buttons"] > .btn input[type="checkbox"],
[data-toggle="buttons"] > .btn-group > .btn input[type="checkbox"] {
position: absolute;
clip: rect(0, 0, 0, 0);
pointer-events: none;
}
.input-group {
position: relative;
display: table;
border-collapse: separate;
}
.input-group[class*="col-"] {
float: none;
padding-left: 0;
padding-right: 0;
}
.input-group .form-control {
position: relative;
z-index: 2;
float: left;
width: 100%;
margin-bottom: 0;
}
.input-group .form-control:focus {
z-index: 3;
}
.input-group-lg > .form-control,
.input-group-lg > .input-group-addon,
.input-group-lg > .input-group-btn > .btn {
height: 45px;
padding: 10px 16px;
font-size: 17px;
line-height: 1.3333333;
border-radius: 3px;
}
select.input-group-lg > .form-control,
select.input-group-lg > .input-group-addon,
select.input-group-lg > .input-group-btn > .btn {
height: 45px;
line-height: 45px;
}
textarea.input-group-lg > .form-control,
textarea.input-group-lg > .input-group-addon,
textarea.input-group-lg > .input-group-btn > .btn,
select[multiple].input-group-lg > .form-control,
select[multiple].input-group-lg > .input-group-addon,
select[multiple].input-group-lg > .input-group-btn > .btn {
height: auto;
}
.input-group-sm > .form-control,
.input-group-sm > .input-group-addon,
.input-group-sm > .input-group-btn > .btn {
height: 30px;
padding: 5px 10px;
font-size: 12px;
line-height: 1.5;
border-radius: 3px;
}
select.input-group-sm > .form-control,
select.input-group-sm > .input-group-addon,
select.input-group-sm > .input-group-btn > .btn {
height: 30px;
line-height: 30px;
}
textarea.input-group-sm > .form-control,
textarea.input-group-sm > .input-group-addon,
textarea.input-group-sm > .input-group-btn > .btn,
select[multiple].input-group-sm > .form-control,
select[multiple].input-group-sm > .input-group-addon,
select[multiple].input-group-sm > .input-group-btn > .btn {
height: auto;
}
.input-group-addon,
.input-group-btn,
.input-group .form-control {
display: table-cell;
}
.input-group-addon:not(:first-child):not(:last-child),
.input-group-btn:not(:first-child):not(:last-child),
.input-group .form-control:not(:first-child):not(:last-child) {
border-radius: 0;
}
.input-group-addon,
.input-group-btn {
width: 1%;
white-space: nowrap;
vertical-align: middle;
}
.input-group-addon {
padding: 6px 16px;
font-size: 13px;
font-weight: normal;
line-height: 1;
color: #666666;
text-align: center;
background-color: transparent;
border: 1px solid transparent;
border-radius: 3px;
}
.input-group-addon.input-sm {
padding: 5px 10px;
font-size: 12px;
border-radius: 3px;
}
.input-group-addon.input-lg {
padding: 10px 16px;
font-size: 17px;
border-radius: 3px;
}
.input-group-addon input[type="radio"],
.input-group-addon input[type="checkbox"] {
margin-top: 0;
}
.input-group .form-control:first-child,
.input-group-addon:first-child,
.input-group-btn:first-child > .btn,
.input-group-btn:first-child > .btn-group > .btn,
.input-group-btn:first-child > .dropdown-toggle,
.input-group-btn:last-child > .btn:not(:last-child):not(.dropdown-toggle),
.input-group-btn:last-child > .btn-group:not(:last-child) > .btn {
border-bottom-right-radius: 0;
border-top-right-radius: 0;
}
.input-group-addon:first-child {
border-right: 0;
}
.input-group .form-control:last-child,
.input-group-addon:last-child,
.input-group-btn:last-child > .btn,
.input-group-btn:last-child > .btn-group > .btn,
.input-group-btn:last-child > .dropdown-toggle,
.input-group-btn:first-child > .btn:not(:first-child),
.input-group-btn:first-child > .btn-group:not(:first-child) > .btn {
border-bottom-left-radius: 0;
border-top-left-radius: 0;
}
.input-group-addon:last-child {
border-left: 0;
}
.input-group-btn {
position: relative;
font-size: 0;
white-space: nowrap;
}
.input-group-btn > .btn {
position: relative;
}
.input-group-btn > .btn + .btn {
margin-left: -1px;
}
.input-group-btn > .btn:hover,
.input-group-btn > .btn:focus,
.input-group-btn > .btn:active {
z-index: 2;
}
.input-group-btn:first-child > .btn,
.input-group-btn:first-child > .btn-group {
margin-right: -1px;
}
.input-group-btn:last-child > .btn,
.input-group-btn:last-child > .btn-group {
z-index: 2;
margin-left: -1px;
}
.nav {
margin-bottom: 0;
padding-left: 0;
list-style: none;
}
.nav > li {
position: relative;
display: block;
}
.nav > li > a {
position: relative;
display: block;
padding: 10px 15px;
}
.nav > li > a:hover,
.nav > li > a:focus {
text-decoration: none;
background-color: #eeeeee;
}
.nav > li.disabled > a {
color: #bbbbbb;
}
.nav > li.disabled > a:hover,
.nav > li.disabled > a:focus {
color: #bbbbbb;
text-decoration: none;
background-color: transparent;
cursor: not-allowed;
}
.nav .open > a,
.nav .open > a:hover,
.nav .open > a:focus {
background-color: #eeeeee;
border-color: #2196f3;
}
.nav .nav-divider {
height: 1px;
margin: 10.5px 0;
overflow: hidden;
background-color: #e5e5e5;
}
.nav > li > a > img {
max-width: none;
}
.nav-tabs {
border-bottom: 1px solid transparent;
}
.nav-tabs > li {
float: left;
margin-bottom: -1px;
}
.nav-tabs > li > a {
margin-right: 2px;
line-height: 1.846;
border: 1px solid transparent;
border-radius: 3px 3px 0 0;
}
.nav-tabs > li > a:hover {
border-color: #eeeeee #eeeeee transparent;
}
.nav-tabs > li.active > a,
.nav-tabs > li.active > a:hover,
.nav-tabs > li.active > a:focus {
color: #666666;
background-color: transparent;
border: 1px solid transparent;
border-bottom-color: transparent;
cursor: default;
}
.nav-tabs.nav-justified {
width: 100%;
border-bottom: 0;
}
.nav-tabs.nav-justified > li {
float: none;
}
.nav-tabs.nav-justified > li > a {
text-align: center;
margin-bottom: 5px;
}
.nav-tabs.nav-justified > .dropdown .dropdown-menu {
top: auto;
left: auto;
}
@media (min-width: 768px) {
.nav-tabs.nav-justified > li {
display: table-cell;
width: 1%;
}
.nav-tabs.nav-justified > li > a {
margin-bottom: 0;
}
}
.nav-tabs.nav-justified > li > a {
margin-right: 0;
border-radius: 3px;
}
.nav-tabs.nav-justified > .active > a,
.nav-tabs.nav-justified > .active > a:hover,
.nav-tabs.nav-justified > .active > a:focus {
border: 1px solid transparent;
}
@media (min-width: 768px) {
.nav-tabs.nav-justified > li > a {
border-bottom: 1px solid transparent;
border-radius: 3px 3px 0 0;
}
.nav-tabs.nav-justified > .active > a,
.nav-tabs.nav-justified > .active > a:hover,
.nav-tabs.nav-justified > .active > a:focus {
border-bottom-color: #ffffff;
}
}
.nav-pills > li {
float: left;
}
.nav-pills > li > a {
border-radius: 3px;
}
.nav-pills > li + li {
margin-left: 2px;
}
.nav-pills > li.active > a,
.nav-pills > li.active > a:hover,
.nav-pills > li.active > a:focus {
color: #ffffff;
background-color: #2196f3;
}
.nav-stacked > li {
float: none;
}
.nav-stacked > li + li {
margin-top: 2px;
margin-left: 0;
}
.nav-justified {
width: 100%;
}
.nav-justified > li {
float: none;
}
.nav-justified > li > a {
text-align: center;
margin-bottom: 5px;
}
.nav-justified > .dropdown .dropdown-menu {
top: auto;
left: auto;
}
@media (min-width: 768px) {
.nav-justified > li {
display: table-cell;
width: 1%;
}
.nav-justified > li > a {
margin-bottom: 0;
}
}
.nav-tabs-justified {
border-bottom: 0;
}
.nav-tabs-justified > li > a {
margin-right: 0;
border-radius: 3px;
}
.nav-tabs-justified > .active > a,
.nav-tabs-justified > .active > a:hover,
.nav-tabs-justified > .active > a:focus {
border: 1px solid transparent;
}
@media (min-width: 768px) {
.nav-tabs-justified > li > a {
border-bottom: 1px solid transparent;
border-radius: 3px 3px 0 0;
}
.nav-tabs-justified > .active > a,
.nav-tabs-justified > .active > a:hover,
.nav-tabs-justified > .active > a:focus {
border-bottom-color: #ffffff;
}
}
.tab-content > .tab-pane {
display: none;
}
.tab-content > .active {
display: block;
}
.nav-tabs .dropdown-menu {
margin-top: -1px;
border-top-right-radius: 0;
border-top-left-radius: 0;
}
.navbar {
position: relative;
min-height: 64px;
margin-bottom: 23px;
border: 1px solid transparent;
}
@media (min-width: 768px) {
.navbar {
border-radius: 3px;
}
}
@media (min-width: 768px) {
.navbar-header {
float: left;
}
}
.navbar-collapse {
overflow-x: visible;
padding-right: 15px;
padding-left: 15px;
border-top: 1px solid transparent;
box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.1);
-webkit-overflow-scrolling: touch;
}
.navbar-collapse.in {
overflow-y: auto;
}
@media (min-width: 768px) {
.navbar-collapse {
width: auto;
border-top: 0;
box-shadow: none;
}
.navbar-collapse.collapse {
display: block !important;
height: auto !important;
padding-bottom: 0;
overflow: visible !important;
}
.navbar-collapse.in {
overflow-y: visible;
}
.navbar-fixed-top .navbar-collapse,
.navbar-static-top .navbar-collapse,
.navbar-fixed-bottom .navbar-collapse {
padding-left: 0;
padding-right: 0;
}
}
.navbar-fixed-top .navbar-collapse,
.navbar-fixed-bottom .navbar-collapse {
max-height: 340px;
}
@media (max-device-width: 480px) and (orientation: landscape) {
.navbar-fixed-top .navbar-collapse,
.navbar-fixed-bottom .navbar-collapse {
max-height: 200px;
}
}
.container > .navbar-header,
.container-fluid > .navbar-header,
.container > .navbar-collapse,
.container-fluid > .navbar-collapse {
margin-right: -15px;
margin-left: -15px;
}
@media (min-width: 768px) {
.container > .navbar-header,
.container-fluid > .navbar-header,
.container > .navbar-collapse,
.container-fluid > .navbar-collapse {
margin-right: 0;
margin-left: 0;
}
}
.navbar-static-top {
z-index: 1000;
border-width: 0 0 1px;
}
@media (min-width: 768px) {
.navbar-static-top {
border-radius: 0;
}
}
.navbar-fixed-top,
.navbar-fixed-bottom {
position: fixed;
right: 0;
left: 0;
z-index: 1030;
}
@media (min-width: 768px) {
.navbar-fixed-top,
.navbar-fixed-bottom {
border-radius: 0;
}
}
.navbar-fixed-top {
top: 0;
border-width: 0 0 1px;
}
.navbar-fixed-bottom {
bottom: 0;
margin-bottom: 0;
border-width: 1px 0 0;
}
.navbar-brand {
float: left;
padding: 20.5px 15px;
font-size: 17px;
line-height: 23px;
height: 64px;
}
.navbar-brand:hover,
.navbar-brand:focus {
text-decoration: none;
}
.navbar-brand > img {
display: block;
}
@media (min-width: 768px) {
.navbar > .container .navbar-brand,
.navbar > .container-fluid .navbar-brand {
margin-left: -15px;
}
}
.navbar-toggle {
position: relative;
float: right;
margin-right: 15px;
padding: 9px 10px;
margin-top: 15px;
margin-bottom: 15px;
background-color: transparent;
background-image: none;
border: 1px solid transparent;
border-radius: 3px;
}
.navbar-toggle:focus {
outline: 0;
}
.navbar-toggle .icon-bar {
display: block;
width: 22px;
height: 2px;
border-radius: 1px;
}
.navbar-toggle .icon-bar + .icon-bar {
margin-top: 4px;
}
@media (min-width: 768px) {
.navbar-toggle {
display: none;
}
}
.navbar-nav {
margin: 10.25px -15px;
}
.navbar-nav > li > a {
padding-top: 10px;
padding-bottom: 10px;
line-height: 23px;
}
@media (max-width: 767px) {
.navbar-nav .open .dropdown-menu {
position: static;
float: none;
width: auto;
margin-top: 0;
background-color: transparent;
border: 0;
box-shadow: none;
}
.navbar-nav .open .dropdown-menu > li > a,
.navbar-nav .open .dropdown-menu .dropdown-header {
padding: 5px 15px 5px 25px;
}
.navbar-nav .open .dropdown-menu > li > a {
line-height: 23px;
}
.navbar-nav .open .dropdown-menu > li > a:hover,
.navbar-nav .open .dropdown-menu > li > a:focus {
background-image: none;
}
}
@media (min-width: 768px) {
.navbar-nav {
float: left;
margin: 0;
}
.navbar-nav > li {
float: left;
}
.navbar-nav > li > a {
padding-top: 20.5px;
padding-bottom: 20.5px;
}
}
.navbar-form {
margin-left: -15px;
margin-right: -15px;
padding: 10px 15px;
border-top: 1px solid transparent;
border-bottom: 1px solid transparent;
-webkit-box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.1), 0 1px 0 rgba(255, 255, 255, 0.1);
box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.1), 0 1px 0 rgba(255, 255, 255, 0.1);
margin-top: 13.5px;
margin-bottom: 13.5px;
}
@media (min-width: 768px) {
.navbar-form .form-group {
display: inline-block;
margin-bottom: 0;
vertical-align: middle;
}
.navbar-form .form-control {
display: inline-block;
width: auto;
vertical-align: middle;
}
.navbar-form .form-control-static {
display: inline-block;
}
.navbar-form .input-group {
display: inline-table;
vertical-align: middle;
}
.navbar-form .input-group .input-group-addon,
.navbar-form .input-group .input-group-btn,
.navbar-form .input-group .form-control {
width: auto;
}
.navbar-form .input-group > .form-control {
width: 100%;
}
.navbar-form .control-label {
margin-bottom: 0;
vertical-align: middle;
}
.navbar-form .radio,
.navbar-form .checkbox {
display: inline-block;
margin-top: 0;
margin-bottom: 0;
vertical-align: middle;
}
.navbar-form .radio label,
.navbar-form .checkbox label {
padding-left: 0;
}
.navbar-form .radio input[type="radio"],
.navbar-form .checkbox input[type="checkbox"] {
position: relative;
margin-left: 0;
}
.navbar-form .has-feedback .form-control-feedback {
top: 0;
}
}
@media (max-width: 767px) {
.navbar-form .form-group {
margin-bottom: 5px;
}
.navbar-form .form-group:last-child {
margin-bottom: 0;
}
}
@media (min-width: 768px) {
.navbar-form {
width: auto;
border: 0;
margin-left: 0;
margin-right: 0;
padding-top: 0;
padding-bottom: 0;
-webkit-box-shadow: none;
box-shadow: none;
}
}
.navbar-nav > li > .dropdown-menu {
margin-top: 0;
border-top-right-radius: 0;
border-top-left-radius: 0;
}
.navbar-fixed-bottom .navbar-nav > li > .dropdown-menu {
margin-bottom: 0;
border-top-right-radius: 3px;
border-top-left-radius: 3px;
border-bottom-right-radius: 0;
border-bottom-left-radius: 0;
}
.navbar-btn {
margin-top: 13.5px;
margin-bottom: 13.5px;
}
.navbar-btn.btn-sm {
margin-top: 17px;
margin-bottom: 17px;
}
.navbar-btn.btn-xs {
margin-top: 21px;
margin-bottom: 21px;
}
.navbar-text {
margin-top: 20.5px;
margin-bottom: 20.5px;
}
@media (min-width: 768px) {
.navbar-text {
float: left;
margin-left: 15px;
margin-right: 15px;
}
}
@media (min-width: 768px) {
.navbar-left {
float: left !important;
}
.navbar-right {
float: right !important;
margin-right: -15px;
}
.navbar-right ~ .navbar-right {
margin-right: 0;
}
}
.navbar-default {
background-color: #ffffff;
border-color: transparent;
}
.navbar-default .navbar-brand {
color: #666666;
}
.navbar-default .navbar-brand:hover,
.navbar-default .navbar-brand:focus {
color: #212121;
background-color: transparent;
}
.navbar-default .navbar-text {
color: #bbbbbb;
}
.navbar-default .navbar-nav > li > a {
color: #666666;
}
.navbar-default .navbar-nav > li > a:hover,
.navbar-default .navbar-nav > li > a:focus {
color: #212121;
background-color: transparent;
}
.navbar-default .navbar-nav > .active > a,
.navbar-default .navbar-nav > .active > a:hover,
.navbar-default .navbar-nav > .active > a:focus {
color: #212121;
background-color: #eeeeee;
}
.navbar-default .navbar-nav > .disabled > a,
.navbar-default .navbar-nav > .disabled > a:hover,
.navbar-default .navbar-nav > .disabled > a:focus {
color: #cccccc;
background-color: transparent;
}
.navbar-default .navbar-toggle {
border-color: transparent;
}
.navbar-default .navbar-toggle:hover,
.navbar-default .navbar-toggle:focus {
background-color: transparent;
}
.navbar-default .navbar-toggle .icon-bar {
background-color: rgba(0, 0, 0, 0.5);
}
.navbar-default .navbar-collapse,
.navbar-default .navbar-form {
border-color: transparent;
}
.navbar-default .navbar-nav > .open > a,
.navbar-default .navbar-nav > .open > a:hover,
.navbar-default .navbar-nav > .open > a:focus {
background-color: #eeeeee;
color: #212121;
}
@media (max-width: 767px) {
.navbar-default .navbar-nav .open .dropdown-menu > li > a {
color: #666666;
}
.navbar-default .navbar-nav .open .dropdown-menu > li > a:hover,
.navbar-default .navbar-nav .open .dropdown-menu > li > a:focus {
color: #212121;
background-color: transparent;
}
.navbar-default .navbar-nav .open .dropdown-menu > .active > a,
.navbar-default .navbar-nav .open .dropdown-menu > .active > a:hover,
.navbar-default .navbar-nav .open .dropdown-menu > .active > a:focus {
color: #212121;
background-color: #eeeeee;
}
.navbar-default .navbar-nav .open .dropdown-menu > .disabled > a,
.navbar-default .navbar-nav .open .dropdown-menu > .disabled > a:hover,
.navbar-default .navbar-nav .open .dropdown-menu > .disabled > a:focus {
color: #cccccc;
background-color: transparent;
}
}
.navbar-default .navbar-link {
color: #666666;
}
.navbar-default .navbar-link:hover {
color: #212121;
}
.navbar-default .btn-link {
color: #666666;
}
.navbar-default .btn-link:hover,
.navbar-default .btn-link:focus {
color: #212121;
}
.navbar-default .btn-link[disabled]:hover,
fieldset[disabled] .navbar-default .btn-link:hover,
.navbar-default .btn-link[disabled]:focus,
fieldset[disabled] .navbar-default .btn-link:focus {
color: #cccccc;
}
.navbar-inverse {
background-color: #2196f3;
border-color: transparent;
}
.navbar-inverse .navbar-brand {
color: #b2dbfb;
}
.navbar-inverse .navbar-brand:hover,
.navbar-inverse .navbar-brand:focus {
color: #ffffff;
background-color: transparent;
}
.navbar-inverse .navbar-text {
color: #bbbbbb;
}
.navbar-inverse .navbar-nav > li > a {
color: #b2dbfb;
}
.navbar-inverse .navbar-nav > li > a:hover,
.navbar-inverse .navbar-nav > li > a:focus {
color: #ffffff;
background-color: transparent;
}
.navbar-inverse .navbar-nav > .active > a,
.navbar-inverse .navbar-nav > .active > a:hover,
.navbar-inverse .navbar-nav > .active > a:focus {
color: #ffffff;
background-color: #0c7cd5;
}
.navbar-inverse .navbar-nav > .disabled > a,
.navbar-inverse .navbar-nav > .disabled > a:hover,
.navbar-inverse .navbar-nav > .disabled > a:focus {
color: #444444;
background-color: transparent;
}
.navbar-inverse .navbar-toggle {
border-color: transparent;
}
.navbar-inverse .navbar-toggle:hover,
.navbar-inverse .navbar-toggle:focus {
background-color: transparent;
}
.navbar-inverse .navbar-toggle .icon-bar {
background-color: rgba(0, 0, 0, 0.5);
}
.navbar-inverse .navbar-collapse,
.navbar-inverse .navbar-form {
border-color: #0c84e4;
}
.navbar-inverse .navbar-nav > .open > a,
.navbar-inverse .navbar-nav > .open > a:hover,
.navbar-inverse .navbar-nav > .open > a:focus {
background-color: #0c7cd5;
color: #ffffff;
}
@media (max-width: 767px) {
.navbar-inverse .navbar-nav .open .dropdown-menu > .dropdown-header {
border-color: transparent;
}
.navbar-inverse .navbar-nav .open .dropdown-menu .divider {
background-color: transparent;
}
.navbar-inverse .navbar-nav .open .dropdown-menu > li > a {
color: #b2dbfb;
}
.navbar-inverse .navbar-nav .open .dropdown-menu > li > a:hover,
.navbar-inverse .navbar-nav .open .dropdown-menu > li > a:focus {
color: #ffffff;
background-color: transparent;
}
.navbar-inverse .navbar-nav .open .dropdown-menu > .active > a,
.navbar-inverse .navbar-nav .open .dropdown-menu > .active > a:hover,
.navbar-inverse .navbar-nav .open .dropdown-menu > .active > a:focus {
color: #ffffff;
background-color: #0c7cd5;
}
.navbar-inverse .navbar-nav .open .dropdown-menu > .disabled > a,
.navbar-inverse .navbar-nav .open .dropdown-menu > .disabled > a:hover,
.navbar-inverse .navbar-nav .open .dropdown-menu > .disabled > a:focus {
color: #444444;
background-color: transparent;
}
}
.navbar-inverse .navbar-link {
color: #b2dbfb;
}
.navbar-inverse .navbar-link:hover {
color: #ffffff;
}
.navbar-inverse .btn-link {
color: #b2dbfb;
}
.navbar-inverse .btn-link:hover,
.navbar-inverse .btn-link:focus {
color: #ffffff;
}
.navbar-inverse .btn-link[disabled]:hover,
fieldset[disabled] .navbar-inverse .btn-link:hover,
.navbar-inverse .btn-link[disabled]:focus,
fieldset[disabled] .navbar-inverse .btn-link:focus {
color: #444444;
}
.breadcrumb {
padding: 8px 15px;
margin-bottom: 23px;
list-style: none;
background-color: #f5f5f5;
border-radius: 3px;
}
.breadcrumb > li {
display: inline-block;
}
.breadcrumb > li + li:before {
content: "/\00a0";
padding: 0 5px;
color: #cccccc;
}
.breadcrumb > .active {
color: #bbbbbb;
}
.pagination {
display: inline-block;
padding-left: 0;
margin: 23px 0;
border-radius: 3px;
}
.pagination > li {
display: inline;
}
.pagination > li > a,
.pagination > li > span {
position: relative;
float: left;
padding: 6px 16px;
line-height: 1.846;
text-decoration: none;
color: #2196f3;
background-color: #ffffff;
border: 1px solid #dddddd;
margin-left: -1px;
}
.pagination > li:first-child > a,
.pagination > li:first-child > span {
margin-left: 0;
border-bottom-left-radius: 3px;
border-top-left-radius: 3px;
}
.pagination > li:last-child > a,
.pagination > li:last-child > span {
border-bottom-right-radius: 3px;
border-top-right-radius: 3px;
}
.pagination > li > a:hover,
.pagination > li > span:hover,
.pagination > li > a:focus,
.pagination > li > span:focus {
z-index: 2;
color: #0a6ebd;
background-color: #eeeeee;
border-color: #dddddd;
}
.pagination > .active > a,
.pagination > .active > span,
.pagination > .active > a:hover,
.pagination > .active > span:hover,
.pagination > .active > a:focus,
.pagination > .active > span:focus {
z-index: 3;
color: #ffffff;
background-color: #2196f3;
border-color: #2196f3;
cursor: default;
}
.pagination > .disabled > span,
.pagination > .disabled > span:hover,
.pagination > .disabled > span:focus,
.pagination > .disabled > a,
.pagination > .disabled > a:hover,
.pagination > .disabled > a:focus {
color: #bbbbbb;
background-color: #ffffff;
border-color: #dddddd;
cursor: not-allowed;
}
.pagination-lg > li > a,
.pagination-lg > li > span {
padding: 10px 16px;
font-size: 17px;
line-height: 1.3333333;
}
.pagination-lg > li:first-child > a,
.pagination-lg > li:first-child > span {
border-bottom-left-radius: 3px;
border-top-left-radius: 3px;
}
.pagination-lg > li:last-child > a,
.pagination-lg > li:last-child > span {
border-bottom-right-radius: 3px;
border-top-right-radius: 3px;
}
.pagination-sm > li > a,
.pagination-sm > li > span {
padding: 5px 10px;
font-size: 12px;
line-height: 1.5;
}
.pagination-sm > li:first-child > a,
.pagination-sm > li:first-child > span {
border-bottom-left-radius: 3px;
border-top-left-radius: 3px;
}
.pagination-sm > li:last-child > a,
.pagination-sm > li:last-child > span {
border-bottom-right-radius: 3px;
border-top-right-radius: 3px;
}
.pager {
padding-left: 0;
margin: 23px 0;
list-style: none;
text-align: center;
}
.pager li {
display: inline;
}
.pager li > a,
.pager li > span {
display: inline-block;
padding: 5px 14px;
background-color: #ffffff;
border: 1px solid #dddddd;
border-radius: 15px;
}
.pager li > a:hover,
.pager li > a:focus {
text-decoration: none;
background-color: #eeeeee;
}
.pager .next > a,
.pager .next > span {
float: right;
}
.pager .previous > a,
.pager .previous > span {
float: left;
}
.pager .disabled > a,
.pager .disabled > a:hover,
.pager .disabled > a:focus,
.pager .disabled > span {
color: #bbbbbb;
background-color: #ffffff;
cursor: not-allowed;
}
.label {
display: inline;
padding: .2em .6em .3em;
font-size: 75%;
font-weight: bold;
line-height: 1;
color: #ffffff;
text-align: center;
white-space: nowrap;
vertical-align: baseline;
border-radius: .25em;
}
a.label:hover,
a.label:focus {
color: #ffffff;
text-decoration: none;
cursor: pointer;
}
.label:empty {
display: none;
}
.btn .label {
position: relative;
top: -1px;
}
.label-default {
background-color: #bbbbbb;
}
.label-default[href]:hover,
.label-default[href]:focus {
background-color: #a2a2a2;
}
.label-primary {
background-color: #2196f3;
}
.label-primary[href]:hover,
.label-primary[href]:focus {
background-color: #0c7cd5;
}
.label-success {
background-color: #4caf50;
}
.label-success[href]:hover,
.label-success[href]:focus {
background-color: #3d8b40;
}
.label-info {
background-color: #9c27b0;
}
.label-info[href]:hover,
.label-info[href]:focus {
background-color: #771e86;
}
.label-warning {
background-color: #ff9800;
}
.label-warning[href]:hover,
.label-warning[href]:focus {
background-color: #cc7a00;
}
.label-danger {
background-color: #e51c23;
}
.label-danger[href]:hover,
.label-danger[href]:focus {
background-color: #b9151b;
}
.badge {
display: inline-block;
min-width: 10px;
padding: 3px 7px;
font-size: 12px;
font-weight: normal;
color: #ffffff;
line-height: 1;
vertical-align: middle;
white-space: nowrap;
text-align: center;
background-color: #bbbbbb;
border-radius: 10px;
}
.badge:empty {
display: none;
}
.btn .badge {
position: relative;
top: -1px;
}
.btn-xs .badge,
.btn-group-xs > .btn .badge {
top: 0;
padding: 1px 5px;
}
a.badge:hover,
a.badge:focus {
color: #ffffff;
text-decoration: none;
cursor: pointer;
}
.list-group-item.active > .badge,
.nav-pills > .active > a > .badge {
color: #2196f3;
background-color: #ffffff;
}
.list-group-item > .badge {
float: right;
}
.list-group-item > .badge + .badge {
margin-right: 5px;
}
.nav-pills > li > a > .badge {
margin-left: 3px;
}
.jumbotron {
padding-top: 30px;
padding-bottom: 30px;
margin-bottom: 30px;
color: inherit;
background-color: #f9f9f9;
}
.jumbotron h1,
.jumbotron .h1 {
color: #444444;
}
.jumbotron p {
margin-bottom: 15px;
font-size: 20px;
font-weight: 200;
}
.jumbotron > hr {
border-top-color: #e0e0e0;
}
.container .jumbotron,
.container-fluid .jumbotron {
border-radius: 3px;
padding-left: 15px;
padding-right: 15px;
}
.jumbotron .container {
max-width: 100%;
}
@media screen and (min-width: 768px) {
.jumbotron {
padding-top: 48px;
padding-bottom: 48px;
}
.container .jumbotron,
.container-fluid .jumbotron {
padding-left: 60px;
padding-right: 60px;
}
.jumbotron h1,
.jumbotron .h1 {
font-size: 59px;
}
}
.thumbnail {
display: block;
padding: 4px;
margin-bottom: 23px;
line-height: 1.846;
background-color: #ffffff;
border: 1px solid #dddddd;
border-radius: 3px;
-webkit-transition: border 0.2s ease-in-out;
-o-transition: border 0.2s ease-in-out;
transition: border 0.2s ease-in-out;
}
.thumbnail > img,
.thumbnail a > img {
margin-left: auto;
margin-right: auto;
}
a.thumbnail:hover,
a.thumbnail:focus,
a.thumbnail.active {
border-color: #2196f3;
}
.thumbnail .caption {
padding: 9px;
color: #666666;
}
.alert {
padding: 15px;
margin-bottom: 23px;
border: 1px solid transparent;
border-radius: 3px;
}
.alert h4 {
margin-top: 0;
color: inherit;
}
.alert .alert-link {
font-weight: bold;
}
.alert > p,
.alert > ul {
margin-bottom: 0;
}
.alert > p + p {
margin-top: 5px;
}
.alert-dismissable,
.alert-dismissible {
padding-right: 35px;
}
.alert-dismissable .close,
.alert-dismissible .close {
position: relative;
top: -2px;
right: -21px;
color: inherit;
}
.alert-success {
background-color: #dff0d8;
border-color: #d6e9c6;
color: #4caf50;
}
.alert-success hr {
border-top-color: #c9e2b3;
}
.alert-success .alert-link {
color: #3d8b40;
}
.alert-info {
background-color: #e1bee7;
border-color: #cba4dd;
color: #9c27b0;
}
.alert-info hr {
border-top-color: #c191d6;
}
.alert-info .alert-link {
color: #771e86;
}
.alert-warning {
background-color: #ffe0b2;
border-color: #ffc599;
color: #ff9800;
}
.alert-warning hr {
border-top-color: #ffb67f;
}
.alert-warning .alert-link {
color: #cc7a00;
}
.alert-danger {
background-color: #f9bdbb;
border-color: #f7a4af;
color: #e51c23;
}
.alert-danger hr {
border-top-color: #f58c9a;
}
.alert-danger .alert-link {
color: #b9151b;
}
@-webkit-keyframes progress-bar-stripes {
from {
background-position: 40px 0;
}
to {
background-position: 0 0;
}
}
@keyframes progress-bar-stripes {
from {
background-position: 40px 0;
}
to {
background-position: 0 0;
}
}
.progress {
overflow: hidden;
height: 23px;
margin-bottom: 23px;
background-color: #f5f5f5;
border-radius: 3px;
-webkit-box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.1);
box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.1);
}
.progress-bar {
float: left;
width: 0%;
height: 100%;
font-size: 12px;
line-height: 23px;
color: #ffffff;
text-align: center;
background-color: #2196f3;
-webkit-box-shadow: inset 0 -1px 0 rgba(0, 0, 0, 0.15);
box-shadow: inset 0 -1px 0 rgba(0, 0, 0, 0.15);
-webkit-transition: width 0.6s ease;
-o-transition: width 0.6s ease;
transition: width 0.6s ease;
}
.progress-striped .progress-bar,
.progress-bar-striped {
background-image: -webkit-linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent);
background-image: -o-linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent);
background-image: linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent);
background-size: 40px 40px;
}
.progress.active .progress-bar,
.progress-bar.active {
-webkit-animation: progress-bar-stripes 2s linear infinite;
-o-animation: progress-bar-stripes 2s linear infinite;
animation: progress-bar-stripes 2s linear infinite;
}
.progress-bar-success {
background-color: #4caf50;
}
.progress-striped .progress-bar-success {
background-image: -webkit-linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent);
background-image: -o-linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent);
background-image: linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent);
}
.progress-bar-info {
background-color: #9c27b0;
}
.progress-striped .progress-bar-info {
background-image: -webkit-linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent);
background-image: -o-linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent);
background-image: linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent);
}
.progress-bar-warning {
background-color: #ff9800;
}
.progress-striped .progress-bar-warning {
background-image: -webkit-linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent);
background-image: -o-linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent);
background-image: linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent);
}
.progress-bar-danger {
background-color: #e51c23;
}
.progress-striped .progress-bar-danger {
background-image: -webkit-linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent);
background-image: -o-linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent);
background-image: linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent);
}
.media {
margin-top: 15px;
}
.media:first-child {
margin-top: 0;
}
.media,
.media-body {
zoom: 1;
overflow: hidden;
}
.media-body {
width: 10000px;
}
.media-object {
display: block;
}
.media-object.img-thumbnail {
max-width: none;
}
.media-right,
.media > .pull-right {
padding-left: 10px;
}
.media-left,
.media > .pull-left {
padding-right: 10px;
}
.media-left,
.media-right,
.media-body {
display: table-cell;
vertical-align: top;
}
.media-middle {
vertical-align: middle;
}
.media-bottom {
vertical-align: bottom;
}
.media-heading {
margin-top: 0;
margin-bottom: 5px;
}
.media-list {
padding-left: 0;
list-style: none;
}
.list-group {
margin-bottom: 20px;
padding-left: 0;
}
.list-group-item {
position: relative;
display: block;
padding: 10px 15px;
margin-bottom: -1px;
background-color: #ffffff;
border: 1px solid #dddddd;
}
.list-group-item:first-child {
border-top-right-radius: 3px;
border-top-left-radius: 3px;
}
.list-group-item:last-child {
margin-bottom: 0;
border-bottom-right-radius: 3px;
border-bottom-left-radius: 3px;
}
a.list-group-item,
button.list-group-item {
color: #555555;
}
a.list-group-item .list-group-item-heading,
button.list-group-item .list-group-item-heading {
color: #333333;
}
a.list-group-item:hover,
button.list-group-item:hover,
a.list-group-item:focus,
button.list-group-item:focus {
text-decoration: none;
color: #555555;
background-color: #f5f5f5;
}
button.list-group-item {
width: 100%;
text-align: left;
}
.list-group-item.disabled,
.list-group-item.disabled:hover,
.list-group-item.disabled:focus {
background-color: #eeeeee;
color: #bbbbbb;
cursor: not-allowed;
}
.list-group-item.disabled .list-group-item-heading,
.list-group-item.disabled:hover .list-group-item-heading,
.list-group-item.disabled:focus .list-group-item-heading {
color: inherit;
}
.list-group-item.disabled .list-group-item-text,
.list-group-item.disabled:hover .list-group-item-text,
.list-group-item.disabled:focus .list-group-item-text {
color: #bbbbbb;
}
.list-group-item.active,
.list-group-item.active:hover,
.list-group-item.active:focus {
z-index: 2;
color: #ffffff;
background-color: #2196f3;
border-color: #2196f3;
}
.list-group-item.active .list-group-item-heading,
.list-group-item.active:hover .list-group-item-heading,
.list-group-item.active:focus .list-group-item-heading,
.list-group-item.active .list-group-item-heading > small,
.list-group-item.active:hover .list-group-item-heading > small,
.list-group-item.active:focus .list-group-item-heading > small,
.list-group-item.active .list-group-item-heading > .small,
.list-group-item.active:hover .list-group-item-heading > .small,
.list-group-item.active:focus .list-group-item-heading > .small {
color: inherit;
}
.list-group-item.active .list-group-item-text,
.list-group-item.active:hover .list-group-item-text,
.list-group-item.active:focus .list-group-item-text {
color: #e3f2fd;
}
.list-group-item-success {
color: #4caf50;
background-color: #dff0d8;
}
a.list-group-item-success,
button.list-group-item-success {
color: #4caf50;
}
a.list-group-item-success .list-group-item-heading,
button.list-group-item-success .list-group-item-heading {
color: inherit;
}
a.list-group-item-success:hover,
button.list-group-item-success:hover,
a.list-group-item-success:focus,
button.list-group-item-success:focus {
color: #4caf50;
background-color: #d0e9c6;
}
a.list-group-item-success.active,
button.list-group-item-success.active,
a.list-group-item-success.active:hover,
button.list-group-item-success.active:hover,
a.list-group-item-success.active:focus,
button.list-group-item-success.active:focus {
color: #fff;
background-color: #4caf50;
border-color: #4caf50;
}
.list-group-item-info {
color: #9c27b0;
background-color: #e1bee7;
}
a.list-group-item-info,
button.list-group-item-info {
color: #9c27b0;
}
a.list-group-item-info .list-group-item-heading,
button.list-group-item-info .list-group-item-heading {
color: inherit;
}
a.list-group-item-info:hover,
button.list-group-item-info:hover,
a.list-group-item-info:focus,
button.list-group-item-info:focus {
color: #9c27b0;
background-color: #d8abe0;
}
a.list-group-item-info.active,
button.list-group-item-info.active,
a.list-group-item-info.active:hover,
button.list-group-item-info.active:hover,
a.list-group-item-info.active:focus,
button.list-group-item-info.active:focus {
color: #fff;
background-color: #9c27b0;
border-color: #9c27b0;
}
.list-group-item-warning {
color: #ff9800;
background-color: #ffe0b2;
}
a.list-group-item-warning,
button.list-group-item-warning {
color: #ff9800;
}
a.list-group-item-warning .list-group-item-heading,
button.list-group-item-warning .list-group-item-heading {
color: inherit;
}
a.list-group-item-warning:hover,
button.list-group-item-warning:hover,
a.list-group-item-warning:focus,
button.list-group-item-warning:focus {
color: #ff9800;
background-color: #ffd699;
}
a.list-group-item-warning.active,
button.list-group-item-warning.active,
a.list-group-item-warning.active:hover,
button.list-group-item-warning.active:hover,
a.list-group-item-warning.active:focus,
button.list-group-item-warning.active:focus {
color: #fff;
background-color: #ff9800;
border-color: #ff9800;
}
.list-group-item-danger {
color: #e51c23;
background-color: #f9bdbb;
}
a.list-group-item-danger,
button.list-group-item-danger {
color: #e51c23;
}
a.list-group-item-danger .list-group-item-heading,
button.list-group-item-danger .list-group-item-heading {
color: inherit;
}
a.list-group-item-danger:hover,
button.list-group-item-danger:hover,
a.list-group-item-danger:focus,
button.list-group-item-danger:focus {
color: #e51c23;
background-color: #f7a6a4;
}
a.list-group-item-danger.active,
button.list-group-item-danger.active,
a.list-group-item-danger.active:hover,
button.list-group-item-danger.active:hover,
a.list-group-item-danger.active:focus,
button.list-group-item-danger.active:focus {
color: #fff;
background-color: #e51c23;
border-color: #e51c23;
}
.list-group-item-heading {
margin-top: 0;
margin-bottom: 5px;
}
.list-group-item-text {
margin-bottom: 0;
line-height: 1.3;
}
.panel {
margin-bottom: 23px;
background-color: #ffffff;
border: 1px solid transparent;
border-radius: 3px;
-webkit-box-shadow: 0 1px 1px rgba(0, 0, 0, 0.05);
box-shadow: 0 1px 1px rgba(0, 0, 0, 0.05);
}
.panel-body {
padding: 15px;
}
.panel-heading {
padding: 10px 15px;
border-bottom: 1px solid transparent;
border-top-right-radius: 2px;
border-top-left-radius: 2px;
}
.panel-heading > .dropdown .dropdown-toggle {
color: inherit;
}
.panel-title {
margin-top: 0;
margin-bottom: 0;
font-size: 15px;
color: inherit;
}
.panel-title > a,
.panel-title > small,
.panel-title > .small,
.panel-title > small > a,
.panel-title > .small > a {
color: inherit;
}
.panel-footer {
padding: 10px 15px;
background-color: #f5f5f5;
border-top: 1px solid #dddddd;
border-bottom-right-radius: 2px;
border-bottom-left-radius: 2px;
}
.panel > .list-group,
.panel > .panel-collapse > .list-group {
margin-bottom: 0;
}
.panel > .list-group .list-group-item,
.panel > .panel-collapse > .list-group .list-group-item {
border-width: 1px 0;
border-radius: 0;
}
.panel > .list-group:first-child .list-group-item:first-child,
.panel > .panel-collapse > .list-group:first-child .list-group-item:first-child {
border-top: 0;
border-top-right-radius: 2px;
border-top-left-radius: 2px;
}
.panel > .list-group:last-child .list-group-item:last-child,
.panel > .panel-collapse > .list-group:last-child .list-group-item:last-child {
border-bottom: 0;
border-bottom-right-radius: 2px;
border-bottom-left-radius: 2px;
}
.panel > .panel-heading + .panel-collapse > .list-group .list-group-item:first-child {
border-top-right-radius: 0;
border-top-left-radius: 0;
}
.panel-heading + .list-group .list-group-item:first-child {
border-top-width: 0;
}
.list-group + .panel-footer {
border-top-width: 0;
}
.panel > .table,
.panel > .table-responsive > .table,
.panel > .panel-collapse > .table {
margin-bottom: 0;
}
.panel > .table caption,
.panel > .table-responsive > .table caption,
.panel > .panel-collapse > .table caption {
padding-left: 15px;
padding-right: 15px;
}
.panel > .table:first-child,
.panel > .table-responsive:first-child > .table:first-child {
border-top-right-radius: 2px;
border-top-left-radius: 2px;
}
.panel > .table:first-child > thead:first-child > tr:first-child,
.panel > .table-responsive:first-child > .table:first-child > thead:first-child > tr:first-child,
.panel > .table:first-child > tbody:first-child > tr:first-child,
.panel > .table-responsive:first-child > .table:first-child > tbody:first-child > tr:first-child {
border-top-left-radius: 2px;
border-top-right-radius: 2px;
}
.panel > .table:first-child > thead:first-child > tr:first-child td:first-child,
.panel > .table-responsive:first-child > .table:first-child > thead:first-child > tr:first-child td:first-child,
.panel > .table:first-child > tbody:first-child > tr:first-child td:first-child,
.panel > .table-responsive:first-child > .table:first-child > tbody:first-child > tr:first-child td:first-child,
.panel > .table:first-child > thead:first-child > tr:first-child th:first-child,
.panel > .table-responsive:first-child > .table:first-child > thead:first-child > tr:first-child th:first-child,
.panel > .table:first-child > tbody:first-child > tr:first-child th:first-child,
.panel > .table-responsive:first-child > .table:first-child > tbody:first-child > tr:first-child th:first-child {
border-top-left-radius: 2px;
}
.panel > .table:first-child > thead:first-child > tr:first-child td:last-child,
.panel > .table-responsive:first-child > .table:first-child > thead:first-child > tr:first-child td:last-child,
.panel > .table:first-child > tbody:first-child > tr:first-child td:last-child,
.panel > .table-responsive:first-child > .table:first-child > tbody:first-child > tr:first-child td:last-child,
.panel > .table:first-child > thead:first-child > tr:first-child th:last-child,
.panel > .table-responsive:first-child > .table:first-child > thead:first-child > tr:first-child th:last-child,
.panel > .table:first-child > tbody:first-child > tr:first-child th:last-child,
.panel > .table-responsive:first-child > .table:first-child > tbody:first-child > tr:first-child th:last-child {
border-top-right-radius: 2px;
}
.panel > .table:last-child,
.panel > .table-responsive:last-child > .table:last-child {
border-bottom-right-radius: 2px;
border-bottom-left-radius: 2px;
}
.panel > .table:last-child > tbody:last-child > tr:last-child,
.panel > .table-responsive:last-child > .table:last-child > tbody:last-child > tr:last-child,
.panel > .table:last-child > tfoot:last-child > tr:last-child,
.panel > .table-responsive:last-child > .table:last-child > tfoot:last-child > tr:last-child {
border-bottom-left-radius: 2px;
border-bottom-right-radius: 2px;
}
.panel > .table:last-child > tbody:last-child > tr:last-child td:first-child,
.panel > .table-responsive:last-child > .table:last-child > tbody:last-child > tr:last-child td:first-child,
.panel > .table:last-child > tfoot:last-child > tr:last-child td:first-child,
.panel > .table-responsive:last-child > .table:last-child > tfoot:last-child > tr:last-child td:first-child,
.panel > .table:last-child > tbody:last-child > tr:last-child th:first-child,
.panel > .table-responsive:last-child > .table:last-child > tbody:last-child > tr:last-child th:first-child,
.panel > .table:last-child > tfoot:last-child > tr:last-child th:first-child,
.panel > .table-responsive:last-child > .table:last-child > tfoot:last-child > tr:last-child th:first-child {
border-bottom-left-radius: 2px;
}
.panel > .table:last-child > tbody:last-child > tr:last-child td:last-child,
.panel > .table-responsive:last-child > .table:last-child > tbody:last-child > tr:last-child td:last-child,
.panel > .table:last-child > tfoot:last-child > tr:last-child td:last-child,
.panel > .table-responsive:last-child > .table:last-child > tfoot:last-child > tr:last-child td:last-child,
.panel > .table:last-child > tbody:last-child > tr:last-child th:last-child,
.panel > .table-responsive:last-child > .table:last-child > tbody:last-child > tr:last-child th:last-child,
.panel > .table:last-child > tfoot:last-child > tr:last-child th:last-child,
.panel > .table-responsive:last-child > .table:last-child > tfoot:last-child > tr:last-child th:last-child {
border-bottom-right-radius: 2px;
}
.panel > .panel-body + .table,
.panel > .panel-body + .table-responsive,
.panel > .table + .panel-body,
.panel > .table-responsive + .panel-body {
border-top: 1px solid #dddddd;
}
.panel > .table > tbody:first-child > tr:first-child th,
.panel > .table > tbody:first-child > tr:first-child td {
border-top: 0;
}
.panel > .table-bordered,
.panel > .table-responsive > .table-bordered {
border: 0;
}
.panel > .table-bordered > thead > tr > th:first-child,
.panel > .table-responsive > .table-bordered > thead > tr > th:first-child,
.panel > .table-bordered > tbody > tr > th:first-child,
.panel > .table-responsive > .table-bordered > tbody > tr > th:first-child,
.panel > .table-bordered > tfoot > tr > th:first-child,
.panel > .table-responsive > .table-bordered > tfoot > tr > th:first-child,
.panel > .table-bordered > thead > tr > td:first-child,
.panel > .table-responsive > .table-bordered > thead > tr > td:first-child,
.panel > .table-bordered > tbody > tr > td:first-child,
.panel > .table-responsive > .table-bordered > tbody > tr > td:first-child,
.panel > .table-bordered > tfoot > tr > td:first-child,
.panel > .table-responsive > .table-bordered > tfoot > tr > td:first-child {
border-left: 0;
}
.panel > .table-bordered > thead > tr > th:last-child,
.panel > .table-responsive > .table-bordered > thead > tr > th:last-child,
.panel > .table-bordered > tbody > tr > th:last-child,
.panel > .table-responsive > .table-bordered > tbody > tr > th:last-child,
.panel > .table-bordered > tfoot > tr > th:last-child,
.panel > .table-responsive > .table-bordered > tfoot > tr > th:last-child,
.panel > .table-bordered > thead > tr > td:last-child,
.panel > .table-responsive > .table-bordered > thead > tr > td:last-child,
.panel > .table-bordered > tbody > tr > td:last-child,
.panel > .table-responsive > .table-bordered > tbody > tr > td:last-child,
.panel > .table-bordered > tfoot > tr > td:last-child,
.panel > .table-responsive > .table-bordered > tfoot > tr > td:last-child {
border-right: 0;
}
.panel > .table-bordered > thead > tr:first-child > td,
.panel > .table-responsive > .table-bordered > thead > tr:first-child > td,
.panel > .table-bordered > tbody > tr:first-child > td,
.panel > .table-responsive > .table-bordered > tbody > tr:first-child > td,
.panel > .table-bordered > thead > tr:first-child > th,
.panel > .table-responsive > .table-bordered > thead > tr:first-child > th,
.panel > .table-bordered > tbody > tr:first-child > th,
.panel > .table-responsive > .table-bordered > tbody > tr:first-child > th {
border-bottom: 0;
}
.panel > .table-bordered > tbody > tr:last-child > td,
.panel > .table-responsive > .table-bordered > tbody > tr:last-child > td,
.panel > .table-bordered > tfoot > tr:last-child > td,
.panel > .table-responsive > .table-bordered > tfoot > tr:last-child > td,
.panel > .table-bordered > tbody > tr:last-child > th,
.panel > .table-responsive > .table-bordered > tbody > tr:last-child > th,
.panel > .table-bordered > tfoot > tr:last-child > th,
.panel > .table-responsive > .table-bordered > tfoot > tr:last-child > th {
border-bottom: 0;
}
.panel > .table-responsive {
border: 0;
margin-bottom: 0;
}
.panel-group {
margin-bottom: 23px;
}
.panel-group .panel {
margin-bottom: 0;
border-radius: 3px;
}
.panel-group .panel + .panel {
margin-top: 5px;
}
.panel-group .panel-heading {
border-bottom: 0;
}
.panel-group .panel-heading + .panel-collapse > .panel-body,
.panel-group .panel-heading + .panel-collapse > .list-group {
border-top: 1px solid #dddddd;
}
.panel-group .panel-footer {
border-top: 0;
}
.panel-group .panel-footer + .panel-collapse .panel-body {
border-bottom: 1px solid #dddddd;
}
.panel-default {
border-color: #dddddd;
}
.panel-default > .panel-heading {
color: #212121;
background-color: #f5f5f5;
border-color: #dddddd;
}
.panel-default > .panel-heading + .panel-collapse > .panel-body {
border-top-color: #dddddd;
}
.panel-default > .panel-heading .badge {
color: #f5f5f5;
background-color: #212121;
}
.panel-default > .panel-footer + .panel-collapse > .panel-body {
border-bottom-color: #dddddd;
}
.panel-primary {
border-color: #2196f3;
}
.panel-primary > .panel-heading {
color: #ffffff;
background-color: #2196f3;
border-color: #2196f3;
}
.panel-primary > .panel-heading + .panel-collapse > .panel-body {
border-top-color: #2196f3;
}
.panel-primary > .panel-heading .badge {
color: #2196f3;
background-color: #ffffff;
}
.panel-primary > .panel-footer + .panel-collapse > .panel-body {
border-bottom-color: #2196f3;
}
.panel-success {
border-color: #d6e9c6;
}
.panel-success > .panel-heading {
color: #ffffff;
background-color: #4caf50;
border-color: #d6e9c6;
}
.panel-success > .panel-heading + .panel-collapse > .panel-body {
border-top-color: #d6e9c6;
}
.panel-success > .panel-heading .badge {
color: #4caf50;
background-color: #ffffff;
}
.panel-success > .panel-footer + .panel-collapse > .panel-body {
border-bottom-color: #d6e9c6;
}
.panel-info {
border-color: #cba4dd;
}
.panel-info > .panel-heading {
color: #ffffff;
background-color: #9c27b0;
border-color: #cba4dd;
}
.panel-info > .panel-heading + .panel-collapse > .panel-body {
border-top-color: #cba4dd;
}
.panel-info > .panel-heading .badge {
color: #9c27b0;
background-color: #ffffff;
}
.panel-info > .panel-footer + .panel-collapse > .panel-body {
border-bottom-color: #cba4dd;
}
.panel-warning {
border-color: #ffc599;
}
.panel-warning > .panel-heading {
color: #ffffff;
background-color: #ff9800;
border-color: #ffc599;
}
.panel-warning > .panel-heading + .panel-collapse > .panel-body {
border-top-color: #ffc599;
}
.panel-warning > .panel-heading .badge {
color: #ff9800;
background-color: #ffffff;
}
.panel-warning > .panel-footer + .panel-collapse > .panel-body {
border-bottom-color: #ffc599;
}
.panel-danger {
border-color: #f7a4af;
}
.panel-danger > .panel-heading {
color: #ffffff;
background-color: #e51c23;
border-color: #f7a4af;
}
.panel-danger > .panel-heading + .panel-collapse > .panel-body {
border-top-color: #f7a4af;
}
.panel-danger > .panel-heading .badge {
color: #e51c23;
background-color: #ffffff;
}
.panel-danger > .panel-footer + .panel-collapse > .panel-body {
border-bottom-color: #f7a4af;
}
.embed-responsive {
position: relative;
display: block;
height: 0;
padding: 0;
overflow: hidden;
}
.embed-responsive .embed-responsive-item,
.embed-responsive iframe,
.embed-responsive embed,
.embed-responsive object,
.embed-responsive video {
position: absolute;
top: 0;
left: 0;
bottom: 0;
height: 100%;
width: 100%;
border: 0;
}
.embed-responsive-16by9 {
padding-bottom: 56.25%;
}
.embed-responsive-4by3 {
padding-bottom: 75%;
}
.well {
min-height: 20px;
padding: 19px;
margin-bottom: 20px;
background-color: #f9f9f9;
border: 1px solid transparent;
border-radius: 3px;
-webkit-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.05);
box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.05);
}
.well blockquote {
border-color: #ddd;
border-color: rgba(0, 0, 0, 0.15);
}
.well-lg {
padding: 24px;
border-radius: 3px;
}
.well-sm {
padding: 9px;
border-radius: 3px;
}
.close {
float: right;
font-size: 19.5px;
font-weight: normal;
line-height: 1;
color: #000000;
text-shadow: none;
opacity: 0.2;
filter: alpha(opacity=20);
}
.close:hover,
.close:focus {
color: #000000;
text-decoration: none;
cursor: pointer;
opacity: 0.5;
filter: alpha(opacity=50);
}
button.close {
padding: 0;
cursor: pointer;
background: transparent;
border: 0;
-webkit-appearance: none;
}
.modal-open {
overflow: hidden;
}
.modal {
display: none;
overflow: hidden;
position: fixed;
top: 0;
right: 0;
bottom: 0;
left: 0;
z-index: 1050;
-webkit-overflow-scrolling: touch;
outline: 0;
}
.modal.fade .modal-dialog {
-webkit-transform: translate(0, -25%);
-ms-transform: translate(0, -25%);
-o-transform: translate(0, -25%);
transform: translate(0, -25%);
-webkit-transition: -webkit-transform 0.3s ease-out;
-moz-transition: -moz-transform 0.3s ease-out;
-o-transition: -o-transform 0.3s ease-out;
transition: transform 0.3s ease-out;
}
.modal.in .modal-dialog {
-webkit-transform: translate(0, 0);
-ms-transform: translate(0, 0);
-o-transform: translate(0, 0);
transform: translate(0, 0);
}
.modal-open .modal {
overflow-x: hidden;
overflow-y: auto;
}
.modal-dialog {
position: relative;
width: auto;
margin: 10px;
}
.modal-content {
position: relative;
background-color: #ffffff;
border: 1px solid #999999;
border: 1px solid transparent;
border-radius: 3px;
-webkit-box-shadow: 0 3px 9px rgba(0, 0, 0, 0.5);
box-shadow: 0 3px 9px rgba(0, 0, 0, 0.5);
background-clip: padding-box;
outline: 0;
}
.modal-backdrop {
position: fixed;
top: 0;
right: 0;
bottom: 0;
left: 0;
z-index: 1040;
background-color: #000000;
}
.modal-backdrop.fade {
opacity: 0;
filter: alpha(opacity=0);
}
.modal-backdrop.in {
opacity: 0.5;
filter: alpha(opacity=50);
}
.modal-header {
padding: 15px;
border-bottom: 1px solid transparent;
}
.modal-header .close {
margin-top: -2px;
}
.modal-title {
margin: 0;
line-height: 1.846;
}
.modal-body {
position: relative;
padding: 15px;
}
.modal-footer {
padding: 15px;
text-align: right;
border-top: 1px solid transparent;
}
.modal-footer .btn + .btn {
margin-left: 5px;
margin-bottom: 0;
}
.modal-footer .btn-group .btn + .btn {
margin-left: -1px;
}
.modal-footer .btn-block + .btn-block {
margin-left: 0;
}
.modal-scrollbar-measure {
position: absolute;
top: -9999px;
width: 50px;
height: 50px;
overflow: scroll;
}
@media (min-width: 768px) {
.modal-dialog {
width: 600px;
margin: 30px auto;
}
.modal-content {
-webkit-box-shadow: 0 5px 15px rgba(0, 0, 0, 0.5);
box-shadow: 0 5px 15px rgba(0, 0, 0, 0.5);
}
.modal-sm {
width: 300px;
}
}
@media (min-width: 992px) {
.modal-lg {
width: 900px;
}
}
.tooltip {
position: absolute;
z-index: 1070;
display: block;
font-family: "Roboto", "Helvetica Neue", Helvetica, Arial, sans-serif;
font-style: normal;
font-weight: normal;
letter-spacing: normal;
line-break: auto;
line-height: 1.846;
text-align: left;
text-align: start;
text-decoration: none;
text-shadow: none;
text-transform: none;
white-space: normal;
word-break: normal;
word-spacing: normal;
word-wrap: normal;
font-size: 12px;
opacity: 0;
filter: alpha(opacity=0);
}
.tooltip.in {
opacity: 0.9;
filter: alpha(opacity=90);
}
.tooltip.top {
margin-top: -3px;
padding: 5px 0;
}
.tooltip.right {
margin-left: 3px;
padding: 0 5px;
}
.tooltip.bottom {
margin-top: 3px;
padding: 5px 0;
}
.tooltip.left {
margin-left: -3px;
padding: 0 5px;
}
.tooltip-inner {
max-width: 200px;
padding: 3px 8px;
color: #ffffff;
text-align: center;
background-color: #727272;
border-radius: 3px;
}
.tooltip-arrow {
position: absolute;
width: 0;
height: 0;
border-color: transparent;
border-style: solid;
}
.tooltip.top .tooltip-arrow {
bottom: 0;
left: 50%;
margin-left: -5px;
border-width: 5px 5px 0;
border-top-color: #727272;
}
.tooltip.top-left .tooltip-arrow {
bottom: 0;
right: 5px;
margin-bottom: -5px;
border-width: 5px 5px 0;
border-top-color: #727272;
}
.tooltip.top-right .tooltip-arrow {
bottom: 0;
left: 5px;
margin-bottom: -5px;
border-width: 5px 5px 0;
border-top-color: #727272;
}
.tooltip.right .tooltip-arrow {
top: 50%;
left: 0;
margin-top: -5px;
border-width: 5px 5px 5px 0;
border-right-color: #727272;
}
.tooltip.left .tooltip-arrow {
top: 50%;
right: 0;
margin-top: -5px;
border-width: 5px 0 5px 5px;
border-left-color: #727272;
}
.tooltip.bottom .tooltip-arrow {
top: 0;
left: 50%;
margin-left: -5px;
border-width: 0 5px 5px;
border-bottom-color: #727272;
}
.tooltip.bottom-left .tooltip-arrow {
top: 0;
right: 5px;
margin-top: -5px;
border-width: 0 5px 5px;
border-bottom-color: #727272;
}
.tooltip.bottom-right .tooltip-arrow {
top: 0;
left: 5px;
margin-top: -5px;
border-width: 0 5px 5px;
border-bottom-color: #727272;
}
.popover {
position: absolute;
top: 0;
left: 0;
z-index: 1060;
display: none;
max-width: 276px;
padding: 1px;
font-family: "Roboto", "Helvetica Neue", Helvetica, Arial, sans-serif;
font-style: normal;
font-weight: normal;
letter-spacing: normal;
line-break: auto;
line-height: 1.846;
text-align: left;
text-align: start;
text-decoration: none;
text-shadow: none;
text-transform: none;
white-space: normal;
word-break: normal;
word-spacing: normal;
word-wrap: normal;
font-size: 13px;
background-color: #ffffff;
background-clip: padding-box;
border: 1px solid transparent;
border-radius: 3px;
-webkit-box-shadow: 0 5px 10px rgba(0, 0, 0, 0.2);
box-shadow: 0 5px 10px rgba(0, 0, 0, 0.2);
}
.popover.top {
margin-top: -10px;
}
.popover.right {
margin-left: 10px;
}
.popover.bottom {
margin-top: 10px;
}
.popover.left {
margin-left: -10px;
}
.popover-title {
margin: 0;
padding: 8px 14px;
font-size: 13px;
background-color: #f7f7f7;
border-bottom: 1px solid #ebebeb;
border-radius: 2px 2px 0 0;
}
.popover-content {
padding: 9px 14px;
}
.popover > .arrow,
.popover > .arrow:after {
position: absolute;
display: block;
width: 0;
height: 0;
border-color: transparent;
border-style: solid;
}
.popover > .arrow {
border-width: 11px;
}
.popover > .arrow:after {
border-width: 10px;
content: "";
}
.popover.top > .arrow {
left: 50%;
margin-left: -11px;
border-bottom-width: 0;
border-top-color: rgba(0, 0, 0, 0);
border-top-color: rgba(0, 0, 0, 0.075);
bottom: -11px;
}
.popover.top > .arrow:after {
content: " ";
bottom: 1px;
margin-left: -10px;
border-bottom-width: 0;
border-top-color: #ffffff;
}
.popover.right > .arrow {
top: 50%;
left: -11px;
margin-top: -11px;
border-left-width: 0;
border-right-color: rgba(0, 0, 0, 0);
border-right-color: rgba(0, 0, 0, 0.075);
}
.popover.right > .arrow:after {
content: " ";
left: 1px;
bottom: -10px;
border-left-width: 0;
border-right-color: #ffffff;
}
.popover.bottom > .arrow {
left: 50%;
margin-left: -11px;
border-top-width: 0;
border-bottom-color: rgba(0, 0, 0, 0);
border-bottom-color: rgba(0, 0, 0, 0.075);
top: -11px;
}
.popover.bottom > .arrow:after {
content: " ";
top: 1px;
margin-left: -10px;
border-top-width: 0;
border-bottom-color: #ffffff;
}
.popover.left > .arrow {
top: 50%;
right: -11px;
margin-top: -11px;
border-right-width: 0;
border-left-color: rgba(0, 0, 0, 0);
border-left-color: rgba(0, 0, 0, 0.075);
}
.popover.left > .arrow:after {
content: " ";
right: 1px;
border-right-width: 0;
border-left-color: #ffffff;
bottom: -10px;
}
.carousel {
position: relative;
}
.carousel-inner {
position: relative;
overflow: hidden;
width: 100%;
}
.carousel-inner > .item {
display: none;
position: relative;
-webkit-transition: 0.6s ease-in-out left;
-o-transition: 0.6s ease-in-out left;
transition: 0.6s ease-in-out left;
}
.carousel-inner > .item > img,
.carousel-inner > .item > a > img {
line-height: 1;
}
@media all and (transform-3d), (-webkit-transform-3d) {
.carousel-inner > .item {
-webkit-transition: -webkit-transform 0.6s ease-in-out;
-moz-transition: -moz-transform 0.6s ease-in-out;
-o-transition: -o-transform 0.6s ease-in-out;
transition: transform 0.6s ease-in-out;
-webkit-backface-visibility: hidden;
-moz-backface-visibility: hidden;
backface-visibility: hidden;
-webkit-perspective: 1000px;
-moz-perspective: 1000px;
perspective: 1000px;
}
.carousel-inner > .item.next,
.carousel-inner > .item.active.right {
-webkit-transform: translate3d(100%, 0, 0);
transform: translate3d(100%, 0, 0);
left: 0;
}
.carousel-inner > .item.prev,
.carousel-inner > .item.active.left {
-webkit-transform: translate3d(-100%, 0, 0);
transform: translate3d(-100%, 0, 0);
left: 0;
}
.carousel-inner > .item.next.left,
.carousel-inner > .item.prev.right,
.carousel-inner > .item.active {
-webkit-transform: translate3d(0, 0, 0);
transform: translate3d(0, 0, 0);
left: 0;
}
}
.carousel-inner > .active,
.carousel-inner > .next,
.carousel-inner > .prev {
display: block;
}
.carousel-inner > .active {
left: 0;
}
.carousel-inner > .next,
.carousel-inner > .prev {
position: absolute;
top: 0;
width: 100%;
}
.carousel-inner > .next {
left: 100%;
}
.carousel-inner > .prev {
left: -100%;
}
.carousel-inner > .next.left,
.carousel-inner > .prev.right {
left: 0;
}
.carousel-inner > .active.left {
left: -100%;
}
.carousel-inner > .active.right {
left: 100%;
}
.carousel-control {
position: absolute;
top: 0;
left: 0;
bottom: 0;
width: 15%;
opacity: 0.5;
filter: alpha(opacity=50);
font-size: 20px;
color: #ffffff;
text-align: center;
text-shadow: 0 1px 2px rgba(0, 0, 0, 0.6);
background-color: rgba(0, 0, 0, 0);
}
.carousel-control.left {
background-image: -webkit-linear-gradient(left, rgba(0, 0, 0, 0.5) 0%, rgba(0, 0, 0, 0.0001) 100%);
background-image: -o-linear-gradient(left, rgba(0, 0, 0, 0.5) 0%, rgba(0, 0, 0, 0.0001) 100%);
background-image: linear-gradient(to right, rgba(0, 0, 0, 0.5) 0%, rgba(0, 0, 0, 0.0001) 100%);
background-repeat: repeat-x;
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#80000000', endColorstr='#00000000', GradientType=1);
}
.carousel-control.right {
left: auto;
right: 0;
background-image: -webkit-linear-gradient(left, rgba(0, 0, 0, 0.0001) 0%, rgba(0, 0, 0, 0.5) 100%);
background-image: -o-linear-gradient(left, rgba(0, 0, 0, 0.0001) 0%, rgba(0, 0, 0, 0.5) 100%);
background-image: linear-gradient(to right, rgba(0, 0, 0, 0.0001) 0%, rgba(0, 0, 0, 0.5) 100%);
background-repeat: repeat-x;
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#00000000', endColorstr='#80000000', GradientType=1);
}
.carousel-control:hover,
.carousel-control:focus {
outline: 0;
color: #ffffff;
text-decoration: none;
opacity: 0.9;
filter: alpha(opacity=90);
}
.carousel-control .icon-prev,
.carousel-control .icon-next,
.carousel-control .glyphicon-chevron-left,
.carousel-control .glyphicon-chevron-right {
position: absolute;
top: 50%;
margin-top: -10px;
z-index: 5;
display: inline-block;
}
.carousel-control .icon-prev,
.carousel-control .glyphicon-chevron-left {
left: 50%;
margin-left: -10px;
}
.carousel-control .icon-next,
.carousel-control .glyphicon-chevron-right {
right: 50%;
margin-right: -10px;
}
.carousel-control .icon-prev,
.carousel-control .icon-next {
width: 20px;
height: 20px;
line-height: 1;
font-family: serif;
}
.carousel-control .icon-prev:before {
content: '\2039';
}
.carousel-control .icon-next:before {
content: '\203a';
}
.carousel-indicators {
position: absolute;
bottom: 10px;
left: 50%;
z-index: 15;
width: 60%;
margin-left: -30%;
padding-left: 0;
list-style: none;
text-align: center;
}
.carousel-indicators li {
display: inline-block;
width: 10px;
height: 10px;
margin: 1px;
text-indent: -999px;
border: 1px solid #ffffff;
border-radius: 10px;
cursor: pointer;
background-color: #000 \9;
background-color: rgba(0, 0, 0, 0);
}
.carousel-indicators .active {
margin: 0;
width: 12px;
height: 12px;
background-color: #ffffff;
}
.carousel-caption {
position: absolute;
left: 15%;
right: 15%;
bottom: 20px;
z-index: 10;
padding-top: 20px;
padding-bottom: 20px;
color: #ffffff;
text-align: center;
text-shadow: 0 1px 2px rgba(0, 0, 0, 0.6);
}
.carousel-caption .btn {
text-shadow: none;
}
@media screen and (min-width: 768px) {
.carousel-control .glyphicon-chevron-left,
.carousel-control .glyphicon-chevron-right,
.carousel-control .icon-prev,
.carousel-control .icon-next {
width: 30px;
height: 30px;
margin-top: -10px;
font-size: 30px;
}
.carousel-control .glyphicon-chevron-left,
.carousel-control .icon-prev {
margin-left: -10px;
}
.carousel-control .glyphicon-chevron-right,
.carousel-control .icon-next {
margin-right: -10px;
}
.carousel-caption {
left: 20%;
right: 20%;
padding-bottom: 30px;
}
.carousel-indicators {
bottom: 20px;
}
}
.clearfix:before,
.clearfix:after,
.dl-horizontal dd:before,
.dl-horizontal dd:after,
.container:before,
.container:after,
.container-fluid:before,
.container-fluid:after,
.row:before,
.row:after,
.form-horizontal .form-group:before,
.form-horizontal .form-group:after,
.btn-toolbar:before,
.btn-toolbar:after,
.btn-group-vertical > .btn-group:before,
.btn-group-vertical > .btn-group:after,
.nav:before,
.nav:after,
.navbar:before,
.navbar:after,
.navbar-header:before,
.navbar-header:after,
.navbar-collapse:before,
.navbar-collapse:after,
.pager:before,
.pager:after,
.panel-body:before,
.panel-body:after,
.modal-header:before,
.modal-header:after,
.modal-footer:before,
.modal-footer:after {
content: " ";
display: table;
}
.clearfix:after,
.dl-horizontal dd:after,
.container:after,
.container-fluid:after,
.row:after,
.form-horizontal .form-group:after,
.btn-toolbar:after,
.btn-group-vertical > .btn-group:after,
.nav:after,
.navbar:after,
.navbar-header:after,
.navbar-collapse:after,
.pager:after,
.panel-body:after,
.modal-header:after,
.modal-footer:after {
clear: both;
}
.center-block {
display: block;
margin-left: auto;
margin-right: auto;
}
.pull-right {
float: right !important;
}
.pull-left {
float: left !important;
}
.hide {
display: none !important;
}
.show {
display: block !important;
}
.invisible {
visibility: hidden;
}
.text-hide {
font: 0/0 a;
color: transparent;
text-shadow: none;
background-color: transparent;
border: 0;
}
.hidden {
display: none !important;
}
.affix {
position: fixed;
}
@-ms-viewport {
width: device-width;
}
.visible-xs,
.visible-sm,
.visible-md,
.visible-lg {
display: none !important;
}
.visible-xs-block,
.visible-xs-inline,
.visible-xs-inline-block,
.visible-sm-block,
.visible-sm-inline,
.visible-sm-inline-block,
.visible-md-block,
.visible-md-inline,
.visible-md-inline-block,
.visible-lg-block,
.visible-lg-inline,
.visible-lg-inline-block {
display: none !important;
}
@media (max-width: 767px) {
.visible-xs {
display: block !important;
}
table.visible-xs {
display: table !important;
}
tr.visible-xs {
display: table-row !important;
}
th.visible-xs,
td.visible-xs {
display: table-cell !important;
}
}
@media (max-width: 767px) {
.visible-xs-block {
display: block !important;
}
}
@media (max-width: 767px) {
.visible-xs-inline {
display: inline !important;
}
}
@media (max-width: 767px) {
.visible-xs-inline-block {
display: inline-block !important;
}
}
@media (min-width: 768px) and (max-width: 991px) {
.visible-sm {
display: block !important;
}
table.visible-sm {
display: table !important;
}
tr.visible-sm {
display: table-row !important;
}
th.visible-sm,
td.visible-sm {
display: table-cell !important;
}
}
@media (min-width: 768px) and (max-width: 991px) {
.visible-sm-block {
display: block !important;
}
}
@media (min-width: 768px) and (max-width: 991px) {
.visible-sm-inline {
display: inline !important;
}
}
@media (min-width: 768px) and (max-width: 991px) {
.visible-sm-inline-block {
display: inline-block !important;
}
}
@media (min-width: 992px) and (max-width: 1199px) {
.visible-md {
display: block !important;
}
table.visible-md {
display: table !important;
}
tr.visible-md {
display: table-row !important;
}
th.visible-md,
td.visible-md {
display: table-cell !important;
}
}
@media (min-width: 992px) and (max-width: 1199px) {
.visible-md-block {
display: block !important;
}
}
@media (min-width: 992px) and (max-width: 1199px) {
.visible-md-inline {
display: inline !important;
}
}
@media (min-width: 992px) and (max-width: 1199px) {
.visible-md-inline-block {
display: inline-block !important;
}
}
@media (min-width: 1200px) {
.visible-lg {
display: block !important;
}
table.visible-lg {
display: table !important;
}
tr.visible-lg {
display: table-row !important;
}
th.visible-lg,
td.visible-lg {
display: table-cell !important;
}
}
@media (min-width: 1200px) {
.visible-lg-block {
display: block !important;
}
}
@media (min-width: 1200px) {
.visible-lg-inline {
display: inline !important;
}
}
@media (min-width: 1200px) {
.visible-lg-inline-block {
display: inline-block !important;
}
}
@media (max-width: 767px) {
.hidden-xs {
display: none !important;
}
}
@media (min-width: 768px) and (max-width: 991px) {
.hidden-sm {
display: none !important;
}
}
@media (min-width: 992px) and (max-width: 1199px) {
.hidden-md {
display: none !important;
}
}
@media (min-width: 1200px) {
.hidden-lg {
display: none !important;
}
}
.visible-print {
display: none !important;
}
@media print {
.visible-print {
display: block !important;
}
table.visible-print {
display: table !important;
}
tr.visible-print {
display: table-row !important;
}
th.visible-print,
td.visible-print {
display: table-cell !important;
}
}
.visible-print-block {
display: none !important;
}
@media print {
.visible-print-block {
display: block !important;
}
}
.visible-print-inline {
display: none !important;
}
@media print {
.visible-print-inline {
display: inline !important;
}
}
.visible-print-inline-block {
display: none !important;
}
@media print {
.visible-print-inline-block {
display: inline-block !important;
}
}
@media print {
.hidden-print {
display: none !important;
}
}
header.page-header::before,
.layout_social > .container:before {
content: none;
}
.topbar {
margin-bottom: 20px;
}
.cssmenu_horiz li ul,
.cssmenu_vert li ul {
padding: 0;
margin: 2px 0 0;
background-color: #ffffff;
border: 1px solid rgba(0, 0, 0, 0.15);
border-radius: 3px;
-webkit-box-shadow: 0 6px 12px rgba(0, 0, 0, 0.175);
box-shadow: 0 6px 12px rgba(0, 0, 0, 0.175);
-webkit-background-clip: padding-box;
background-clip: padding-box;
}
.cssmenu_horiz li ul > li > a,
.cssmenu_vert li ul > li > a {
padding: 3px 20px;
font-weight: normal;
line-height: 1.846;
color: #666666;
}
.cssmenu_horiz > li > ul {
border-top-left-radius: 0;
border-top-right-radius: 0;
margin: 0;
}
.cssmenu_horiz > li > a:hover,
.cssmenu_vert > li > a:hover,
.cssmenu_horiz ul > li > a:hover,
.cssmenu_vert ul > li > a:hover,
.cssmenu_horiz > li > a:focus,
.cssmenu_vert > li > a:focus,
.cssmenu_horiz ul > li > a:focus,
.cssmenu_vert ul > li > a:focus {
text-decoration: none;
color: #141414;
background-color: #eeeeee;
}
.topbar .nav > li.selected > a,
.topbar .nav > li.selected > a:hover {
background: #eeeeee;
}
.sf-arrows .sf-with-ul:after {
border: 5px solid transparent;
border-top-color: #666666;
}
.sf-arrows ul .sf-with-ul:after,
.cssmenu_vert.sf-arrows > li > .sf-with-ul:after {
border-color: transparent;
border-left-color: #666666;
}
.sf-arrows ul li > .sf-with-ul:focus:after,
.sf-arrows ul li:hover > .sf-with-ul:after,
.sf-arrows ul .sfHover > .sf-with-ul:after {
border-color: transparent;
border-left-color: #141414;
}
.cssmenu_vert.sf-arrows li > .sf-with-ul:focus:after,
.cssmenu_vert.sf-arrows li:hover > .sf-with-ul:after,
.cssmenu_vert.sf-arrows .sfHover > .sf-with-ul:after {
border-color: transparent;
border-left-color: #141414;
}
.dropdown-menu li {
background-color: #ffffff;
color: #666666;
}
.dropdown-menu li:hover,
.dropdown-menu li:focus {
background-color: #eeeeee;
color: #141414;
}
.navbar {
border: none;
-webkit-box-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
box-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
}
.navbar-brand {
font-size: 24px;
}
.navbar-inverse .navbar-form input[type=text],
.navbar-inverse .navbar-form input[type=password] {
color: #ffffff;
-webkit-box-shadow: inset 0 -1px 0 #b2dbfb;
box-shadow: inset 0 -1px 0 #b2dbfb;
}
.navbar-inverse .navbar-form input[type=text]::-moz-placeholder,
.navbar-inverse .navbar-form input[type=password]::-moz-placeholder {
color: #b2dbfb;
opacity: 1;
}
.navbar-inverse .navbar-form input[type=text]:-ms-input-placeholder,
.navbar-inverse .navbar-form input[type=password]:-ms-input-placeholder {
color: #b2dbfb;
}
.navbar-inverse .navbar-form input[type=text]::-webkit-input-placeholder,
.navbar-inverse .navbar-form input[type=password]::-webkit-input-placeholder {
color: #b2dbfb;
}
.navbar-inverse .navbar-form input[type=text]:focus,
.navbar-inverse .navbar-form input[type=password]:focus {
-webkit-box-shadow: inset 0 -2px 0 #ffffff;
box-shadow: inset 0 -2px 0 #ffffff;
}
.btn-default {
background-size: 200%;
background-position: 50%;
}
.btn-default:focus {
background-color: #ffffff;
}
.btn-default:hover,
.btn-default:active:hover {
background-color: #f0f0f0;
}
.btn-default:active {
background-color: #e0e0e0;
background-image: -webkit-radial-gradient(circle, #e0e0e0 10%, #ffffff 11%);
background-image: radial-gradient(circle, #e0e0e0 10%, #ffffff 11%);
background-repeat: no-repeat;
background-size: 1000%;
-webkit-box-shadow: 2px 2px 4px rgba(0, 0, 0, 0.4);
box-shadow: 2px 2px 4px rgba(0, 0, 0, 0.4);
}
.btn-primary {
background-size: 200%;
background-position: 50%;
}
.btn-primary:focus {
background-color: #2196f3;
}
.btn-primary:hover,
.btn-primary:active:hover {
background-color: #0d87e9;
}
.btn-primary:active {
background-color: #0b76cc;
background-image: -webkit-radial-gradient(circle, #0b76cc 10%, #2196f3 11%);
background-image: radial-gradient(circle, #0b76cc 10%, #2196f3 11%);
background-repeat: no-repeat;
background-size: 1000%;
-webkit-box-shadow: 2px 2px 4px rgba(0, 0, 0, 0.4);
box-shadow: 2px 2px 4px rgba(0, 0, 0, 0.4);
}
.btn-success {
background-size: 200%;
background-position: 50%;
}
.btn-success:focus {
background-color: #4caf50;
}
.btn-success:hover,
.btn-success:active:hover {
background-color: #439a46;
}
.btn-success:active {
background-color: #39843c;
background-image: -webkit-radial-gradient(circle, #39843c 10%, #4caf50 11%);
background-image: radial-gradient(circle, #39843c 10%, #4caf50 11%);
background-repeat: no-repeat;
background-size: 1000%;
-webkit-box-shadow: 2px 2px 4px rgba(0, 0, 0, 0.4);
box-shadow: 2px 2px 4px rgba(0, 0, 0, 0.4);
}
.btn-info {
background-size: 200%;
background-position: 50%;
}
.btn-info:focus {
background-color: #9c27b0;
}
.btn-info:hover,
.btn-info:active:hover {
background-color: #862197;
}
.btn-info:active {
background-color: #701c7e;
background-image: -webkit-radial-gradient(circle, #701c7e 10%, #9c27b0 11%);
background-image: radial-gradient(circle, #701c7e 10%, #9c27b0 11%);
background-repeat: no-repeat;
background-size: 1000%;
-webkit-box-shadow: 2px 2px 4px rgba(0, 0, 0, 0.4);
box-shadow: 2px 2px 4px rgba(0, 0, 0, 0.4);
}
.btn-warning {
background-size: 200%;
background-position: 50%;
}
.btn-warning:focus {
background-color: #ff9800;
}
.btn-warning:hover,
.btn-warning:active:hover {
background-color: #e08600;
}
.btn-warning:active {
background-color: #c27400;
background-image: -webkit-radial-gradient(circle, #c27400 10%, #ff9800 11%);
background-image: radial-gradient(circle, #c27400 10%, #ff9800 11%);
background-repeat: no-repeat;
background-size: 1000%;
-webkit-box-shadow: 2px 2px 4px rgba(0, 0, 0, 0.4);
box-shadow: 2px 2px 4px rgba(0, 0, 0, 0.4);
}
.btn-danger {
background-size: 200%;
background-position: 50%;
}
.btn-danger:focus {
background-color: #e51c23;
}
.btn-danger:hover,
.btn-danger:active:hover {
background-color: #cb171e;
}
.btn-danger:active {
background-color: #b0141a;
background-image: -webkit-radial-gradient(circle, #b0141a 10%, #e51c23 11%);
background-image: radial-gradient(circle, #b0141a 10%, #e51c23 11%);
background-repeat: no-repeat;
background-size: 1000%;
-webkit-box-shadow: 2px 2px 4px rgba(0, 0, 0, 0.4);
box-shadow: 2px 2px 4px rgba(0, 0, 0, 0.4);
}
.btn-link {
background-size: 200%;
background-position: 50%;
}
.btn-link:focus {
background-color: #ffffff;
}
.btn-link:hover,
.btn-link:active:hover {
background-color: #f0f0f0;
}
.btn-link:active {
background-color: #e0e0e0;
background-image: -webkit-radial-gradient(circle, #e0e0e0 10%, #ffffff 11%);
background-image: radial-gradient(circle, #e0e0e0 10%, #ffffff 11%);
background-repeat: no-repeat;
background-size: 1000%;
-webkit-box-shadow: 2px 2px 4px rgba(0, 0, 0, 0.4);
box-shadow: 2px 2px 4px rgba(0, 0, 0, 0.4);
}
.btn {
text-transform: uppercase;
border: none;
-webkit-box-shadow: 1px 1px 4px rgba(0, 0, 0, 0.4);
box-shadow: 1px 1px 4px rgba(0, 0, 0, 0.4);
-webkit-transition: all 0.4s;
-o-transition: all 0.4s;
transition: all 0.4s;
}
.btn-link {
border-radius: 3px;
-webkit-box-shadow: none;
box-shadow: none;
color: #444444;
}
.btn-link:hover,
.btn-link:focus {
-webkit-box-shadow: none;
box-shadow: none;
color: #444444;
text-decoration: none;
}
.btn-default.disabled {
background-color: rgba(0, 0, 0, 0.1);
color: rgba(0, 0, 0, 0.4);
opacity: 1;
}
.btn-group .btn + .btn,
.btn-group .btn + .btn-group,
.btn-group .btn-group + .btn,
.btn-group .btn-group + .btn-group {
margin-left: 0;
}
.btn-group-vertical > .btn + .btn,
.btn-group-vertical > .btn + .btn-group,
.btn-group-vertical > .btn-group + .btn,
.btn-group-vertical > .btn-group + .btn-group {
margin-top: 0;
}
body {
-webkit-font-smoothing: antialiased;
letter-spacing: .1px;
}
p {
margin: 0 0 1em;
}
input,
button {
-webkit-font-smoothing: antialiased;
letter-spacing: .1px;
}
a {
-webkit-transition: all 0.2s;
-o-transition: all 0.2s;
transition: all 0.2s;
}
.table-hover > tbody > tr,
.table-hover > tbody > tr > th,
.table-hover > tbody > tr > td {
-webkit-transition: all 0.2s;
-o-transition: all 0.2s;
transition: all 0.2s;
}
label {
font-weight: normal;
}
textarea,
textarea.form-control,
input.form-control,
input[type=text],
input[type=password],
input[type=email],
input[type=number],
[type=text].form-control,
[type=password].form-control,
[type=email].form-control,
[type=tel].form-control,
[contenteditable].form-control {
padding: 0;
border: none;
border-radius: 0;
-webkit-appearance: none;
-webkit-box-shadow: inset 0 -1px 0 #dddddd;
box-shadow: inset 0 -1px 0 #dddddd;
font-size: 16px;
}
textarea:focus,
textarea.form-control:focus,
input.form-control:focus,
input[type=text]:focus,
input[type=password]:focus,
input[type=email]:focus,
input[type=number]:focus,
[type=text].form-control:focus,
[type=password].form-control:focus,
[type=email].form-control:focus,
[type=tel].form-control:focus,
[contenteditable].form-control:focus {
-webkit-box-shadow: inset 0 -2px 0 #2196f3;
box-shadow: inset 0 -2px 0 #2196f3;
}
textarea[disabled],
textarea.form-control[disabled],
input.form-control[disabled],
input[type=text][disabled],
input[type=password][disabled],
input[type=email][disabled],
input[type=number][disabled],
[type=text].form-control[disabled],
[type=password].form-control[disabled],
[type=email].form-control[disabled],
[type=tel].form-control[disabled],
[contenteditable].form-control[disabled],
textarea[readonly],
textarea.form-control[readonly],
input.form-control[readonly],
input[type=text][readonly],
input[type=password][readonly],
input[type=email][readonly],
input[type=number][readonly],
[type=text].form-control[readonly],
[type=password].form-control[readonly],
[type=email].form-control[readonly],
[type=tel].form-control[readonly],
[contenteditable].form-control[readonly] {
-webkit-box-shadow: none;
box-shadow: none;
border-bottom: 1px dotted #dddddd;
}
textarea.input-sm,
textarea.form-control.input-sm,
input.form-control.input-sm,
input[type=text].input-sm,
input[type=password].input-sm,
input[type=email].input-sm,
input[type=number].input-sm,
[type=text].form-control.input-sm,
[type=password].form-control.input-sm,
[type=email].form-control.input-sm,
[type=tel].form-control.input-sm,
[contenteditable].form-control.input-sm {
font-size: 12px;
}
textarea.input-lg,
textarea.form-control.input-lg,
input.form-control.input-lg,
input[type=text].input-lg,
input[type=password].input-lg,
input[type=email].input-lg,
input[type=number].input-lg,
[type=text].form-control.input-lg,
[type=password].form-control.input-lg,
[type=email].form-control.input-lg,
[type=tel].form-control.input-lg,
[contenteditable].form-control.input-lg {
font-size: 17px;
}
select,
select.form-control {
border: 0;
border-radius: 0;
-webkit-appearance: none;
-moz-appearance: none;
appearance: none;
padding-left: 0;
padding-right: 0\9;
background-image: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABoAAAAaCAMAAACelLz8AAAAJ1BMVEVmZmZmZmZmZmZmZmZmZmZmZmZmZmZmZmZmZmZmZmZmZmZmZmZmZmaP/QSjAAAADHRSTlMAAgMJC0uWpKa6wMxMdjkoAAAANUlEQVR4AeXJyQEAERAAsNl7Hf3X6xt0QL6JpZWq30pdvdadme+0PMdzvHm8YThHcT1H7K0BtOMDniZhWOgAAAAASUVORK5CYII=);
background-size: 13px;
background-repeat: no-repeat;
background-position: right center;
-webkit-box-shadow: inset 0 -1px 0 #dddddd;
box-shadow: inset 0 -1px 0 #dddddd;
font-size: 16px;
line-height: 1.5;
}
select::-ms-expand,
select.form-control::-ms-expand {
display: none;
}
select.input-sm,
select.form-control.input-sm {
font-size: 12px;
}
select.input-lg,
select.form-control.input-lg {
font-size: 17px;
}
select:focus,
select.form-control:focus {
-webkit-box-shadow: inset 0 -2px 0 #2196f3;
box-shadow: inset 0 -2px 0 #2196f3;
background-image: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABoAAAAaCAMAAACelLz8AAAAJ1BMVEUhISEhISEhISEhISEhISEhISEhISEhISEhISEhISEhISEhISEhISF8S9ewAAAADHRSTlMAAgMJC0uWpKa6wMxMdjkoAAAANUlEQVR4AeXJyQEAERAAsNl7Hf3X6xt0QL6JpZWq30pdvdadme+0PMdzvHm8YThHcT1H7K0BtOMDniZhWOgAAAAASUVORK5CYII=);
}
select[multiple],
select.form-control[multiple] {
background: none;
}
.radio label,
.radio-inline label,
.checkbox label,
.checkbox-inline label {
padding-left: 25px;
}
.radio input[type="radio"],
.radio-inline input[type="radio"],
.checkbox input[type="radio"],
.checkbox-inline input[type="radio"],
.radio input[type="checkbox"],
.radio-inline input[type="checkbox"],
.checkbox input[type="checkbox"],
.checkbox-inline input[type="checkbox"] {
margin-left: -25px;
}
input[type="radio"],
.radio input[type="radio"],
.radio-inline input[type="radio"] {
position: relative;
margin-top: 6px;
margin-right: 4px;
vertical-align: top;
border: none;
background-color: transparent;
-webkit-appearance: none;
appearance: none;
cursor: pointer;
}
input[type="radio"]:focus,
.radio input[type="radio"]:focus,
.radio-inline input[type="radio"]:focus {
outline: none;
}
input[type="radio"]:before,
.radio input[type="radio"]:before,
.radio-inline input[type="radio"]:before,
input[type="radio"]:after,
.radio input[type="radio"]:after,
.radio-inline input[type="radio"]:after {
content: "";
display: block;
width: 18px;
height: 18px;
border-radius: 50%;
-webkit-transition: 240ms;
-o-transition: 240ms;
transition: 240ms;
}
input[type="radio"]:before,
.radio input[type="radio"]:before,
.radio-inline input[type="radio"]:before {
position: absolute;
left: 0;
top: -3px;
background-color: #2196f3;
-webkit-transform: scale(0);
-ms-transform: scale(0);
-o-transform: scale(0);
transform: scale(0);
}
input[type="radio"]:after,
.radio input[type="radio"]:after,
.radio-inline input[type="radio"]:after {
position: relative;
top: -3px;
border: 2px solid #666666;
}
input[type="radio"]:checked:before,
.radio input[type="radio"]:checked:before,
.radio-inline input[type="radio"]:checked:before {
-webkit-transform: scale(0.5);
-ms-transform: scale(0.5);
-o-transform: scale(0.5);
transform: scale(0.5);
}
input[type="radio"]:disabled:checked:before,
.radio input[type="radio"]:disabled:checked:before,
.radio-inline input[type="radio"]:disabled:checked:before {
background-color: #bbbbbb;
}
input[type="radio"]:checked:after,
.radio input[type="radio"]:checked:after,
.radio-inline input[type="radio"]:checked:after {
border-color: #2196f3;
}
input[type="radio"]:disabled:after,
.radio input[type="radio"]:disabled:after,
.radio-inline input[type="radio"]:disabled:after,
input[type="radio"]:disabled:checked:after,
.radio input[type="radio"]:disabled:checked:after,
.radio-inline input[type="radio"]:disabled:checked:after {
border-color: #bbbbbb;
}
input[type="checkbox"],
.checkbox input[type="checkbox"],
.checkbox-inline input[type="checkbox"] {
position: relative;
border: none;
margin-bottom: -4px;
-webkit-appearance: none;
appearance: none;
cursor: pointer;
}
input[type="checkbox"]:focus,
.checkbox input[type="checkbox"]:focus,
.checkbox-inline input[type="checkbox"]:focus {
outline: none;
}
input[type="checkbox"]:focus:after,
.checkbox input[type="checkbox"]:focus:after,
.checkbox-inline input[type="checkbox"]:focus:after {
border-color: #2196f3;
}
input[type="checkbox"]:after,
.checkbox input[type="checkbox"]:after,
.checkbox-inline input[type="checkbox"]:after {
content: "";
display: block;
width: 18px;
height: 18px;
margin-top: -2px;
margin-right: 5px;
border: 2px solid #666666;
border-radius: 2px;
-webkit-transition: 240ms;
-o-transition: 240ms;
transition: 240ms;
}
input[type="checkbox"]:checked:before,
.checkbox input[type="checkbox"]:checked:before,
.checkbox-inline input[type="checkbox"]:checked:before {
content: "";
position: absolute;
top: 0;
left: 6px;
display: table;
width: 6px;
height: 12px;
border: 2px solid #ffffff;
border-top-width: 0;
border-left-width: 0;
-webkit-transform: rotate(45deg);
-ms-transform: rotate(45deg);
-o-transform: rotate(45deg);
transform: rotate(45deg);
}
input[type="checkbox"]:checked:after,
.checkbox input[type="checkbox"]:checked:after,
.checkbox-inline input[type="checkbox"]:checked:after {
background-color: #2196f3;
border-color: #2196f3;
}
input[type="checkbox"]:disabled:after,
.checkbox input[type="checkbox"]:disabled:after,
.checkbox-inline input[type="checkbox"]:disabled:after {
border-color: #bbbbbb;
}
input[type="checkbox"]:disabled:checked:after,
.checkbox input[type="checkbox"]:disabled:checked:after,
.checkbox-inline input[type="checkbox"]:disabled:checked:after {
background-color: #bbbbbb;
border-color: transparent;
}
.has-warning input:not([type=checkbox]),
.has-warning .form-control,
.has-warning input.form-control[readonly],
.has-warning input[type=text][readonly],
.has-warning [type=text].form-control[readonly],
.has-warning input:not([type=checkbox]):focus,
.has-warning .form-control:focus {
border-bottom: none;
-webkit-box-shadow: inset 0 -2px 0 #ff9800;
box-shadow: inset 0 -2px 0 #ff9800;
}
.has-error input:not([type=checkbox]),
.has-error .form-control,
.has-error input.form-control[readonly],
.has-error input[type=text][readonly],
.has-error [type=text].form-control[readonly],
.has-error input:not([type=checkbox]):focus,
.has-error .form-control:focus {
border-bottom: none;
-webkit-box-shadow: inset 0 -2px 0 #e51c23;
box-shadow: inset 0 -2px 0 #e51c23;
}
.has-success input:not([type=checkbox]),
.has-success .form-control,
.has-success input.form-control[readonly],
.has-success input[type=text][readonly],
.has-success [type=text].form-control[readonly],
.has-success input:not([type=checkbox]):focus,
.has-success .form-control:focus {
border-bottom: none;
-webkit-box-shadow: inset 0 -2px 0 #4caf50;
box-shadow: inset 0 -2px 0 #4caf50;
}
.has-warning .input-group-addon,
.has-error .input-group-addon,
.has-success .input-group-addon {
color: #666666;
border-color: transparent;
background-color: transparent;
}
.nav-tabs > li > a,
.nav-tabs > li > a:focus {
margin-right: 0;
background-color: transparent;
border: none;
color: #666666;
-webkit-box-shadow: inset 0 -1px 0 #dddddd;
box-shadow: inset 0 -1px 0 #dddddd;
-webkit-transition: all 0.2s;
-o-transition: all 0.2s;
transition: all 0.2s;
}
.nav-tabs > li > a:hover,
.nav-tabs > li > a:focus:hover {
background-color: transparent;
-webkit-box-shadow: inset 0 -2px 0 #2196f3;
box-shadow: inset 0 -2px 0 #2196f3;
color: #2196f3;
}
.nav-tabs > li.active > a,
.nav-tabs > li.active > a:focus {
border: none;
-webkit-box-shadow: inset 0 -2px 0 #2196f3;
box-shadow: inset 0 -2px 0 #2196f3;
color: #2196f3;
}
.nav-tabs > li.active > a:hover,
.nav-tabs > li.active > a:focus:hover {
border: none;
color: #2196f3;
}
.nav-tabs > li.disabled > a {
-webkit-box-shadow: inset 0 -1px 0 #dddddd;
box-shadow: inset 0 -1px 0 #dddddd;
}
.nav-tabs.nav-justified > li > a,
.nav-tabs.nav-justified > li > a:hover,
.nav-tabs.nav-justified > li > a:focus,
.nav-tabs.nav-justified > .active > a,
.nav-tabs.nav-justified > .active > a:hover,
.nav-tabs.nav-justified > .active > a:focus {
border: none;
}
.nav-tabs .dropdown-menu {
margin-top: 0;
}
.dropdown-menu {
margin-top: 0;
border: none;
-webkit-box-shadow: 0 1px 4px rgba(0, 0, 0, 0.3);
box-shadow: 0 1px 4px rgba(0, 0, 0, 0.3);
}
.alert {
border: none;
color: #ffffff;
}
.alert-success {
background-color: #4caf50;
}
.alert-info {
background-color: #9c27b0;
}
.alert-warning {
background-color: #ff9800;
}
.alert-danger {
background-color: #e51c23;
}
.alert a:not(.close),
.alert .alert-link {
color: #ffffff;
font-weight: bold;
}
.alert .close {
color: #ffffff;
}
.badge {
padding: 4px 6px 4px;
}
.progress {
position: relative;
z-index: 1;
height: 6px;
border-radius: 0;
-webkit-box-shadow: none;
box-shadow: none;
}
.progress-bar {
-webkit-box-shadow: none;
box-shadow: none;
}
.progress-bar:last-child {
border-radius: 0 3px 3px 0;
}
.progress-bar:last-child:before {
display: block;
content: "";
position: absolute;
width: 100%;
height: 100%;
left: 0;
right: 0;
z-index: -1;
background-color: #cae6fc;
}
.progress-bar-success:last-child.progress-bar:before {
background-color: #c7e7c8;
}
.progress-bar-info:last-child.progress-bar:before {
background-color: #edc9f3;
}
.progress-bar-warning:last-child.progress-bar:before {
background-color: #ffe0b3;
}
.progress-bar-danger:last-child.progress-bar:before {
background-color: #f28e92;
}
.close {
font-size: 34px;
font-weight: 300;
line-height: 24px;
opacity: 0.6;
-webkit-transition: all 0.2s;
-o-transition: all 0.2s;
transition: all 0.2s;
}
.close:hover {
opacity: 1;
}
.list-group-item {
padding: 15px;
}
.list-group-item-text {
color: #bbbbbb;
}
.well {
border-radius: 0;
-webkit-box-shadow: none;
box-shadow: none;
}
.panel {
border: none;
border-radius: 2px;
-webkit-box-shadow: 0 1px 4px rgba(0, 0, 0, 0.3);
box-shadow: 0 1px 4px rgba(0, 0, 0, 0.3);
}
.panel-heading {
border-bottom: none;
}
.panel-footer {
border-top: none;
}
.popover {
border: none;
-webkit-box-shadow: 0 1px 4px rgba(0, 0, 0, 0.3);
box-shadow: 0 1px 4px rgba(0, 0, 0, 0.3);
}
.carousel-caption h1,
.carousel-caption h2,
.carousel-caption h3,
.carousel-caption h4,
.carousel-caption h5,
.carousel-caption h6 {
color: inherit;
}
.margin-bottom-xs {
margin-bottom: 6px;
}
.margin-bottom-sm {
margin-bottom: 12px;
}
.margin-bottom-md {
margin-bottom: 23px;
}
.margin-bottom-lg {
margin-bottom: 46px;
}
.navbar-collapse.collapse.in {
background: #ffffff;
}
.warning a,
.warning a:link,
.warning a:visited {
color: #ff9800;
}
.calhighlight {
color: #9c27b0;
background: #e1bee7;
}
a.fc-event:hover {
color: #ffffff;
}
.filter .fancyfilter {
border: thin solid transparent /*black*/;
}
.filter .fancyfilter .token {
background: #ffffff;
border: 1px solid #bbbbbb;
font-size: 11px;
padding: 3px;
}
.note-list .postbody-title {
background: #ffffff;
color: #212121;
}
.post-approved-n {
border-left: 3px dotted #4caf50;
}
.post-approved-r {
border-left: 3px double #ff9800;
}
.post-approved-r .content * {
background: url('../../../img/icons/dots.gif');
}
.dropdown-menu {
color: #bbbbbb;
}
.cssmenu_horiz > li:hover,
.cssmenu_horiz > li.sfHover,
.cssmenu_vert > li:hover,
.cssmenu_vert > li.sfHover {
-webkit-transition: none;
-moz-transition: none;
-o-transition: none;
transition: none;
}
.topbar .nav > li > a:hover,
.topbar .nav > li > a:focus {
background: transparent;
}
.cssmenu_horiz ul,
.cssmenu_vert ul {
border: rgba(0, 0, 0, 0.15);
}
.cssmenu_horiz ul li a,
.cssmenu_vert ul li a {
background: #ffffff;
color: #666666;
}
.cssmenu_horiz > ul > li:hover > a,
.cssmenu_vert > ul > li:hover > a {
color: #141414;
background: #eeeeee;
}
.sf-arrows .sf-with-ul:after {
border: 5px solid transparent;
border-top-color: #2196f3;
}
.cssmenu_vert.sf-arrows li > .sf-with-ul:after {
border-color: transparent;
border-left-color: #2196f3;
/* edit this to suit design (no rgba in IE8) */
}
.sf-arrows ul .sf-with-ul:after,
.cssmenu_vert.sf-arrows ul > li > .sf-with-ul:after {
border-color: transparent;
border-left-color: #666666;
/* edit this to suit design (no rgba in IE8) */
}
.sf-arrows ul li > .sf-with-ul:focus:after,
.sf-arrows ul li:hover > .sf-with-ul:after,
.sf-arrows ul .sfHover > .sf-with-ul:after {
border-color: transparent;
border-left-color: #141414;
}
.cssmenu_vert.sf-arrows li > .sf-with-ul:focus:after,
.cssmenu_vert.sf-arrows li:hover > .sf-with-ul:after,
.cssmenu_vert.sf-arrows .sfHover > .sf-with-ul:after {
border-color: transparent;
border-left-color: #141414;
}
.topbar,
.topbar .navbar-default .navbar-nav > li,
.topbar .nav > li {
background: #ffffff;
color: #bbbbbb;
}
.topbar > a,
.topbar .navbar-default .navbar-nav > li > a,
.topbar .nav > li > a {
color: #666666;
padding-top: 20.5px;
padding-bottom: 20.5px;
}
.topbar > a:hover,
.topbar .navbar-default .navbar-nav > li > a:hover,
.topbar .nav > li > a:hover,
.topbar > a:focus,
.topbar .navbar-default .navbar-nav > li > a:focus,
.topbar .nav > li > a:focus {
color: #212121;
}
.topbar .cssmenu_horiz ul {
background: #ffffff;
}
.topbar .cssmenu_horiz.sf-arrows > .menuSection0 > .sf-with-ul:after {
border: 5px solid transparent;
border-top-color: #666666;
}
.topbar .cssmenu_horiz.sf-arrows > .menuSection0:hover > .sf-with-ul:after,
.topbar .cssmenu_horiz.sf-arrows > .menuSection0.sfhover > .sf-with-ul:after {
border-top-color: #212121;
}
/* order of following 3 rules important for fallbacks to work */
.dropdown-menu .dropdown-title,
.dropdown-menu li label {
color: #666666;
}
.thumbinfosothers {
color: #eeeeee;
}
table.treetable.objectperms td.added {
background-color: #dff0d8;
}
table.treetable.objectperms td.removed {
background-color: #ffe0b2;
}
.progressBarInProgress {
background-color: #9c27b0;
color: #e1bee7;
}
.progressBarComplete {
background-color: #4caf50;
color: #dff0d8;
}
.progressBarError {
background-color: #ff9800;
color: #ffe0b2;
}
.progressContainer {
border: solid 1px transparent;
background-color: #ffffff;
}
.filter-panel-heading a:after {
color: #666666;
}
.olControlMousePosition {
background: rgba(0, 0, 0, 0.75);
color: #ffffff;
}
.olControlScaleLineTop,
.olControlScaleLineBottom {
background-color: rgba(255, 255, 255, 0.5);
}
.ui-selectmenu-icon {
background-color: inherit;
border: solid 5px transparent !important;
-webkit-box-shadow: -5px 0 5px 2px rgba(0, 0, 0, 0.1), -1px 0 0 rgba(0, 0, 0, 0.1), -2px 0 0 rgba(255, 255, 255, 0.25);
box-shadow: -5px 0 5px 2px rgba(0, 0, 0, 0.1), -1px 0 0 rgba(0, 0, 0, 0.1), -2px 0 0 rgba(255, 255, 255, 0.25);
}
.dirsitetrail {
color: #f5f5f5;
}
.dirsitecats {
color: #f5f5f5;
}
#resultzone > div:hover {
background: #4caf50;
}
.searchresults blockquote em,
.highlight,
.btn-default.highlight a,
.btn-default a.highlight {
background: #f9bdbb;
color: #e51c23;
border-color: #f7a4af;
}
.btn-default.highlight:hover {
background: #f37975;
}
.btn-default.btn-link,
.btn-default.btn-link:hover {
background: transparent;
border: none;
}
#ajaxLoadingBG {
background: transparent url('../../../img/overlay-light.png');
}
#ajaxLoading {
color: #eeeeee;
background: transparent url('../../../img/loading-light.gif') no-repeat 50% 50%;
}
#cookie_consent_div {
padding: 15px;
border: 1px solid #cba4dd;
color: #9c27b0;
background-color: #e1bee7;
}
#cookie_consent_div.banner {
padding: 15px;
border: 1px solid #cba4dd;
}
html#print,
body.print * {
background: #ffffff;
color: #000000;
}
body.fullscreen {
background: #ffffff;
}
.attention {
color: #e51c23;
}
#debugconsole {
background: #2196f3;
color: #b2dbfb;
border: 2px solid transparent;
}
#debugconsole form {
color: #bbbbbb;
}
#debugconsole a {
color: #ffffff;
}
#debugconsole a.btn {
color: #666666;
}
a.icon,
img.icon {
background: transparent;
}
div #metadata fieldset.tabcontent,
div #metadata div.tabs {
background-color: transparent;
}
.openid_url {
background: #ffffff url('../../../img/icons/login-OpenID-bg.gif') 1px 1px no-repeat;
}
input:-webkit-autofill {
background-color: transparent !important;
/* needs important because Chrome has it already important */
background-image: none !important;
color: #666666 !important;
/* the Google guys forgot the number-one rule... when they specify background they should specify forgeround color too ;) */
}
#cboxTitle {
background-color: #ffffff;
}
#captchaImg {
border: 1px solid #dddddd;
}
form.simple label.error {
background: url('../../../img/icons/error.png') no-repeat 0 4px;
color: #e51c23;
}
form.simple label .warning {
color: #e51c23;
}
.tiki-modal .mask {
background-color: #ffffff;
}
.ui-dialog {
background: #ffffff;
color: #666666;
}
.cssmenu_horiz ul li.selected a,
.cssmenu_vert ul li.selected a,
.cssmenu_horiz ul li a:hover,
.cssmenu_vert ul li a:hover {
text-decoration: none;
color: #141414;
background-color: #eeeeee;
}
.box-quickadmin .cssmenu_horiz ul li {
background-color: #ffffff;
}
.box-switch_lang .box-data img.highlight {
border: 0.1em solid #f7a4af;
}
.box-switch_lang .box-data .highlight {
border: 0.1em solid #f7a4af;
}
div.cvsup {
color: #bbbbbb;
}
.layout_social .topbar_modules h1.sitetitle,
.layout_social_modules .topbar_modules h1.sitetitle,
.layout_fixed_top_modules #top_modules h1.sitetitle {
color: #666666;
}
.layout_social .topbar_modules .navbar-inverse .navbar-collapse,
.layout_social_modules .topbar_modules .navbar-inverse .navbar-collapse,
.layout_fixed_top_modules #top_modules .navbar-inverse .navbar-collapse,
.layout_social .topbar_modules .navbar-inverse .navbar-form,
.layout_social_modules .topbar_modules .navbar-inverse .navbar-form,
.layout_fixed_top_modules #top_modules .navbar-inverse .navbar-form,
.layout_social .topbar_modules .navbar-inverse,
.layout_social_modules .topbar_modules .navbar-inverse,
.layout_fixed_top_modules #top_modules .navbar-inverse {
border-color: transparent;
}
.prio1 {
background: inherit;
}
.prio2 {
background: #dff0d8;
color: #4caf50;
border: #d6e9c6;
}
.prio2 a {
color: #4caf50;
}
.prio3 {
background: #e1bee7;
color: #9c27b0;
border: #cba4dd;
}
.prio3 a {
color: #9c27b0;
}
.prio4 {
background: #ffe0b2;
color: #ff9800;
border: #ffc599;
}
.prio4 a {
color: #ff9800;
}
.prio5 {
background: #f9bdbb;
color: #e51c23;
border: #f7a4af;
}
.prio5 a {
color: #e51c23;
}
.messureadflag {
background: #666666;
}
.messureadhead {
background: #bbbbbb;
}
.messureadbody {
background: #eeeeee;
}
.readlink {
color: #666666;
}
.webmail_item {
border: 1px solid #dddddd;
}
.webmail_list .odd {
background: #f9f9f9;
}
.webmail_list .button {
background: #ffffff;
border: 1px solid #2196f3;
}
.webmail_list .webmail_read {
background: #e1bee7;
}
.webmail_list .webmail_replied {
background: #dff0d8;
}
.webmail_list .webmail_taken {
border: #ffc599;
color: #ff9800;
}
.webmail_message {
background: #ffffff;
}
.webmail_message_headers {
background: #ffffff;
}
.webmail_message_headers th {
background: transparent;
}
.tiki_sheet table td {
border: 1px solid #dddddd;
}
.odd {
background: transparent;
color: #666666;
}
.even {
background: #f9f9f9;
color: #666666;
}
.objectperms .checkBoxHeader:nth-of-type(odd) > div > label,
.objectperms td.checkBoxCell:nth-of-type(odd),
.objectperms .checkBoxHeader:nth-of-type(odd) > .checkBoxLabel {
background: #ececec;
}
.helptool-admin {
border-left: medium double #bbbbbb;
}
.toolbar-list {
border-left: medium double #bbbbbb;
}
.toolbars-picker {
background: #ffffff;
border: thin solid #666666;
color: #666666;
}
.toolbars-picker a {
border: 1px solid #ffffff;
color: #666666;
}
.toolbars-picker a:hover {
border: 1px solid #e51c23;
background: #bbbbbb;
color: #666666;
}
.textarea-toolbar > div {
background-color: #eeeeee;
border: outset 1px #eeeeee;
}
#intertrans-indicator {
background-color: #dff0d8;
color: #4caf50;
}
#intertrans-form {
background-color: #ffffff;
border: 1px solid #dddddd;
color: #212121;
}
#edit_translations tr.last {
border-bottom: 2px solid #d6e9c6;
}
ul.all_languages > li {
border: 1px solid #d6e9c6;
}
.plugin-mouseover {
background: #ffffff;
border: 1px solid transparent;
}
.mandatory_note {
color: #e51c23;
}
.author0 {
color: #ffffff;
}
.author1 {
color: #ffffff;
}
.author2 {
color: #ffffff;
}
.author3 {
color: #ffffff;
}
.author4 {
color: #ffffff;
}
.author5 {
color: #ffffff;
}
.author6 {
color: #ffffff;
}
.author7 {
color: #ffffff;
}
.author8 {
color: #ffffff;
}
.author9 {
color: #ffffff;
}
.author10 {
color: #ffffff;
}
.author11 {
color: #ffffff;
}
.author12 {
color: #ffffff;
}
.author13 {
color: #ffffff;
}
.author14 {
color: #ffffff;
}
.author15 {
color: #ffffff;
}
.structuremenu .menuSection {
border-left: 1px dotted #666666;
}
.cke_editable:hover {
outline: #666666 dotted 1px;
}
.tiki .cke_wysiwyg_frame,
.tiki .cke_wysiwyg_div {
background: #ffffff;
color: #666666;
}
.tiki_plugin {
background-color: transparent;
border: 1px solid #bbbbbb;
}
.unsavedChangesInEditor {
border: 1px solid;
border-color: #ffc599;
}
.autotoc > .nav {
background: #ffffff;
border: 1px solid #dddddd;
border-radius: 3px;
}
.autotoc * {
color: #2196f3;
}
.autotoc .nav > li > a:hover,
.autotoc .nav .nav > li > a:hover {
color: #0a6ebd;
}
.plugin-form-float {
background: #ffffff;
color: #666666;
border: solid 2px #666666;
}
body.wikitext {
background: #ffffff;
color: #666666;
}
.editable-inline {
background: transparent url('../../../img/icons/database_lightning.png') no-repeat top right;
padding-right: 20px;
display: inline-block;
}
.editable-inline.loaded {
background: #ffffff;
padding: 6px;
border: 1px solid #eee;
border-radius: 4px;
z-index: 2;
}
.editable-inline.failure {
background: transparent url('../../../img/icons/lock_gray.png') no-repeat top right;
}
.editable-inline.modified {
border: solid 2px transparent;
padding: 2px;
}
.editable-inline.unsaved {
border: solid 2px transparent;
}
.structure_select .cssmenu_horiz ul li {
border: 1px solid #666666;
}
.admintoclevel .actions input {
border: solid 1px #666666;
}
.TextArea-fullscreen {
background-color: #666666;
}
.TextArea-fullscreen .actions,
.CodeMirror-fullscreen .actions {
background-color: #ffffff;
border-top: #eeeeee 1px solid;
}
#autosave_preview {
background-color: #ffffff;
color: #666666;
}
#autosave_preview_grippy {
background-color: #eeeeee;
background-image: url('../../../img/icons/shading.png');
}
h1:hover a.tiki_anchor,
h2:hover a.tiki_anchor,
h3:hover a.tiki_anchor,
h4:hover a.tiki_anchor,
h5:hover a.tiki_anchor,
h6:hover a.tiki_anchor {
color: #eeeeee;
}
h1 a.tiki_anchor:hover,
h2 a.tiki_anchor:hover,
h3 a.tiki_anchor:hover,
h4 a.tiki_anchor:hover,
h5 a.tiki_anchor:hover,
h6 a.tiki_anchor:hover {
color: #666666;
}
.wiki .namespace {
background: #eeeeee;
}
.site_report a {
border-left: 1px solid #666666;
border-right: 1px solid #666666;
}
.quotebody {
border-left: 2px solid #bbbbbb;
}
.mandatory_star {
color: #e51c23;
font-size: 120%;
}
.trackerplugindesc {
color: #212121;
}
.charCount {
color: #212121;
}
.imgbox {
border: 1px solid transparent;
background-color: #ffffff;
}
.ic_button {
border: 2px solid #dddddd;
}
.ic_active {
border: 2px solid #2196f3;
}
.ic_caption {
background: #2196f3;
color: #bbbbbb;
}
.wp-cookie-consent-required {
color: #e51c23;
}
.wp-sign {
color: #ffffff;
background-color: #727272;
}
.wp-sign a,
.wp-sign a:visited {
color: #ffffff;
}
.wp-sign a:hover,
.wp-sign a:visited:hover {
color: #ffffff;
text-decoration: none;
}
.toc {
border-top: 1px dotted #bbbbbb;
border-bottom: 1px dotted #bbbbbb;
}
.diff td {
border: 1px solid #212121;
}
.diff div {
border-top: 1px solid #bbbbbb;
}
.diffadded {
background: #dff0d8;
color: #4caf50;
}
.diffdeleted {
background: #f9bdbb;
color: #e51c23;
}
.diffinldel {
background: #ffe0b2;
}
.diffbody {
background: #eeeeee;
color: #222222;
}
.diffchar {
color: #ea4a4f;
}
.diffadded .diffchar {
color: #6ec071;
}
.searchresults blockquote em.hlt1,
.searchresults blockquote em.hlt6,
.highlight_word_0 {
color: #ffffff;
background: #4caf50;
}
.searchresults blockquote em.hlt2,
.searchresults blockquote em.hlt7,
.highlight_word_1 {
color: #ffffff;
background: #9c27b0;
}
.searchresults blockquote em.hlt3,
.searchresults blockquote em.hlt8,
.highlight_word_2 {
color: #ffffff;
background: #ff9800;
}
.searchresults blockquote em.hlt4,
.searchresults blockquote em.hlt9,
.highlight_word_3 {
color: #ffffff;
background: #e51c23;
}
.searchresults blockquote em.hlt5,
.searchresults blockquote em.hlt10,
.highlight_word_4 {
color: #ffffff;
background: #e5581c;
}
/* Structures drill-down menu */
div.drillshow {
border: 1px solid #bbbbbb;
}
.tiki .chosen-container-single .chosen-single {
height: 37px;
padding: 6px 6px;
font-size: 13px;
line-height: 1.846;
}
.chosen-container-multi .chosen-choices {
background-color: rgba(26, 26, 26, 0);
color: #666666;
border: 1px solid transparent;
}
.chosen-container-single .chosen-single,
.chosen-container-active.chosen-with-drop .chosen-single,
.chosen-container .chosen-drop,
.chosen-container-multi .chosen-choices .search-choice {
background-color: transparent;
color: #666666;
border: 1px solid transparent;
}
.chosen-container-single .chosen-search input[type="text"] {
background-color: transparent;
border: 1px solid transparent;
}
.chosen-container .chosen-results li.highlighted {
background-color: #eeeeee;
color: #141414;
}
.tiki .chosen-container .active-result {
color: #666666;
}
.breadcrumb {
font-style: normal;
font-size: 90%;
display: block;
}
a.admbox.off {
border: 1px solid rgba(0, 0, 0, 0);
color: #999999;
}
a.admbox.off:hover,
a.admbox.off:focus,
a.admbox.off:active {
border: 1px solid rgba(0, 0, 0, 0);
color: #999999;
}
.tiki .ui-widget-content,
span.plugin-mouseover {
background: #ffffff;
color: #666666;
border: 1px solid transparent;
}
.tiki .ui-widget-header {
background: #ffffff;
color: #666666;
border: 1px solid transparent;
}
.tiki .ui-dialog-content {
background: #ffffff;
color: #666666;
}
.tiki .ui-dialog-content select,
.tiki .ui-dialog-content input,
.tiki .ui-dialog-content optgroup,
.tiki .ui-dialog-content textarea {
background: transparent;
color: #666666;
}
.tiki .ui-widget button {
background: #ffffff;
color: #444444;
}
.tiki .modal-content .ui-state-default {
color: #2196f3;
}
.tiki .modal-content .ui-state-hover:hover {
color: #0a6ebd;
}
.dropdown-menu {
color: #666666;
}
.tiki .col1 .table-responsive {
border: 1px solid #dddddd;
}
.codecaption {
display: inline-block;
color: #444444;
background: #f8f8f8;
border: 1px solid #dddddd;
border-bottom: none;
padding: 2px 9.5px;
font-size: 0.8em;
font-weight: bold;
}
code,
pre.codelisting {
color: #444444;
background: #f8f8f8;
border: 1px solid #dddddd;
border-radius: 1px;
}
.edit-menu {
position: absolute;
top: 6px;
right: 2px;
}
@media (min-width: 992px) {
.edit-menu {
display: none;
}
.navbar-default:hover .edit-menu {
display: block;
}
}
@media (max-width: 767px) {
.navbar-default .edit-menu {
top: 48px;
}
}
.adminoptionboxchild {
border-bottom: 1px solid #eeeeee;
}
.adminoptionboxchild legend {
font-size: 18px;
}
input[type="checkbox"].preffilter-toggle-round + label {
background-color: #bbbbbb;
}
input[type="checkbox"].preffilter-toggle-round + label:before {
color: #444444;
background-color: #ffffff;
border-color: transparent;
}
input[type="checkbox"].preffilter-toggle-round:checked + label:before {
color: #ffffff;
background-color: #2196f3;
border-color: transparent;
}
.tiki .chosen-container-single .chosen-single,
.tiki .chosen-container-active.chosen-with-drop .chosen-single,
.tiki .chosen-container .chosen-drop,
.tiki .chosen-container-multi .chosen-choices .search-choice {
background-color: #ffffff;
border: 1px solid transparent;
color: #666666;
}
.topbar {
box-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
}
.topbar .navbar {
box-shadow: none;
}
.cssmenu_horiz ul li a:hover,
.cssmenu_vert ul li a:hover {
color: #141414;
background-color: #eeeeee;
}
.cssmenu_horiz ul li.selected a,
.cssmenu_vert ul li.selected a {
text-decoration: none;
color: #ffffff;
background-color: #2196f3;
}
/* black */
/* white */
/* automatically choose the correct arrow/text color */
.tsFilterInput {
border: none;
background-color: #f7f7f7;
}
table.tablesorter {
/* style header */
}
table.tablesorter thead tr.tablesorter-headerRow th.tablesorter-headerUnSorted:not(.sorter-false) {
background-image: url(data:image/gif;base64,R0lGODlhFQAJAIAAACMtMP///yH5BAEAAAEALAAAAAAVAAkAAAIXjI+AywnaYnhUMoqt3gZXPmVg94yJVQAAOw==);
}
table.tablesorter thead tr.tablesorter-headerRow th.tablesorter-headerAsc {
background-image: url(data:image/gif;base64,R0lGODlhFQAEAIAAACMtMP///yH5BAEAAAEALAAAAAAVAAQAAAINjI8Bya2wnINUMopZAQA7);
}
table.tablesorter thead tr.tablesorter-headerRow th.tablesorter-headerDesc {
background-image: url(data:image/gif;base64,R0lGODlhFQAEAIAAACMtMP///yH5BAEAAAEALAAAAAAVAAQAAAINjB+gC+jP2ptn0WskLQA7);
}
table.tablesorter thead tr.tablesorter-filter-row input.tablesorter-filter {
border: none;
background-color: #f7f7f7;
}
table.tablesorter thead tr.tablesorter-filter-row input.dateFrom,
table.tablesorter thead tr.tablesorter-filter-row input.dateTo {
border: none;
background-color: #f7f7f7;
}
table.tablesorter thead tr.tablesorter-headerRow,
table.tablesorter thead tr.tablesorter-filter-row {
background-color: #ffffff;
}
.tiki .pvtUi {
color: #666666;
}
.tiki table.pvtTable {
font-size: 13px;
}
.tiki table.pvtTable tr th {
background-color: #9c27b0;
color: #ffffff;
border: 1px solid #dddddd;
font-size: 13px;
padding: 5px;
}
.tiki table.pvtTable tr td {
color: #666666;
background-color: transparent;
border-color: #dddddd;
}
.tiki .pvtTotal,
.tiki .pvtGrandTotal {
font-weight: bold;
}
.tiki .pvtVals {
text-align: center;
}
.tiki .pvtAggregator,
.tiki .pvtRenderer,
.tiki .pvtSearch,
.tiki .pvtAttrDropdown {
margin-bottom: 5px;
background: transparent;
color: #666666;
border: 1px solid transparent;
border-radius: 3px;
}
.tiki .pvtAxisContainer,
.tiki .pvtVals {
border-color: #dddddd;
background: #ffffff;
padding: 5px;
}
.tiki .pvtAxisContainer li.pvtPlaceholder {
padding: 3px 15px;
border-radius: 5px;
border: 1px dashed #dddddd;
}
.tiki .pvtAxisContainer li span.pvtAttr {
-webkit-text-size-adjust: 100%;
padding: 2px 5px;
white-space: nowrap;
background: #ffffff;
border: 1px solid transparent;
border-radius: 3px;
color: #444444;
}
.tiki .pvtTriangle {
cursor: pointer;
color: grey;
}
.tiki .pvtHorizList li {
display: inline;
}
.tiki .pvtVertList {
vertical-align: top;
}
.tiki .pvtFilteredAttribute {
font-style: italic;
}
.tiki .pvtFilterBox {
z-index: 100;
width: 280px;
border: 1px solid #dddddd;
background-color: #ffffff;
position: absolute;
padding: 20px;
text-align: center;
}
.tiki .pvtFilterBox h4 {
margin: 0;
}
.tiki .pvtFilterBox p {
margin: 1em auto;
}
.tiki .pvtFilterBox label {
font-weight: normal;
}
.tiki .pvtFilterBox input[type='checkbox'] {
margin-right: 5px;
}
.tiki .pvtCheckContainer {
text-align: left;
overflow: auto;
width: 100%;
max-height: 200px;
}
.tiki .pvtCheckContainer p {
margin: 5px;
}
.tiki .pvtRendererArea {
padding: 5px;
}
.tiki .pvtFilterBox button {
background: #ffffff;
border: 1px solid transparent;
border-radius: 3px;
color: #444444;
}
.tiki .pvtFilterBox button:hover {
background: #ffffff;
}
.tiki .pvtFilterBox button + button {
margin-left: 4px;
margin-bottom: 4px;
}
.tiki .c3 line,
.tiki .c3 path,
.tiki .c3 svg {
fill: none;
stroke: #666666;
}
.tiki select {
font-size: 13px;
}
.tiki .ui-state-default,
.tiki .ui-widget-content .ui-state-default,
.tiki .ui-widget-header .ui-state-default,
.tiki .ui-button,
.tiki html .ui-button.ui-state-disabled:hover,
.tiki html .ui-button.ui-state-disabled:active {
border: 1px solid transparent;
background: #ffffff;
font-weight: normal;
color: #444444;
font-size: 13px;
}
.tiki .ui-state-hover,
.tiki .ui-widget-content .ui-state-hover,
.tiki .ui-widget-header .ui-state-hover,
.tiki .ui-state-focus,
.tiki .ui-widget-content .ui-state-focus,
.tiki .ui-widget-header .ui-state-focus,
.tiki .ui-button:hover,
.tiki .ui-button:focus {
border: 1px solid transparent;
background: #ffffff;
font-weight: normal;
color: #444444;
}
.tiki .ui-widget-header a {
color: #2196f3;
}
.tiki #converse-embedded-chat,
.tiki #conversejs {
font-family: "Roboto", "Helvetica Neue", Helvetica, Arial, sans-serif;
color: #666666;
}
.tiki #converse-embedded-chat a,
.tiki #conversejs a,
.tiki #converse-embedded-chat a:visited,
.tiki #conversejs a:visited {
color: #2196f3;
}
.tiki #converse-embedded-chat input[type=text],
.tiki #conversejs input[type=text],
.tiki #converse-embedded-chat textarea,
.tiki #conversejs textarea,
.tiki #converse-embedded-chat select,
.tiki #conversejs select {
background-color: transparent;
color: #666666;
border-color: transparent;
}
.tiki #converse-embedded-chat form.pure-form input[type=text],
.tiki #conversejs form.pure-form input[type=text],
.tiki #converse-embedded-chat form.pure-form textarea,
.tiki #conversejs form.pure-form textarea,
.tiki #converse-embedded-chat form.pure-form select,
.tiki #conversejs form.pure-form select {
background-color: transparent;
color: #666666;
border-color: transparent;
}
.tiki #converse-embedded-chat form.pure-form.converse-form,
.tiki #conversejs form.pure-form.converse-form {
background-color: inherit;
}
.tiki #converse-embedded-chat form.pure-form.converse-form .form-help,
.tiki #conversejs form.pure-form.converse-form .form-help,
.tiki #converse-embedded-chat form.pure-form.converse-form .form-help:hover,
.tiki #conversejs form.pure-form.converse-form .form-help:hover {
color: #666666;
}
.tiki #converse-embedded-chat .button-primary,
.tiki #conversejs .button-primary {
color: #ffffff;
background-color: #2196f3;
border-color: transparent;
}
.tiki #converse-embedded-chat .button-primary:focus,
.tiki #conversejs .button-primary:focus,
.tiki #converse-embedded-chat .button-primary.focus,
.tiki #conversejs .button-primary.focus {
color: #ffffff;
background-color: #0c7cd5;
border-color: rgba(0, 0, 0, 0);
}
.tiki #converse-embedded-chat .button-primary:hover,
.tiki #conversejs .button-primary:hover {
color: #ffffff;
background-color: #0c7cd5;
border-color: rgba(0, 0, 0, 0);
}
.tiki #converse-embedded-chat .button-primary:active,
.tiki #conversejs .button-primary:active,
.tiki #converse-embedded-chat .button-primary.active,
.tiki #conversejs .button-primary.active,
.open > .dropdown-toggle.tiki #converse-embedded-chat .button-primary,
.open > .dropdown-toggle.tiki #conversejs .button-primary {
color: #ffffff;
background-color: #0c7cd5;
border-color: rgba(0, 0, 0, 0);
}
.tiki #converse-embedded-chat .button-primary:active:hover,
.tiki #conversejs .button-primary:active:hover,
.tiki #converse-embedded-chat .button-primary.active:hover,
.tiki #conversejs .button-primary.active:hover,
.open > .dropdown-toggle.tiki #converse-embedded-chat .button-primary:hover,
.open > .dropdown-toggle.tiki #conversejs .button-primary:hover,
.tiki #converse-embedded-chat .button-primary:active:focus,
.tiki #conversejs .button-primary:active:focus,
.tiki #converse-embedded-chat .button-primary.active:focus,
.tiki #conversejs .button-primary.active:focus,
.open > .dropdown-toggle.tiki #converse-embedded-chat .button-primary:focus,
.open > .dropdown-toggle.tiki #conversejs .button-primary:focus,
.tiki #converse-embedded-chat .button-primary:active.focus,
.tiki #conversejs .button-primary:active.focus,
.tiki #converse-embedded-chat .button-primary.active.focus,
.tiki #conversejs .button-primary.active.focus,
.open > .dropdown-toggle.tiki #converse-embedded-chat .button-primary.focus,
.open > .dropdown-toggle.tiki #conversejs .button-primary.focus {
color: #ffffff;
background-color: #0a68b4;
border-color: rgba(0, 0, 0, 0);
}
.tiki #converse-embedded-chat .button-primary:active,
.tiki #conversejs .button-primary:active,
.tiki #converse-embedded-chat .button-primary.active,
.tiki #conversejs .button-primary.active,
.open > .dropdown-toggle.tiki #converse-embedded-chat .button-primary,
.open > .dropdown-toggle.tiki #conversejs .button-primary {
background-image: none;
}
.tiki #converse-embedded-chat .button-primary.disabled:hover,
.tiki #conversejs .button-primary.disabled:hover,
.tiki #converse-embedded-chat .button-primary[disabled]:hover,
.tiki #conversejs .button-primary[disabled]:hover,
fieldset[disabled] .tiki #converse-embedded-chat .button-primary:hover,
fieldset[disabled] .tiki #conversejs .button-primary:hover,
.tiki #converse-embedded-chat .button-primary.disabled:focus,
.tiki #conversejs .button-primary.disabled:focus,
.tiki #converse-embedded-chat .button-primary[disabled]:focus,
.tiki #conversejs .button-primary[disabled]:focus,
fieldset[disabled] .tiki #converse-embedded-chat .button-primary:focus,
fieldset[disabled] .tiki #conversejs .button-primary:focus,
.tiki #converse-embedded-chat .button-primary.disabled.focus,
.tiki #conversejs .button-primary.disabled.focus,
.tiki #converse-embedded-chat .button-primary[disabled].focus,
.tiki #conversejs .button-primary[disabled].focus,
fieldset[disabled] .tiki #converse-embedded-chat .button-primary.focus,
fieldset[disabled] .tiki #conversejs .button-primary.focus {
background-color: #2196f3;
border-color: transparent;
}
.tiki #converse-embedded-chat .button-primary .badge,
.tiki #conversejs .button-primary .badge {
color: #2196f3;
background-color: #ffffff;
}
.tiki #converse-embedded-chat .button-secondary,
.tiki #conversejs .button-secondary {
color: #ffffff;
background-color: #9c27b0;
border-color: transparent;
}
.tiki #converse-embedded-chat .button-secondary:focus,
.tiki #conversejs .button-secondary:focus,
.tiki #converse-embedded-chat .button-secondary.focus,
.tiki #conversejs .button-secondary.focus {
color: #ffffff;
background-color: #771e86;
border-color: rgba(0, 0, 0, 0);
}
.tiki #converse-embedded-chat .button-secondary:hover,
.tiki #conversejs .button-secondary:hover {
color: #ffffff;
background-color: #771e86;
border-color: rgba(0, 0, 0, 0);
}
.tiki #converse-embedded-chat .button-secondary:active,
.tiki #conversejs .button-secondary:active,
.tiki #converse-embedded-chat .button-secondary.active,
.tiki #conversejs .button-secondary.active,
.open > .dropdown-toggle.tiki #converse-embedded-chat .button-secondary,
.open > .dropdown-toggle.tiki #conversejs .button-secondary {
color: #ffffff;
background-color: #771e86;
border-color: rgba(0, 0, 0, 0);
}
.tiki #converse-embedded-chat .button-secondary:active:hover,
.tiki #conversejs .button-secondary:active:hover,
.tiki #converse-embedded-chat .button-secondary.active:hover,
.tiki #conversejs .button-secondary.active:hover,
.open > .dropdown-toggle.tiki #converse-embedded-chat .button-secondary:hover,
.open > .dropdown-toggle.tiki #conversejs .button-secondary:hover,
.tiki #converse-embedded-chat .button-secondary:active:focus,
.tiki #conversejs .button-secondary:active:focus,
.tiki #converse-embedded-chat .button-secondary.active:focus,
.tiki #conversejs .button-secondary.active:focus,
.open > .dropdown-toggle.tiki #converse-embedded-chat .button-secondary:focus,
.open > .dropdown-toggle.tiki #conversejs .button-secondary:focus,
.tiki #converse-embedded-chat .button-secondary:active.focus,
.tiki #conversejs .button-secondary:active.focus,
.tiki #converse-embedded-chat .button-secondary.active.focus,
.tiki #conversejs .button-secondary.active.focus,
.open > .dropdown-toggle.tiki #converse-embedded-chat .button-secondary.focus,
.open > .dropdown-toggle.tiki #conversejs .button-secondary.focus {
color: #ffffff;
background-color: #5d1769;
border-color: rgba(0, 0, 0, 0);
}
.tiki #converse-embedded-chat .button-secondary:active,
.tiki #conversejs .button-secondary:active,
.tiki #converse-embedded-chat .button-secondary.active,
.tiki #conversejs .button-secondary.active,
.open > .dropdown-toggle.tiki #converse-embedded-chat .button-secondary,
.open > .dropdown-toggle.tiki #conversejs .button-secondary {
background-image: none;
}
.tiki #converse-embedded-chat .button-secondary.disabled:hover,
.tiki #conversejs .button-secondary.disabled:hover,
.tiki #converse-embedded-chat .button-secondary[disabled]:hover,
.tiki #conversejs .button-secondary[disabled]:hover,
fieldset[disabled] .tiki #converse-embedded-chat .button-secondary:hover,
fieldset[disabled] .tiki #conversejs .button-secondary:hover,
.tiki #converse-embedded-chat .button-secondary.disabled:focus,
.tiki #conversejs .button-secondary.disabled:focus,
.tiki #converse-embedded-chat .button-secondary[disabled]:focus,
.tiki #conversejs .button-secondary[disabled]:focus,
fieldset[disabled] .tiki #converse-embedded-chat .button-secondary:focus,
fieldset[disabled] .tiki #conversejs .button-secondary:focus,
.tiki #converse-embedded-chat .button-secondary.disabled.focus,
.tiki #conversejs .button-secondary.disabled.focus,
.tiki #converse-embedded-chat .button-secondary[disabled].focus,
.tiki #conversejs .button-secondary[disabled].focus,
fieldset[disabled] .tiki #converse-embedded-chat .button-secondary.focus,
fieldset[disabled] .tiki #conversejs .button-secondary.focus {
background-color: #9c27b0;
border-color: transparent;
}
.tiki #converse-embedded-chat .button-secondary .badge,
.tiki #conversejs .button-secondary .badge {
color: #9c27b0;
background-color: #ffffff;
}
.tiki #converse-embedded-chat .toggle-controlbox,
.tiki #conversejs .toggle-controlbox {
background-color: #2196f3;
padding: 8px 10px 0 10px;
}
.tiki #converse-embedded-chat .toggle-controlbox span,
.tiki #conversejs .toggle-controlbox span {
color: #ffffff;
}
.tiki #converse-embedded-chat #minimized-chats .chat-head-chatbox,
.tiki #conversejs #minimized-chats .chat-head-chatbox {
background-color: #2196f3;
}
.tiki #converse-embedded-chat #minimized-chats .chat-head-chatbox .restore-chat,
.tiki #conversejs #minimized-chats .chat-head-chatbox .restore-chat,
.tiki #converse-embedded-chat #minimized-chats .chat-head-chatbox .chatbox-btn,
.tiki #conversejs #minimized-chats .chat-head-chatbox .chatbox-btn {
color: #ffffff;
}
.tiki #converse-embedded-chat #minimized-chats .chat-head-chatroom,
.tiki #conversejs #minimized-chats .chat-head-chatroom {
background-color: #9c27b0;
}
.tiki #converse-embedded-chat #minimized-chats .chat-head-chatroom .restore-chat,
.tiki #conversejs #minimized-chats .chat-head-chatroom .restore-chat,
.tiki #converse-embedded-chat #minimized-chats .chat-head-chatroom .chatbox-btn,
.tiki #conversejs #minimized-chats .chat-head-chatroom .chatbox-btn {
color: #ffffff;
}
.tiki #converse-embedded-chat #controlbox .box-flyout,
.tiki #conversejs #controlbox .box-flyout,
.tiki #converse-embedded-chat .chatbox .box-flyout,
.tiki #conversejs .chatbox .box-flyout {
background-color: #ffffff;
}
.tiki #converse-embedded-chat #controlbox .controlbox-head,
.tiki #conversejs #controlbox .controlbox-head,
.tiki #converse-embedded-chat #controlbox .controlbox-panes,
.tiki #conversejs #controlbox .controlbox-panes,
.tiki #converse-embedded-chat #controlbox .controlbox-pane,
.tiki #conversejs #controlbox .controlbox-pane {
background-color: inherit;
}
.tiki #converse-embedded-chat #controlbox .controlbox-head,
.tiki #conversejs #controlbox .controlbox-head {
border-bottom: 1px solid transparent;
}
.tiki #converse-embedded-chat #controlbox .controlbox-head .chatbox-btn,
.tiki #conversejs #controlbox .controlbox-head .chatbox-btn {
color: #666666;
}
.tiki #converse-embedded-chat #controlbox #controlbox-tabs,
.tiki #conversejs #controlbox #controlbox-tabs {
border-bottom: 1px solid transparent;
}
.tiki #converse-embedded-chat #controlbox #controlbox-tabs li a,
.tiki #conversejs #controlbox #controlbox-tabs li a {
margin-left: 2px;
height: 48px;
line-height: 48px;
color: #2196f3;
border: 1px solid transparent;
box-shadow: none;
background-color: transparent;
}
.tiki #converse-embedded-chat #controlbox #controlbox-tabs li a:hover,
.tiki #conversejs #controlbox #controlbox-tabs li a:hover {
color: #2196f3;
}
.tiki #converse-embedded-chat #controlbox #controlbox-tabs li a.current,
.tiki #conversejs #controlbox #controlbox-tabs li a.current,
.tiki #converse-embedded-chat #controlbox #controlbox-tabs li a.current:hover,
.tiki #conversejs #controlbox #controlbox-tabs li a.current:hover,
.tiki #converse-embedded-chat #controlbox #controlbox-tabs li a.current:focus,
.tiki #conversejs #controlbox #controlbox-tabs li a.current:focus {
color: #666666;
background-color: transparent;
border: 1px solid transparent;
border-bottom-color: transparent;
height: 48px;
}
.tiki #converse-embedded-chat #controlbox #chatrooms dl.rooms-list dt,
.tiki #conversejs #controlbox #chatrooms dl.rooms-list dt {
color: #666666;
text-shadow: none;
}
.tiki #converse-embedded-chat #controlbox #chatrooms dl.rooms-list dd.available-chatroom:hover,
.tiki #conversejs #controlbox #chatrooms dl.rooms-list dd.available-chatroom:hover {
background-color: inherit;
}
.tiki #converse-embedded-chat #controlbox #chatrooms dl.rooms-list dd.available-chatroom:hover a,
.tiki #conversejs #controlbox #chatrooms dl.rooms-list dd.available-chatroom:hover a {
color: #666666;
}
.tiki #converse-embedded-chat #controlbox #chatrooms dl.rooms-list dd.available-chatroom a.room-info,
.tiki #conversejs #controlbox #chatrooms dl.rooms-list dd.available-chatroom a.room-info {
margin-top: 2px;
}
.tiki #converse-embedded-chat #controlbox #fancy-xmpp-status-select,
.tiki #conversejs #controlbox #fancy-xmpp-status-select,
.tiki #converse-embedded-chat #controlbox .fancy-dropdown,
.tiki #conversejs #controlbox .fancy-dropdown {
color: #ffffff;
background-color: #9c27b0;
border-color: transparent;
}
.tiki #converse-embedded-chat #controlbox #fancy-xmpp-status-select:focus,
.tiki #conversejs #controlbox #fancy-xmpp-status-select:focus,
.tiki #converse-embedded-chat #controlbox .fancy-dropdown:focus,
.tiki #conversejs #controlbox .fancy-dropdown:focus,
.tiki #converse-embedded-chat #controlbox #fancy-xmpp-status-select.focus,
.tiki #conversejs #controlbox #fancy-xmpp-status-select.focus,
.tiki #converse-embedded-chat #controlbox .fancy-dropdown.focus,
.tiki #conversejs #controlbox .fancy-dropdown.focus {
color: #ffffff;
background-color: #771e86;
border-color: rgba(0, 0, 0, 0);
}
.tiki #converse-embedded-chat #controlbox #fancy-xmpp-status-select:hover,
.tiki #conversejs #controlbox #fancy-xmpp-status-select:hover,
.tiki #converse-embedded-chat #controlbox .fancy-dropdown:hover,
.tiki #conversejs #controlbox .fancy-dropdown:hover {
color: #ffffff;
background-color: #771e86;
border-color: rgba(0, 0, 0, 0);
}
.tiki #converse-embedded-chat #controlbox #fancy-xmpp-status-select:active,
.tiki #conversejs #controlbox #fancy-xmpp-status-select:active,
.tiki #converse-embedded-chat #controlbox .fancy-dropdown:active,
.tiki #conversejs #controlbox .fancy-dropdown:active,
.tiki #converse-embedded-chat #controlbox #fancy-xmpp-status-select.active,
.tiki #conversejs #controlbox #fancy-xmpp-status-select.active,
.tiki #converse-embedded-chat #controlbox .fancy-dropdown.active,
.tiki #conversejs #controlbox .fancy-dropdown.active,
.open > .dropdown-toggle.tiki #converse-embedded-chat #controlbox #fancy-xmpp-status-select,
.open > .dropdown-toggle.tiki #conversejs #controlbox #fancy-xmpp-status-select,
.open > .dropdown-toggle.tiki #converse-embedded-chat #controlbox .fancy-dropdown,
.open > .dropdown-toggle.tiki #conversejs #controlbox .fancy-dropdown {
color: #ffffff;
background-color: #771e86;
border-color: rgba(0, 0, 0, 0);
}
.tiki #converse-embedded-chat #controlbox #fancy-xmpp-status-select:active:hover,
.tiki #conversejs #controlbox #fancy-xmpp-status-select:active:hover,
.tiki #converse-embedded-chat #controlbox .fancy-dropdown:active:hover,
.tiki #conversejs #controlbox .fancy-dropdown:active:hover,
.tiki #converse-embedded-chat #controlbox #fancy-xmpp-status-select.active:hover,
.tiki #conversejs #controlbox #fancy-xmpp-status-select.active:hover,
.tiki #converse-embedded-chat #controlbox .fancy-dropdown.active:hover,
.tiki #conversejs #controlbox .fancy-dropdown.active:hover,
.open > .dropdown-toggle.tiki #converse-embedded-chat #controlbox #fancy-xmpp-status-select:hover,
.open > .dropdown-toggle.tiki #conversejs #controlbox #fancy-xmpp-status-select:hover,
.open > .dropdown-toggle.tiki #converse-embedded-chat #controlbox .fancy-dropdown:hover,
.open > .dropdown-toggle.tiki #conversejs #controlbox .fancy-dropdown:hover,
.tiki #converse-embedded-chat #controlbox #fancy-xmpp-status-select:active:focus,
.tiki #conversejs #controlbox #fancy-xmpp-status-select:active:focus,
.tiki #converse-embedded-chat #controlbox .fancy-dropdown:active:focus,
.tiki #conversejs #controlbox .fancy-dropdown:active:focus,
.tiki #converse-embedded-chat #controlbox #fancy-xmpp-status-select.active:focus,
.tiki #conversejs #controlbox #fancy-xmpp-status-select.active:focus,
.tiki #converse-embedded-chat #controlbox .fancy-dropdown.active:focus,
.tiki #conversejs #controlbox .fancy-dropdown.active:focus,
.open > .dropdown-toggle.tiki #converse-embedded-chat #controlbox #fancy-xmpp-status-select:focus,
.open > .dropdown-toggle.tiki #conversejs #controlbox #fancy-xmpp-status-select:focus,
.open > .dropdown-toggle.tiki #converse-embedded-chat #controlbox .fancy-dropdown:focus,
.open > .dropdown-toggle.tiki #conversejs #controlbox .fancy-dropdown:focus,
.tiki #converse-embedded-chat #controlbox #fancy-xmpp-status-select:active.focus,
.tiki #conversejs #controlbox #fancy-xmpp-status-select:active.focus,
.tiki #converse-embedded-chat #controlbox .fancy-dropdown:active.focus,
.tiki #conversejs #controlbox .fancy-dropdown:active.focus,
.tiki #converse-embedded-chat #controlbox #fancy-xmpp-status-select.active.focus,
.tiki #conversejs #controlbox #fancy-xmpp-status-select.active.focus,
.tiki #converse-embedded-chat #controlbox .fancy-dropdown.active.focus,
.tiki #conversejs #controlbox .fancy-dropdown.active.focus,
.open > .dropdown-toggle.tiki #converse-embedded-chat #controlbox #fancy-xmpp-status-select.focus,
.open > .dropdown-toggle.tiki #conversejs #controlbox #fancy-xmpp-status-select.focus,
.open > .dropdown-toggle.tiki #converse-embedded-chat #controlbox .fancy-dropdown.focus,
.open > .dropdown-toggle.tiki #conversejs #controlbox .fancy-dropdown.focus {
color: #ffffff;
background-color: #5d1769;
border-color: rgba(0, 0, 0, 0);
}
.tiki #converse-embedded-chat #controlbox #fancy-xmpp-status-select:active,
.tiki #conversejs #controlbox #fancy-xmpp-status-select:active,
.tiki #converse-embedded-chat #controlbox .fancy-dropdown:active,
.tiki #conversejs #controlbox .fancy-dropdown:active,
.tiki #converse-embedded-chat #controlbox #fancy-xmpp-status-select.active,
.tiki #conversejs #controlbox #fancy-xmpp-status-select.active,
.tiki #converse-embedded-chat #controlbox .fancy-dropdown.active,
.tiki #conversejs #controlbox .fancy-dropdown.active,
.open > .dropdown-toggle.tiki #converse-embedded-chat #controlbox #fancy-xmpp-status-select,
.open > .dropdown-toggle.tiki #conversejs #controlbox #fancy-xmpp-status-select,
.open > .dropdown-toggle.tiki #converse-embedded-chat #controlbox .fancy-dropdown,
.open > .dropdown-toggle.tiki #conversejs #controlbox .fancy-dropdown {
background-image: none;
}
.tiki #converse-embedded-chat #controlbox #fancy-xmpp-status-select.disabled:hover,
.tiki #conversejs #controlbox #fancy-xmpp-status-select.disabled:hover,
.tiki #converse-embedded-chat #controlbox .fancy-dropdown.disabled:hover,
.tiki #conversejs #controlbox .fancy-dropdown.disabled:hover,
.tiki #converse-embedded-chat #controlbox #fancy-xmpp-status-select[disabled]:hover,
.tiki #conversejs #controlbox #fancy-xmpp-status-select[disabled]:hover,
.tiki #converse-embedded-chat #controlbox .fancy-dropdown[disabled]:hover,
.tiki #conversejs #controlbox .fancy-dropdown[disabled]:hover,
fieldset[disabled] .tiki #converse-embedded-chat #controlbox #fancy-xmpp-status-select:hover,
fieldset[disabled] .tiki #conversejs #controlbox #fancy-xmpp-status-select:hover,
fieldset[disabled] .tiki #converse-embedded-chat #controlbox .fancy-dropdown:hover,
fieldset[disabled] .tiki #conversejs #controlbox .fancy-dropdown:hover,
.tiki #converse-embedded-chat #controlbox #fancy-xmpp-status-select.disabled:focus,
.tiki #conversejs #controlbox #fancy-xmpp-status-select.disabled:focus,
.tiki #converse-embedded-chat #controlbox .fancy-dropdown.disabled:focus,
.tiki #conversejs #controlbox .fancy-dropdown.disabled:focus,
.tiki #converse-embedded-chat #controlbox #fancy-xmpp-status-select[disabled]:focus,
.tiki #conversejs #controlbox #fancy-xmpp-status-select[disabled]:focus,
.tiki #converse-embedded-chat #controlbox .fancy-dropdown[disabled]:focus,
.tiki #conversejs #controlbox .fancy-dropdown[disabled]:focus,
fieldset[disabled] .tiki #converse-embedded-chat #controlbox #fancy-xmpp-status-select:focus,
fieldset[disabled] .tiki #conversejs #controlbox #fancy-xmpp-status-select:focus,
fieldset[disabled] .tiki #converse-embedded-chat #controlbox .fancy-dropdown:focus,
fieldset[disabled] .tiki #conversejs #controlbox .fancy-dropdown:focus,
.tiki #converse-embedded-chat #controlbox #fancy-xmpp-status-select.disabled.focus,
.tiki #conversejs #controlbox #fancy-xmpp-status-select.disabled.focus,
.tiki #converse-embedded-chat #controlbox .fancy-dropdown.disabled.focus,
.tiki #conversejs #controlbox .fancy-dropdown.disabled.focus,
.tiki #converse-embedded-chat #controlbox #fancy-xmpp-status-select[disabled].focus,
.tiki #conversejs #controlbox #fancy-xmpp-status-select[disabled].focus,
.tiki #converse-embedded-chat #controlbox .fancy-dropdown[disabled].focus,
.tiki #conversejs #controlbox .fancy-dropdown[disabled].focus,
fieldset[disabled] .tiki #converse-embedded-chat #controlbox #fancy-xmpp-status-select.focus,
fieldset[disabled] .tiki #conversejs #controlbox #fancy-xmpp-status-select.focus,
fieldset[disabled] .tiki #converse-embedded-chat #controlbox .fancy-dropdown.focus,
fieldset[disabled] .tiki #conversejs #controlbox .fancy-dropdown.focus {
background-color: #9c27b0;
border-color: transparent;
}
.tiki #converse-embedded-chat #controlbox #fancy-xmpp-status-select .badge,
.tiki #conversejs #controlbox #fancy-xmpp-status-select .badge,
.tiki #converse-embedded-chat #controlbox .fancy-dropdown .badge,
.tiki #conversejs #controlbox .fancy-dropdown .badge {
color: #9c27b0;
background-color: #ffffff;
}
.tiki #converse-embedded-chat #controlbox #fancy-xmpp-status-select .choose-xmpp-status,
.tiki #conversejs #controlbox #fancy-xmpp-status-select .choose-xmpp-status,
.tiki #converse-embedded-chat #controlbox .fancy-dropdown .choose-xmpp-status,
.tiki #conversejs #controlbox .fancy-dropdown .choose-xmpp-status,
.tiki #converse-embedded-chat #controlbox #fancy-xmpp-status-select .toggle-xmpp-contact-form,
.tiki #conversejs #controlbox #fancy-xmpp-status-select .toggle-xmpp-contact-form,
.tiki #converse-embedded-chat #controlbox .fancy-dropdown .toggle-xmpp-contact-form,
.tiki #conversejs #controlbox .fancy-dropdown .toggle-xmpp-contact-form,
.tiki #converse-embedded-chat #controlbox #fancy-xmpp-status-select a.change-xmpp-status-message,
.tiki #conversejs #controlbox #fancy-xmpp-status-select a.change-xmpp-status-message,
.tiki #converse-embedded-chat #controlbox .fancy-dropdown a.change-xmpp-status-message,
.tiki #conversejs #controlbox .fancy-dropdown a.change-xmpp-status-message {
color: inherit;
text-shadow: none;
}
.tiki #converse-embedded-chat #controlbox .xmpp-status-menu li a.online,
.tiki #conversejs #controlbox .xmpp-status-menu li a.online,
.tiki #converse-embedded-chat #controlbox .xmpp-status-menu li a.dnd,
.tiki #conversejs #controlbox .xmpp-status-menu li a.dnd,
.tiki #converse-embedded-chat #controlbox .xmpp-status-menu li a.away,
.tiki #conversejs #controlbox .xmpp-status-menu li a.away {
color: #1f7e9a;
}
.tiki #converse-embedded-chat #controlbox #converse-roster .roster-filter-form .filter-type,
.tiki #conversejs #controlbox #converse-roster .roster-filter-form .filter-type {
border-color: transparent;
}
.tiki #converse-embedded-chat #controlbox #converse-roster .roster-filter-form .roster-filter,
.tiki #conversejs #controlbox #converse-roster .roster-filter-form .roster-filter {
background-color: transparent;
color: #666666;
border-color: transparent;
}
.tiki #converse-embedded-chat #controlbox #converse-roster .roster-contacts dt,
.tiki #conversejs #controlbox #converse-roster .roster-contacts dt {
color: #666666;
}
.tiki #converse-embedded-chat #controlbox #converse-roster .roster-contacts dt a,
.tiki #conversejs #controlbox #converse-roster .roster-contacts dt a {
color: inherit;
}
.tiki #converse-embedded-chat #controlbox #converse-roster .roster-contacts dt:hover,
.tiki #conversejs #controlbox #converse-roster .roster-contacts dt:hover {
background-color: transparent;
}
.tiki #converse-embedded-chat #controlbox #converse-roster .roster-contacts dd,
.tiki #conversejs #controlbox #converse-roster .roster-contacts dd {
color: #2196f3;
background-color: transparent;
}
.tiki #converse-embedded-chat #controlbox #converse-roster .roster-contacts dd a,
.tiki #conversejs #controlbox #converse-roster .roster-contacts dd a,
.tiki #converse-embedded-chat #controlbox #converse-roster .roster-contacts dd span,
.tiki #conversejs #controlbox #converse-roster .roster-contacts dd span {
color: inherit;
text-shadow: none;
}
.tiki #converse-embedded-chat #controlbox #converse-roster .roster-contacts dd a:hover,
.tiki #conversejs #controlbox #converse-roster .roster-contacts dd a:hover,
.tiki #converse-embedded-chat #controlbox #converse-roster .roster-contacts dd span:hover,
.tiki #conversejs #controlbox #converse-roster .roster-contacts dd span:hover {
color: #666666;
}
.tiki #converse-embedded-chat #controlbox #converse-register,
.tiki #conversejs #controlbox #converse-register {
background-color: transparent;
}
.tiki #converse-embedded-chat #controlbox #converse-register .form-help .url,
.tiki #conversejs #controlbox #converse-register .form-help .url {
color: #2196f3;
}
.tiki #converse-embedded-chat #controlbox #converse-register .form-help .url:hover,
.tiki #conversejs #controlbox #converse-register .form-help .url:hover {
color: #0a6ebd;
}
.tiki #converse-embedded-chat .chatbox form.sendXMPPMessage .chat-toolbar,
.tiki #conversejs .chatbox form.sendXMPPMessage .chat-toolbar {
background-color: #2196f3;
}
.tiki #converse-embedded-chat .chatbox form.sendXMPPMessage .chat-toolbar ul,
.tiki #conversejs .chatbox form.sendXMPPMessage .chat-toolbar ul {
background-color: #2196f3;
}
.tiki #converse-embedded-chat .chatbox form.sendXMPPMessage .chat-toolbar > li,
.tiki #conversejs .chatbox form.sendXMPPMessage .chat-toolbar > li {
margin: -2px;
}
.tiki #converse-embedded-chat .chatbox form.sendXMPPMessage .chat-toolbar a,
.tiki #conversejs .chatbox form.sendXMPPMessage .chat-toolbar a,
.tiki #converse-embedded-chat .chatbox form.sendXMPPMessage .chat-toolbar .toggle-smiley,
.tiki #conversejs .chatbox form.sendXMPPMessage .chat-toolbar .toggle-smiley,
.tiki #converse-embedded-chat .chatbox form.sendXMPPMessage .chat-toolbar .unencrypted,
.tiki #conversejs .chatbox form.sendXMPPMessage .chat-toolbar .unencrypted {
color: #ffffff;
}
.tiki #converse-embedded-chat .chatbox form.sendXMPPMessage .chat-toolbar .toggle-smiley ul li:hover,
.tiki #conversejs .chatbox form.sendXMPPMessage .chat-toolbar .toggle-smiley ul li:hover {
background-color: #ffffff;
}
.tiki #converse-embedded-chat .chatbox form.sendXMPPMessage .chat-toolbar .toggle-smiley ul li:hover a,
.tiki #conversejs .chatbox form.sendXMPPMessage .chat-toolbar .toggle-smiley ul li:hover a {
color: #2196f3;
}
.tiki #converse-embedded-chat .chatbox form.sendXMPPMessage .chat-toolbar .chat-toolbar-text,
.tiki #conversejs .chatbox form.sendXMPPMessage .chat-toolbar .chat-toolbar-text {
text-shadow: none;
}
.tiki #converse-embedded-chat .chatbox .dropdown,
.tiki #conversejs .chatbox .dropdown {
background-color: transparent;
}
.tiki #converse-embedded-chat .chatbox .chat-head,
.tiki #conversejs .chatbox .chat-head {
border-bottom: 1px solid #666666;
}
.tiki #converse-embedded-chat .chatbox .chat-head.chat-head-chatbox,
.tiki #conversejs .chatbox .chat-head.chat-head-chatbox {
background-color: #2196f3;
}
.tiki #converse-embedded-chat .chatbox .chat-head .chat-title,
.tiki #conversejs .chatbox .chat-head .chat-title,
.tiki #converse-embedded-chat .chatbox .chat-head .close-chatbox-button,
.tiki #conversejs .chatbox .chat-head .close-chatbox-button,
.tiki #converse-embedded-chat .chatbox .chat-head .toggle-chatbox-button,
.tiki #conversejs .chatbox .chat-head .toggle-chatbox-button {
color: #ffffff;
}
.tiki #converse-embedded-chat .chatbox .chat-body,
.tiki #conversejs .chatbox .chat-body {
background-color: inherit;
}
.tiki #converse-embedded-chat .chatbox .chat-body .chat-content,
.tiki #conversejs .chatbox .chat-body .chat-content {
height: calc(100% - 95px);
color: #666666;
background-color: inherit;
}
.tiki #converse-embedded-chat .chatbox .chat-body .chat-info,
.tiki #conversejs .chatbox .chat-body .chat-info {
color: #2196f3;
}
.tiki #converse-embedded-chat .chatbox .chat-body .chat-message span.chat-msg-me,
.tiki #conversejs .chatbox .chat-body .chat-message span.chat-msg-me {
color: #9c27b0;
}
.tiki #converse-embedded-chat .chatbox .chat-body .chat-message span.chat-msg-them,
.tiki #conversejs .chatbox .chat-body .chat-message span.chat-msg-them {
color: #2196f3;
}
.tiki #converse-embedded-chat .chatroom .box-flyout .chat-head-chatroom,
.tiki #conversejs .chatroom .box-flyout .chat-head-chatroom {
background-color: #9c27b0;
}
.tiki #converse-embedded-chat .chatroom .box-flyout .chat-head-chatroom .close-chatbox-button,
.tiki #conversejs .chatroom .box-flyout .chat-head-chatroom .close-chatbox-button,
.tiki #converse-embedded-chat .chatroom .box-flyout .chat-head-chatroom .toggle-chatbox-button,
.tiki #conversejs .chatroom .box-flyout .chat-head-chatroom .toggle-chatbox-button,
.tiki #converse-embedded-chat .chatroom .box-flyout .chat-head-chatroom .toggle-bookmark,
.tiki #conversejs .chatroom .box-flyout .chat-head-chatroom .toggle-bookmark,
.tiki #converse-embedded-chat .chatroom .box-flyout .chat-head-chatroom .chat-title,
.tiki #conversejs .chatroom .box-flyout .chat-head-chatroom .chat-title,
.tiki #converse-embedded-chat .chatroom .box-flyout .chat-head-chatroom .chatroom-description,
.tiki #conversejs .chatroom .box-flyout .chat-head-chatroom .chatroom-description,
.tiki #converse-embedded-chat .chatroom .box-flyout .chat-head-chatroom .configure-chatroom-button,
.tiki #conversejs .chatroom .box-flyout .chat-head-chatroom .configure-chatroom-button {
color: #ffffff;
}
.tiki #converse-embedded-chat .chatroom .box-flyout .chatroom-body p,
.tiki #conversejs .chatroom .box-flyout .chatroom-body p {
color: #666666;
}
.tiki #converse-embedded-chat .chatroom .box-flyout .chatroom-body .occupants,
.tiki #conversejs .chatroom .box-flyout .chatroom-body .occupants {
background-color: inherit;
border-left-color: #666666;
}
.tiki #converse-embedded-chat .chatroom .box-flyout .chatroom-body .occupants ul li.moderator,
.tiki #conversejs .chatroom .box-flyout .chatroom-body .occupants ul li.moderator {
color: #2196f3;
}
.tiki #converse-embedded-chat .chatroom .box-flyout .chatroom-body .occupants ul li.occupant .occupant-status,
.tiki #conversejs .chatroom .box-flyout .chatroom-body .occupants ul li.occupant .occupant-status {
margin-left: 1px;
box-shadow: 0px 0px 1px 1px #444;
}
.tiki #converse-embedded-chat .chatroom .box-flyout .chatroom-body .chatroom-form-container,
.tiki #conversejs .chatroom .box-flyout .chatroom-body .chatroom-form-container {
background-color: inherit;
color: #666666;
}
.tiki #converse-embedded-chat .chatroom .box-flyout .chatroom-body .room-invite .invited-contact,
.tiki #conversejs .chatroom .box-flyout .chatroom-body .room-invite .invited-contact {
border-color: transparent;
}
| Java |
/*******************************************************************************
* Copyright 2002 National Student Clearinghouse
*
* This code is part of the Meteor system as defined and specified
* by the National Student Clearinghouse and the Meteor Sponsors.
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
* version 2.1 of the License, or (at your option) any later version.
*
* This library is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
* Lesser General Public License for more details.
*
* You should have received a copy of the GNU Lesser General Public
* License along with this library; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
******************************************************************************/
package org.meteornetwork.meteor.common.abstraction.index;
import org.meteornetwork.meteor.common.xml.indexresponse.DataProvider;
import org.meteornetwork.meteor.common.xml.indexresponse.DataProviders;
import org.meteornetwork.meteor.common.xml.indexresponse.IndexProviderData;
import org.meteornetwork.meteor.common.xml.indexresponse.IndexProviderMessages;
import org.meteornetwork.meteor.common.xml.indexresponse.Message;
import org.meteornetwork.meteor.common.xml.indexresponse.MeteorIndexResponse;
import org.meteornetwork.meteor.common.xml.indexresponse.types.RsMsgLevelEnum;
public class MeteorIndexResponseWrapper {
private final MeteorIndexResponse response;
public MeteorIndexResponseWrapper() {
response = new MeteorIndexResponse();
response.setDataProviders(new DataProviders());
}
/**
* Add index provider information to the response.
*
* @param id
* the ID of this index provider
* @param name
* the name of this index provider
* @param url
* the contact URL of this index provider
*/
public void setIndexProviderData(String id, String name, String url) {
IndexProviderData data = new IndexProviderData();
data.setEntityID(id);
data.setEntityName(name);
data.setEntityURL(url);
response.setIndexProviderData(data);
}
/**
* Add a message to this response
*
* @param messageText
* the text of the message
* @param level
* the severity level of the message
*/
public void addMessage(String messageText, RsMsgLevelEnum level) {
Message message = new Message();
message.setRsMsg(messageText);
message.setRsMsgLevel(level.name());
if (response.getIndexProviderMessages() == null) {
response.setIndexProviderMessages(new IndexProviderMessages());
}
response.getIndexProviderMessages().addMessage(message);
}
/**
* Add one or more Data Provider objects to the response
*
* @param dataProviders
* the data providers to add to the response
*/
public void addDataProviders(DataProvider... dataProviders) {
for (DataProvider dataProvider : dataProviders) {
response.getDataProviders().addDataProvider(dataProvider);
}
}
/**
* Add Data Provider objects to the response
*
* @param dataProviders
* an iterable collection of Data Providers to add to the
* response
*/
public void addDataProviders(Iterable<DataProvider> dataProviders) {
for (DataProvider dataProvider : dataProviders) {
response.getDataProviders().addDataProvider(dataProvider);
}
}
/**
* Access a mutable version of the response.
*
* @return A mutable version of the internal MeteorIndexResponse object
*/
public MeteorIndexResponse getResponse() {
return response;
}
}
| Java |
// The libMesh Finite Element Library.
// Copyright (C) 2002-2018 Benjamin S. Kirk, John W. Peterson, Roy H. Stogner
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
// License as published by the Free Software Foundation; either
// version 2.1 of the License, or (at your option) any later version.
// This library is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
// You should have received a copy of the GNU Lesser General Public
// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
// Local includes
#include "libmesh/side.h"
#include "libmesh/edge_edge3.h"
#include "libmesh/face_quad9.h"
#include "libmesh/enum_io_package.h"
#include "libmesh/enum_order.h"
namespace libMesh
{
// ------------------------------------------------------------
// Quad9 class static member initializations
const int Quad9::num_nodes;
const int Quad9::num_sides;
const int Quad9::num_children;
const int Quad9::nodes_per_side;
const unsigned int Quad9::side_nodes_map[Quad9::num_sides][Quad9::nodes_per_side] =
{
{0, 1, 4}, // Side 0
{1, 2, 5}, // Side 1
{2, 3, 6}, // Side 2
{3, 0, 7} // Side 3
};
#ifdef LIBMESH_ENABLE_AMR
const float Quad9::_embedding_matrix[Quad9::num_children][Quad9::num_nodes][Quad9::num_nodes] =
{
// embedding matrix for child 0
{
// 0 1 2 3 4 5 6 7 8
{ 1.00000, 0.00000, 0.00000, 0.00000, 0.00000, 0.00000, 0.00000, 0.00000, 0.00000 }, // 0
{ 0.00000, 0.00000, 0.00000, 0.00000, 1.00000, 0.00000, 0.00000, 0.00000, 0.00000 }, // 1
{ 0.00000, 0.00000, 0.00000, 0.00000, 0.00000, 0.00000, 0.00000, 0.00000, 1.00000 }, // 2
{ 0.00000, 0.00000, 0.00000, 0.00000, 0.00000, 0.00000, 0.00000, 1.00000, 0.00000 }, // 3
{ 0.375000, -0.125000, 0.00000, 0.00000, 0.750000, 0.00000, 0.00000, 0.00000, 0.00000 }, // 4
{ 0.00000, 0.00000, 0.00000, 0.00000, 0.375000, 0.00000, -0.125000, 0.00000, 0.750000 }, // 5
{ 0.00000, 0.00000, 0.00000, 0.00000, 0.00000, -0.125000, 0.00000, 0.375000, 0.750000 }, // 6
{ 0.375000, 0.00000, 0.00000, -0.125000, 0.00000, 0.00000, 0.00000, 0.750000, 0.00000 }, // 7
{ 0.140625, -0.0468750, 0.0156250, -0.0468750, 0.281250, -0.0937500, -0.0937500, 0.281250, 0.562500 } // 8
},
// embedding matrix for child 1
{
// 0 1 2 3 4 5 6 7 8
{ 0.00000, 0.00000, 0.00000, 0.00000, 1.00000, 0.00000, 0.00000, 0.00000, 0.00000 }, // 0
{ 0.00000, 1.00000, 0.00000, 0.00000, 0.00000, 0.00000, 0.00000, 0.00000, 0.00000 }, // 1
{ 0.00000, 0.00000, 0.00000, 0.00000, 0.00000, 1.00000, 0.00000, 0.00000, 0.00000 }, // 2
{ 0.00000, 0.00000, 0.00000, 0.00000, 0.00000, 0.00000, 0.00000, 0.00000, 1.00000 }, // 3
{ -0.125000, 0.375000, 0.00000, 0.00000, 0.750000, 0.00000, 0.00000, 0.00000, 0.00000 }, // 4
{ 0.00000, 0.375000, -0.125000, 0.00000, 0.00000, 0.750000, 0.00000, 0.00000, 0.00000 }, // 5
{ 0.00000, 0.00000, 0.00000, 0.00000, 0.00000, 0.375000, 0.00000, -0.125000, 0.750000 }, // 6
{ 0.00000, 0.00000, 0.00000, 0.00000, 0.375000, 0.00000, -0.125000, 0.00000, 0.750000 }, // 7
{ -0.0468750, 0.140625, -0.0468750, 0.0156250, 0.281250, 0.281250, -0.0937500, -0.0937500, 0.562500 } // 8
},
// embedding matrix for child 2
{
// 0 1 2 3 4 5 6 7 8
{ 0.00000, 0.00000, 0.00000, 0.00000, 0.00000, 0.00000, 0.00000, 1.00000, 0.00000 }, // 0
{ 0.00000, 0.00000, 0.00000, 0.00000, 0.00000, 0.00000, 0.00000, 0.00000, 1.00000 }, // 1
{ 0.00000, 0.00000, 0.00000, 0.00000, 0.00000, 0.00000, 1.00000, 0.00000, 0.00000 }, // 2
{ 0.00000, 0.00000, 0.00000, 1.00000, 0.00000, 0.00000, 0.00000, 0.00000, 0.00000 }, // 3
{ 0.00000, 0.00000, 0.00000, 0.00000, 0.00000, -0.125000, 0.00000, 0.375000, 0.750000 }, // 4
{ 0.00000, 0.00000, 0.00000, 0.00000, -0.125000, 0.00000, 0.375000, 0.00000, 0.750000 }, // 5
{ 0.00000, 0.00000, -0.125000, 0.375000, 0.00000, 0.00000, 0.750000, 0.00000, 0.00000 }, // 6
{ -0.125000, 0.00000, 0.00000, 0.375000, 0.00000, 0.00000, 0.00000, 0.750000, 0.00000 }, // 7
{ -0.0468750, 0.0156250, -0.0468750, 0.140625, -0.0937500, -0.0937500, 0.281250, 0.281250, 0.562500 } // 8
},
// embedding matrix for child 3
{
// 0 1 2 3 4 5 6 7 8
{ 0.00000, 0.00000, 0.00000, 0.00000, 0.00000, 0.00000, 0.00000, 0.00000, 1.00000 }, // 0
{ 0.00000, 0.00000, 0.00000, 0.00000, 0.00000, 1.00000, 0.00000, 0.00000, 0.00000 }, // 1
{ 0.00000, 0.00000, 1.00000, 0.00000, 0.00000, 0.00000, 0.00000, 0.00000, 0.00000 }, // 2
{ 0.00000, 0.00000, 0.00000, 0.00000, 0.00000, 0.00000, 1.00000, 0.00000, 0.00000 }, // 3
{ 0.00000, 0.00000, 0.00000, 0.00000, 0.00000, 0.375000, 0.00000, -0.125000, 0.750000 }, // 4
{ 0.00000, -0.125000, 0.375000, 0.00000, 0.00000, 0.750000, 0.00000, 0.00000, 0.00000 }, // 5
{ 0.00000, 0.00000, 0.375000, -0.125000, 0.00000, 0.00000, 0.750000, 0.00000, 0.00000 }, // 6
{ 0.00000, 0.00000, 0.00000, 0.00000, -0.125000, 0.00000, 0.375000, 0.00000, 0.750000 }, // 7
{ 0.0156250, -0.0468750, 0.140625, -0.0468750, -0.0937500, 0.281250, 0.281250, -0.0937500, 0.562500 } // 8
}
};
#endif
// ------------------------------------------------------------
// Quad9 class member functions
bool Quad9::is_vertex(const unsigned int i) const
{
if (i < 4)
return true;
return false;
}
bool Quad9::is_edge(const unsigned int i) const
{
if (i < 4)
return false;
if (i > 7)
return false;
return true;
}
bool Quad9::is_face(const unsigned int i) const
{
if (i > 7)
return true;
return false;
}
bool Quad9::is_node_on_side(const unsigned int n,
const unsigned int s) const
{
libmesh_assert_less (s, n_sides());
return std::find(std::begin(side_nodes_map[s]),
std::end(side_nodes_map[s]),
n) != std::end(side_nodes_map[s]);
}
std::vector<unsigned>
Quad9::nodes_on_side(const unsigned int s) const
{
libmesh_assert_less(s, n_sides());
return {std::begin(side_nodes_map[s]), std::end(side_nodes_map[s])};
}
bool Quad9::has_affine_map() const
{
// make sure corners form a parallelogram
Point v = this->point(1) - this->point(0);
if (!v.relative_fuzzy_equals(this->point(2) - this->point(3)))
return false;
// make sure "horizontal" sides are straight
v /= 2;
if (!v.relative_fuzzy_equals(this->point(4) - this->point(0)) ||
!v.relative_fuzzy_equals(this->point(6) - this->point(3)))
return false;
// make sure "vertical" sides are straight
// and the center node is centered
v = (this->point(3) - this->point(0))/2;
if (!v.relative_fuzzy_equals(this->point(7) - this->point(0)) ||
!v.relative_fuzzy_equals(this->point(5) - this->point(1)) ||
!v.relative_fuzzy_equals(this->point(8) - this->point(4)))
return false;
return true;
}
Order Quad9::default_order() const
{
return SECOND;
}
dof_id_type Quad9::key (const unsigned int s) const
{
libmesh_assert_less (s, this->n_sides());
switch (s)
{
case 0:
return
this->compute_key (this->node_id(4));
case 1:
return
this->compute_key (this->node_id(5));
case 2:
return
this->compute_key (this->node_id(6));
case 3:
return
this->compute_key (this->node_id(7));
default:
libmesh_error_msg("Invalid side s = " << s);
}
}
dof_id_type Quad9::key () const
{
return this->compute_key(this->node_id(8));
}
unsigned int Quad9::which_node_am_i(unsigned int side,
unsigned int side_node) const
{
libmesh_assert_less (side, this->n_sides());
libmesh_assert_less (side_node, Quad9::nodes_per_side);
return Quad9::side_nodes_map[side][side_node];
}
std::unique_ptr<Elem> Quad9::build_side_ptr (const unsigned int i,
bool proxy)
{
libmesh_assert_less (i, this->n_sides());
if (proxy)
return libmesh_make_unique<Side<Edge3,Quad9>>(this,i);
else
{
std::unique_ptr<Elem> edge = libmesh_make_unique<Edge3>();
edge->subdomain_id() = this->subdomain_id();
// Set the nodes
for (unsigned n=0; n<edge->n_nodes(); ++n)
edge->set_node(n) = this->node_ptr(Quad9::side_nodes_map[i][n]);
return edge;
}
}
void Quad9::connectivity(const unsigned int sf,
const IOPackage iop,
std::vector<dof_id_type> & conn) const
{
libmesh_assert_less (sf, this->n_sub_elem());
libmesh_assert_not_equal_to (iop, INVALID_IO_PACKAGE);
conn.resize(4);
switch (iop)
{
case TECPLOT:
{
switch(sf)
{
case 0:
// linear sub-quad 0
conn[0] = this->node_id(0)+1;
conn[1] = this->node_id(4)+1;
conn[2] = this->node_id(8)+1;
conn[3] = this->node_id(7)+1;
return;
case 1:
// linear sub-quad 1
conn[0] = this->node_id(4)+1;
conn[1] = this->node_id(1)+1;
conn[2] = this->node_id(5)+1;
conn[3] = this->node_id(8)+1;
return;
case 2:
// linear sub-quad 2
conn[0] = this->node_id(7)+1;
conn[1] = this->node_id(8)+1;
conn[2] = this->node_id(6)+1;
conn[3] = this->node_id(3)+1;
return;
case 3:
// linear sub-quad 3
conn[0] = this->node_id(8)+1;
conn[1] = this->node_id(5)+1;
conn[2] = this->node_id(2)+1;
conn[3] = this->node_id(6)+1;
return;
default:
libmesh_error_msg("Invalid sf = " << sf);
}
}
case VTK:
{
conn.resize(9);
conn[0] = this->node_id(0);
conn[1] = this->node_id(1);
conn[2] = this->node_id(2);
conn[3] = this->node_id(3);
conn[4] = this->node_id(4);
conn[5] = this->node_id(5);
conn[6] = this->node_id(6);
conn[7] = this->node_id(7);
conn[8] = this->node_id(8);
return;
/*
switch(sf)
{
case 0:
// linear sub-quad 0
conn[0] = this->node_id(0);
conn[1] = this->node_id(4);
conn[2] = this->node_id(8);
conn[3] = this->node_id(7);
return;
case 1:
// linear sub-quad 1
conn[0] = this->node_id(4);
conn[1] = this->node_id(1);
conn[2] = this->node_id(5);
conn[3] = this->node_id(8);
return;
case 2:
// linear sub-quad 2
conn[0] = this->node_id(7);
conn[1] = this->node_id(8);
conn[2] = this->node_id(6);
conn[3] = this->node_id(3);
return;
case 3:
// linear sub-quad 3
conn[0] = this->node_id(8);
conn[1] = this->node_id(5);
conn[2] = this->node_id(2);
conn[3] = this->node_id(6);
return;
default:
libmesh_error_msg("Invalid sf = " << sf);
}*/
}
default:
libmesh_error_msg("Unsupported IO package " << iop);
}
}
BoundingBox Quad9::loose_bounding_box () const
{
// This might have curved edges, or might be a curved surface in
// 3-space, in which case the full bounding box can be larger than
// the bounding box of just the nodes.
//
//
// FIXME - I haven't yet proven the formula below to be correct for
// biquadratics - RHS
Point pmin, pmax;
for (unsigned d=0; d<LIBMESH_DIM; ++d)
{
const Real center = this->point(8)(d);
Real hd = std::abs(center - this->point(0)(d));
for (unsigned int p=0; p != 8; ++p)
hd = std::max(hd, std::abs(center - this->point(p)(d)));
pmin(d) = center - hd;
pmax(d) = center + hd;
}
return BoundingBox(pmin, pmax);
}
Real Quad9::volume () const
{
// Make copies of our points. It makes the subsequent calculations a bit
// shorter and avoids dereferencing the same pointer multiple times.
Point
x0 = point(0), x1 = point(1), x2 = point(2),
x3 = point(3), x4 = point(4), x5 = point(5),
x6 = point(6), x7 = point(7), x8 = point(8);
// Construct constant data vectors.
// \vec{x}_{\xi} = \vec{a1}*xi*eta^2 + \vec{b1}*eta**2 + \vec{c1}*xi*eta + \vec{d1}*xi + \vec{e1}*eta + \vec{f1}
// \vec{x}_{\eta} = \vec{a2}*xi^2*eta + \vec{b2}*xi**2 + \vec{c2}*xi*eta + \vec{d2}*xi + \vec{e2}*eta + \vec{f2}
// This is copy-pasted directly from the output of a Python script.
Point
a1 = x0/2 + x1/2 + x2/2 + x3/2 - x4 - x5 - x6 - x7 + 2*x8,
b1 = -x0/4 + x1/4 + x2/4 - x3/4 - x5/2 + x7/2,
c1 = -x0/2 - x1/2 + x2/2 + x3/2 + x4 - x6,
d1 = x5 + x7 - 2*x8,
e1 = x0/4 - x1/4 + x2/4 - x3/4,
f1 = x5/2 - x7/2,
a2 = a1,
b2 = -x0/4 - x1/4 + x2/4 + x3/4 + x4/2 - x6/2,
c2 = -x0/2 + x1/2 + x2/2 - x3/2 - x5 + x7,
d2 = x0/4 - x1/4 + x2/4 - x3/4,
e2 = x4 + x6 - 2*x8,
f2 = -x4/2 + x6/2;
// 3x3 quadrature, exact for bi-quintics
const unsigned int N = 3;
const Real q[N] = {-std::sqrt(15)/5., 0., std::sqrt(15)/5.};
const Real w[N] = {5./9, 8./9, 5./9};
Real vol=0.;
for (unsigned int i=0; i<N; ++i)
for (unsigned int j=0; j<N; ++j)
vol += w[i] * w[j] *
cross_norm(q[i]*q[j]*q[j]*a1 + q[j]*q[j]*b1 + q[j]*q[i]*c1 + q[i]*d1 + q[j]*e1 + f1,
q[i]*q[i]*q[j]*a2 + q[i]*q[i]*b2 + q[j]*q[i]*c2 + q[i]*d2 + q[j]*e2 + f2);
return vol;
}
unsigned int Quad9::n_second_order_adjacent_vertices (const unsigned int n) const
{
switch (n)
{
case 4:
case 5:
case 6:
case 7:
return 2;
case 8:
return 4;
default:
libmesh_error_msg("Invalid n = " << n);
}
}
unsigned short int Quad9::second_order_adjacent_vertex (const unsigned int n,
const unsigned int v) const
{
libmesh_assert_greater_equal (n, this->n_vertices());
libmesh_assert_less (n, this->n_nodes());
switch (n)
{
case 8:
{
libmesh_assert_less (v, 4);
return static_cast<unsigned short int>(v);
}
default:
{
libmesh_assert_less (v, 2);
// use the matrix that we inherited from \p Quad
return _second_order_adjacent_vertices[n-this->n_vertices()][v];
}
}
}
std::pair<unsigned short int, unsigned short int>
Quad9::second_order_child_vertex (const unsigned int n) const
{
libmesh_assert_greater_equal (n, this->n_vertices());
libmesh_assert_less (n, this->n_nodes());
/*
* the _second_order_vertex_child_* vectors are
* stored in face_quad.C, since they are identical
* for Quad8 and Quad9 (for the first 4 higher-order nodes)
*/
return std::pair<unsigned short int, unsigned short int>
(_second_order_vertex_child_number[n],
_second_order_vertex_child_index[n]);
}
} // namespace libMesh
| Java |
/***************************************************************************
* Copyright (C) 2011-2015 by Fabrizio Montesi <famontesi@gmail.com> *
* *
* This program is free software; you can redistribute it and/or modify *
* it under the terms of the GNU Library General Public License as *
* published by the Free Software Foundation; either version 2 of the *
* License, or (at your option) any later version. *
* *
* This program is distributed in the hope that it will be useful, *
* but WITHOUT ANY WARRANTY; without even the implied warranty of *
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
* GNU General Public License for more details. *
* *
* You should have received a copy of the GNU Library General Public *
* License along with this program; if not, write to the *
* Free Software Foundation, Inc., *
* 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. *
* *
* For details about the authors of this software, see the AUTHORS file. *
***************************************************************************/
package jolie.runtime.typing;
import jolie.lang.Constants;
/**
*
* @author Fabrizio Montesi
*/
public class TypeCastingException extends Exception {
public final static long serialVersionUID = Constants.serialVersionUID();
public TypeCastingException() {
super();
}
public TypeCastingException( String message ) {
super( message );
}
/*
* @Override public Throwable fillInStackTrace() { return this; }
*/
}
| Java |
/*
* bsb2png.c - Convert a bsb raster image to a Portable Network Graphics (png).
* See http://www.libpng.org for details of the PNG format and how
* to use libpng.
*
* Copyright (C) 2004 Stefan Petersen <spetm@users.sourceforge.net>
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
* version 2.1 of the License, or (at your option) any later version.
*
* This library is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
* Lesser General Public License for more details.
*
* You should have received a copy of the GNU Lesser General Public
* License along with this library; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
*
* $Id: bsb2png.c,v 1.7 2007/02/05 17:08:18 mikrom Exp $
*
*/
#include <stdlib.h>
#include <stdio.h>
#include <bsb.h>
#include <png.h>
static void copy_bsb_to_png(BSBImage *image, png_structp png_ptr)
{
int row, bp, pp;
uint8_t *bsb_row, *png_row;
bsb_row = (uint8_t *)malloc(image->height * sizeof(uint8_t *));
png_row = (uint8_t *)malloc(image->height * sizeof(uint8_t *) * image->depth);
/* Copy row by row */
for (row = 0; row < image->height; row++)
{
bsb_seek_to_row(image, row);
bsb_read_row(image, bsb_row);
for (bp = 0, pp = 0; bp < image->width; bp++)
{
png_row[pp++] = image->red[bsb_row[bp]];
png_row[pp++] = image->green[bsb_row[bp]];
png_row[pp++] = image->blue[bsb_row[bp]];
}
png_write_row(png_ptr, png_row);
}
free(bsb_row);
free(png_row);
} /* copy_bsb_to_png */
int main(int argc, char *argv[])
{
BSBImage image;
FILE *png_fd;
png_structp png_ptr;
png_infop info_ptr;
png_text text[2];
if (argc != 3) {
fprintf(stderr, "Usage:\n\tbsb2png input.kap output.png\n");
exit(1);
}
png_ptr = png_create_write_struct(PNG_LIBPNG_VER_STRING, NULL, NULL, NULL);
if (png_ptr == NULL) {
fprintf(stderr, "png_ptr == NULL\n");
exit(1);
}
info_ptr = png_create_info_struct(png_ptr);
if (info_ptr == NULL) {
fprintf(stderr, "info_ptr == NULL\n");
png_destroy_write_struct(&png_ptr, (png_infopp)NULL);
exit(1);
}
if ((png_fd = fopen(argv[2], "wb")) == NULL) {
perror("fopen");
exit(1);
}
png_init_io(png_ptr, png_fd);
if (! bsb_open_header(argv[1], &image)) {
exit(1);
}
png_set_IHDR(png_ptr, info_ptr, image.width, image.height, 8,
PNG_COLOR_TYPE_RGB, PNG_INTERLACE_NONE,
PNG_COMPRESSION_TYPE_DEFAULT, PNG_FILTER_TYPE_DEFAULT);
/* Some text to go with the png image */
text[0].key = "Title";
text[0].text = argv[2];
text[0].compression = PNG_TEXT_COMPRESSION_NONE;
text[1].key = "Generator";
text[1].text = "bsb2png";
text[1].compression = PNG_TEXT_COMPRESSION_NONE;
png_set_text(png_ptr, info_ptr, text, 2);
/* Write header data */
png_write_info(png_ptr, info_ptr);
/* Copy the image in itself */
copy_bsb_to_png(&image, png_ptr);
png_write_end(png_ptr, NULL);
fclose(png_fd);
png_destroy_write_struct(&png_ptr, &info_ptr);
bsb_close(&image);
return 0;
}
| Java |
/******************************************************************************
*
* Copyright (C) 2006-2015 by
* The Salk Institute for Biological Studies and
* Pittsburgh Supercomputing Center, Carnegie Mellon University
*
* This program is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301,
* USA.
*
******************************************************************************/
#include "config.h"
#include "logging.h"
#include "mem_util.h"
#include <stdio.h>
#include <stdlib.h>
#undef _XOPEN_SOURCE
#define _XOPEN_SOURCE 600
#include <string.h>
/* Our log file */
static FILE *mcell_log_file = NULL;
/* Our warning/error file */
static FILE *mcell_error_file = NULL;
/* Get the log file. */
FILE *mcell_get_log_file(void) {
if (mcell_log_file == NULL) {
#ifdef DEBUG
setvbuf(stdout, NULL, _IONBF, 0);
#endif
mcell_log_file = stdout;
}
return mcell_log_file;
}
/* Get the error file. */
FILE *mcell_get_error_file(void) {
if (mcell_error_file == NULL) {
#ifdef DEBUG
setvbuf(stderr, NULL, _IONBF, 0);
#endif
mcell_error_file = stderr;
}
return mcell_error_file;
}
/* Set the log file. */
void mcell_set_log_file(FILE *f) {
if (mcell_log_file != NULL && mcell_log_file != stdout &&
mcell_log_file != stderr)
fclose(mcell_log_file);
mcell_log_file = f;
#ifdef DEBUG
setvbuf(mcell_log_file, NULL, _IONBF, 0);
#else
setvbuf(mcell_log_file, NULL, _IOLBF, 128);
#endif
}
/* Set the error file. */
void mcell_set_error_file(FILE *f) {
if (mcell_error_file != NULL && mcell_error_file != stdout &&
mcell_error_file != stderr)
fclose(mcell_error_file);
mcell_error_file = f;
#ifdef DEBUG
setvbuf(mcell_error_file, NULL, _IONBF, 0);
#else
setvbuf(mcell_error_file, NULL, _IOLBF, 128);
#endif
}
/* Log a message. */
void mcell_log_raw(char const *fmt, ...) {
va_list args;
va_start(args, fmt);
mcell_logv_raw(fmt, args);
va_end(args);
}
/* Log a message (va_list version). */
void mcell_logv_raw(char const *fmt, va_list args) {
vfprintf(mcell_get_log_file(), fmt, args);
}
/* Log a message. */
void mcell_error_raw(char const *fmt, ...) {
va_list args;
va_start(args, fmt);
mcell_errorv_raw(fmt, args);
va_end(args);
}
/* Log a message (va_list version). */
void mcell_errorv_raw(char const *fmt, va_list args) {
vfprintf(mcell_get_error_file(), fmt, args);
}
/* Log a message. */
void mcell_log(char const *fmt, ...) {
va_list args;
va_start(args, fmt);
mcell_logv(fmt, args);
va_end(args);
}
/* Log a message (va_list version). */
void mcell_logv(char const *fmt, va_list args) {
mcell_logv_raw(fmt, args);
fprintf(mcell_get_log_file(), "\n");
}
/* Log a warning. */
void mcell_warn(char const *fmt, ...) {
va_list args;
va_start(args, fmt);
mcell_warnv(fmt, args);
va_end(args);
}
/* Log a warning (va_list version). */
void mcell_warnv(char const *fmt, va_list args) {
fprintf(mcell_get_error_file(), "Warning: ");
mcell_errorv_raw(fmt, args);
fprintf(mcell_get_error_file(), "\n");
}
/* Log an error and carry on. */
void mcell_error_nodie(char const *fmt, ...) {
va_list args;
va_start(args, fmt);
mcell_errorv_nodie(fmt, args);
va_end(args);
}
/* Log an error and carry on (va_list version). */
void mcell_errorv_nodie(char const *fmt, va_list args) {
fprintf(mcell_get_error_file(), "Fatal error: ");
mcell_errorv_raw(fmt, args);
fprintf(mcell_get_error_file(), "\n");
}
/* Log an error and exit. */
void mcell_error(char const *fmt, ...) {
va_list args;
va_start(args, fmt);
mcell_errorv(fmt, args);
va_end(args);
}
/* Log an error and exit (va_list version). */
void mcell_errorv(char const *fmt, va_list args) {
mcell_errorv_nodie(fmt, args);
mcell_die();
}
/* Log an internal error and exit. */
void mcell_internal_error_(char const *file, unsigned int line,
char const *func, char const *fmt, ...) {
va_list args;
va_start(args, fmt);
mcell_internal_errorv_(file, line, func, fmt, args);
va_end(args);
}
/* Log an error and exit (va_list version). */
void mcell_internal_errorv_(char const *file, unsigned int line,
char const *func, char const *fmt, va_list args) {
fprintf(mcell_get_error_file(), "****************\n");
fprintf(mcell_get_error_file(), "INTERNAL ERROR at %s:%u [%s]: ", file, line,
func);
mcell_errorv_raw(fmt, args);
fprintf(mcell_get_error_file(), "\n");
fprintf(mcell_get_error_file(),
"MCell has detected an internal program error.\n");
fprintf(mcell_get_error_file(),
"Please report this error to the MCell developers at <%s>.\n",
PACKAGE_BUGREPORT);
fprintf(mcell_get_error_file(), "****************\n");
mcell_die();
}
/* Get a copy of a string giving an error message. */
char *mcell_strerror(int err) {
char buffer[2048];
#ifdef STRERROR_R_CHAR_P
char *pbuf = strerror_r(err, buffer, sizeof(buffer));
if (pbuf != NULL)
return CHECKED_STRDUP(pbuf, "error description");
else
return CHECKED_SPRINTF("UNIX error code %d.", err);
#else
if (strerror_r(err, buffer, sizeof(buffer)) == 0)
return CHECKED_STRDUP(buffer, "error description");
else
return CHECKED_SPRINTF("UNIX error code %d.", err);
#endif
}
/* Log an error due to a failed standard library call, and exit. */
void mcell_perror_nodie(int err, char const *fmt, ...) {
va_list args;
va_start(args, fmt);
mcell_perrorv_nodie(err, fmt, args);
va_end(args);
}
/* Log an error due to a failed standard library call, and exit (va_list
* version). */
void mcell_perrorv_nodie(int err, char const *fmt, va_list args) {
char buffer[2048];
fprintf(mcell_get_error_file(), "Fatal error: ");
mcell_errorv_raw(fmt, args);
#ifdef STRERROR_R_CHAR_P
fprintf(mcell_get_error_file(), ": %s\n",
strerror_r(err, buffer, sizeof(buffer)));
#else
if (strerror_r(err, buffer, sizeof(buffer)) == 0)
fprintf(mcell_get_error_file(), ": %s\n", buffer);
else
fprintf(mcell_get_error_file(), "\n");
#endif
}
/* Log an error due to a failed standard library call, and exit. */
void mcell_perror(int err, char const *fmt, ...) {
va_list args;
va_start(args, fmt);
mcell_perrorv(err, fmt, args);
va_end(args);
}
/* Log an error due to a failed standard library call, and exit (va_list
* version). */
void mcell_perrorv(int err, char const *fmt, va_list args) {
mcell_perrorv_nodie(err, fmt, args);
mcell_die();
}
/* Log an error due to failed memory allocation, but do not exit. */
void mcell_allocfailed_nodie(char const *fmt, ...) {
va_list args;
va_start(args, fmt);
mcell_allocfailedv_nodie(fmt, args);
va_end(args);
}
/* Log an error due to failed memory allocation, but do not exit (va_list
* version). */
void mcell_allocfailedv_nodie(char const *fmt, va_list args) {
fprintf(mcell_get_error_file(), "Fatal error: ");
mcell_errorv_raw(fmt, args);
fprintf(mcell_get_error_file(), "\n");
fprintf(mcell_get_error_file(), "Fatal error: Out of memory\n\n");
mem_dump_stats(mcell_get_error_file());
}
/* Log an error due to failed memory allocation, and exit. */
void mcell_allocfailed(char const *fmt, ...) {
va_list args;
va_start(args, fmt);
mcell_allocfailedv_nodie(fmt, args);
va_end(args);
mcell_die();
}
/* Log an error due to failed memory allocation, and exit (va_list version). */
void mcell_allocfailedv(char const *fmt, va_list args) {
mcell_allocfailedv_nodie(fmt, args);
mcell_die();
}
/* Terminate program execution due to an error. */
void mcell_die(void) { exit(EXIT_FAILURE); }
| Java |
/* mgrp_test.c
*
* Test messenger group broadcast/receive functionality and concurrency.
* Each thread broadcasts a counter from 0 to ITERS, to all other threads
* (but not itself).
* Every receiving thread should sum received integers into a per-thread
* rx_sum variable.
* Every thread should accumulate the same rx_sum, which is:
* (ITERS -1) * ITERS * (THREAD_CNT -1) * 0.5
* (see memorywell/test/well_test.c for more details).
*
* (c) 2018 Sirio Balmelli and Anthony Soenen
*/
#include <ndebug.h>
#include <posigs.h> /* use atomic PSG kill flag as a global error flag */
#include <pcg_rand.h>
#include <messenger.h>
#include <pthread.h>
#include <stdbool.h>
#include <unistd.h>
#include <fcntl.h>
#define THREAD_CNT 2
#define ITERS 2 /* How many messages each thread should send.
* TODO: increase once registration/rcu issue is resolved.
*/
/* thread()
*/
void *thread(void* arg)
{
struct mgrp *group = arg;
int pvc[2] = { 0, 0 };
size_t rx_sum = 0, rx_i = 0;
size_t message;
NB_die_if(
pipe(pvc)
|| fcntl(pvc[0], F_SETFL, fcntl(pvc[0], F_GETFL) | O_NONBLOCK)
, "");
NB_die_if(
mgrp_subscribe(group, pvc[1])
, "");
/* Don't start broadcasting until everyone is subscribed.
* We could use pthread_barrier_t but that's not implemented on macOS,
* and anyways messenger()'s mgrp_count uses acquire/release semantics.
*/
while (mgrp_count(group) != THREAD_CNT && !psg_kill_check())
sched_yield();
/* generate ITERS broadcasts; receive others' broadcasts */
for (size_t i = 0; i < ITERS && !psg_kill_check(); i++) {
NB_die_if(
mgrp_broadcast(group, pvc[1], &i, sizeof(i))
, "");
while ((mg_recv(pvc[0], &message) > 0) && !psg_kill_check()) {
rx_sum += message;
rx_i++;
sched_yield(); /* prevent deadlock: give other threads a chance to write */
}
errno = 0; /* _should_ be EINVAL: don't pollute later prints */
}
/* wait for all other senders */
while (rx_i < ITERS * (THREAD_CNT -1) && !psg_kill_check()) {
if ((mg_recv(pvc[0], &message) > 0)) {
rx_sum += message;
rx_i++;
} else {
sched_yield();
}
}
die:
NB_err_if(
mgrp_unsubscribe(group, pvc[1])
, "fd %d unsubscribe fail", pvc[1]);
if (err_cnt)
psg_kill();
if (pvc[0]) {
close(pvc[1]);
close(pvc[0]);
}
return (void *)rx_sum;
}
/* main()
*/
int main()
{
int err_cnt = 0;
struct mgrp *group = NULL;
pthread_t threads[THREAD_CNT];
NB_die_if(!(
group = mgrp_new()
), "");
/* run all threads */
for (unsigned int i=0; i < THREAD_CNT; i++) {
NB_die_if(pthread_create(&threads[i], NULL, thread, group), "");
}
/* test results */
size_t expected = (ITERS -1) * ITERS * (THREAD_CNT -1) * 0.5;
for (unsigned int i=0; i < THREAD_CNT; i++) {
size_t rx_sum;
NB_die_if(
pthread_join(threads[i], (void **)&rx_sum)
, "");
NB_err_if(rx_sum != expected,
"thread %zu != expected %zu", rx_sum, expected);
}
die:
mgrp_free(group);
err_cnt += psg_kill_check(); /* return any error from any thread */
return err_cnt;
}
| Java |
/* Copyright 2010, 2011 Michael Steinert
* This file is part of Log4g.
*
* Log4g is free software: you can redistribute it and/or modify it under the
* terms of the GNU Lesser General Public License as published by the Free
* Software Foundation, either version 2.1 of the License, or (at your option)
* any later version.
*
* Log4g is distributed in the hope that it will be useful, but WITHOUT ANY
* WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
* FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for
* more details.
*
* You should have received a copy of the GNU Lesser General Public License
* along with Log4g. If not, see <http://www.gnu.org/licenses/>.
*/
/**
* SECTION: logging-event
* @short_description: The internal representation of logging events
*
* Once an affirmative decision is made to log an event a logging event
* instance is created. This instance is passed to appenders and filters to
* perform actual logging.
*
* <note><para>
* This class is only useful to those wishing to extend Log4g.
* </para></note>
*/
#ifdef HAVE_CONFIG_H
#include "config.h"
#endif
#include <errno.h>
#include "log4g/helpers/thread.h"
#include "log4g/logging-event.h"
#include "log4g/mdc.h"
#include "log4g/ndc.h"
G_DEFINE_TYPE(Log4gLoggingEvent, log4g_logging_event, G_TYPE_OBJECT)
#define ASSIGN_PRIVATE(instance) \
(G_TYPE_INSTANCE_GET_PRIVATE(instance, LOG4G_TYPE_LOGGING_EVENT, \
struct Private))
#define GET_PRIVATE(instance) \
((struct Private *)((Log4gLoggingEvent *)instance)->priv)
struct Private {
gchar *logger;
Log4gLevel *level;
gchar *message;
GTimeVal timestamp;
gboolean thread_lookup_required;
gchar *thread;
gboolean ndc_lookup_required;
gchar *ndc;
gboolean mdc_lookup_required;
GHashTable *mdc;
const gchar *function;
const gchar *file;
const gchar *line;
gchar *fullinfo;
GArray *keys;
};
static void
log4g_logging_event_init(Log4gLoggingEvent *self)
{
self->priv = ASSIGN_PRIVATE(self);
struct Private *priv = GET_PRIVATE(self);
priv->thread_lookup_required = TRUE;
priv->ndc_lookup_required = TRUE;
priv->mdc_lookup_required = TRUE;
}
static void
dispose(GObject *base)
{
struct Private *priv = GET_PRIVATE(base);
if (priv->level) {
g_object_unref(priv->level);
priv->level = NULL;
}
G_OBJECT_CLASS(log4g_logging_event_parent_class)->dispose(base);
}
static void
finalize(GObject *base)
{
struct Private *priv = GET_PRIVATE(base);
g_free(priv->logger);
g_free(priv->message);
g_free(priv->ndc);
g_free(priv->fullinfo);
g_free(priv->thread);
if (priv->mdc) {
g_hash_table_destroy(priv->mdc);
}
if (priv->keys) {
g_array_free(priv->keys, TRUE);
}
G_OBJECT_CLASS(log4g_logging_event_parent_class)->finalize(base);
}
static void
log4g_logging_event_class_init(Log4gLoggingEventClass *klass)
{
GObjectClass *object_class = G_OBJECT_CLASS(klass);
object_class->dispose = dispose;
object_class->finalize = finalize;
GTimeVal start;
g_get_current_time(&start);
klass->start = (start.tv_sec * 1000) + (start.tv_usec * 0.001);
g_type_class_add_private(klass, sizeof(struct Private));
}
/**
* log4g_logging_event_new:
* @logger: The name of the logger that is creating this event.
* @level: The log level of this event.
* @function: The function where this event was logged.
* @file: The file where this event was logged.
* @line: The line in @file where this event was logged.
* @message: A printf formatted log message.
* @ap: Format parameters.
*
* Create a new logging event.
*
* Returns: A new logging event object.
* Since: 0.1
*/
Log4gLoggingEvent *
log4g_logging_event_new(const gchar *logger, Log4gLevel *level,
const gchar *function, const gchar *file, const gchar *line,
const gchar *message, va_list ap)
{
Log4gLoggingEvent *self = g_object_new(LOG4G_TYPE_LOGGING_EVENT, NULL);
if (!self) {
return NULL;
}
struct Private *priv = GET_PRIVATE(self);
if (logger) {
priv->logger = g_strdup(logger);
if (!priv->logger) {
goto error;
}
}
if (level) {
g_object_ref(level);
priv->level = level;
}
if (message) {
priv->message = g_strdup_vprintf(message, ap);
if (!priv->message) {
goto error;
}
}
priv->function = function;
priv->file = file;
priv->line = line;
g_get_current_time(&priv->timestamp);
return self;
error:
g_object_unref(self);
return NULL;
}
/**
* log4g_logging_event_get_level:
* @self: A logging event object.
*
* Calls the @get_level function from the #Log4gLoggingEventClass of @self.
*
* Returns: (transfer none): The log level of @self.
* Since: 0.1
*/
Log4gLevel *
log4g_logging_event_get_level(Log4gLoggingEvent *self)
{
struct Private *priv = GET_PRIVATE(self);
return priv->level;
}
/**
* log4g_logging_event_get_logger_name:
* @self: A logging event object.
*
* Retrieve the name of the logger that created a logging event.
*
* Returns: The name of the logger that created @self.
* Since: 0.1
*/
const gchar *
log4g_logging_event_get_logger_name(Log4gLoggingEvent *self)
{
return GET_PRIVATE(self)->logger;
}
/**
* log4g_logging_event_get_rendered_message:
* @self: A logging event object.
*
* Retrieve the rendered logging message.
*
* See: log4g_logging_event_get_message()
*
* Returns: The rendered logging message.
* Since: 0.1
*/
const gchar *
log4g_logging_event_get_rendered_message(Log4gLoggingEvent *self)
{
return GET_PRIVATE(self)->message;
}
/**
* log4g_logging_event_get_message:
* @self: A logging event object.
*
* Retrieve the log message.
*
* This function is equivalent to log4g_logging_event_get_rendered_message().
*
* Returns: The log message.
* Since: 0.1
*/
const gchar *
log4g_logging_event_get_message(Log4gLoggingEvent *self)
{
return GET_PRIVATE(self)->message;
}
/**
* log4g_logging_event_get_mdc:
* @self: A logging event object.
* @key: A mapped data context key.
*
* Retrieve a mapped data context value for a logging event.
*
* See: #Log4gMDC
*
* Returns: The MDC value for @key.
* Since: 0.1
*/
const gchar *
log4g_logging_event_get_mdc(Log4gLoggingEvent *self, const gchar *key)
{
struct Private *priv = GET_PRIVATE(self);
if (priv->mdc) {
const gchar *value = g_hash_table_lookup(priv->mdc, key);
if (value) {
return value;
}
}
if (priv->mdc_lookup_required) {
return log4g_mdc_get(key);
}
return NULL;
}
/**
* log4g_logging_event_get_time_stamp:
* @self: A logging event object.
*
* Retrieve the timestamp of a logging event.
*
* Returns: (transfer none): The timestamp of @self.
* Since: 0.1
*/
const GTimeVal *
log4g_logging_event_get_time_stamp(Log4gLoggingEvent *self)
{
return &GET_PRIVATE(self)->timestamp;
}
/**
* log4g_logging_event_get_thread_name:
* @self: A logging event object.
*
* Retrieve the name of the thread where a logging event was logged.
*
* Returns: The name of the thread where @self was logged.
* Since: 0.1
*/
const gchar *
log4g_logging_event_get_thread_name(Log4gLoggingEvent *self)
{
struct Private *priv = GET_PRIVATE(self);
if (priv->thread) {
return priv->thread;
}
if (priv->thread_lookup_required) {
return log4g_thread_get_name();
}
return NULL;
}
/**
* log4g_logging_event_get_ndc:
* @self: A logging event object.
*
* Retrieve the nested data context for a logging event.
*
* See: #Log4gNDC
*
* Returns: The rendered NDC string for @self.
* Since: 0.1
*/
const gchar *
log4g_logging_event_get_ndc(Log4gLoggingEvent *self)
{
struct Private *priv = GET_PRIVATE(self);
if (priv->ndc) {
return priv->ndc;
}
if (priv->ndc_lookup_required) {
return log4g_ndc_get();
}
return NULL;
}
/**
* get_keys_:
* @key: The hash table key.
* @value: The hash table value (unused).
* @user_data: An array to append @key to.
*
* Callback for g_hash_table_foreach().
*/
static void
get_keys_(gpointer key, G_GNUC_UNUSED gpointer value, gpointer user_data)
{
g_array_append_val((GArray *)user_data, key);
}
/**
* get_property_key_set_:
* @self: A logging event object.
* @mdc: The hash table to get keys from.
*
* Construct a key set from an MDC hash table.
*/
static void
get_property_key_set_(Log4gLoggingEvent *self, GHashTable *mdc)
{
guint size = g_hash_table_size((GHashTable *)mdc);
struct Private *priv = GET_PRIVATE(self);
if (!size) {
return;
}
if (priv->keys) {
g_array_free(priv->keys, TRUE);
}
priv->keys = g_array_sized_new(FALSE, FALSE, sizeof(gchar *), size);
if (!priv->keys) {
return;
}
g_hash_table_foreach(mdc, get_keys_, priv->keys);
}
/**
* log4g_logging_event_get_property_key_set:
* @self: A logging event object.
*
* Get the MDC keys (if any) for this event.
*
* See: #Log4gMDC
*
* Returns: An array of keys, or %NULL if no keys exist.
* Since: 0.1
*/
const GArray *
log4g_logging_event_get_property_key_set(Log4gLoggingEvent *self)
{
struct Private *priv = GET_PRIVATE(self);
if (priv->mdc) {
if (!priv->keys) {
get_property_key_set_(self, priv->mdc);
}
} else {
const GHashTable *mdc = log4g_mdc_get_context();
if (mdc) {
get_property_key_set_(self, (GHashTable *)mdc);
}
}
return priv->keys;
}
/**
* mdc_copy_:
* @key: The hash table key.
* @value: The hash table value (unused).
* @user_data: A hash table to insert @key & @value into.
*
* Callback for g_hash_table_foreach().
*/
static void
mdc_copy_(gpointer key, gpointer value, gpointer user_data)
{
g_hash_table_insert((GHashTable *)user_data, key, value);
}
/**
* log4g_logging_event_get_thread_copy:
* @self: A logging event object.
*
* Copy the current thread name into a logging object.
*
* Asynchronous appenders should call this function.
*
* See: #Log4gThreadClass
*/
void
log4g_logging_event_get_thread_copy(Log4gLoggingEvent *self)
{
struct Private *priv = GET_PRIVATE(self);
if (!priv->thread_lookup_required) {
return;
}
priv->thread_lookup_required = FALSE;
priv->thread = g_strdup(log4g_thread_get_name());
}
/**
* log4g_logging_event_get_mdc_copy:
* @self: A logging event object.
*
* Copy the current mapped data context into a logging event.
*
* Asynchronous appenders should call this function.
*
* See #Log4gMDC
*
* Since: 0.1
*/
void
log4g_logging_event_get_mdc_copy(Log4gLoggingEvent *self)
{
struct Private *priv = GET_PRIVATE(self);
if (!priv->mdc_lookup_required) {
return;
}
const GHashTable *mdc;
priv->mdc_lookup_required = FALSE;
mdc = log4g_mdc_get_context();
if (!mdc) {
return;
}
priv->mdc = g_hash_table_new_full(g_str_hash, g_str_equal,
g_free, g_free);
if (!priv->mdc) {
return;
}
g_hash_table_foreach((GHashTable *)mdc, mdc_copy_, priv->mdc);
}
/**
* log4g_logging_event_get_ndc_copy:
* @self: A logging event object.
*
* Copy the current nested data context into a logging event.
*
* Asynchronous appenders should call this function.
*
* See #Log4gNDC
*
* Since: 0.1
*/
void
log4g_logging_event_get_ndc_copy(Log4gLoggingEvent *self)
{
struct Private *priv = GET_PRIVATE(self);
if (!priv->ndc_lookup_required) {
return;
}
priv->ndc_lookup_required = FALSE;
priv->ndc = g_strdup(log4g_ndc_get());
}
/**
* log4g_logging_event_get_function_name:
* @self: A logging event object.
*
* Retrieve the function where a logging event was logged.
*
* Returns: The function where @self was logged.
* Since: 0.1
*/
const gchar *
log4g_logging_event_get_function_name(Log4gLoggingEvent *self)
{
const gchar *function = GET_PRIVATE(self)->function;
return (function ? function : "?");
}
/**
* log4g_logging_event_get_file_name:
* @self: A logging event object.
*
* Retrieve the file where a logging event was logged.
*
* Returns: The file where @self was logged.
* Since: 0.1
*/
const gchar *
log4g_logging_event_get_file_name(Log4gLoggingEvent *self)
{
const gchar *file = GET_PRIVATE(self)->file;
return (file ? file : "?");
}
/**
* log4g_logging_event_get_line_number:
* @self: A logging event object.
*
* Retrieve the line number where a logging event was logged.
*
* Returns: The line number where @self was logged.
* Since: 0.1
*/
const gchar *
log4g_logging_event_get_line_number(Log4gLoggingEvent *self)
{
const gchar *line = GET_PRIVATE(self)->line;
return (line ? line : "?");
}
/**
* log4g_logging_event_get_full_info:
* @self: A logging event object.
*
* Retrieve the full location information where a logging event was logged.
*
* The full location information is in the format:
*
* |[
* function(file:line)
* ]|
*
* Returns: The full log location information for @self.
* Since: 0.1
*/
const gchar *
log4g_logging_event_get_full_info(Log4gLoggingEvent *self)
{
struct Private *priv = GET_PRIVATE(self);
if (!priv->fullinfo) {
priv->fullinfo = g_strdup_printf("%s(%s:%s)",
(priv->function ? priv->function : "?"),
(priv->file ? priv->file : "?"),
(priv->line ? priv->line : "?"));
}
return priv->fullinfo;
}
/**
* log4g_logging_event_get_start_time:
*
* Retrieve the time when the log system was initialized.
*
* Returns: The number of seconds elapsed since the Unix epoch when the log
* system was initialized
* Since: 0.1
*/
glong
log4g_logging_event_get_start_time(void)
{
Log4gLoggingEventClass *klass =
g_type_class_peek(LOG4G_TYPE_LOGGING_EVENT);
return klass->start;
}
| Java |
/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
* qimsys *
* Copyright (C) 2010-2016 by Tasuku Suzuki <stasuku@gmail.com> *
* Copyright (C) 2016 by Takahiro Hashimoto <kenya888@gmail.com> *
* *
* This program is free software; you can redistribute it and/or modify *
* it under the terms of the GNU General Lesser Public License as *
* published by the Free Software Foundation; either version 2 of the *
* License, or (at your option) any later version. *
* *
* This program is distributed in the hope that it will be useful, *
* but WITHOUT ANY WARRANTY; without even the implied warranty of *
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
* GNU Lesser General Public License for more details. *
* *
* You should have received a copy of the GNU Lesser General Public *
* License along with this program; if not, write to the *
* Free Software Foundation, Inc., *
* 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. *
* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
#include "../qimsysimcontext.h"
#include <gtk/gtk.h>
#include <gdk/gdkx.h>
#include <qimsysdebug.h>
#include <qimsysapplicationmanager.h>
#include <qimsysinputmethodmanager.h>
#include <qimsyskeymanager.h>
#include <qimsyskeyboardmanager.h>
#include <qimsyspreeditmanager.h>
#include <string.h>
#include "../gtk2qt.h"
#define QIMSYS_IM_CONTEXT_GET_PRIVATE(obj) (G_TYPE_INSTANCE_GET_PRIVATE ((obj), QIMSYS_IM_CONTEXT_TYPE, QimsysIMContextPrivate))
struct _QimsysIMContextPrivate
{
GtkIMContext *slave;
QimsysApplicationManager *application_manager;
QimsysInputMethodManager *inputmethod_manager;
QimsysKeyManager *key_manager;
QimsysKeyboardManager *keyboard_manager;
QimsysPreeditManager *preedit_manager;
QimsysPreeditItem *item;
GdkWindow *client_window;
};
static GType _qimsys_im_context_type = 0;
static GtkIMContextClass *_parent_im_context_class = NULL;
static GtkIMContext *_focus_im_context = NULL;
static void qimsys_im_context_class_init(QimsysIMContextClass *klass);
static void qimsys_im_context_init(QimsysIMContext *self);
static void qimsys_im_context_dispose(GObject *object);
static void qimsys_im_context_reset(GtkIMContext *context);
static gboolean qimsys_im_context_filter_keypress(GtkIMContext *context, GdkEventKey *key);
static void qimsys_im_context_focus_in(GtkIMContext *context);
static void qimsys_im_context_focus_out(GtkIMContext *context);
static void qimsys_im_context_get_preedit_string(GtkIMContext *context, gchar **str, PangoAttrList **attrs, gint *cursor_pos);
static void qimsys_im_context_set_client_window(GtkIMContext *context, GdkWindow *client_window);
static void qimsys_im_context_set_cursor_location(GtkIMContext *context, GdkRectangle *area);
static void qimsys_im_context_set_use_preedit(GtkIMContext *context, gboolean use_preedit);
static void qimsys_im_context_set_surrounding(GtkIMContext *context, const gchar *text, gint len, gint cursor_index);
static void qimsys_im_context_get_surrounding(GtkIMContext *context, gchar **text, gint *cursor_index);
static void qimsys_im_context_delete_surrounding(GtkIMContext *context, gint offset, gint n_chars);
static void qimsys_im_context_preedit_item_changed(gpointer data, QimsysPreeditItem *item, QimsysPreeditManager *preedit_manager);
static void qimsys_im_context_preedit_committed(gpointer data, char *text, gulong target, QimsysPreeditManager *preedit_manager);
static void qimsys_im_context_slave_commit(GtkIMContext *slave, char *text, QimsysIMContext *master);
static void qimsys_im_context_slave_preedit_start(GtkIMContext *slave, QimsysIMContext *master);
static void qimsys_im_context_slave_preedit_end(GtkIMContext *slave, QimsysIMContext *master);
static void qimsys_im_context_slave_preedit_changed(GtkIMContext *slave, QimsysIMContext *master);
static void qimsys_im_context_slave_retrieve_surrounding(GtkIMContext *slave, QimsysIMContext *master);
static void qimsys_im_context_slave_delete_surrounding(GtkIMContext *slave, gint offset, gint n_chars, QimsysIMContext *master);
void qimsys_im_context_register_type(GTypeModule *module)
{
static const GTypeInfo qimsys_im_context_info = {
sizeof(QimsysIMContextClass)
, (GBaseInitFunc)NULL
, (GBaseFinalizeFunc)NULL
, (GClassInitFunc)qimsys_im_context_class_init
, (GClassFinalizeFunc)NULL
, (gconstpointer)NULL
, sizeof(QimsysIMContext)
, 0
, (GInstanceInitFunc)qimsys_im_context_init
, (GTypeValueTable *)NULL
};
qimsys_debug_in();
if (!qimsys_im_context_get_type()) {
GType type = g_type_module_register_type(module
, GTK_TYPE_IM_CONTEXT
, "QimsysIMContext"
, &qimsys_im_context_info
, (GTypeFlags)0
);
_qimsys_im_context_type = type;
}
qimsys_debug_out();
}
GType qimsys_im_context_get_type()
{
return _qimsys_im_context_type;
}
QimsysIMContext *qimsys_im_context_new()
{
QimsysIMContext *ret;
qimsys_debug_in();
ret = QIMSYS_IM_CONTEXT(g_object_new(QIMSYS_IM_CONTEXT_TYPE, NULL));
qimsys_debug_out();
return ret;
}
static void qimsys_im_context_class_init(QimsysIMContextClass *klass)
{
GtkIMContextClass *im_context_class;
GObjectClass *gobject_class;
qimsys_debug_in();
_parent_im_context_class = (GtkIMContextClass *)g_type_class_peek_parent(klass);
im_context_class = GTK_IM_CONTEXT_CLASS(klass);
im_context_class->reset = qimsys_im_context_reset;
im_context_class->focus_in = qimsys_im_context_focus_in;
im_context_class->focus_out = qimsys_im_context_focus_out;
im_context_class->filter_keypress = qimsys_im_context_filter_keypress;
im_context_class->get_preedit_string = qimsys_im_context_get_preedit_string;
im_context_class->set_client_window = qimsys_im_context_set_client_window;
im_context_class->set_cursor_location = qimsys_im_context_set_cursor_location;
im_context_class->set_use_preedit = qimsys_im_context_set_use_preedit;
im_context_class->set_surrounding = qimsys_im_context_set_surrounding;
im_context_class->get_surrounding = qimsys_im_context_get_surrounding;
im_context_class->delete_surrounding = qimsys_im_context_delete_surrounding;
gobject_class = G_OBJECT_CLASS(klass);
gobject_class->dispose = qimsys_im_context_dispose;
g_type_class_add_private(klass, sizeof(QimsysIMContextPrivate));
qimsys_debug_out();
}
static void qimsys_im_context_init(QimsysIMContext *self)
{
qimsys_debug_in();
self->d = QIMSYS_IM_CONTEXT_GET_PRIVATE(self);
self->d->slave = gtk_im_context_simple_new();
g_signal_connect(self->d->slave, "commit", G_CALLBACK(qimsys_im_context_slave_commit), self);
g_signal_connect(self->d->slave, "preedit-start", G_CALLBACK(qimsys_im_context_slave_preedit_start), self);
g_signal_connect(self->d->slave, "preedit-end", G_CALLBACK(qimsys_im_context_slave_preedit_end), self);
g_signal_connect(self->d->slave, "preedit-changed", G_CALLBACK(qimsys_im_context_slave_preedit_changed), self);
g_signal_connect(self->d->slave, "retrieve-surrounding", G_CALLBACK(qimsys_im_context_slave_retrieve_surrounding), self);
g_signal_connect(self->d->slave, "delete-surrounding", G_CALLBACK(qimsys_im_context_slave_delete_surrounding), self);
self->d->application_manager = NULL;
self->d->inputmethod_manager = NULL;
self->d->key_manager = NULL;
self->d->keyboard_manager = NULL;
self->d->preedit_manager = NULL;
self->d->item = NULL;
self->d->client_window = NULL;
qimsys_debug_out();
}
static void qimsys_im_context_dispose(GObject *object)
{
QimsysIMContext *self;
qimsys_debug_in();
self = QIMSYS_IM_CONTEXT(object);
qimsys_im_context_set_client_window(GTK_IM_CONTEXT(self), NULL);
if (self->d->item) {
g_object_unref(self->d->item);
}
G_OBJECT_CLASS(_parent_im_context_class)->dispose(object);
qimsys_debug_out();
}
static void qimsys_im_context_reset(GtkIMContext *context)
{
QimsysIMContext *self;
qimsys_debug_in();
self = QIMSYS_IM_CONTEXT(context);
if (self->d->application_manager)
qimsys_application_manager_exec(self->d->application_manager, 0 /* Reset */);
gtk_im_context_reset(self->d->slave);
if (self->d->keyboard_manager) {
qimsys_keyboard_manager_set_visible(self->d->keyboard_manager, TRUE);
}
qimsys_debug_out();
}
static gboolean qimsys_im_context_filter_keypress(GtkIMContext *context, GdkEventKey *event)
{
gboolean ret = FALSE;
QimsysIMContext *self;
int modifiers = 0;
qimsys_debug_in();
qimsys_debug("\ttype = %d\n", event->type);
qimsys_debug("\tsend_event = %d\n", event->send_event);
qimsys_debug("\tstate = %X\n", event->state);
qimsys_debug("\tkeyval = %X(%X)\n", event->keyval, qimsys_gtk2qt_key_convert(event->keyval));
qimsys_debug("\tis_modifier = %d\n", event->is_modifier);
if (event->state & 0x1) modifiers |= 0x02000000;
if (event->state & 0x4) modifiers |= 0x04000000;
if (event->state & 0x8) modifiers |= 0x08000000;
if (event->state & 4000040) modifiers |= 0x10000000;
self = QIMSYS_IM_CONTEXT(context);
if (self->d->key_manager) {
switch (event->type) {
case GDK_KEY_PRESS:
qimsys_key_manager_key_press(self->d->key_manager, event->string, qimsys_gtk2qt_key_convert(event->keyval), modifiers, FALSE, &ret);
break;
case GDK_KEY_RELEASE:
qimsys_key_manager_key_release(self->d->key_manager, event->string, qimsys_gtk2qt_key_convert(event->keyval), modifiers, FALSE, &ret);
break;
default:
break;
}
}
if (!ret) {
ret = gtk_im_context_filter_keypress(self->d->slave, event);
}
qimsys_debug_out();
return ret;
}
static void qimsys_im_context_focus_in(GtkIMContext *context)
{
QimsysIMContext *self;
qimsys_debug_in();
self = QIMSYS_IM_CONTEXT(context);
if (_focus_im_context != NULL && _focus_im_context != GTK_IM_CONTEXT(self)) {
gtk_im_context_focus_out(_focus_im_context);
}
_focus_im_context = GTK_IM_CONTEXT(self);
g_object_ref(_focus_im_context);
if (!self->d->application_manager) {
self->d->application_manager = qimsys_application_manager_new();
}
if (!self->d->inputmethod_manager) {
self->d->inputmethod_manager = qimsys_inputmethod_manager_new();
}
if (!self->d->key_manager) {
self->d->key_manager = qimsys_key_manager_new();
}
if (!self->d->keyboard_manager) {
self->d->keyboard_manager = qimsys_keyboard_manager_new();
if (self->d->keyboard_manager) {
qimsys_keyboard_manager_set_visible(self->d->keyboard_manager, FALSE);
}
}
if (!self->d->preedit_manager) {
self->d->preedit_manager = qimsys_preedit_manager_new();
if (self->d->preedit_manager) {
g_signal_connect_swapped(self->d->preedit_manager, "item-changed", G_CALLBACK(qimsys_im_context_preedit_item_changed), self);
g_signal_connect_swapped(self->d->preedit_manager, "committed", G_CALLBACK(qimsys_im_context_preedit_committed), self);
}
}
if (self->d->application_manager) {
if (self->d->client_window) {
qimsys_application_manager_set_window(self->d->application_manager, gdk_x11_drawable_get_xid(self->d->client_window));
qimsys_application_manager_set_widget(self->d->application_manager, gdk_x11_drawable_get_xid(self->d->client_window));
}
qimsys_application_manager_set_focus(self->d->application_manager, TRUE);
}
gtk_im_context_focus_in(self->d->slave);
qimsys_debug_out();
}
static void qimsys_im_context_focus_out(GtkIMContext *context)
{
QimsysIMContext *self;
gulonglong client_window = 0;
qimsys_debug_in();
self = QIMSYS_IM_CONTEXT(context);
if (_focus_im_context == GTK_IM_CONTEXT(self)) {
g_object_unref(_focus_im_context);
_focus_im_context = NULL;
}
if (self->d->application_manager) {
qimsys_application_manager_set_focus(self->d->application_manager, FALSE);
qimsys_application_manager_get_widget(self->d->application_manager, &client_window);
if (self->d->client_window && gdk_x11_drawable_get_xid(self->d->client_window) == client_window) {
qimsys_application_manager_set_window(self->d->application_manager, 0);
qimsys_application_manager_set_widget(self->d->application_manager, 0);
}
g_object_unref(self->d->application_manager);
self->d->application_manager = NULL;
}
if (self->d->inputmethod_manager) {
g_object_unref(self->d->inputmethod_manager);
self->d->inputmethod_manager = NULL;
}
if (self->d->key_manager) {
g_object_unref(self->d->key_manager);
self->d->key_manager = NULL;
}
if (self->d->keyboard_manager) {
qimsys_keyboard_manager_set_visible(self->d->keyboard_manager, FALSE);
g_object_unref(self->d->keyboard_manager);
self->d->keyboard_manager = NULL;
}
if (self->d->preedit_manager) {
g_object_unref(self->d->preedit_manager);
self->d->preedit_manager = 0;
}
gtk_im_context_focus_out(self->d->slave);
qimsys_debug_out();
}
static void qimsys_im_context_get_preedit_string(GtkIMContext *context, gchar **str, PangoAttrList **attrs, gint *cursor_pos)
{
gboolean ret;
guint i = 0;
QimsysIMContext *self;
QimsysPreeditItem *item;
char *preedit_string;
char **strv_ptr;
char *buf;
int cursor;
int selection = 0;
int start_index = 0;
int end_index = 0;
PangoAttrList *attr_list;
PangoAttribute *attr;
qimsys_debug_in();
self = QIMSYS_IM_CONTEXT(context);
preedit_string = g_strdup("");
cursor = 0;
attr_list = pango_attr_list_new();
if (self->d->application_manager) {
qimsys_application_manager_get_composing(self->d->application_manager, &ret);
if (ret) {
if (self->d->item) {
item = self->d->item;
if (item->cursor >= 0) {
cursor = g_utf8_strlen(preedit_string, -1) + item->cursor;
if (item->selection != 0) {
selection = item->selection;
}
}
qimsys_debug("%s(%d)\n", __FUNCTION__, __LINE__);
attr = pango_attr_underline_new(PANGO_UNDERLINE_SINGLE);
qimsys_debug("%s(%d)\n", __FUNCTION__, __LINE__);
attr->start_index = strlen(preedit_string);
attr->end_index = attr->start_index;
qimsys_debug("%s(%d)\n", __FUNCTION__, __LINE__);
for (strv_ptr = item->to; *strv_ptr != NULL; *strv_ptr++) {
qimsys_debug("%s(%d) %x\n", __FUNCTION__, __LINE__, (void*)*strv_ptr);
qimsys_debug("%s(%d) %s\n", __FUNCTION__, __LINE__, *strv_ptr);
attr->end_index += strlen(*strv_ptr);
}
qimsys_debug("%s(%d)\n", __FUNCTION__, __LINE__);
pango_attr_list_insert(attr_list, attr);
qimsys_debug("%s(%d)\n", __FUNCTION__, __LINE__);
for (strv_ptr = item->to; *strv_ptr != NULL; *strv_ptr++) {
buf = g_strconcat(preedit_string, *strv_ptr, NULL);
g_free(preedit_string);
preedit_string = buf;
}
qimsys_debug("\t%d: %s %d %d %d\n", i, preedit_string, item->cursor, item->selection, item->modified);
if (selection != 0) {
buf = g_strdup(preedit_string);
g_utf8_strncpy(buf, preedit_string, cursor);
start_index = strlen(buf);
qimsys_debug("start_index: %d(%d) - %s\n", start_index, cursor, buf);
g_utf8_strncpy(buf, preedit_string, cursor + selection);
end_index = strlen(buf);
g_free(buf);
qimsys_debug("end_index: %d(%d + %d) - %s\n", end_index, cursor, selection, buf);
attr = pango_attr_foreground_new(0xffff, 0xffff, 0xffff);
attr->start_index = start_index;
attr->end_index = end_index;
pango_attr_list_insert(attr_list, attr);
attr = pango_attr_background_new(0, 0, 0x8fff);
attr->start_index = start_index;
attr->end_index = end_index;
pango_attr_list_insert(attr_list, attr);
}
} else {
// qimsys_preedit_manager_get_item(self->d->preedit_manager, &item);
}
if (str) {
*str = preedit_string;
} else {
g_free(preedit_string);
}
if (cursor_pos) {
*cursor_pos = cursor;
}
if (attrs) {
*attrs = attr_list;
} else {
pango_attr_list_unref(attr_list);
}
} else {
gtk_im_context_get_preedit_string(self->d->slave, str, attrs, cursor_pos);
}
} else {
gtk_im_context_get_preedit_string(self->d->slave, str, attrs, cursor_pos);
}
qimsys_debug_out();
}
static void qimsys_im_context_set_client_window(GtkIMContext *context, GdkWindow *client_window)
{
QimsysIMContext *self;
self = QIMSYS_IM_CONTEXT(context);
if (self->d->client_window == client_window) return;
qimsys_debug_in();
if (self->d->client_window != NULL)
g_object_unref(self->d->client_window);
self->d->client_window = client_window;
if (client_window != NULL) {
g_object_ref(client_window);
}
gtk_im_context_set_client_window(self->d->slave, client_window);
if (self->d->application_manager) {
if (client_window) {
qimsys_application_manager_set_window(self->d->application_manager, gdk_x11_drawable_get_xid(client_window));
qimsys_application_manager_set_widget(self->d->application_manager, gdk_x11_drawable_get_xid(client_window));
} else {
qimsys_application_manager_set_window(self->d->application_manager, 0);
qimsys_application_manager_set_widget(self->d->application_manager, 0);
}
}
qimsys_debug_out();
}
static void qimsys_im_context_set_cursor_location(GtkIMContext *context, GdkRectangle *area)
{
QimsysIMContext *self;
int x = 0;
int y = 0;
qimsys_debug_in();
self = QIMSYS_IM_CONTEXT(context);
if (self->d->client_window) {
gdk_window_get_origin (self->d->client_window, &x, &y);
}
if (self->d->preedit_manager) {
qimsys_preedit_manager_set_rect(self->d->preedit_manager, x + area->x, y + area->y, area->width, area->height);
}
gtk_im_context_set_cursor_location(self->d->slave, area);
qimsys_debug_out();
}
static void qimsys_im_context_set_use_preedit(GtkIMContext *context, gboolean use_preedit)
{
QimsysIMContext *self;
qimsys_debug_in();
self = QIMSYS_IM_CONTEXT(context);
gtk_im_context_set_use_preedit(self->d->slave, use_preedit);
qimsys_debug_out();
}
static void qimsys_im_context_set_surrounding(GtkIMContext *context, const gchar *text, gint len, gint cursor_index)
{
QimsysIMContext *self;
qimsys_debug_in();
self = QIMSYS_IM_CONTEXT(context);
qimsys_debug("text: %s, len: %d, cursor_index, %d\n", text, len, cursor_index);
qimsys_preedit_manager_set_surrounding_text(self->d->preedit_manager, text);
qimsys_preedit_manager_set_cursor_position(self->d->preedit_manager, cursor_index);
// gtk_im_context_set_surrounding(self->d->slave, text, len, cursor_index);
qimsys_debug_out();
}
static void qimsys_im_context_get_surrounding(GtkIMContext *context, gchar **text, gint *cursor_index)
{
QimsysIMContext *self;
qimsys_debug_in();
self = QIMSYS_IM_CONTEXT(context);
qimsys_preedit_manager_get_cursor_position(self->d->preedit_manager, cursor_index);
qimsys_preedit_manager_get_surrounding_text(self->d->preedit_manager, text);
// gtk_im_context_get_surrounding(self->d->slave, text, cursor_index);
qimsys_debug_out();
}
static void qimsys_im_context_delete_surrounding(GtkIMContext *context, gint offset, gint n_chars)
{
QimsysIMContext *self;
qimsys_debug_in();
self = QIMSYS_IM_CONTEXT(context);
qimsys_debug("offset: %d, n_chars: %d\n", offset, n_chars);
// qimsys_preedit_manager_set_surrounding_text(self->d->preedit, text);
gtk_im_context_delete_surrounding(self->d->slave, offset, n_chars);
qimsys_debug_out();
}
static void qimsys_im_context_preedit_item_changed(gpointer data, QimsysPreeditItem *item, QimsysPreeditManager *preedit_manager)
{
QimsysIMContext *context = QIMSYS_IM_CONTEXT(data);
qimsys_debug_in();
if (_focus_im_context == GTK_IM_CONTEXT(context)) {
if (context->d->item) {
// has preedit
g_object_unref(context->d->item);
if (g_strv_length(item->to) > 0) {
context->d->item = item;
g_object_ref(context->d->item);
g_signal_emit_by_name(context, "preedit-changed");
} else {
context->d->item = NULL;
g_signal_emit_by_name(context, "preedit-changed");
g_signal_emit_by_name(context, "preedit-end");
}
} else {
if (g_strv_length(item->to) > 0) {
context->d->item = item;
g_object_ref(context->d->item);
g_signal_emit_by_name(context, "preedit-start");
g_signal_emit_by_name(context, "preedit-changed");
} else {
//
}
}
}
qimsys_debug_out();
}
static void qimsys_im_context_preedit_committed(gpointer data, char *text, gulong target, QimsysPreeditManager *preedit_manager)
{
QimsysIMContext *context = QIMSYS_IM_CONTEXT(data);
qimsys_debug_in();
if (context->d->client_window && target == gdk_x11_drawable_get_xid(context->d->client_window)) { // \todo
g_signal_emit_by_name(context, "commit", text);
}
qimsys_debug_out();
}
static void qimsys_im_context_slave_commit(GtkIMContext *slave, char *text, QimsysIMContext *master)
{
g_signal_emit_by_name(master, "commit", text);
}
static void qimsys_im_context_slave_preedit_start(GtkIMContext *slave, QimsysIMContext *master)
{
g_signal_emit_by_name(master, "preedit-start");
}
static void qimsys_im_context_slave_preedit_end(GtkIMContext *slave, QimsysIMContext *master)
{
g_signal_emit_by_name(master, "preedit-end");
}
static void qimsys_im_context_slave_preedit_changed(GtkIMContext *slave, QimsysIMContext *master)
{
g_signal_emit_by_name(master, "preedit-changed");
}
static void qimsys_im_context_slave_retrieve_surrounding(GtkIMContext *slave, QimsysIMContext *master)
{
g_signal_emit_by_name(master, "retrieve-surrounding");
}
static void qimsys_im_context_slave_delete_surrounding(GtkIMContext *slave, gint offset, gint n_chars, QimsysIMContext *master)
{
g_signal_emit_by_name(master, "delete-surrounding", offset, n_chars);
}
| Java |
/* optiondialog.hpp
*
* Copyright (C) 2010 Martin Skowronski
*
* This program is free software; you can redistribute it and/or modify it
* under the terms of the GNU General Public License as published by the Free
* Software Foundation; either version 2 of the License, or (at your option)
* any later version.
*
* This program is distributed in the hope that it will be useful, but WITHOUT
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for
* more details.
*
* You should have received a copy of the GNU General Public License along with
* this program; if not, write to the Free Software Foundation, Inc., 51
* Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
*/
#ifndef OPTIONDIALOG_HPP
#define OPTIONDIALOG_HPP
#include <QDialog>
namespace Ui {
class OptionDialog;
}
class OptionDialog : public QDialog
{
Q_OBJECT
public:
explicit OptionDialog(QWidget *parent = 0);
~OptionDialog();
private:
Ui::OptionDialog *ui;
};
#endif // OPTIONDIALOG_HPP
| Java |
/*
* Hibernate, Relational Persistence for Idiomatic Java
*
* License: GNU Lesser General Public License (LGPL), version 2.1 or later.
* See the lgpl.txt file in the root directory or <http://www.gnu.org/licenses/lgpl-2.1.html>.
*/
//$Id: $
package org.hibernate.test.join;
/**
* @author Chris Jones
*/
public class Thing {
private Employee salesperson;
private String comments;
/**
* @return Returns the salesperson.
*/
public Employee getSalesperson() {
return salesperson;
}
/**
* @param salesperson The salesperson to set.
*/
public void setSalesperson(Employee salesperson) {
this.salesperson = salesperson;
}
/**
* @return Returns the comments.
*/
public String getComments() {
return comments;
}
/**
* @param comments The comments to set.
*/
public void setComments(String comments) {
this.comments = comments;
}
Long id;
String name;
/**
* @return Returns the ID.
*/
public Long getId() {
return id;
}
/**
* @param id The ID to set.
*/
public void setId(Long id) {
this.id = id;
}
/**
* @return Returns the name.
*/
public String getName() {
return name;
}
/**
* @param name The name to set.
*/
public void setName(String name) {
this.name = name;
}
}
| Java |
<?php
/**
* @package copix
* @subpackage smarty_plugins
* @author Steevan BARBOYON
* @copyright 2001-2007 CopixTeam
* @link http://copix.org
* @license http://www.gnu.org/licenses/lgpl.html GNU Lesser General Public Licence, see LICENCE file
*/
/**
* Smarty {tabs}{/tabs} block plugin
*
* Type: block function
* Name: tabs
* Purpose: make tabs with ul / li and css styles
* @param ul_class: string -> class du tag ul
* @param li_class: string -> class du tag li, si non selectionne
* @param li_class_selected: string -> class du tag li, si selectionne
* @param values: string -> url*caption|url*caption, lien et texte de chaque onglet
* @param selected: string -> url de l'onglet selectionne
* @return string -> html du ul / li
*/
function smarty_block_tabs($params, $content, &$me)
{
if (is_null ($content)){
return;
}
if (isset ($params['assign'])){
$me->assign ($params['assign'], _tag ('tabs', $params, $content));
}
return _tag ('tabs', $params, $content);
}
| Java |
/*
* Copyright (C) 2008 Trustin Heuiseung Lee
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
* version 2.1 of the License, or (at your option) any later version.
*
* This library is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
* Lesser General Public License for more details.
*
* You should have received a copy of the GNU Lesser General Public
* License along with this library; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, 5th Floor, Boston, MA 02110-1301 USA
*/
package net.gleamynode.netty.channel;
import java.util.ArrayList;
import java.util.List;
import java.util.concurrent.TimeUnit;
import net.gleamynode.netty.logging.Logger;
public class DefaultChannelFuture implements ChannelFuture {
private static final Logger logger =
Logger.getLogger(DefaultChannelFuture.class);
private static final int DEAD_LOCK_CHECK_INTERVAL = 5000;
private static final Throwable CANCELLED = new Throwable();
private final Channel channel;
private final boolean cancellable;
private ChannelFutureListener firstListener;
private List<ChannelFutureListener> otherListeners;
private boolean done;
private Throwable cause;
private int waiters;
public DefaultChannelFuture(Channel channel, boolean cancellable) {
this.channel = channel;
this.cancellable = cancellable;
}
public Channel getChannel() {
return channel;
}
public synchronized boolean isDone() {
return done;
}
public synchronized boolean isSuccess() {
return cause == null;
}
public synchronized Throwable getCause() {
if (cause != CANCELLED) {
return cause;
} else {
return null;
}
}
public synchronized boolean isCancelled() {
return cause == CANCELLED;
}
public void addListener(ChannelFutureListener listener) {
if (listener == null) {
throw new NullPointerException("listener");
}
boolean notifyNow = false;
synchronized (this) {
if (done) {
notifyNow = true;
} else {
if (firstListener == null) {
firstListener = listener;
} else {
if (otherListeners == null) {
otherListeners = new ArrayList<ChannelFutureListener>(1);
}
otherListeners.add(listener);
}
}
}
if (notifyNow) {
notifyListener(listener);
}
}
public void removeListener(ChannelFutureListener listener) {
if (listener == null) {
throw new NullPointerException("listener");
}
synchronized (this) {
if (!done) {
if (listener == firstListener) {
if (otherListeners != null && !otherListeners.isEmpty()) {
firstListener = otherListeners.remove(0);
} else {
firstListener = null;
}
} else if (otherListeners != null) {
otherListeners.remove(listener);
}
}
}
}
public ChannelFuture await() throws InterruptedException {
synchronized (this) {
while (!done) {
waiters++;
try {
this.wait(DEAD_LOCK_CHECK_INTERVAL);
checkDeadLock();
} finally {
waiters--;
}
}
}
return this;
}
public boolean await(long timeout, TimeUnit unit)
throws InterruptedException {
return await(unit.toMillis(timeout));
}
public boolean await(long timeoutMillis) throws InterruptedException {
return await0(timeoutMillis, true);
}
public ChannelFuture awaitUninterruptibly() {
synchronized (this) {
while (!done) {
waiters++;
try {
this.wait(DEAD_LOCK_CHECK_INTERVAL);
} catch (InterruptedException e) {
// Ignore.
} finally {
waiters--;
if (!done) {
checkDeadLock();
}
}
}
}
return this;
}
public boolean awaitUninterruptibly(long timeout, TimeUnit unit) {
return awaitUninterruptibly(unit.toMillis(timeout));
}
public boolean awaitUninterruptibly(long timeoutMillis) {
try {
return await0(timeoutMillis, false);
} catch (InterruptedException e) {
throw new InternalError();
}
}
private boolean await0(long timeoutMillis, boolean interruptable) throws InterruptedException {
long startTime = timeoutMillis <= 0 ? 0 : System.currentTimeMillis();
long waitTime = timeoutMillis;
synchronized (this) {
if (done) {
return done;
} else if (waitTime <= 0) {
return done;
}
waiters++;
try {
for (;;) {
try {
this.wait(Math.min(waitTime, DEAD_LOCK_CHECK_INTERVAL));
} catch (InterruptedException e) {
if (interruptable) {
throw e;
}
}
if (done) {
return true;
} else {
waitTime = timeoutMillis
- (System.currentTimeMillis() - startTime);
if (waitTime <= 0) {
return done;
}
}
}
} finally {
waiters--;
if (!done) {
checkDeadLock();
}
}
}
}
private void checkDeadLock() {
// IllegalStateException e = new IllegalStateException(
// "DEAD LOCK: " + ChannelFuture.class.getSimpleName() +
// ".await() was invoked from an I/O processor thread. " +
// "Please use " + ChannelFutureListener.class.getSimpleName() +
// " or configure a proper thread model alternatively.");
//
// StackTraceElement[] stackTrace = e.getStackTrace();
//
// // Simple and quick check.
// for (StackTraceElement s: stackTrace) {
// if (AbstractPollingIoProcessor.class.getName().equals(s.getClassName())) {
// throw e;
// }
// }
//
// // And then more precisely.
// for (StackTraceElement s: stackTrace) {
// try {
// Class<?> cls = DefaultChannelFuture.class.getClassLoader().loadClass(s.getClassName());
// if (IoProcessor.class.isAssignableFrom(cls)) {
// throw e;
// }
// } catch (Exception cnfe) {
// // Ignore
// }
// }
}
public void setSuccess() {
synchronized (this) {
// Allow only once.
if (done) {
return;
}
done = true;
if (waiters > 0) {
this.notifyAll();
}
}
notifyListeners();
}
public void setFailure(Throwable cause) {
synchronized (this) {
// Allow only once.
if (done) {
return;
}
this.cause = cause;
done = true;
if (waiters > 0) {
this.notifyAll();
}
}
notifyListeners();
}
public boolean cancel() {
if (!cancellable) {
return false;
}
synchronized (this) {
// Allow only once.
if (done) {
return false;
}
cause = CANCELLED;
done = true;
if (waiters > 0) {
this.notifyAll();
}
}
notifyListeners();
return true;
}
private void notifyListeners() {
// There won't be any visibility problem or concurrent modification
// because 'ready' flag will be checked against both addListener and
// removeListener calls.
if (firstListener != null) {
notifyListener(firstListener);
firstListener = null;
if (otherListeners != null) {
for (ChannelFutureListener l: otherListeners) {
notifyListener(l);
}
otherListeners = null;
}
}
}
private void notifyListener(ChannelFutureListener l) {
try {
l.operationComplete(this);
} catch (Throwable t) {
logger.warn(
"An exception was thrown by " +
ChannelFutureListener.class.getSimpleName() + ".", t);
}
}
}
| Java |
vti_encoding:SR|utf8-nl
vti_timelastmodified:TR|02 Jan 2009 17:15:39 -0000
vti_extenderversion:SR|6.0.2.8161
vti_author:SR|EX3\\José Miguel Sánchez
vti_modifiedby:SR|VPCXNAGS20\\EX3
vti_timecreated:TR|24 Jan 2006 03:59:18 -0000
vti_title:SR|dx_Sound_Class: CD_NextTrack
vti_backlinkinfo:VX|dx_Sound_Class.CD_Pause.html dx_Sound_Class.html dx_Sound_Class.CD_GetVolume.html
vti_nexttolasttimemodified:TR|02 Jan 2009 17:12:58 -0000
vti_cacheddtm:TX|02 Jan 2009 17:15:39 -0000
vti_filesize:IR|1831
vti_cachedtitle:SR|dx_Sound_Class: CD_NextTrack
vti_cachedbodystyle:SR|<BODY TOPMARGIN="0">
vti_cachedlinkinfo:VX|S|linkcss.js S|langref.js H|dx_lib32.html H|dx_Sound_Class.html K|dx_Sound_Class.html K|dx_Sound_Class.html H|dx_Sound_Class.CD_GetVolume.html H|dx_Sound_Class.CD_Pause.html H|http://vbdox.sourceforge.net/
vti_cachedsvcrellinks:VX|FSUS|linkcss.js FSUS|langref.js FHUS|dx_lib32.html FHUS|dx_Sound_Class.html FHUS|dx_Sound_Class.html FHUS|dx_Sound_Class.html FHUS|dx_Sound_Class.CD_GetVolume.html FHUS|dx_Sound_Class.CD_Pause.html NHHS|http://vbdox.sourceforge.net/
vti_cachedneedsrewrite:BR|false
vti_cachedhasbots:BR|false
vti_cachedhastheme:BR|false
vti_cachedhasborder:BR|false
vti_metatags:VR|HTTP-EQUIV=Content-Type Text/html;\\ charset=iso-8859-1 Author misho GENERATOR VBDOX\\ [1.0.24]
vti_charset:SR|iso-8859-1
vti_generator:SR|VBDOX [1.0.24]
| Java |
/**
* Contains the service and the class filter required for this bundle.
*/
package org.awb.env.networkModel.classFilter; | Java |
#
# Dockerfile for the basic link-grammar source download.
# No compilation is performed.
#
FROM ubuntu:14.04
MAINTAINER Linas Vepstas linasvepstas@gmail.com
RUN apt-get update
RUN apt-get -y install apt-utils
RUN apt-get -y install gcc g++ make
# Need wget to download link-grammar source
RUN apt-get -y install wget
# Download the current released version of link-grammar.
# RUN http://www.abisource.com/downloads/link-grammar/current/link-grammar-5*.tar.gz
# The wget tries to guess the correct file to download w/ wildcard
RUN wget -r --no-parent -nH --cut-dirs=2 http://www.abisource.com/downloads/link-grammar/current/
# Unpack the sources, too.
RUN tar -zxf current/link-grammar-5*.tar.gz
# Need the locales for utf8
RUN apt-get install locales
RUN (echo "en_US.UTF-8 UTF-8" > /etc/locale.gen && \
echo "ru_RU.UTF-8 UTF-8" >> /etc/locale.gen && \
echo "he_IL.UTF-8 UTF-8" >> /etc/locale.gen && \
echo "de_DE.UTF-8 UTF-8" >> /etc/locale.gen && \
echo "lt_LT.UTF-8 UTF-8" >> /etc/locale.gen && \
echo "fa_IR.UTF-8 UTF-8" >> /etc/locale.gen && \
echo "ar_AE.UTF-8 UTF-8" >> /etc/locale.gen && \
echo "kk_KZ.UTF-8 UTF-8" >> /etc/locale.gen && \
echo "tr_TR.UTF-8 UTF-8" >> /etc/locale.gen)
# WTF. In debian wheezy, it is enough to just say locale-gen without
# any arguments. But in trusty, we eneed to be explicit. I'm confused.
# RUN locale-gen
# Note also: under trusty, fa_IR.UTF-8 causes locale-gen to fail,
# must use the naked fa_IR
# Note also: Kazakh is kk_KZ not kz_KZ
RUN locale-gen en_US.UTF-8 ru_RU.UTF-8 he_IL.UTF-8 de_DE.UTF-8 lt_LT.UTF-8 fa_IR ar_AE.UTF-8 kk_KZ.UTF-8 tr_TR.UTF-8
| Java |
# Set the ERL environnement variable if you want to use a specific erl
ERL ?= $(shell which erl)
EJABBERD_DEV ?= ../ejabberd-modules/ejabberd-dev/trunk
all: clean
$(ERL) -pa $(EJABBERD_DEV)/ebin -make
clean:
rm -f ebin/*.beam
dist-clean: clean
find . \( -name \*~ -o -name *.swp \) -exec rm -f {} \;
| Java |
class CfmxCompat
class Version
MAJOR = 0
MINOR = 0
PATCH = 1
PRE = nil
class << self
def to_s
[MAJOR, MINOR, PATCH, PRE].compact.join(".")
end
end
end
end
| Java |
# Orca
#
# Copyright 2005-2009 Sun Microsystems Inc.
#
# This library is free software; you can redistribute it and/or
# modify it under the terms of the GNU Lesser General Public
# License as published by the Free Software Foundation; either
# version 2.1 of the License, or (at your option) any later version.
#
# This library is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
# Lesser General Public License for more details.
#
# You should have received a copy of the GNU Lesser General Public
# License along with this library; if not, write to the
# Free Software Foundation, Inc., Franklin Street, Fifth Floor,
# Boston MA 02110-1301 USA.
"""Displays a GUI for the user to set Orca preferences."""
__id__ = "$Id$"
__version__ = "$Revision$"
__date__ = "$Date$"
__copyright__ = "Copyright (c) 2005-2009 Sun Microsystems Inc."
__license__ = "LGPL"
import os
from gi.repository import Gdk
from gi.repository import GLib
from gi.repository import Gtk
from gi.repository import GObject
from gi.repository import Pango
import pyatspi
import time
from . import acss
from . import debug
from . import guilabels
from . import messages
from . import orca
from . import orca_gtkbuilder
from . import orca_gui_profile
from . import orca_state
from . import orca_platform
from . import settings
from . import settings_manager
from . import input_event
from . import keybindings
from . import pronunciation_dict
from . import braille
from . import speech
from . import speechserver
from . import text_attribute_names
_settingsManager = settings_manager.getManager()
try:
import louis
except ImportError:
louis = None
from .orca_platform import tablesdir
if louis and not tablesdir:
louis = None
(HANDLER, DESCRIP, MOD_MASK1, MOD_USED1, KEY1, CLICK_COUNT1, OLDTEXT1, \
TEXT1, MODIF, EDITABLE) = list(range(10))
(NAME, IS_SPOKEN, IS_BRAILLED, VALUE) = list(range(4))
(ACTUAL, REPLACEMENT) = list(range(2))
# Must match the order of voice types in the GtkBuilder file.
#
(DEFAULT, UPPERCASE, HYPERLINK, SYSTEM) = list(range(4))
# Must match the order that the timeFormatCombo is populated.
#
(TIME_FORMAT_LOCALE, TIME_FORMAT_12_HM, TIME_FORMAT_12_HMS, TIME_FORMAT_24_HMS,
TIME_FORMAT_24_HMS_WITH_WORDS, TIME_FORMAT_24_HM,
TIME_FORMAT_24_HM_WITH_WORDS) = list(range(7))
# Must match the order that the dateFormatCombo is populated.
#
(DATE_FORMAT_LOCALE, DATE_FORMAT_NUMBERS_DM, DATE_FORMAT_NUMBERS_MD,
DATE_FORMAT_NUMBERS_DMY, DATE_FORMAT_NUMBERS_MDY, DATE_FORMAT_NUMBERS_YMD,
DATE_FORMAT_FULL_DM, DATE_FORMAT_FULL_MD, DATE_FORMAT_FULL_DMY,
DATE_FORMAT_FULL_MDY, DATE_FORMAT_FULL_YMD, DATE_FORMAT_ABBREVIATED_DM,
DATE_FORMAT_ABBREVIATED_MD, DATE_FORMAT_ABBREVIATED_DMY,
DATE_FORMAT_ABBREVIATED_MDY, DATE_FORMAT_ABBREVIATED_YMD) = list(range(16))
class OrcaSetupGUI(orca_gtkbuilder.GtkBuilderWrapper):
def __init__(self, fileName, windowName, prefsDict):
"""Initialize the Orca configuration GUI.
Arguments:
- fileName: name of the GtkBuilder file.
- windowName: name of the component to get from the GtkBuilder file.
- prefsDict: dictionary of preferences to use during initialization
"""
orca_gtkbuilder.GtkBuilderWrapper.__init__(self, fileName, windowName)
self.prefsDict = prefsDict
self._defaultProfile = ['Default', 'default']
# Initialize variables to None to keep pylint happy.
#
self.bbindings = None
self.cellRendererText = None
self.defaultVoice = None
self.disableKeyGrabPref = None
self.getTextAttributesView = None
self.hyperlinkVoice = None
self.initializingSpeech = None
self.kbindings = None
self.keyBindingsModel = None
self.keyBindView = None
self.newBinding = None
self.pendingKeyBindings = None
self.planeCellRendererText = None
self.pronunciationModel = None
self.pronunciationView = None
self.screenHeight = None
self.screenWidth = None
self.speechFamiliesChoice = None
self.speechFamiliesChoices = None
self.speechFamiliesModel = None
self.speechLanguagesChoice = None
self.speechLanguagesChoices = None
self.speechLanguagesModel = None
self.speechFamilies = []
self.speechServersChoice = None
self.speechServersChoices = None
self.speechServersModel = None
self.speechSystemsChoice = None
self.speechSystemsChoices = None
self.speechSystemsModel = None
self.systemVoice = None
self.uppercaseVoice = None
self.window = None
self.workingFactories = None
self.savedGain = None
self.savedPitch = None
self.savedRate = None
self._isInitialSetup = False
self.selectedFamilyChoices = {}
self.selectedLanguageChoices = {}
self.profilesCombo = None
self.profilesComboModel = None
self.startingProfileCombo = None
self._capturedKey = []
self.script = None
def init(self, script):
"""Initialize the Orca configuration GUI. Read the users current
set of preferences and set the GUI state to match. Setup speech
support and populate the combo box lists on the Speech Tab pane
accordingly.
"""
self.script = script
# Restore the default rate/pitch/gain,
# in case the user played with the sliders.
#
try:
voices = _settingsManager.getSetting('voices')
defaultVoice = voices[settings.DEFAULT_VOICE]
except KeyError:
defaultVoice = {}
try:
self.savedGain = defaultVoice[acss.ACSS.GAIN]
except KeyError:
self.savedGain = 10.0
try:
self.savedPitch = defaultVoice[acss.ACSS.AVERAGE_PITCH]
except KeyError:
self.savedPitch = 5.0
try:
self.savedRate = defaultVoice[acss.ACSS.RATE]
except KeyError:
self.savedRate = 50.0
# ***** Key Bindings treeview initialization *****
self.keyBindView = self.get_widget("keyBindingsTreeview")
if self.keyBindView.get_columns():
for column in self.keyBindView.get_columns():
self.keyBindView.remove_column(column)
self.keyBindingsModel = Gtk.TreeStore(
GObject.TYPE_STRING, # Handler name
GObject.TYPE_STRING, # Human Readable Description
GObject.TYPE_STRING, # Modifier mask 1
GObject.TYPE_STRING, # Used Modifiers 1
GObject.TYPE_STRING, # Modifier key name 1
GObject.TYPE_STRING, # Click count 1
GObject.TYPE_STRING, # Original Text of the Key Binding Shown 1
GObject.TYPE_STRING, # Text of the Key Binding Shown 1
GObject.TYPE_BOOLEAN, # Key Modified by User
GObject.TYPE_BOOLEAN) # Row with fields editable or not
self.planeCellRendererText = Gtk.CellRendererText()
self.cellRendererText = Gtk.CellRendererText()
self.cellRendererText.set_property("ellipsize", Pango.EllipsizeMode.END)
# HANDLER - invisble column
#
column = Gtk.TreeViewColumn("Handler",
self.planeCellRendererText,
text=HANDLER)
column.set_resizable(True)
column.set_visible(False)
column.set_sort_column_id(HANDLER)
self.keyBindView.append_column(column)
# DESCRIP
#
column = Gtk.TreeViewColumn(guilabels.KB_HEADER_FUNCTION,
self.cellRendererText,
text=DESCRIP)
column.set_resizable(True)
column.set_min_width(380)
column.set_sort_column_id(DESCRIP)
self.keyBindView.append_column(column)
# MOD_MASK1 - invisble column
#
column = Gtk.TreeViewColumn("Mod.Mask 1",
self.planeCellRendererText,
text=MOD_MASK1)
column.set_visible(False)
column.set_resizable(True)
column.set_sort_column_id(MOD_MASK1)
self.keyBindView.append_column(column)
# MOD_USED1 - invisble column
#
column = Gtk.TreeViewColumn("Use Mod.1",
self.planeCellRendererText,
text=MOD_USED1)
column.set_visible(False)
column.set_resizable(True)
column.set_sort_column_id(MOD_USED1)
self.keyBindView.append_column(column)
# KEY1 - invisble column
#
column = Gtk.TreeViewColumn("Key1",
self.planeCellRendererText,
text=KEY1)
column.set_resizable(True)
column.set_visible(False)
column.set_sort_column_id(KEY1)
self.keyBindView.append_column(column)
# CLICK_COUNT1 - invisble column
#
column = Gtk.TreeViewColumn("ClickCount1",
self.planeCellRendererText,
text=CLICK_COUNT1)
column.set_resizable(True)
column.set_visible(False)
column.set_sort_column_id(CLICK_COUNT1)
self.keyBindView.append_column(column)
# OLDTEXT1 - invisble column which will store a copy of the
# original keybinding in TEXT1 prior to the Apply or OK
# buttons being pressed. This will prevent automatic
# resorting each time a cell is edited.
#
column = Gtk.TreeViewColumn("OldText1",
self.planeCellRendererText,
text=OLDTEXT1)
column.set_resizable(True)
column.set_visible(False)
column.set_sort_column_id(OLDTEXT1)
self.keyBindView.append_column(column)
# TEXT1
#
rendererText = Gtk.CellRendererText()
rendererText.connect("editing-started",
self.editingKey,
self.keyBindingsModel)
rendererText.connect("editing-canceled",
self.editingCanceledKey)
rendererText.connect('edited',
self.editedKey,
self.keyBindingsModel,
MOD_MASK1, MOD_USED1, KEY1, CLICK_COUNT1, TEXT1)
column = Gtk.TreeViewColumn(guilabels.KB_HEADER_KEY_BINDING,
rendererText,
text=TEXT1,
editable=EDITABLE)
column.set_resizable(True)
column.set_sort_column_id(OLDTEXT1)
self.keyBindView.append_column(column)
# MODIF
#
rendererToggle = Gtk.CellRendererToggle()
rendererToggle.connect('toggled',
self.keyModifiedToggle,
self.keyBindingsModel,
MODIF)
column = Gtk.TreeViewColumn(guilabels.KB_MODIFIED,
rendererToggle,
active=MODIF,
activatable=EDITABLE)
#column.set_visible(False)
column.set_resizable(True)
column.set_sort_column_id(MODIF)
self.keyBindView.append_column(column)
# EDITABLE - invisble column
#
rendererToggle = Gtk.CellRendererToggle()
rendererToggle.set_property('activatable', False)
column = Gtk.TreeViewColumn("Modified",
rendererToggle,
active=EDITABLE)
column.set_visible(False)
column.set_resizable(True)
column.set_sort_column_id(EDITABLE)
self.keyBindView.append_column(column)
# Populates the treeview with all the keybindings:
#
self._populateKeyBindings()
self.window = self.get_widget("orcaSetupWindow")
self._setKeyEchoItems()
self.speechSystemsModel = \
self._initComboBox(self.get_widget("speechSystems"))
self.speechServersModel = \
self._initComboBox(self.get_widget("speechServers"))
self.speechLanguagesModel = \
self._initComboBox(self.get_widget("speechLanguages"))
self.speechFamiliesModel = \
self._initComboBox(self.get_widget("speechFamilies"))
self._initSpeechState()
# TODO - JD: Will this ever be the case??
self._isInitialSetup = \
not os.path.exists(_settingsManager.getPrefsDir())
appPage = self.script.getAppPreferencesGUI()
if appPage:
label = Gtk.Label(label=self.script.app.name)
self.get_widget("notebook").append_page(appPage, label)
self._initGUIState()
def _getACSSForVoiceType(self, voiceType):
"""Return the ACSS value for the given voice type.
Arguments:
- voiceType: one of DEFAULT, UPPERCASE, HYPERLINK, SYSTEM
Returns the voice dictionary for the given voice type.
"""
if voiceType == DEFAULT:
voiceACSS = self.defaultVoice
elif voiceType == UPPERCASE:
voiceACSS = self.uppercaseVoice
elif voiceType == HYPERLINK:
voiceACSS = self.hyperlinkVoice
elif voiceType == SYSTEM:
voiceACSS = self.systemVoice
else:
voiceACSS = self.defaultVoice
return voiceACSS
def writeUserPreferences(self):
"""Write out the user's generic Orca preferences.
"""
pronunciationDict = self.getModelDict(self.pronunciationModel)
keyBindingsDict = self.getKeyBindingsModelDict(self.keyBindingsModel)
self.prefsDict.update(self.script.getPreferencesFromGUI())
_settingsManager.saveSettings(self.script,
self.prefsDict,
pronunciationDict,
keyBindingsDict)
def _getKeyValueForVoiceType(self, voiceType, key, useDefault=True):
"""Look for the value of the given key in the voice dictionary
for the given voice type.
Arguments:
- voiceType: one of DEFAULT, UPPERCASE, HYPERLINK, SYSTEM
- key: the key to look for in the voice dictionary.
- useDefault: if True, and the key isn't found for the given voice
type, the look for it in the default voice dictionary
as well.
Returns the value of the given key, or None if it's not set.
"""
if voiceType == DEFAULT:
voice = self.defaultVoice
elif voiceType == UPPERCASE:
voice = self.uppercaseVoice
if key not in voice:
if not useDefault:
return None
voice = self.defaultVoice
elif voiceType == HYPERLINK:
voice = self.hyperlinkVoice
if key not in voice:
if not useDefault:
return None
voice = self.defaultVoice
elif voiceType == SYSTEM:
voice = self.systemVoice
if key not in voice:
if not useDefault:
return None
voice = self.defaultVoice
else:
voice = self.defaultVoice
if key in voice:
return voice[key]
else:
return None
def _getFamilyNameForVoiceType(self, voiceType):
"""Gets the name of the voice family for the given voice type.
Arguments:
- voiceType: one of DEFAULT, UPPERCASE, HYPERLINK, SYSTEM
Returns the name of the voice family for the given voice type,
or None if not set.
"""
familyName = None
family = self._getKeyValueForVoiceType(voiceType, acss.ACSS.FAMILY)
if family and speechserver.VoiceFamily.NAME in family:
familyName = family[speechserver.VoiceFamily.NAME]
return familyName
def _setFamilyNameForVoiceType(self, voiceType, name, language, dialect, variant):
"""Sets the name of the voice family for the given voice type.
Arguments:
- voiceType: one of DEFAULT, UPPERCASE, HYPERLINK, SYSTEM
- name: the name of the voice family to set.
- language: the locale of the voice family to set.
- dialect: the dialect of the voice family to set.
"""
family = self._getKeyValueForVoiceType(voiceType,
acss.ACSS.FAMILY,
False)
voiceACSS = self._getACSSForVoiceType(voiceType)
if family:
family[speechserver.VoiceFamily.NAME] = name
family[speechserver.VoiceFamily.LANG] = language
family[speechserver.VoiceFamily.DIALECT] = dialect
family[speechserver.VoiceFamily.VARIANT] = variant
else:
voiceACSS[acss.ACSS.FAMILY] = {}
voiceACSS[acss.ACSS.FAMILY][speechserver.VoiceFamily.NAME] = name
voiceACSS[acss.ACSS.FAMILY][speechserver.VoiceFamily.LANG] = language
voiceACSS[acss.ACSS.FAMILY][speechserver.VoiceFamily.DIALECT] = dialect
voiceACSS[acss.ACSS.FAMILY][speechserver.VoiceFamily.VARIANT] = variant
voiceACSS['established'] = True
#settings.voices[voiceType] = voiceACSS
def _getRateForVoiceType(self, voiceType):
"""Gets the speaking rate value for the given voice type.
Arguments:
- voiceType: one of DEFAULT, UPPERCASE, HYPERLINK, SYSTEM
Returns the rate value for the given voice type, or None if
not set.
"""
return self._getKeyValueForVoiceType(voiceType, acss.ACSS.RATE)
def _setRateForVoiceType(self, voiceType, value):
"""Sets the speaking rate value for the given voice type.
Arguments:
- voiceType: one of DEFAULT, UPPERCASE, HYPERLINK, SYSTEM
- value: the rate value to set.
"""
voiceACSS = self._getACSSForVoiceType(voiceType)
voiceACSS[acss.ACSS.RATE] = value
voiceACSS['established'] = True
#settings.voices[voiceType] = voiceACSS
def _getPitchForVoiceType(self, voiceType):
"""Gets the pitch value for the given voice type.
Arguments:
- voiceType: one of DEFAULT, UPPERCASE, HYPERLINK, SYSTEM
Returns the pitch value for the given voice type, or None if
not set.
"""
return self._getKeyValueForVoiceType(voiceType,
acss.ACSS.AVERAGE_PITCH)
def _setPitchForVoiceType(self, voiceType, value):
"""Sets the pitch value for the given voice type.
Arguments:
- voiceType: one of DEFAULT, UPPERCASE, HYPERLINK, SYSTEM
- value: the pitch value to set.
"""
voiceACSS = self._getACSSForVoiceType(voiceType)
voiceACSS[acss.ACSS.AVERAGE_PITCH] = value
voiceACSS['established'] = True
#settings.voices[voiceType] = voiceACSS
def _getVolumeForVoiceType(self, voiceType):
"""Gets the volume (gain) value for the given voice type.
Arguments:
- voiceType: one of DEFAULT, UPPERCASE, HYPERLINK, SYSTEM
Returns the volume (gain) value for the given voice type, or
None if not set.
"""
return self._getKeyValueForVoiceType(voiceType, acss.ACSS.GAIN)
def _setVolumeForVoiceType(self, voiceType, value):
"""Sets the volume (gain) value for the given voice type.
Arguments:
- voiceType: one of DEFAULT, UPPERCASE, HYPERLINK, SYSTEM
- value: the volume (gain) value to set.
"""
voiceACSS = self._getACSSForVoiceType(voiceType)
voiceACSS[acss.ACSS.GAIN] = value
voiceACSS['established'] = True
#settings.voices[voiceType] = voiceACSS
def _setVoiceSettingsForVoiceType(self, voiceType):
"""Sets the family, rate, pitch and volume GUI components based
on the given voice type.
Arguments:
- voiceType: one of DEFAULT, UPPERCASE, HYPERLINK, SYSTEM
"""
familyName = self._getFamilyNameForVoiceType(voiceType)
self._setSpeechFamiliesChoice(familyName)
rate = self._getRateForVoiceType(voiceType)
if rate is not None:
self.get_widget("rateScale").set_value(rate)
else:
self.get_widget("rateScale").set_value(50.0)
pitch = self._getPitchForVoiceType(voiceType)
if pitch is not None:
self.get_widget("pitchScale").set_value(pitch)
else:
self.get_widget("pitchScale").set_value(5.0)
volume = self._getVolumeForVoiceType(voiceType)
if volume is not None:
self.get_widget("volumeScale").set_value(volume)
else:
self.get_widget("volumeScale").set_value(10.0)
def _setSpeechFamiliesChoice(self, familyName):
"""Sets the active item in the families ("Person:") combo box
to the given family name.
Arguments:
- familyName: the family name to use to set the active combo box item.
"""
if len(self.speechFamilies) == 0:
return
languageSet = False
familySet = False
for family in self.speechFamilies:
name = family[speechserver.VoiceFamily.NAME]
if name == familyName:
lang = family[speechserver.VoiceFamily.LANG]
dialect = family[speechserver.VoiceFamily.DIALECT]
if dialect:
language = lang + '-' + dialect
else:
language = lang
i = 0
for languageChoice in self.speechLanguagesChoices:
if languageChoice == language:
self.get_widget("speechLanguages").set_active(i)
self.speechLanguagesChoice = self.speechLanguagesChoices[i]
languageSet = True
self._setupFamilies()
i = 0
for familyChoice in self.speechFamiliesChoices:
name = familyChoice[speechserver.VoiceFamily.NAME]
if name == familyName:
self.get_widget("speechFamilies").set_active(i)
self.speechFamiliesChoice = self.speechFamiliesChoices[i]
familySet = True
break
i += 1
break
i += 1
break
if not languageSet:
debug.println(debug.LEVEL_FINEST,
"Could not find speech language match for %s" \
% familyName)
self.get_widget("speechLanguages").set_active(0)
self.speechLanguagesChoice = self.speechLanguagesChoices[0]
if languageSet:
self.selectedLanguageChoices[self.speechServersChoice] = i
if not familySet:
debug.println(debug.LEVEL_FINEST,
"Could not find speech family match for %s" \
% familyName)
self.get_widget("speechFamilies").set_active(0)
self.speechFamiliesChoice = self.speechFamiliesChoices[0]
if familySet:
self.selectedFamilyChoices[self.speechServersChoice,
self.speechLanguagesChoice] = i
def _setupFamilies(self):
"""Gets the list of voice variants for the current speech server and
current language.
If there are variants, get the information associated with
each voice variant and add an entry for it to the variants
GtkComboBox list.
"""
self.speechFamiliesModel.clear()
currentLanguage = self.speechLanguagesChoice
i = 0
self.speechFamiliesChoices = []
for family in self.speechFamilies:
lang = family[speechserver.VoiceFamily.LANG]
dialect = family[speechserver.VoiceFamily.DIALECT]
if dialect:
language = lang + '-' + dialect
else:
language = lang
if language != currentLanguage:
continue
name = family[speechserver.VoiceFamily.NAME]
self.speechFamiliesChoices.append(family)
self.speechFamiliesModel.append((i, name))
i += 1
if i == 0:
debug.println(debug.LEVEL_SEVERE, "No speech family was available for %s." % str(currentLanguage))
debug.printStack(debug.LEVEL_FINEST)
self.speechFamiliesChoice = None
return
# If user manually selected a family for the current speech server
# this choice it's restored. In other case the first family
# (usually the default one) is selected
#
selectedIndex = 0
if (self.speechServersChoice, self.speechLanguagesChoice) \
in self.selectedFamilyChoices:
selectedIndex = self.selectedFamilyChoices[self.speechServersChoice,
self.speechLanguagesChoice]
self.get_widget("speechFamilies").set_active(selectedIndex)
def _setSpeechLanguagesChoice(self, languageName):
"""Sets the active item in the languages ("Language:") combo box
to the given language name.
Arguments:
- languageName: the language name to use to set the active combo box item.
"""
print("setSpeechLanguagesChoice")
if len(self.speechLanguagesChoices) == 0:
return
valueSet = False
i = 0
for language in self.speechLanguagesChoices:
if language == languageName:
self.get_widget("speechLanguages").set_active(i)
self.speechLanguagesChoice = self.speechLanguagesChoices[i]
valueSet = True
break
i += 1
if not valueSet:
debug.println(debug.LEVEL_FINEST,
"Could not find speech language match for %s" \
% languageName)
self.get_widget("speechLanguages").set_active(0)
self.speechLanguagesChoice = self.speechLanguagesChoices[0]
if valueSet:
self.selectedLanguageChoices[self.speechServersChoice] = i
self._setupFamilies()
def _setupVoices(self):
"""Gets the list of voices for the current speech server.
If there are families, get the information associated with
each voice family and add an entry for it to the families
GtkComboBox list.
"""
self.speechLanguagesModel.clear()
self.speechFamilies = self.speechServersChoice.getVoiceFamilies()
self.speechLanguagesChoices = []
if len(self.speechFamilies) == 0:
debug.println(debug.LEVEL_SEVERE, "No speech voice was available.")
debug.printStack(debug.LEVEL_FINEST)
self.speechLanguagesChoice = None
return
done = {}
i = 0
for family in self.speechFamilies:
lang = family[speechserver.VoiceFamily.LANG]
dialect = family[speechserver.VoiceFamily.DIALECT]
if (lang,dialect) in done:
continue
done[lang,dialect] = True
if dialect:
language = lang + '-' + dialect
else:
language = lang
# TODO: get translated language name from CLDR or such
msg = language
if msg == "":
# Unsupported locale
msg = "default language"
self.speechLanguagesChoices.append(language)
self.speechLanguagesModel.append((i, msg))
i += 1
# If user manually selected a language for the current speech server
# this choice it's restored. In other case the first language
# (usually the default one) is selected
#
selectedIndex = 0
if self.speechServersChoice in self.selectedLanguageChoices:
selectedIndex = self.selectedLanguageChoices[self.speechServersChoice]
self.get_widget("speechLanguages").set_active(selectedIndex)
if self.initializingSpeech:
self.speechLanguagesChoice = self.speechLanguagesChoices[selectedIndex]
self._setupFamilies()
# The family name will be selected as part of selecting the
# voice type. Whenever the families change, we'll reset the
# voice type selection to the first one ("Default").
#
comboBox = self.get_widget("voiceTypesCombo")
types = [guilabels.SPEECH_VOICE_TYPE_DEFAULT,
guilabels.SPEECH_VOICE_TYPE_UPPERCASE,
guilabels.SPEECH_VOICE_TYPE_HYPERLINK,
guilabels.SPEECH_VOICE_TYPE_SYSTEM]
self.populateComboBox(comboBox, types)
comboBox.set_active(DEFAULT)
voiceType = comboBox.get_active()
self._setVoiceSettingsForVoiceType(voiceType)
def _setSpeechServersChoice(self, serverInfo):
"""Sets the active item in the speech servers combo box to the
given server.
Arguments:
- serversChoices: the list of available speech servers.
- serverInfo: the speech server to use to set the active combo
box item.
"""
if len(self.speechServersChoices) == 0:
return
# We'll fallback to whatever we happen to be using in the event
# that this preference has never been set.
#
if not serverInfo:
serverInfo = speech.getInfo()
valueSet = False
i = 0
for server in self.speechServersChoices:
if serverInfo == server.getInfo():
self.get_widget("speechServers").set_active(i)
self.speechServersChoice = server
valueSet = True
break
i += 1
if not valueSet:
debug.println(debug.LEVEL_FINEST,
"Could not find speech server match for %s" \
% repr(serverInfo))
self.get_widget("speechServers").set_active(0)
self.speechServersChoice = self.speechServersChoices[0]
self._setupVoices()
def _setupSpeechServers(self):
"""Gets the list of speech servers for the current speech factory.
If there are servers, get the information associated with each
speech server and add an entry for it to the speechServers
GtkComboBox list. Set the current choice to be the first item.
"""
self.speechServersModel.clear()
self.speechServersChoices = \
self.speechSystemsChoice.SpeechServer.getSpeechServers()
if len(self.speechServersChoices) == 0:
debug.println(debug.LEVEL_SEVERE, "Speech not available.")
debug.printStack(debug.LEVEL_FINEST)
self.speechServersChoice = None
self.speechLanguagesChoices = []
self.speechLanguagesChoice = None
self.speechFamiliesChoices = []
self.speechFamiliesChoice = None
return
i = 0
for server in self.speechServersChoices:
name = server.getInfo()[0]
self.speechServersModel.append((i, name))
i += 1
self._setSpeechServersChoice(self.prefsDict["speechServerInfo"])
debug.println(
debug.LEVEL_FINEST,
"orca_gui_prefs._setupSpeechServers: speechServersChoice: %s" \
% self.speechServersChoice.getInfo())
def _setSpeechSystemsChoice(self, systemName):
"""Set the active item in the speech systems combo box to the
given system name.
Arguments:
- factoryChoices: the list of available speech factories (systems).
- systemName: the speech system name to use to set the active combo
box item.
"""
systemName = systemName.strip("'")
if len(self.speechSystemsChoices) == 0:
self.speechSystemsChoice = None
return
valueSet = False
i = 0
for speechSystem in self.speechSystemsChoices:
name = speechSystem.__name__
if name.endswith(systemName):
self.get_widget("speechSystems").set_active(i)
self.speechSystemsChoice = self.speechSystemsChoices[i]
valueSet = True
break
i += 1
if not valueSet:
debug.println(debug.LEVEL_FINEST,
"Could not find speech system match for %s" \
% systemName)
self.get_widget("speechSystems").set_active(0)
self.speechSystemsChoice = self.speechSystemsChoices[0]
self._setupSpeechServers()
def _setupSpeechSystems(self, factories):
"""Sets up the speech systems combo box and sets the selection
to the preferred speech system.
Arguments:
-factories: the list of known speech factories (working or not)
"""
self.speechSystemsModel.clear()
self.workingFactories = []
for factory in factories:
try:
servers = factory.SpeechServer.getSpeechServers()
if len(servers):
self.workingFactories.append(factory)
except:
debug.printException(debug.LEVEL_FINEST)
self.speechSystemsChoices = []
if len(self.workingFactories) == 0:
debug.println(debug.LEVEL_SEVERE, "Speech not available.")
debug.printStack(debug.LEVEL_FINEST)
self.speechSystemsChoice = None
self.speechServersChoices = []
self.speechServersChoice = None
self.speechLanguagesChoices = []
self.speechLanguagesChoice = None
self.speechFamiliesChoices = []
self.speechFamiliesChoice = None
return
i = 0
for workingFactory in self.workingFactories:
self.speechSystemsChoices.append(workingFactory)
name = workingFactory.SpeechServer.getFactoryName()
self.speechSystemsModel.append((i, name))
i += 1
if self.prefsDict["speechServerFactory"]:
self._setSpeechSystemsChoice(self.prefsDict["speechServerFactory"])
else:
self.speechSystemsChoice = None
debug.println(
debug.LEVEL_FINEST,
"orca_gui_prefs._setupSpeechSystems: speechSystemsChoice: %s" \
% self.speechSystemsChoice)
def _initSpeechState(self):
"""Initialize the various speech components.
"""
voices = self.prefsDict["voices"]
self.defaultVoice = acss.ACSS(voices.get(settings.DEFAULT_VOICE))
self.uppercaseVoice = acss.ACSS(voices.get(settings.UPPERCASE_VOICE))
self.hyperlinkVoice = acss.ACSS(voices.get(settings.HYPERLINK_VOICE))
self.systemVoice = acss.ACSS(voices.get(settings.SYSTEM_VOICE))
# Just a note on general naming pattern:
#
# * = The name of the combobox
# *Model = the name of the comobox model
# *Choices = the Orca/speech python objects
# *Choice = a value from *Choices
#
# Where * = speechSystems, speechServers, speechLanguages, speechFamilies
#
factories = _settingsManager.getSpeechServerFactories()
if len(factories) == 0 or not self.prefsDict.get('enableSpeech', True):
self.workingFactories = []
self.speechSystemsChoice = None
self.speechServersChoices = []
self.speechServersChoice = None
self.speechLanguagesChoices = []
self.speechLanguagesChoice = None
self.speechFamiliesChoices = []
self.speechFamiliesChoice = None
return
try:
speech.init()
except:
self.workingFactories = []
self.speechSystemsChoice = None
self.speechServersChoices = []
self.speechServersChoice = None
self.speechLanguagesChoices = []
self.speechLanguagesChoice = None
self.speechFamiliesChoices = []
self.speechFamiliesChoice = None
return
# This cascades into systems->servers->voice_type->families...
#
self.initializingSpeech = True
self._setupSpeechSystems(factories)
self.initializingSpeech = False
def _setSpokenTextAttributes(self, view, setAttributes,
state, moveToTop=False):
"""Given a set of spoken text attributes, update the model used by the
text attribute tree view.
Arguments:
- view: the text attribute tree view.
- setAttributes: the list of spoken text attributes to update.
- state: the state (True or False) that they all should be set to.
- moveToTop: if True, move these attributes to the top of the list.
"""
model = view.get_model()
view.set_model(None)
[attrList, attrDict] = \
self.script.utilities.stringToKeysAndDict(setAttributes)
[allAttrList, allAttrDict] = self.script.utilities.stringToKeysAndDict(
_settingsManager.getSetting('allTextAttributes'))
for i in range(0, len(attrList)):
for path in range(0, len(allAttrList)):
localizedKey = text_attribute_names.getTextAttributeName(
attrList[i], self.script)
localizedValue = text_attribute_names.getTextAttributeName(
attrDict[attrList[i]], self.script)
if localizedKey == model[path][NAME]:
thisIter = model.get_iter(path)
model.set_value(thisIter, NAME, localizedKey)
model.set_value(thisIter, IS_SPOKEN, state)
model.set_value(thisIter, VALUE, localizedValue)
if moveToTop:
thisIter = model.get_iter(path)
otherIter = model.get_iter(i)
model.move_before(thisIter, otherIter)
break
view.set_model(model)
def _setBrailledTextAttributes(self, view, setAttributes, state):
"""Given a set of brailled text attributes, update the model used
by the text attribute tree view.
Arguments:
- view: the text attribute tree view.
- setAttributes: the list of brailled text attributes to update.
- state: the state (True or False) that they all should be set to.
"""
model = view.get_model()
view.set_model(None)
[attrList, attrDict] = \
self.script.utilities.stringToKeysAndDict(setAttributes)
[allAttrList, allAttrDict] = self.script.utilities.stringToKeysAndDict(
_settingsManager.getSetting('allTextAttributes'))
for i in range(0, len(attrList)):
for path in range(0, len(allAttrList)):
localizedKey = text_attribute_names.getTextAttributeName(
attrList[i], self.script)
if localizedKey == model[path][NAME]:
thisIter = model.get_iter(path)
model.set_value(thisIter, IS_BRAILLED, state)
break
view.set_model(model)
def _getAppNameForAttribute(self, attributeName):
"""Converts the given Atk attribute name into the application's
equivalent. This is necessary because an application or toolkit
(e.g. Gecko) might invent entirely new names for the same text
attributes.
Arguments:
- attribName: The name of the text attribute
Returns the application's equivalent name if found or attribName
otherwise.
"""
return self.script.utilities.getAppNameForAttribute(attributeName)
def _updateTextDictEntry(self):
"""The user has updated the text attribute list in some way. Update
the "enabledSpokenTextAttributes" and "enabledBrailledTextAttributes"
preference strings to reflect the current state of the corresponding
text attribute lists.
"""
model = self.getTextAttributesView.get_model()
spokenAttrStr = ""
brailledAttrStr = ""
noRows = model.iter_n_children(None)
for path in range(0, noRows):
localizedKey = model[path][NAME]
key = text_attribute_names.getTextAttributeKey(localizedKey)
# Convert the normalized, Atk attribute name back into what
# the app/toolkit uses.
#
key = self._getAppNameForAttribute(key)
localizedValue = model[path][VALUE]
value = text_attribute_names.getTextAttributeKey(localizedValue)
if model[path][IS_SPOKEN]:
spokenAttrStr += key + ":" + value + "; "
if model[path][IS_BRAILLED]:
brailledAttrStr += key + ":" + value + "; "
self.prefsDict["enabledSpokenTextAttributes"] = spokenAttrStr
self.prefsDict["enabledBrailledTextAttributes"] = brailledAttrStr
def contractedBrailleToggled(self, checkbox):
grid = self.get_widget('contractionTableGrid')
grid.set_sensitive(checkbox.get_active())
self.prefsDict["enableContractedBraille"] = checkbox.get_active()
def contractionTableComboChanged(self, combobox):
model = combobox.get_model()
myIter = combobox.get_active_iter()
self.prefsDict["brailleContractionTable"] = model[myIter][1]
def flashPersistenceToggled(self, checkbox):
grid = self.get_widget('flashMessageDurationGrid')
grid.set_sensitive(not checkbox.get_active())
self.prefsDict["flashIsPersistent"] = checkbox.get_active()
def textAttributeSpokenToggled(self, cell, path, model):
"""The user has toggled the state of one of the text attribute
checkboxes to be spoken. Update our model to reflect this, then
update the "enabledSpokenTextAttributes" preference string.
Arguments:
- cell: the cell that changed.
- path: the path of that cell.
- model: the model that the cell is part of.
"""
thisIter = model.get_iter(path)
model.set(thisIter, IS_SPOKEN, not model[path][IS_SPOKEN])
self._updateTextDictEntry()
def textAttributeBrailledToggled(self, cell, path, model):
"""The user has toggled the state of one of the text attribute
checkboxes to be brailled. Update our model to reflect this,
then update the "enabledBrailledTextAttributes" preference string.
Arguments:
- cell: the cell that changed.
- path: the path of that cell.
- model: the model that the cell is part of.
"""
thisIter = model.get_iter(path)
model.set(thisIter, IS_BRAILLED, not model[path][IS_BRAILLED])
self._updateTextDictEntry()
def textAttrValueEdited(self, cell, path, new_text, model):
"""The user has edited the value of one of the text attributes.
Update our model to reflect this, then update the
"enabledSpokenTextAttributes" and "enabledBrailledTextAttributes"
preference strings.
Arguments:
- cell: the cell that changed.
- path: the path of that cell.
- new_text: the new text attribute value string.
- model: the model that the cell is part of.
"""
thisIter = model.get_iter(path)
model.set(thisIter, VALUE, new_text)
self._updateTextDictEntry()
def textAttrCursorChanged(self, widget):
"""Set the search column in the text attribute tree view
depending upon which column the user currently has the cursor in.
"""
[path, focusColumn] = self.getTextAttributesView.get_cursor()
if focusColumn:
noColumns = len(self.getTextAttributesView.get_columns())
for i in range(0, noColumns):
col = self.getTextAttributesView.get_column(i)
if focusColumn == col:
self.getTextAttributesView.set_search_column(i)
break
def _createTextAttributesTreeView(self):
"""Create the text attributes tree view. The view is the
textAttributesTreeView GtkTreeView widget. The view will consist
of a list containing three columns:
IS_SPOKEN - a checkbox whose state indicates whether this text
attribute will be spoken or not.
NAME - the text attribute name.
VALUE - if set, (and this attributes is enabled for speaking),
then this attribute will be spoken unless it equals
this value.
"""
self.getTextAttributesView = self.get_widget("textAttributesTreeView")
if self.getTextAttributesView.get_columns():
for column in self.getTextAttributesView.get_columns():
self.getTextAttributesView.remove_column(column)
model = Gtk.ListStore(GObject.TYPE_STRING,
GObject.TYPE_BOOLEAN,
GObject.TYPE_BOOLEAN,
GObject.TYPE_STRING)
# Initially setup the list store model based on the values of all
# the known text attributes.
#
[allAttrList, allAttrDict] = self.script.utilities.stringToKeysAndDict(
_settingsManager.getSetting('allTextAttributes'))
for i in range(0, len(allAttrList)):
thisIter = model.append()
localizedKey = text_attribute_names.getTextAttributeName(
allAttrList[i], self.script)
localizedValue = text_attribute_names.getTextAttributeName(
allAttrDict[allAttrList[i]], self.script)
model.set_value(thisIter, NAME, localizedKey)
model.set_value(thisIter, IS_SPOKEN, False)
model.set_value(thisIter, IS_BRAILLED, False)
model.set_value(thisIter, VALUE, localizedValue)
self.getTextAttributesView.set_model(model)
# Attribute Name column (NAME).
column = Gtk.TreeViewColumn(guilabels.TEXT_ATTRIBUTE_NAME)
column.set_min_width(250)
column.set_resizable(True)
renderer = Gtk.CellRendererText()
column.pack_end(renderer, True)
column.add_attribute(renderer, 'text', NAME)
self.getTextAttributesView.insert_column(column, 0)
# Attribute Speak column (IS_SPOKEN).
speakAttrColumnLabel = guilabels.PRESENTATION_SPEAK
column = Gtk.TreeViewColumn(speakAttrColumnLabel)
renderer = Gtk.CellRendererToggle()
column.pack_start(renderer, False)
column.add_attribute(renderer, 'active', IS_SPOKEN)
renderer.connect("toggled",
self.textAttributeSpokenToggled,
model)
self.getTextAttributesView.insert_column(column, 1)
column.clicked()
# Attribute Mark in Braille column (IS_BRAILLED).
markAttrColumnLabel = guilabels.PRESENTATION_MARK_IN_BRAILLE
column = Gtk.TreeViewColumn(markAttrColumnLabel)
renderer = Gtk.CellRendererToggle()
column.pack_start(renderer, False)
column.add_attribute(renderer, 'active', IS_BRAILLED)
renderer.connect("toggled",
self.textAttributeBrailledToggled,
model)
self.getTextAttributesView.insert_column(column, 2)
column.clicked()
# Attribute Value column (VALUE)
column = Gtk.TreeViewColumn(guilabels.PRESENTATION_PRESENT_UNLESS)
renderer = Gtk.CellRendererText()
renderer.set_property('editable', True)
column.pack_end(renderer, True)
column.add_attribute(renderer, 'text', VALUE)
renderer.connect("edited", self.textAttrValueEdited, model)
self.getTextAttributesView.insert_column(column, 4)
# Check all the enabled (spoken) text attributes.
#
self._setSpokenTextAttributes(
self.getTextAttributesView,
_settingsManager.getSetting('enabledSpokenTextAttributes'),
True, True)
# Check all the enabled (brailled) text attributes.
#
self._setBrailledTextAttributes(
self.getTextAttributesView,
_settingsManager.getSetting('enabledBrailledTextAttributes'),
True)
# Connect a handler for when the user changes columns within the
# view, so that we can adjust the search column for item lookups.
#
self.getTextAttributesView.connect("cursor_changed",
self.textAttrCursorChanged)
def pronActualValueEdited(self, cell, path, new_text, model):
"""The user has edited the value of one of the actual strings in
the pronunciation dictionary. Update our model to reflect this.
Arguments:
- cell: the cell that changed.
- path: the path of that cell.
- new_text: the new pronunciation dictionary actual string.
- model: the model that the cell is part of.
"""
thisIter = model.get_iter(path)
model.set(thisIter, ACTUAL, new_text)
def pronReplacementValueEdited(self, cell, path, new_text, model):
"""The user has edited the value of one of the replacement strings
in the pronunciation dictionary. Update our model to reflect this.
Arguments:
- cell: the cell that changed.
- path: the path of that cell.
- new_text: the new pronunciation dictionary replacement string.
- model: the model that the cell is part of.
"""
thisIter = model.get_iter(path)
model.set(thisIter, REPLACEMENT, new_text)
def pronunciationFocusChange(self, widget, event, isFocused):
"""Callback for the pronunciation tree's focus-{in,out}-event signal."""
_settingsManager.setSetting('usePronunciationDictionary', not isFocused)
def pronunciationCursorChanged(self, widget):
"""Set the search column in the pronunciation dictionary tree view
depending upon which column the user currently has the cursor in.
"""
[path, focusColumn] = self.pronunciationView.get_cursor()
if focusColumn:
noColumns = len(self.pronunciationView.get_columns())
for i in range(0, noColumns):
col = self.pronunciationView.get_column(i)
if focusColumn == col:
self.pronunciationView.set_search_column(i)
break
def _createPronunciationTreeView(self):
"""Create the pronunciation dictionary tree view. The view is the
pronunciationTreeView GtkTreeView widget. The view will consist
of a list containing two columns:
ACTUAL - the actual text string (word).
REPLACEMENT - the string that is used to pronounce that word.
"""
self.pronunciationView = self.get_widget("pronunciationTreeView")
if self.pronunciationView.get_columns():
for column in self.pronunciationView.get_columns():
self.pronunciationView.remove_column(column)
model = Gtk.ListStore(GObject.TYPE_STRING,
GObject.TYPE_STRING)
# Initially setup the list store model based on the values of all
# existing entries in the pronunciation dictionary -- unless it's
# the default script.
#
if not self.script.app:
_profile = self.prefsDict.get('activeProfile')[1]
pronDict = _settingsManager.getPronunciations(_profile)
else:
pronDict = pronunciation_dict.pronunciation_dict
for pronKey in sorted(pronDict.keys()):
thisIter = model.append()
try:
actual, replacement = pronDict[pronKey]
except:
# Try to do something sensible for the previous format of
# pronunciation dictionary entries. See bug #464754 for
# more details.
#
actual = pronKey
replacement = pronDict[pronKey]
model.set(thisIter,
ACTUAL, actual,
REPLACEMENT, replacement)
self.pronunciationView.set_model(model)
# Pronunciation Dictionary actual string (word) column (ACTUAL).
column = Gtk.TreeViewColumn(guilabels.DICTIONARY_ACTUAL_STRING)
column.set_min_width(250)
column.set_resizable(True)
renderer = Gtk.CellRendererText()
renderer.set_property('editable', True)
column.pack_end(renderer, True)
column.add_attribute(renderer, 'text', ACTUAL)
renderer.connect("edited", self.pronActualValueEdited, model)
self.pronunciationView.insert_column(column, 0)
# Pronunciation Dictionary replacement string column (REPLACEMENT)
column = Gtk.TreeViewColumn(guilabels.DICTIONARY_REPLACEMENT_STRING)
renderer = Gtk.CellRendererText()
renderer.set_property('editable', True)
column.pack_end(renderer, True)
column.add_attribute(renderer, 'text', REPLACEMENT)
renderer.connect("edited", self.pronReplacementValueEdited, model)
self.pronunciationView.insert_column(column, 1)
self.pronunciationModel = model
# Connect a handler for when the user changes columns within the
# view, so that we can adjust the search column for item lookups.
#
self.pronunciationView.connect("cursor_changed",
self.pronunciationCursorChanged)
self.pronunciationView.connect(
"focus_in_event", self.pronunciationFocusChange, True)
self.pronunciationView.connect(
"focus_out_event", self.pronunciationFocusChange, False)
def _initGUIState(self):
"""Adjust the settings of the various components on the
configuration GUI depending upon the users preferences.
"""
prefs = self.prefsDict
# Speech pane.
#
enable = prefs["enableSpeech"]
self.get_widget("speechSupportCheckButton").set_active(enable)
self.get_widget("speechOptionsGrid").set_sensitive(enable)
enable = prefs["onlySpeakDisplayedText"]
self.get_widget("onlySpeakDisplayedTextCheckButton").set_active(enable)
self.get_widget("contextOptionsGrid").set_sensitive(not enable)
if prefs["verbalizePunctuationStyle"] == \
settings.PUNCTUATION_STYLE_NONE:
self.get_widget("noneButton").set_active(True)
elif prefs["verbalizePunctuationStyle"] == \
settings.PUNCTUATION_STYLE_SOME:
self.get_widget("someButton").set_active(True)
elif prefs["verbalizePunctuationStyle"] == \
settings.PUNCTUATION_STYLE_MOST:
self.get_widget("mostButton").set_active(True)
else:
self.get_widget("allButton").set_active(True)
if prefs["speechVerbosityLevel"] == settings.VERBOSITY_LEVEL_BRIEF:
self.get_widget("speechBriefButton").set_active(True)
else:
self.get_widget("speechVerboseButton").set_active(True)
self.get_widget("onlySpeakDisplayedTextCheckButton").set_active(
prefs["onlySpeakDisplayedText"])
self.get_widget("enableSpeechIndentationCheckButton").set_active(\
prefs["enableSpeechIndentation"])
self.get_widget("speakBlankLinesCheckButton").set_active(\
prefs["speakBlankLines"])
self.get_widget("speakMultiCaseStringsAsWordsCheckButton").set_active(\
prefs["speakMultiCaseStringsAsWords"])
self.get_widget("speakNumbersAsDigitsCheckButton").set_active(
prefs.get("speakNumbersAsDigits", settings.speakNumbersAsDigits))
self.get_widget("enableTutorialMessagesCheckButton").set_active(\
prefs["enableTutorialMessages"])
self.get_widget("enablePauseBreaksCheckButton").set_active(\
prefs["enablePauseBreaks"])
self.get_widget("enablePositionSpeakingCheckButton").set_active(\
prefs["enablePositionSpeaking"])
self.get_widget("enableMnemonicSpeakingCheckButton").set_active(\
prefs["enableMnemonicSpeaking"])
self.get_widget("speakMisspelledIndicatorCheckButton").set_active(
prefs.get("speakMisspelledIndicator", settings.speakMisspelledIndicator))
self.get_widget("speakDescriptionCheckButton").set_active(
prefs.get("speakDescription", settings.speakDescription))
self.get_widget("speakContextBlockquoteCheckButton").set_active(
prefs.get("speakContextBlockquote", settings.speakContextList))
self.get_widget("speakContextLandmarkCheckButton").set_active(
prefs.get("speakContextLandmark", settings.speakContextLandmark))
self.get_widget("speakContextNonLandmarkFormCheckButton").set_active(
prefs.get("speakContextNonLandmarkForm", settings.speakContextNonLandmarkForm))
self.get_widget("speakContextListCheckButton").set_active(
prefs.get("speakContextList", settings.speakContextList))
self.get_widget("speakContextPanelCheckButton").set_active(
prefs.get("speakContextPanel", settings.speakContextPanel))
self.get_widget("speakContextTableCheckButton").set_active(
prefs.get("speakContextTable", settings.speakContextTable))
enable = prefs.get("messagesAreDetailed", settings.messagesAreDetailed)
self.get_widget("messagesAreDetailedCheckButton").set_active(enable)
enable = prefs.get("useColorNames", settings.useColorNames)
self.get_widget("useColorNamesCheckButton").set_active(enable)
enable = prefs.get("readFullRowInGUITable", settings.readFullRowInGUITable)
self.get_widget("readFullRowInGUITableCheckButton").set_active(enable)
enable = prefs.get("readFullRowInDocumentTable", settings.readFullRowInDocumentTable)
self.get_widget("readFullRowInDocumentTableCheckButton").set_active(enable)
enable = prefs.get("readFullRowInSpreadSheet", settings.readFullRowInSpreadSheet)
self.get_widget("readFullRowInSpreadSheetCheckButton").set_active(enable)
style = prefs.get("capitalizationStyle", settings.capitalizationStyle)
combobox = self.get_widget("capitalizationStyle")
options = [guilabels.CAPITALIZATION_STYLE_NONE,
guilabels.CAPITALIZATION_STYLE_ICON,
guilabels.CAPITALIZATION_STYLE_SPELL]
self.populateComboBox(combobox, options)
if style == settings.CAPITALIZATION_STYLE_ICON:
value = guilabels.CAPITALIZATION_STYLE_ICON
elif style == settings.CAPITALIZATION_STYLE_SPELL:
value = guilabels.CAPITALIZATION_STYLE_SPELL
else:
value = guilabels.CAPITALIZATION_STYLE_NONE
combobox.set_active(options.index(value))
combobox2 = self.get_widget("dateFormatCombo")
sdtime = time.strftime
ltime = time.localtime
self.populateComboBox(combobox2,
[sdtime(messages.DATE_FORMAT_LOCALE, ltime()),
sdtime(messages.DATE_FORMAT_NUMBERS_DM, ltime()),
sdtime(messages.DATE_FORMAT_NUMBERS_MD, ltime()),
sdtime(messages.DATE_FORMAT_NUMBERS_DMY, ltime()),
sdtime(messages.DATE_FORMAT_NUMBERS_MDY, ltime()),
sdtime(messages.DATE_FORMAT_NUMBERS_YMD, ltime()),
sdtime(messages.DATE_FORMAT_FULL_DM, ltime()),
sdtime(messages.DATE_FORMAT_FULL_MD, ltime()),
sdtime(messages.DATE_FORMAT_FULL_DMY, ltime()),
sdtime(messages.DATE_FORMAT_FULL_MDY, ltime()),
sdtime(messages.DATE_FORMAT_FULL_YMD, ltime()),
sdtime(messages.DATE_FORMAT_ABBREVIATED_DM, ltime()),
sdtime(messages.DATE_FORMAT_ABBREVIATED_MD, ltime()),
sdtime(messages.DATE_FORMAT_ABBREVIATED_DMY, ltime()),
sdtime(messages.DATE_FORMAT_ABBREVIATED_MDY, ltime()),
sdtime(messages.DATE_FORMAT_ABBREVIATED_YMD, ltime())
])
indexdate = DATE_FORMAT_LOCALE
dateFormat = self.prefsDict["presentDateFormat"]
if dateFormat == messages.DATE_FORMAT_LOCALE:
indexdate = DATE_FORMAT_LOCALE
elif dateFormat == messages.DATE_FORMAT_NUMBERS_DM:
indexdate = DATE_FORMAT_NUMBERS_DM
elif dateFormat == messages.DATE_FORMAT_NUMBERS_MD:
indexdate = DATE_FORMAT_NUMBERS_MD
elif dateFormat == messages.DATE_FORMAT_NUMBERS_DMY:
indexdate = DATE_FORMAT_NUMBERS_DMY
elif dateFormat == messages.DATE_FORMAT_NUMBERS_MDY:
indexdate = DATE_FORMAT_NUMBERS_MDY
elif dateFormat == messages.DATE_FORMAT_NUMBERS_YMD:
indexdate = DATE_FORMAT_NUMBERS_YMD
elif dateFormat == messages.DATE_FORMAT_FULL_DM:
indexdate = DATE_FORMAT_FULL_DM
elif dateFormat == messages.DATE_FORMAT_FULL_MD:
indexdate = DATE_FORMAT_FULL_MD
elif dateFormat == messages.DATE_FORMAT_FULL_DMY:
indexdate = DATE_FORMAT_FULL_DMY
elif dateFormat == messages.DATE_FORMAT_FULL_MDY:
indexdate = DATE_FORMAT_FULL_MDY
elif dateFormat == messages.DATE_FORMAT_FULL_YMD:
indexdate = DATE_FORMAT_FULL_YMD
elif dateFormat == messages.DATE_FORMAT_ABBREVIATED_DM:
indexdate = DATE_FORMAT_ABBREVIATED_DM
elif dateFormat == messages.DATE_FORMAT_ABBREVIATED_MD:
indexdate = DATE_FORMAT_ABBREVIATED_MD
elif dateFormat == messages.DATE_FORMAT_ABBREVIATED_DMY:
indexdate = DATE_FORMAT_ABBREVIATED_DMY
elif dateFormat == messages.DATE_FORMAT_ABBREVIATED_MDY:
indexdate = DATE_FORMAT_ABBREVIATED_MDY
elif dateFormat == messages.DATE_FORMAT_ABBREVIATED_YMD:
indexdate = DATE_FORMAT_ABBREVIATED_YMD
combobox2.set_active (indexdate)
combobox3 = self.get_widget("timeFormatCombo")
self.populateComboBox(combobox3,
[sdtime(messages.TIME_FORMAT_LOCALE, ltime()),
sdtime(messages.TIME_FORMAT_12_HM, ltime()),
sdtime(messages.TIME_FORMAT_12_HMS, ltime()),
sdtime(messages.TIME_FORMAT_24_HMS, ltime()),
sdtime(messages.TIME_FORMAT_24_HMS_WITH_WORDS, ltime()),
sdtime(messages.TIME_FORMAT_24_HM, ltime()),
sdtime(messages.TIME_FORMAT_24_HM_WITH_WORDS, ltime())])
indextime = TIME_FORMAT_LOCALE
timeFormat = self.prefsDict["presentTimeFormat"]
if timeFormat == messages.TIME_FORMAT_LOCALE:
indextime = TIME_FORMAT_LOCALE
elif timeFormat == messages.TIME_FORMAT_12_HM:
indextime = TIME_FORMAT_12_HM
elif timeFormat == messages.TIME_FORMAT_12_HMS:
indextime = TIME_FORMAT_12_HMS
elif timeFormat == messages.TIME_FORMAT_24_HMS:
indextime = TIME_FORMAT_24_HMS
elif timeFormat == messages.TIME_FORMAT_24_HMS_WITH_WORDS:
indextime = TIME_FORMAT_24_HMS_WITH_WORDS
elif timeFormat == messages.TIME_FORMAT_24_HM:
indextime = TIME_FORMAT_24_HM
elif timeFormat == messages.TIME_FORMAT_24_HM_WITH_WORDS:
indextime = TIME_FORMAT_24_HM_WITH_WORDS
combobox3.set_active (indextime)
self.get_widget("speakProgressBarUpdatesCheckButton").set_active(
prefs.get("speakProgressBarUpdates", settings.speakProgressBarUpdates))
self.get_widget("brailleProgressBarUpdatesCheckButton").set_active(
prefs.get("brailleProgressBarUpdates", settings.brailleProgressBarUpdates))
self.get_widget("beepProgressBarUpdatesCheckButton").set_active(
prefs.get("beepProgressBarUpdates", settings.beepProgressBarUpdates))
interval = prefs["progressBarUpdateInterval"]
self.get_widget("progressBarUpdateIntervalSpinButton").set_value(interval)
comboBox = self.get_widget("progressBarVerbosity")
levels = [guilabels.PROGRESS_BAR_ALL,
guilabels.PROGRESS_BAR_APPLICATION,
guilabels.PROGRESS_BAR_WINDOW]
self.populateComboBox(comboBox, levels)
comboBox.set_active(prefs["progressBarVerbosity"])
enable = prefs["enableMouseReview"]
self.get_widget("enableMouseReviewCheckButton").set_active(enable)
# Braille pane.
#
self.get_widget("enableBrailleCheckButton").set_active( \
prefs["enableBraille"])
state = prefs["brailleRolenameStyle"] == \
settings.BRAILLE_ROLENAME_STYLE_SHORT
self.get_widget("abbrevRolenames").set_active(state)
self.get_widget("disableBrailleEOLCheckButton").set_active(
prefs["disableBrailleEOL"])
if louis is None:
self.get_widget( \
"contractedBrailleCheckButton").set_sensitive(False)
else:
self.get_widget("contractedBrailleCheckButton").set_active( \
prefs["enableContractedBraille"])
# Set up contraction table combo box and set it to the
# currently used one.
#
tablesCombo = self.get_widget("contractionTableCombo")
tableDict = braille.listTables()
selectedTableIter = None
selectedTable = prefs["brailleContractionTable"] or \
braille.getDefaultTable()
if tableDict:
tablesModel = Gtk.ListStore(str, str)
names = sorted(tableDict.keys())
for name in names:
fname = tableDict[name]
it = tablesModel.append([name, fname])
if os.path.join(braille.tablesdir, fname) == \
selectedTable:
selectedTableIter = it
cell = self.planeCellRendererText
tablesCombo.clear()
tablesCombo.pack_start(cell, True)
tablesCombo.add_attribute(cell, 'text', 0)
tablesCombo.set_model(tablesModel)
if selectedTableIter:
tablesCombo.set_active_iter(selectedTableIter)
else:
tablesCombo.set_active(0)
else:
tablesCombo.set_sensitive(False)
if prefs["brailleVerbosityLevel"] == settings.VERBOSITY_LEVEL_BRIEF:
self.get_widget("brailleBriefButton").set_active(True)
else:
self.get_widget("brailleVerboseButton").set_active(True)
self.get_widget("enableBrailleWordWrapCheckButton").set_active(
prefs.get("enableBrailleWordWrap", settings.enableBrailleWordWrap))
selectionIndicator = prefs["brailleSelectorIndicator"]
if selectionIndicator == settings.BRAILLE_UNDERLINE_7:
self.get_widget("brailleSelection7Button").set_active(True)
elif selectionIndicator == settings.BRAILLE_UNDERLINE_8:
self.get_widget("brailleSelection8Button").set_active(True)
elif selectionIndicator == settings.BRAILLE_UNDERLINE_BOTH:
self.get_widget("brailleSelectionBothButton").set_active(True)
else:
self.get_widget("brailleSelectionNoneButton").set_active(True)
linkIndicator = prefs["brailleLinkIndicator"]
if linkIndicator == settings.BRAILLE_UNDERLINE_7:
self.get_widget("brailleLink7Button").set_active(True)
elif linkIndicator == settings.BRAILLE_UNDERLINE_8:
self.get_widget("brailleLink8Button").set_active(True)
elif linkIndicator == settings.BRAILLE_UNDERLINE_BOTH:
self.get_widget("brailleLinkBothButton").set_active(True)
else:
self.get_widget("brailleLinkNoneButton").set_active(True)
enable = prefs.get("enableFlashMessages", settings.enableFlashMessages)
self.get_widget("enableFlashMessagesCheckButton").set_active(enable)
enable = prefs.get("flashIsPersistent", settings.flashIsPersistent)
self.get_widget("flashIsPersistentCheckButton").set_active(enable)
enable = prefs.get("flashIsDetailed", settings.flashIsDetailed)
self.get_widget("flashIsDetailedCheckButton").set_active(enable)
duration = prefs["brailleFlashTime"]
self.get_widget("brailleFlashTimeSpinButton").set_value(duration / 1000)
# Key Echo pane.
#
self.get_widget("keyEchoCheckButton").set_active( \
prefs["enableKeyEcho"])
self.get_widget("enableAlphabeticKeysCheckButton").set_active(
prefs.get("enableAlphabeticKeys", settings.enableAlphabeticKeys))
self.get_widget("enableNumericKeysCheckButton").set_active(
prefs.get("enableNumericKeys", settings.enableNumericKeys))
self.get_widget("enablePunctuationKeysCheckButton").set_active(
prefs.get("enablePunctuationKeys", settings.enablePunctuationKeys))
self.get_widget("enableSpaceCheckButton").set_active(
prefs.get("enableSpace", settings.enableSpace))
self.get_widget("enableModifierKeysCheckButton").set_active( \
prefs["enableModifierKeys"])
self.get_widget("enableFunctionKeysCheckButton").set_active( \
prefs["enableFunctionKeys"])
self.get_widget("enableActionKeysCheckButton").set_active( \
prefs["enableActionKeys"])
self.get_widget("enableNavigationKeysCheckButton").set_active( \
prefs["enableNavigationKeys"])
self.get_widget("enableDiacriticalKeysCheckButton").set_active( \
prefs["enableDiacriticalKeys"])
self.get_widget("enableEchoByCharacterCheckButton").set_active( \
prefs["enableEchoByCharacter"])
self.get_widget("enableEchoByWordCheckButton").set_active( \
prefs["enableEchoByWord"])
self.get_widget("enableEchoBySentenceCheckButton").set_active( \
prefs["enableEchoBySentence"])
# Text attributes pane.
#
self._createTextAttributesTreeView()
brailleIndicator = prefs["textAttributesBrailleIndicator"]
if brailleIndicator == settings.BRAILLE_UNDERLINE_7:
self.get_widget("textBraille7Button").set_active(True)
elif brailleIndicator == settings.BRAILLE_UNDERLINE_8:
self.get_widget("textBraille8Button").set_active(True)
elif brailleIndicator == settings.BRAILLE_UNDERLINE_BOTH:
self.get_widget("textBrailleBothButton").set_active(True)
else:
self.get_widget("textBrailleNoneButton").set_active(True)
# Pronunciation dictionary pane.
#
self._createPronunciationTreeView()
# General pane.
#
self.get_widget("presentToolTipsCheckButton").set_active(
prefs["presentToolTips"])
if prefs["keyboardLayout"] == settings.GENERAL_KEYBOARD_LAYOUT_DESKTOP:
self.get_widget("generalDesktopButton").set_active(True)
else:
self.get_widget("generalLaptopButton").set_active(True)
combobox = self.get_widget("sayAllStyle")
self.populateComboBox(combobox, [guilabels.SAY_ALL_STYLE_LINE,
guilabels.SAY_ALL_STYLE_SENTENCE])
combobox.set_active(prefs["sayAllStyle"])
self.get_widget("rewindAndFastForwardInSayAllCheckButton").set_active(
prefs.get("rewindAndFastForwardInSayAll", settings.rewindAndFastForwardInSayAll))
self.get_widget("structNavInSayAllCheckButton").set_active(
prefs.get("structNavInSayAll", settings.structNavInSayAll))
self.get_widget("sayAllContextBlockquoteCheckButton").set_active(
prefs.get("sayAllContextBlockquote", settings.sayAllContextBlockquote))
self.get_widget("sayAllContextLandmarkCheckButton").set_active(
prefs.get("sayAllContextLandmark", settings.sayAllContextLandmark))
self.get_widget("sayAllContextNonLandmarkFormCheckButton").set_active(
prefs.get("sayAllContextNonLandmarkForm", settings.sayAllContextNonLandmarkForm))
self.get_widget("sayAllContextListCheckButton").set_active(
prefs.get("sayAllContextList", settings.sayAllContextList))
self.get_widget("sayAllContextPanelCheckButton").set_active(
prefs.get("sayAllContextPanel", settings.sayAllContextPanel))
self.get_widget("sayAllContextTableCheckButton").set_active(
prefs.get("sayAllContextTable", settings.sayAllContextTable))
# Orca User Profiles
#
self.profilesCombo = self.get_widget('availableProfilesComboBox1')
self.startingProfileCombo = self.get_widget('availableProfilesComboBox2')
self.profilesComboModel = self.get_widget('model9')
self.__initProfileCombo()
if self.script.app:
self.get_widget('profilesFrame').set_sensitive(False)
def __initProfileCombo(self):
"""Adding available profiles and setting active as the active one"""
availableProfiles = self.__getAvailableProfiles()
self.profilesComboModel.clear()
if not len(availableProfiles):
self.profilesComboModel.append(self._defaultProfile)
else:
for profile in availableProfiles:
self.profilesComboModel.append(profile)
activeProfile = self.prefsDict.get('activeProfile') or self._defaultProfile
startingProfile = self.prefsDict.get('startingProfile') or self._defaultProfile
activeProfileIter = self.getComboBoxIndex(self.profilesCombo,
activeProfile[0])
startingProfileIter = self.getComboBoxIndex(self.startingProfileCombo,
startingProfile[0])
self.profilesCombo.set_active(activeProfileIter)
self.startingProfileCombo.set_active(startingProfileIter)
def __getAvailableProfiles(self):
"""Get available user profiles."""
return _settingsManager.availableProfiles()
def _updateOrcaModifier(self):
combobox = self.get_widget("orcaModifierComboBox")
keystring = ", ".join(self.prefsDict["orcaModifierKeys"])
combobox.set_active(self.getComboBoxIndex(combobox, keystring))
def populateComboBox(self, combobox, items):
"""Populates the combobox with the items provided.
Arguments:
- combobox: the GtkComboBox to populate
- items: the list of strings with which to populate it
"""
model = Gtk.ListStore(str)
for item in items:
model.append([item])
combobox.set_model(model)
def getComboBoxIndex(self, combobox, searchStr, col=0):
""" For each of the entries in the given combo box, look for searchStr.
Return the index of the entry if searchStr is found.
Arguments:
- combobox: the GtkComboBox to search.
- searchStr: the string to search for.
Returns the index of the first entry in combobox with searchStr, or
0 if not found.
"""
model = combobox.get_model()
myiter = model.get_iter_first()
for i in range(0, len(model)):
name = model.get_value(myiter, col)
if name == searchStr:
return i
myiter = model.iter_next(myiter)
return 0
def getComboBoxList(self, combobox):
"""Get the list of values from the active combox
"""
active = combobox.get_active()
model = combobox.get_model()
activeIter = model.get_iter(active)
activeLabel = model.get_value(activeIter, 0)
activeName = model.get_value(activeIter, 1)
return [activeLabel, activeName]
def getKeyBindingsModelDict(self, model, modifiedOnly=True):
modelDict = {}
node = model.get_iter_first()
while node:
child = model.iter_children(node)
while child:
key, modified = model.get(child, HANDLER, MODIF)
if modified or not modifiedOnly:
value = []
value.append(list(model.get(
child, KEY1, MOD_MASK1, MOD_USED1, CLICK_COUNT1)))
modelDict[key] = value
child = model.iter_next(child)
node = model.iter_next(node)
return modelDict
def getModelDict(self, model):
"""Get the list of values from a list[str,str] model
"""
pronunciation_dict.pronunciation_dict = {}
currentIter = model.get_iter_first()
while currentIter is not None:
key, value = model.get(currentIter, ACTUAL, REPLACEMENT)
if key and value:
pronunciation_dict.setPronunciation(key, value)
currentIter = model.iter_next(currentIter)
modelDict = pronunciation_dict.pronunciation_dict
return modelDict
def showGUI(self):
"""Show the Orca configuration GUI window. This assumes that
the GUI has already been created.
"""
orcaSetupWindow = self.get_widget("orcaSetupWindow")
accelGroup = Gtk.AccelGroup()
orcaSetupWindow.add_accel_group(accelGroup)
helpButton = self.get_widget("helpButton")
(keyVal, modifierMask) = Gtk.accelerator_parse("F1")
helpButton.add_accelerator("clicked",
accelGroup,
keyVal,
modifierMask,
0)
try:
ts = orca_state.lastInputEvent.timestamp
except:
ts = 0
if ts == 0:
ts = Gtk.get_current_event_time()
orcaSetupWindow.present_with_time(ts)
# We always want to re-order the text attributes page so that enabled
# items are consistently at the top.
#
self._setSpokenTextAttributes(
self.getTextAttributesView,
_settingsManager.getSetting('enabledSpokenTextAttributes'),
True, True)
if self.script.app:
title = guilabels.PREFERENCES_APPLICATION_TITLE % self.script.app.name
orcaSetupWindow.set_title(title)
orcaSetupWindow.show()
def _initComboBox(self, combobox):
"""Initialize the given combo box to take a list of int/str pairs.
Arguments:
- combobox: the GtkComboBox to initialize.
"""
cell = Gtk.CellRendererText()
combobox.pack_start(cell, True)
# We only want to display one column; not two.
#
try:
columnToDisplay = combobox.get_cells()[0]
combobox.add_attribute(columnToDisplay, 'text', 1)
except:
combobox.add_attribute(cell, 'text', 1)
model = Gtk.ListStore(int, str)
combobox.set_model(model)
# Force the display comboboxes to be left aligned.
#
if isinstance(combobox, Gtk.ComboBoxText):
size = combobox.size_request()
cell.set_fixed_size(size[0] - 29, -1)
return model
def _setKeyEchoItems(self):
"""[In]sensitize the checkboxes for the various types of key echo,
depending upon whether the value of the key echo check button is set.
"""
enable = self.get_widget("keyEchoCheckButton").get_active()
self.get_widget("enableAlphabeticKeysCheckButton").set_sensitive(enable)
self.get_widget("enableNumericKeysCheckButton").set_sensitive(enable)
self.get_widget("enablePunctuationKeysCheckButton").set_sensitive(enable)
self.get_widget("enableSpaceCheckButton").set_sensitive(enable)
self.get_widget("enableModifierKeysCheckButton").set_sensitive(enable)
self.get_widget("enableFunctionKeysCheckButton").set_sensitive(enable)
self.get_widget("enableActionKeysCheckButton").set_sensitive(enable)
self.get_widget("enableNavigationKeysCheckButton").set_sensitive(enable)
self.get_widget("enableDiacriticalKeysCheckButton").set_sensitive( \
enable)
def _presentMessage(self, text, interrupt=False):
"""If the text field is not None, presents the given text, optionally
interrupting anything currently being spoken.
Arguments:
- text: the text to present
- interrupt: if True, interrupt any speech currently being spoken
"""
self.script.speakMessage(text, interrupt=interrupt)
try:
self.script.displayBrailleMessage(text, flashTime=-1)
except:
pass
def _createNode(self, appName):
"""Create a new root node in the TreeStore model with the name of the
application.
Arguments:
- appName: the name of the TreeStore Node (the same of the application)
"""
model = self.keyBindingsModel
myiter = model.append(None)
model.set_value(myiter, DESCRIP, appName)
model.set_value(myiter, MODIF, False)
return myiter
def _getIterOf(self, appName):
"""Returns the Gtk.TreeIter of the TreeStore model
that matches the application name passed as argument
Arguments:
- appName: a string with the name of the application of the node wanted
it's the same that the field DESCRIP of the model treeStore
"""
model = self.keyBindingsModel
for row in model:
if ((model.iter_depth(row.iter) == 0) \
and (row[DESCRIP] == appName)):
return row.iter
return None
def _clickCountToString(self, clickCount):
"""Given a numeric clickCount, returns a string for inclusion
in the list of keybindings.
Argument:
- clickCount: the number of clicks associated with the keybinding.
"""
clickCountString = ""
if clickCount == 2:
clickCountString = " (%s)" % guilabels.CLICK_COUNT_DOUBLE
elif clickCount == 3:
clickCountString = " (%s)" % guilabels.CLICK_COUNT_TRIPLE
return clickCountString
def _insertRow(self, handl, kb, parent=None, modif=False):
"""Appends a new row with the new keybinding data to the treeview
Arguments:
- handl: the name of the handler associated to the keyBinding
- kb: the new keybinding.
- parent: the parent node of the treeview, where to append the kb
- modif: whether to check the modified field or not.
Returns a Gtk.TreeIter pointing at the new row.
"""
model = self.keyBindingsModel
if parent is None:
parent = self._getIterOf(guilabels.KB_GROUP_DEFAULT)
if parent is not None:
myiter = model.append(parent)
if not kb.keysymstring:
text = None
else:
clickCount = self._clickCountToString(kb.click_count)
modifierNames = keybindings.getModifierNames(kb.modifiers)
keysymstring = kb.keysymstring
text = keybindings.getModifierNames(kb.modifiers) \
+ keysymstring \
+ clickCount
model.set_value(myiter, HANDLER, handl)
model.set_value(myiter, DESCRIP, kb.handler.description)
model.set_value(myiter, MOD_MASK1, str(kb.modifier_mask))
model.set_value(myiter, MOD_USED1, str(kb.modifiers))
model.set_value(myiter, KEY1, kb.keysymstring)
model.set_value(myiter, CLICK_COUNT1, str(kb.click_count))
if text is not None:
model.set_value(myiter, OLDTEXT1, text)
model.set_value(myiter, TEXT1, text)
model.set_value(myiter, MODIF, modif)
model.set_value(myiter, EDITABLE, True)
return myiter
else:
return None
def _insertRowBraille(self, handl, com, inputEvHand,
parent=None, modif=False):
"""Appends a new row with the new braille binding data to the treeview
Arguments:
- handl: the name of the handler associated to the brailleBinding
- com: the BrlTTY command
- inputEvHand: the inputEventHandler with the new brailleBinding
- parent: the parent node of the treeview, where to append the kb
- modif: whether to check the modified field or not.
Returns a Gtk.TreeIter pointing at the new row.
"""
model = self.keyBindingsModel
if parent is None:
parent = self._getIterOf(guilabels.KB_GROUP_BRAILLE)
if parent is not None:
myiter = model.append(parent)
model.set_value(myiter, HANDLER, handl)
model.set_value(myiter, DESCRIP, inputEvHand.description)
model.set_value(myiter, KEY1, str(com))
model.set_value(myiter, TEXT1, braille.command_name[com])
model.set_value(myiter, MODIF, modif)
model.set_value(myiter, EDITABLE, False)
return myiter
else:
return None
def _markModified(self):
""" Mark as modified the user custom key bindings:
"""
try:
self.script.setupInputEventHandlers()
keyBinds = keybindings.KeyBindings()
keyBinds = _settingsManager.overrideKeyBindings(self.script, keyBinds)
keyBind = keybindings.KeyBinding(None, None, None, None)
treeModel = self.keyBindingsModel
myiter = treeModel.get_iter_first()
while myiter is not None:
iterChild = treeModel.iter_children(myiter)
while iterChild is not None:
descrip = treeModel.get_value(iterChild, DESCRIP)
keyBind.handler = \
input_event.InputEventHandler(None, descrip)
if keyBinds.hasKeyBinding(keyBind,
typeOfSearch="description"):
treeModel.set_value(iterChild, MODIF, True)
iterChild = treeModel.iter_next(iterChild)
myiter = treeModel.iter_next(myiter)
except:
debug.printException(debug.LEVEL_SEVERE)
def _populateKeyBindings(self, clearModel=True):
"""Fills the TreeView with the list of Orca keybindings
Arguments:
- clearModel: if True, initially clear out the key bindings model.
"""
self.keyBindView.set_model(None)
self.keyBindView.set_headers_visible(False)
self.keyBindView.hide()
if clearModel:
self.keyBindingsModel.clear()
self.kbindings = None
try:
appName = self.script.app.name
except:
appName = ""
iterApp = self._createNode(appName)
iterOrca = self._createNode(guilabels.KB_GROUP_DEFAULT)
iterUnbound = self._createNode(guilabels.KB_GROUP_UNBOUND)
if not self.kbindings:
self.kbindings = keybindings.KeyBindings()
self.script.setupInputEventHandlers()
allKeyBindings = self.script.getKeyBindings()
defKeyBindings = self.script.getDefaultKeyBindings()
for kb in allKeyBindings.keyBindings:
if not self.kbindings.hasKeyBinding(kb, "strict"):
handl = self.script.getInputEventHandlerKey(kb.handler)
if not defKeyBindings.hasKeyBinding(kb, "description"):
self._insertRow(handl, kb, iterApp)
elif kb.keysymstring:
self._insertRow(handl, kb, iterOrca)
else:
self._insertRow(handl, kb, iterUnbound)
self.kbindings.add(kb)
if not self.keyBindingsModel.iter_has_child(iterApp):
self.keyBindingsModel.remove(iterApp)
if not self.keyBindingsModel.iter_has_child(iterUnbound):
self.keyBindingsModel.remove(iterUnbound)
self._updateOrcaModifier()
self._markModified()
iterBB = self._createNode(guilabels.KB_GROUP_BRAILLE)
self.bbindings = self.script.getBrailleBindings()
for com, inputEvHand in self.bbindings.items():
handl = self.script.getInputEventHandlerKey(inputEvHand)
self._insertRowBraille(handl, com, inputEvHand, iterBB)
self.keyBindView.set_model(self.keyBindingsModel)
self.keyBindView.set_headers_visible(True)
self.keyBindView.expand_all()
self.keyBindingsModel.set_sort_column_id(OLDTEXT1, Gtk.SortType.ASCENDING)
self.keyBindView.show()
# Keep track of new/unbound keybindings that have yet to be applied.
#
self.pendingKeyBindings = {}
def _cleanupSpeechServers(self):
"""Remove unwanted factories and drivers for the current active
factory, when the user dismisses the Orca Preferences dialog."""
for workingFactory in self.workingFactories:
if not (workingFactory == self.speechSystemsChoice):
workingFactory.SpeechServer.shutdownActiveServers()
else:
servers = workingFactory.SpeechServer.getSpeechServers()
for server in servers:
if not (server == self.speechServersChoice):
server.shutdown()
def speechSupportChecked(self, widget):
"""Signal handler for the "toggled" signal for the
speechSupportCheckButton GtkCheckButton widget. The user has
[un]checked the 'Enable Speech' checkbox. Set the 'enableSpeech'
preference to the new value. Set the rest of the speech pane items
[in]sensensitive depending upon whether this checkbox is checked.
Arguments:
- widget: the component that generated the signal.
"""
enable = widget.get_active()
self.prefsDict["enableSpeech"] = enable
self.get_widget("speechOptionsGrid").set_sensitive(enable)
def onlySpeakDisplayedTextToggled(self, widget):
"""Signal handler for the "toggled" signal for the GtkCheckButton
onlySpeakDisplayedText. In addition to updating the preferences,
set the sensitivity of the contextOptionsGrid.
Arguments:
- widget: the component that generated the signal.
"""
enable = widget.get_active()
self.prefsDict["onlySpeakDisplayedText"] = enable
self.get_widget("contextOptionsGrid").set_sensitive(not enable)
def speechSystemsChanged(self, widget):
"""Signal handler for the "changed" signal for the speechSystems
GtkComboBox widget. The user has selected a different speech
system. Clear the existing list of speech servers, and setup
a new list of speech servers based on the new choice. Setup a
new list of voices for the first speech server in the list.
Arguments:
- widget: the component that generated the signal.
"""
if self.initializingSpeech:
return
selectedIndex = widget.get_active()
self.speechSystemsChoice = self.speechSystemsChoices[selectedIndex]
self._setupSpeechServers()
def speechServersChanged(self, widget):
"""Signal handler for the "changed" signal for the speechServers
GtkComboBox widget. The user has selected a different speech
server. Clear the existing list of voices, and setup a new
list of voices based on the new choice.
Arguments:
- widget: the component that generated the signal.
"""
if self.initializingSpeech:
return
selectedIndex = widget.get_active()
self.speechServersChoice = self.speechServersChoices[selectedIndex]
# Whenever the speech servers change, we need to make sure we
# clear whatever family was in use by the current voice types.
# Otherwise, we can end up with family names from one server
# bleeding over (e.g., "Paul" from Fonix ends up getting in
# the "Default" voice type after we switch to eSpeak).
#
try:
del self.defaultVoice[acss.ACSS.FAMILY]
del self.uppercaseVoice[acss.ACSS.FAMILY]
del self.hyperlinkVoice[acss.ACSS.FAMILY]
del self.systemVoice[acss.ACSS.FAMILY]
except:
pass
self._setupVoices()
def speechLanguagesChanged(self, widget):
"""Signal handler for the "value_changed" signal for the languages
GtkComboBox widget. The user has selected a different voice
language. Save the new voice language name based on the new choice.
Arguments:
- widget: the component that generated the signal.
"""
if self.initializingSpeech:
return
selectedIndex = widget.get_active()
try:
self.speechLanguagesChoice = self.speechLanguagesChoices[selectedIndex]
if (self.speechServersChoice, self.speechLanguagesChoice) in \
self.selectedFamilyChoices:
i = self.selectedFamilyChoices[self.speechServersChoice, \
self.speechLanguagesChoice]
family = self.speechFamiliesChoices[i]
name = family[speechserver.VoiceFamily.NAME]
language = family[speechserver.VoiceFamily.LANG]
dialect = family[speechserver.VoiceFamily.DIALECT]
variant = family[speechserver.VoiceFamily.VARIANT]
voiceType = self.get_widget("voiceTypesCombo").get_active()
self._setFamilyNameForVoiceType(voiceType, name, language, dialect, variant)
except:
debug.printException(debug.LEVEL_SEVERE)
# Remember the last family manually selected by the user for the
# current speech server.
#
if not selectedIndex == -1:
self.selectedLanguageChoices[self.speechServersChoice] = selectedIndex
self._setupFamilies()
def speechFamiliesChanged(self, widget):
"""Signal handler for the "value_changed" signal for the families
GtkComboBox widget. The user has selected a different voice
family. Save the new voice family name based on the new choice.
Arguments:
- widget: the component that generated the signal.
"""
if self.initializingSpeech:
return
selectedIndex = widget.get_active()
try:
family = self.speechFamiliesChoices[selectedIndex]
name = family[speechserver.VoiceFamily.NAME]
language = family[speechserver.VoiceFamily.LANG]
dialect = family[speechserver.VoiceFamily.DIALECT]
variant = family[speechserver.VoiceFamily.VARIANT]
voiceType = self.get_widget("voiceTypesCombo").get_active()
self._setFamilyNameForVoiceType(voiceType, name, language, dialect, variant)
except:
debug.printException(debug.LEVEL_SEVERE)
# Remember the last family manually selected by the user for the
# current speech server.
#
if not selectedIndex == -1:
self.selectedFamilyChoices[self.speechServersChoice, \
self.speechLanguagesChoice] = selectedIndex
def voiceTypesChanged(self, widget):
"""Signal handler for the "changed" signal for the voiceTypes
GtkComboBox widget. The user has selected a different voice
type. Setup the new family, rate, pitch and volume component
values based on the new choice.
Arguments:
- widget: the component that generated the signal.
"""
if self.initializingSpeech:
return
voiceType = widget.get_active()
self._setVoiceSettingsForVoiceType(voiceType)
def rateValueChanged(self, widget):
"""Signal handler for the "value_changed" signal for the rateScale
GtkScale widget. The user has changed the current rate value.
Save the new rate value based on the currently selected voice
type.
Arguments:
- widget: the component that generated the signal.
"""
rate = widget.get_value()
voiceType = self.get_widget("voiceTypesCombo").get_active()
self._setRateForVoiceType(voiceType, rate)
voices = _settingsManager.getSetting('voices')
voices[settings.DEFAULT_VOICE][acss.ACSS.RATE] = rate
_settingsManager.setSetting('voices', voices)
def pitchValueChanged(self, widget):
"""Signal handler for the "value_changed" signal for the pitchScale
GtkScale widget. The user has changed the current pitch value.
Save the new pitch value based on the currently selected voice
type.
Arguments:
- widget: the component that generated the signal.
"""
pitch = widget.get_value()
voiceType = self.get_widget("voiceTypesCombo").get_active()
self._setPitchForVoiceType(voiceType, pitch)
voices = _settingsManager.getSetting('voices')
voices[settings.DEFAULT_VOICE][acss.ACSS.AVERAGE_PITCH] = pitch
_settingsManager.setSetting('voices', voices)
def volumeValueChanged(self, widget):
"""Signal handler for the "value_changed" signal for the voiceScale
GtkScale widget. The user has changed the current volume value.
Save the new volume value based on the currently selected voice
type.
Arguments:
- widget: the component that generated the signal.
"""
volume = widget.get_value()
voiceType = self.get_widget("voiceTypesCombo").get_active()
self._setVolumeForVoiceType(voiceType, volume)
voices = _settingsManager.getSetting('voices')
voices[settings.DEFAULT_VOICE][acss.ACSS.GAIN] = volume
_settingsManager.setSetting('voices', voices)
def checkButtonToggled(self, widget):
"""Signal handler for "toggled" signal for basic GtkCheckButton
widgets. The user has altered the state of the checkbox.
Set the preference to the new value.
Arguments:
- widget: the component that generated the signal.
"""
# To use this default handler please make sure:
# The name of the setting that will be changed is: settingName
# The id of the widget in the ui should be: settingNameCheckButton
#
settingName = Gtk.Buildable.get_name(widget)
# strip "CheckButton" from the end.
settingName = settingName[:-11]
self.prefsDict[settingName] = widget.get_active()
def keyEchoChecked(self, widget):
"""Signal handler for the "toggled" signal for the
keyEchoCheckbutton GtkCheckButton widget. The user has
[un]checked the 'Enable Key Echo' checkbox. Set the
'enableKeyEcho' preference to the new value. [In]sensitize
the checkboxes for the various types of key echo, depending
upon whether this value is checked or unchecked.
Arguments:
- widget: the component that generated the signal.
"""
self.prefsDict["enableKeyEcho"] = widget.get_active()
self._setKeyEchoItems()
def brailleSelectionChanged(self, widget):
"""Signal handler for the "toggled" signal for the
brailleSelectionNoneButton, brailleSelection7Button,
brailleSelection8Button or brailleSelectionBothButton
GtkRadioButton widgets. The user has toggled the braille
selection indicator value. If this signal was generated
as the result of a radio button getting selected (as
opposed to a radio button losing the selection), set the
'brailleSelectorIndicator' preference to the new value.
Arguments:
- widget: the component that generated the signal.
"""
if widget.get_active():
if widget.get_label() == guilabels.BRAILLE_DOT_7:
self.prefsDict["brailleSelectorIndicator"] = \
settings.BRAILLE_UNDERLINE_7
elif widget.get_label() == guilabels.BRAILLE_DOT_8:
self.prefsDict["brailleSelectorIndicator"] = \
settings.BRAILLE_UNDERLINE_8
elif widget.get_label() == guilabels.BRAILLE_DOT_7_8:
self.prefsDict["brailleSelectorIndicator"] = \
settings.BRAILLE_UNDERLINE_BOTH
else:
self.prefsDict["brailleSelectorIndicator"] = \
settings.BRAILLE_UNDERLINE_NONE
def brailleLinkChanged(self, widget):
"""Signal handler for the "toggled" signal for the
brailleLinkNoneButton, brailleLink7Button,
brailleLink8Button or brailleLinkBothButton
GtkRadioButton widgets. The user has toggled the braille
link indicator value. If this signal was generated
as the result of a radio button getting selected (as
opposed to a radio button losing the selection), set the
'brailleLinkIndicator' preference to the new value.
Arguments:
- widget: the component that generated the signal.
"""
if widget.get_active():
if widget.get_label() == guilabels.BRAILLE_DOT_7:
self.prefsDict["brailleLinkIndicator"] = \
settings.BRAILLE_UNDERLINE_7
elif widget.get_label() == guilabels.BRAILLE_DOT_8:
self.prefsDict["brailleLinkIndicator"] = \
settings.BRAILLE_UNDERLINE_8
elif widget.get_label() == guilabels.BRAILLE_DOT_7_8:
self.prefsDict["brailleLinkIndicator"] = \
settings.BRAILLE_UNDERLINE_BOTH
else:
self.prefsDict["brailleLinkIndicator"] = \
settings.BRAILLE_UNDERLINE_NONE
def brailleIndicatorChanged(self, widget):
"""Signal handler for the "toggled" signal for the
textBrailleNoneButton, textBraille7Button, textBraille8Button
or textBrailleBothButton GtkRadioButton widgets. The user has
toggled the text attributes braille indicator value. If this signal
was generated as the result of a radio button getting selected
(as opposed to a radio button losing the selection), set the
'textAttributesBrailleIndicator' preference to the new value.
Arguments:
- widget: the component that generated the signal.
"""
if widget.get_active():
if widget.get_label() == guilabels.BRAILLE_DOT_7:
self.prefsDict["textAttributesBrailleIndicator"] = \
settings.BRAILLE_UNDERLINE_7
elif widget.get_label() == guilabels.BRAILLE_DOT_8:
self.prefsDict["textAttributesBrailleIndicator"] = \
settings.BRAILLE_UNDERLINE_8
elif widget.get_label() == guilabels.BRAILLE_DOT_7_8:
self.prefsDict["textAttributesBrailleIndicator"] = \
settings.BRAILLE_UNDERLINE_BOTH
else:
self.prefsDict["textAttributesBrailleIndicator"] = \
settings.BRAILLE_UNDERLINE_NONE
def punctuationLevelChanged(self, widget):
"""Signal handler for the "toggled" signal for the noneButton,
someButton or allButton GtkRadioButton widgets. The user has
toggled the speech punctuation level value. If this signal
was generated as the result of a radio button getting selected
(as opposed to a radio button losing the selection), set the
'verbalizePunctuationStyle' preference to the new value.
Arguments:
- widget: the component that generated the signal.
"""
if widget.get_active():
if widget.get_label() == guilabels.PUNCTUATION_STYLE_NONE:
self.prefsDict["verbalizePunctuationStyle"] = \
settings.PUNCTUATION_STYLE_NONE
elif widget.get_label() == guilabels.PUNCTUATION_STYLE_SOME:
self.prefsDict["verbalizePunctuationStyle"] = \
settings.PUNCTUATION_STYLE_SOME
elif widget.get_label() == guilabels.PUNCTUATION_STYLE_MOST:
self.prefsDict["verbalizePunctuationStyle"] = \
settings.PUNCTUATION_STYLE_MOST
else:
self.prefsDict["verbalizePunctuationStyle"] = \
settings.PUNCTUATION_STYLE_ALL
def orcaModifierChanged(self, widget):
"""Signal handler for the changed signal for the orcaModifierComboBox
Set the 'orcaModifierKeys' preference to the new value.
Arguments:
- widget: the component that generated the signal.
"""
model = widget.get_model()
myIter = widget.get_active_iter()
orcaModifier = model[myIter][0]
self.prefsDict["orcaModifierKeys"] = orcaModifier.split(', ')
def progressBarVerbosityChanged(self, widget):
"""Signal handler for the changed signal for the progressBarVerbosity
GtkComboBox widget. Set the 'progressBarVerbosity' preference to
the new value.
Arguments:
- widget: the component that generated the signal.
"""
model = widget.get_model()
myIter = widget.get_active_iter()
progressBarVerbosity = model[myIter][0]
if progressBarVerbosity == guilabels.PROGRESS_BAR_ALL:
self.prefsDict["progressBarVerbosity"] = \
settings.PROGRESS_BAR_ALL
elif progressBarVerbosity == guilabels.PROGRESS_BAR_WINDOW:
self.prefsDict["progressBarVerbosity"] = \
settings.PROGRESS_BAR_WINDOW
else:
self.prefsDict["progressBarVerbosity"] = \
settings.PROGRESS_BAR_APPLICATION
def capitalizationStyleChanged(self, widget):
model = widget.get_model()
myIter = widget.get_active_iter()
capitalizationStyle = model[myIter][0]
if capitalizationStyle == guilabels.CAPITALIZATION_STYLE_ICON:
self.prefsDict["capitalizationStyle"] = settings.CAPITALIZATION_STYLE_ICON
elif capitalizationStyle == guilabels.CAPITALIZATION_STYLE_SPELL:
self.prefsDict["capitalizationStyle"] = settings.CAPITALIZATION_STYLE_SPELL
else:
self.prefsDict["capitalizationStyle"] = settings.CAPITALIZATION_STYLE_NONE
speech.updateCapitalizationStyle()
def sayAllStyleChanged(self, widget):
"""Signal handler for the "changed" signal for the sayAllStyle
GtkComboBox widget. Set the 'sayAllStyle' preference to the
new value.
Arguments:
- widget: the component that generated the signal.
"""
model = widget.get_model()
myIter = widget.get_active_iter()
sayAllStyle = model[myIter][0]
if sayAllStyle == guilabels.SAY_ALL_STYLE_LINE:
self.prefsDict["sayAllStyle"] = settings.SAYALL_STYLE_LINE
elif sayAllStyle == guilabels.SAY_ALL_STYLE_SENTENCE:
self.prefsDict["sayAllStyle"] = settings.SAYALL_STYLE_SENTENCE
def dateFormatChanged(self, widget):
"""Signal handler for the "changed" signal for the dateFormat
GtkComboBox widget. Set the 'dateFormat' preference to the
new value.
Arguments:
- widget: the component that generated the signal.
"""
dateFormatCombo = widget.get_active()
if dateFormatCombo == DATE_FORMAT_LOCALE:
newFormat = messages.DATE_FORMAT_LOCALE
elif dateFormatCombo == DATE_FORMAT_NUMBERS_DM:
newFormat = messages.DATE_FORMAT_NUMBERS_DM
elif dateFormatCombo == DATE_FORMAT_NUMBERS_MD:
newFormat = messages.DATE_FORMAT_NUMBERS_MD
elif dateFormatCombo == DATE_FORMAT_NUMBERS_DMY:
newFormat = messages.DATE_FORMAT_NUMBERS_DMY
elif dateFormatCombo == DATE_FORMAT_NUMBERS_MDY:
newFormat = messages.DATE_FORMAT_NUMBERS_MDY
elif dateFormatCombo == DATE_FORMAT_NUMBERS_YMD:
newFormat = messages.DATE_FORMAT_NUMBERS_YMD
elif dateFormatCombo == DATE_FORMAT_FULL_DM:
newFormat = messages.DATE_FORMAT_FULL_DM
elif dateFormatCombo == DATE_FORMAT_FULL_MD:
newFormat = messages.DATE_FORMAT_FULL_MD
elif dateFormatCombo == DATE_FORMAT_FULL_DMY:
newFormat = messages.DATE_FORMAT_FULL_DMY
elif dateFormatCombo == DATE_FORMAT_FULL_MDY:
newFormat = messages.DATE_FORMAT_FULL_MDY
elif dateFormatCombo == DATE_FORMAT_FULL_YMD:
newFormat = messages.DATE_FORMAT_FULL_YMD
elif dateFormatCombo == DATE_FORMAT_ABBREVIATED_DM:
newFormat = messages.DATE_FORMAT_ABBREVIATED_DM
elif dateFormatCombo == DATE_FORMAT_ABBREVIATED_MD:
newFormat = messages.DATE_FORMAT_ABBREVIATED_MD
elif dateFormatCombo == DATE_FORMAT_ABBREVIATED_DMY:
newFormat = messages.DATE_FORMAT_ABBREVIATED_DMY
elif dateFormatCombo == DATE_FORMAT_ABBREVIATED_MDY:
newFormat = messages.DATE_FORMAT_ABBREVIATED_MDY
elif dateFormatCombo == DATE_FORMAT_ABBREVIATED_YMD:
newFormat = messages.DATE_FORMAT_ABBREVIATED_YMD
self.prefsDict["presentDateFormat"] = newFormat
def timeFormatChanged(self, widget):
"""Signal handler for the "changed" signal for the timeFormat
GtkComboBox widget. Set the 'timeFormat' preference to the
new value.
Arguments:
- widget: the component that generated the signal.
"""
timeFormatCombo = widget.get_active()
if timeFormatCombo == TIME_FORMAT_LOCALE:
newFormat = messages.TIME_FORMAT_LOCALE
elif timeFormatCombo == TIME_FORMAT_12_HM:
newFormat = messages.TIME_FORMAT_12_HM
elif timeFormatCombo == TIME_FORMAT_12_HMS:
newFormat = messages.TIME_FORMAT_12_HMS
elif timeFormatCombo == TIME_FORMAT_24_HMS:
newFormat = messages.TIME_FORMAT_24_HMS
elif timeFormatCombo == TIME_FORMAT_24_HMS_WITH_WORDS:
newFormat = messages.TIME_FORMAT_24_HMS_WITH_WORDS
elif timeFormatCombo == TIME_FORMAT_24_HM:
newFormat = messages.TIME_FORMAT_24_HM
elif timeFormatCombo == TIME_FORMAT_24_HM_WITH_WORDS:
newFormat = messages.TIME_FORMAT_24_HM_WITH_WORDS
self.prefsDict["presentTimeFormat"] = newFormat
def speechVerbosityChanged(self, widget):
"""Signal handler for the "toggled" signal for the speechBriefButton,
or speechVerboseButton GtkRadioButton widgets. The user has
toggled the speech verbosity level value. If this signal was
generated as the result of a radio button getting selected
(as opposed to a radio button losing the selection), set the
'speechVerbosityLevel' preference to the new value.
Arguments:
- widget: the component that generated the signal.
"""
if widget.get_active():
if widget.get_label() == guilabels.VERBOSITY_LEVEL_BRIEF:
self.prefsDict["speechVerbosityLevel"] = \
settings.VERBOSITY_LEVEL_BRIEF
else:
self.prefsDict["speechVerbosityLevel"] = \
settings.VERBOSITY_LEVEL_VERBOSE
def progressBarUpdateIntervalValueChanged(self, widget):
"""Signal handler for the "value_changed" signal for the
progressBarUpdateIntervalSpinButton GtkSpinButton widget.
Arguments:
- widget: the component that generated the signal.
"""
self.prefsDict["progressBarUpdateInterval"] = widget.get_value_as_int()
def brailleFlashTimeValueChanged(self, widget):
self.prefsDict["brailleFlashTime"] = widget.get_value_as_int() * 1000
def abbrevRolenamesChecked(self, widget):
"""Signal handler for the "toggled" signal for the abbrevRolenames
GtkCheckButton widget. The user has [un]checked the 'Abbreviated
Rolenames' checkbox. Set the 'brailleRolenameStyle' preference
to the new value.
Arguments:
- widget: the component that generated the signal.
"""
if widget.get_active():
self.prefsDict["brailleRolenameStyle"] = \
settings.BRAILLE_ROLENAME_STYLE_SHORT
else:
self.prefsDict["brailleRolenameStyle"] = \
settings.BRAILLE_ROLENAME_STYLE_LONG
def brailleVerbosityChanged(self, widget):
"""Signal handler for the "toggled" signal for the brailleBriefButton,
or brailleVerboseButton GtkRadioButton widgets. The user has
toggled the braille verbosity level value. If this signal was
generated as the result of a radio button getting selected
(as opposed to a radio button losing the selection), set the
'brailleVerbosityLevel' preference to the new value.
Arguments:
- widget: the component that generated the signal.
"""
if widget.get_active():
if widget.get_label() == guilabels.VERBOSITY_LEVEL_BRIEF:
self.prefsDict["brailleVerbosityLevel"] = \
settings.VERBOSITY_LEVEL_BRIEF
else:
self.prefsDict["brailleVerbosityLevel"] = \
settings.VERBOSITY_LEVEL_VERBOSE
def keyModifiedToggle(self, cell, path, model, col):
"""When the user changes a checkbox field (boolean field)"""
model[path][col] = not model[path][col]
return
def editingKey(self, cell, editable, path, treeModel):
"""Starts user input of a Key for a selected key binding"""
self._presentMessage(messages.KB_ENTER_NEW_KEY)
orca_state.capturingKeys = True
editable.connect('key-press-event', self.kbKeyPressed)
return
def editingCanceledKey(self, editable):
"""Stops user input of a Key for a selected key binding"""
orca_state.capturingKeys = False
self._capturedKey = []
return
def _processKeyCaptured(self, keyPressedEvent):
"""Called when a new key event arrives and we are capturing keys.
(used for key bindings redefinition)
"""
# We want the keyname rather than the printable character.
# If it's not on the keypad, get the name of the unshifted
# character. (i.e. "1" instead of "!")
#
keycode = keyPressedEvent.hardware_keycode
keymap = Gdk.Keymap.get_default()
entries_for_keycode = keymap.get_entries_for_keycode(keycode)
entries = entries_for_keycode[-1]
eventString = Gdk.keyval_name(entries[0])
eventState = keyPressedEvent.state
orcaMods = settings.orcaModifierKeys
if eventString in orcaMods:
self._capturedKey = ['', keybindings.ORCA_MODIFIER_MASK, 0]
return False
modifierKeys = ['Alt_L', 'Alt_R', 'Control_L', 'Control_R',
'Shift_L', 'Shift_R', 'Meta_L', 'Meta_R',
'Num_Lock', 'Caps_Lock', 'Shift_Lock']
if eventString in modifierKeys:
return False
eventState = eventState & Gtk.accelerator_get_default_mod_mask()
if not self._capturedKey \
or eventString in ['Return', 'Escape']:
self._capturedKey = [eventString, eventState, 1]
return True
string, modifiers, clickCount = self._capturedKey
isOrcaModifier = modifiers & keybindings.ORCA_MODIFIER_MASK
if isOrcaModifier:
eventState |= keybindings.ORCA_MODIFIER_MASK
self._capturedKey = [eventString, eventState, clickCount + 1]
return True
def kbKeyPressed(self, editable, event):
"""Special handler for the key_pressed events when editing the
keybindings. This lets us control what gets inserted into the
entry.
"""
keyProcessed = self._processKeyCaptured(event)
if not keyProcessed:
return True
if not self._capturedKey:
return False
keyName, modifiers, clickCount = self._capturedKey
if not keyName or keyName in ["Return", "Escape"]:
return False
isOrcaModifier = modifiers & keybindings.ORCA_MODIFIER_MASK
if keyName in ["Delete", "BackSpace"] and not isOrcaModifier:
editable.set_text("")
self._presentMessage(messages.KB_DELETED)
self._capturedKey = []
self.newBinding = None
return True
self.newBinding = keybindings.KeyBinding(keyName,
keybindings.defaultModifierMask,
modifiers,
None,
clickCount)
modifierNames = keybindings.getModifierNames(modifiers)
clickCountString = self._clickCountToString(clickCount)
newString = modifierNames + keyName + clickCountString
description = self.pendingKeyBindings.get(newString)
if description is None:
match = lambda x: x.keysymstring == keyName \
and x.modifiers == modifiers \
and x.click_count == clickCount \
and x.handler
matches = list(filter(match, self.kbindings.keyBindings))
if matches:
description = matches[0].handler.description
if description:
msg = messages.KB_ALREADY_BOUND % description
delay = int(1000 * settings.doubleClickTimeout)
GLib.timeout_add(delay, self._presentMessage, msg)
else:
msg = messages.KB_CAPTURED % newString
editable.set_text(newString)
self._presentMessage(msg)
return True
def editedKey(self, cell, path, new_text, treeModel,
modMask, modUsed, key, click_count, text):
"""The user changed the key for a Keybinding: update the model of
the treeview.
"""
orca_state.capturingKeys = False
self._capturedKey = []
myiter = treeModel.get_iter_from_string(path)
try:
originalBinding = treeModel.get_value(myiter, text)
except:
originalBinding = ''
modified = (originalBinding != new_text)
try:
string = self.newBinding.keysymstring
mods = self.newBinding.modifiers
clickCount = self.newBinding.click_count
except:
string = ''
mods = 0
clickCount = 1
mods = mods & Gdk.ModifierType.MODIFIER_MASK
if mods & (1 << pyatspi.MODIFIER_SHIFTLOCK) \
and mods & keybindings.ORCA_MODIFIER_MASK:
mods ^= (1 << pyatspi.MODIFIER_SHIFTLOCK)
treeModel.set(myiter,
modMask, str(keybindings.defaultModifierMask),
modUsed, str(int(mods)),
key, string,
text, new_text,
click_count, str(clickCount),
MODIF, modified)
speech.stop()
if new_text:
message = messages.KB_CAPTURED_CONFIRMATION % new_text
description = treeModel.get_value(myiter, DESCRIP)
self.pendingKeyBindings[new_text] = description
else:
message = messages.KB_DELETED_CONFIRMATION
if modified:
self._presentMessage(message)
self.pendingKeyBindings[originalBinding] = ""
return
def presentToolTipsChecked(self, widget):
"""Signal handler for the "toggled" signal for the
presentToolTipsCheckButton GtkCheckButton widget.
The user has [un]checked the 'Present ToolTips'
checkbox. Set the 'presentToolTips'
preference to the new value if the user can present tooltips.
Arguments:
- widget: the component that generated the signal.
"""
self.prefsDict["presentToolTips"] = widget.get_active()
def keyboardLayoutChanged(self, widget):
"""Signal handler for the "toggled" signal for the generalDesktopButton,
or generalLaptopButton GtkRadioButton widgets. The user has
toggled the keyboard layout value. If this signal was
generated as the result of a radio button getting selected
(as opposed to a radio button losing the selection), set the
'keyboardLayout' preference to the new value. Also set the
matching list of Orca modifier keys
Arguments:
- widget: the component that generated the signal.
"""
if widget.get_active():
if widget.get_label() == guilabels.KEYBOARD_LAYOUT_DESKTOP:
self.prefsDict["keyboardLayout"] = \
settings.GENERAL_KEYBOARD_LAYOUT_DESKTOP
self.prefsDict["orcaModifierKeys"] = \
settings.DESKTOP_MODIFIER_KEYS
else:
self.prefsDict["keyboardLayout"] = \
settings.GENERAL_KEYBOARD_LAYOUT_LAPTOP
self.prefsDict["orcaModifierKeys"] = \
settings.LAPTOP_MODIFIER_KEYS
def pronunciationAddButtonClicked(self, widget):
"""Signal handler for the "clicked" signal for the
pronunciationAddButton GtkButton widget. The user has clicked
the Add button on the Pronunciation pane. A new row will be
added to the end of the pronunciation dictionary list. Both the
actual and replacement strings will initially be set to an empty
string. Focus will be moved to that row.
Arguments:
- widget: the component that generated the signal.
"""
model = self.pronunciationView.get_model()
thisIter = model.append()
model.set(thisIter, ACTUAL, "", REPLACEMENT, "")
path = model.get_path(thisIter)
col = self.pronunciationView.get_column(0)
self.pronunciationView.grab_focus()
self.pronunciationView.set_cursor(path, col, True)
def pronunciationDeleteButtonClicked(self, widget):
"""Signal handler for the "clicked" signal for the
pronunciationDeleteButton GtkButton widget. The user has clicked
the Delete button on the Pronunciation pane. The row in the
pronunciation dictionary list with focus will be deleted.
Arguments:
- widget: the component that generated the signal.
"""
model, oldIter = self.pronunciationView.get_selection().get_selected()
model.remove(oldIter)
def textSelectAllButtonClicked(self, widget):
"""Signal handler for the "clicked" signal for the
textSelectAllButton GtkButton widget. The user has clicked
the Speak all button. Check all the text attributes and
then update the "enabledSpokenTextAttributes" and
"enabledBrailledTextAttributes" preference strings.
Arguments:
- widget: the component that generated the signal.
"""
attributes = _settingsManager.getSetting('allTextAttributes')
self._setSpokenTextAttributes(
self.getTextAttributesView, attributes, True)
self._setBrailledTextAttributes(
self.getTextAttributesView, attributes, True)
self._updateTextDictEntry()
def textUnselectAllButtonClicked(self, widget):
"""Signal handler for the "clicked" signal for the
textUnselectAllButton GtkButton widget. The user has clicked
the Speak none button. Uncheck all the text attributes and
then update the "enabledSpokenTextAttributes" and
"enabledBrailledTextAttributes" preference strings.
Arguments:
- widget: the component that generated the signal.
"""
attributes = _settingsManager.getSetting('allTextAttributes')
self._setSpokenTextAttributes(
self.getTextAttributesView, attributes, False)
self._setBrailledTextAttributes(
self.getTextAttributesView, attributes, False)
self._updateTextDictEntry()
def textResetButtonClicked(self, widget):
"""Signal handler for the "clicked" signal for the
textResetButton GtkButton widget. The user has clicked
the Reset button. Reset all the text attributes to their
initial state and then update the "enabledSpokenTextAttributes"
and "enabledBrailledTextAttributes" preference strings.
Arguments:
- widget: the component that generated the signal.
"""
attributes = _settingsManager.getSetting('allTextAttributes')
self._setSpokenTextAttributes(
self.getTextAttributesView, attributes, False)
self._setBrailledTextAttributes(
self.getTextAttributesView, attributes, False)
attributes = _settingsManager.getSetting('enabledSpokenTextAttributes')
self._setSpokenTextAttributes(
self.getTextAttributesView, attributes, True)
attributes = \
_settingsManager.getSetting('enabledBrailledTextAttributes')
self._setBrailledTextAttributes(
self.getTextAttributesView, attributes, True)
self._updateTextDictEntry()
def textMoveToTopButtonClicked(self, widget):
"""Signal handler for the "clicked" signal for the
textMoveToTopButton GtkButton widget. The user has clicked
the Move to top button. Move the selected rows in the text
attribute view to the very top of the list and then update
the "enabledSpokenTextAttributes" and "enabledBrailledTextAttributes"
preference strings.
Arguments:
- widget: the component that generated the signal.
"""
textSelection = self.getTextAttributesView.get_selection()
[model, paths] = textSelection.get_selected_rows()
for path in paths:
thisIter = model.get_iter(path)
model.move_after(thisIter, None)
self._updateTextDictEntry()
def textMoveUpOneButtonClicked(self, widget):
"""Signal handler for the "clicked" signal for the
textMoveUpOneButton GtkButton widget. The user has clicked
the Move up one button. Move the selected rows in the text
attribute view up one row in the list and then update the
"enabledSpokenTextAttributes" and "enabledBrailledTextAttributes"
preference strings.
Arguments:
- widget: the component that generated the signal.
"""
textSelection = self.getTextAttributesView.get_selection()
[model, paths] = textSelection.get_selected_rows()
for path in paths:
thisIter = model.get_iter(path)
indices = path.get_indices()
if indices[0]:
otherIter = model.iter_nth_child(None, indices[0]-1)
model.swap(thisIter, otherIter)
self._updateTextDictEntry()
def textMoveDownOneButtonClicked(self, widget):
"""Signal handler for the "clicked" signal for the
textMoveDownOneButton GtkButton widget. The user has clicked
the Move down one button. Move the selected rows in the text
attribute view down one row in the list and then update the
"enabledSpokenTextAttributes" and "enabledBrailledTextAttributes"
preference strings.
Arguments:
- widget: the component that generated the signal.
"""
textSelection = self.getTextAttributesView.get_selection()
[model, paths] = textSelection.get_selected_rows()
noRows = model.iter_n_children(None)
for path in paths:
thisIter = model.get_iter(path)
indices = path.get_indices()
if indices[0] < noRows-1:
otherIter = model.iter_next(thisIter)
model.swap(thisIter, otherIter)
self._updateTextDictEntry()
def textMoveToBottomButtonClicked(self, widget):
"""Signal handler for the "clicked" signal for the
textMoveToBottomButton GtkButton widget. The user has clicked
the Move to bottom button. Move the selected rows in the text
attribute view to the bottom of the list and then update the
"enabledSpokenTextAttributes" and "enabledBrailledTextAttributes"
preference strings.
Arguments:
- widget: the component that generated the signal.
"""
textSelection = self.getTextAttributesView.get_selection()
[model, paths] = textSelection.get_selected_rows()
for path in paths:
thisIter = model.get_iter(path)
model.move_before(thisIter, None)
self._updateTextDictEntry()
def helpButtonClicked(self, widget):
"""Signal handler for the "clicked" signal for the helpButton
GtkButton widget. The user has clicked the Help button.
Arguments:
- widget: the component that generated the signal.
"""
orca.helpForOrca(page="preferences")
def restoreSettings(self):
"""Restore the settings we saved away when opening the preferences
dialog."""
# Restore the default rate/pitch/gain,
# in case the user played with the sliders.
#
voices = _settingsManager.getSetting('voices')
defaultVoice = voices[settings.DEFAULT_VOICE]
defaultVoice[acss.ACSS.GAIN] = self.savedGain
defaultVoice[acss.ACSS.AVERAGE_PITCH] = self.savedPitch
defaultVoice[acss.ACSS.RATE] = self.savedRate
def saveBasicSettings(self):
if not self._isInitialSetup:
self.restoreSettings()
enable = self.get_widget("speechSupportCheckButton").get_active()
self.prefsDict["enableSpeech"] = enable
if self.speechSystemsChoice:
self.prefsDict["speechServerFactory"] = \
self.speechSystemsChoice.__name__
if self.speechServersChoice:
self.prefsDict["speechServerInfo"] = \
self.speechServersChoice.getInfo()
if self.defaultVoice is not None:
self.prefsDict["voices"] = {
settings.DEFAULT_VOICE: acss.ACSS(self.defaultVoice),
settings.UPPERCASE_VOICE: acss.ACSS(self.uppercaseVoice),
settings.HYPERLINK_VOICE: acss.ACSS(self.hyperlinkVoice),
settings.SYSTEM_VOICE: acss.ACSS(self.systemVoice),
}
def applyButtonClicked(self, widget):
"""Signal handler for the "clicked" signal for the applyButton
GtkButton widget. The user has clicked the Apply button.
Write out the users preferences. If GNOME accessibility hadn't
previously been enabled, warn the user that they will need to
log out. Shut down any active speech servers that were started.
Reload the users preferences to get the new speech, braille and
key echo value to take effect. Do not dismiss the configuration
window.
Arguments:
- widget: the component that generated the signal.
"""
self.saveBasicSettings()
activeProfile = self.getComboBoxList(self.profilesCombo)
startingProfile = self.getComboBoxList(self.startingProfileCombo)
self.prefsDict['profile'] = activeProfile
self.prefsDict['activeProfile'] = activeProfile
self.prefsDict['startingProfile'] = startingProfile
_settingsManager.setStartingProfile(startingProfile)
self.writeUserPreferences()
orca.loadUserSettings(self.script)
braille.checkBrailleSetting()
self._initSpeechState()
self._populateKeyBindings()
self.__initProfileCombo()
def cancelButtonClicked(self, widget):
"""Signal handler for the "clicked" signal for the cancelButton
GtkButton widget. The user has clicked the Cancel button.
Don't write out the preferences. Destroy the configuration window.
Arguments:
- widget: the component that generated the signal.
"""
self.windowClosed(widget)
self.get_widget("orcaSetupWindow").destroy()
def okButtonClicked(self, widget=None):
"""Signal handler for the "clicked" signal for the okButton
GtkButton widget. The user has clicked the OK button.
Write out the users preferences. If GNOME accessibility hadn't
previously been enabled, warn the user that they will need to
log out. Shut down any active speech servers that were started.
Reload the users preferences to get the new speech, braille and
key echo value to take effect. Hide the configuration window.
Arguments:
- widget: the component that generated the signal.
"""
self.applyButtonClicked(widget)
self._cleanupSpeechServers()
self.get_widget("orcaSetupWindow").destroy()
def windowClosed(self, widget):
"""Signal handler for the "closed" signal for the orcaSetupWindow
GtkWindow widget. This is effectively the same as pressing the
cancel button, except the window is destroyed for us.
Arguments:
- widget: the component that generated the signal.
"""
factory = _settingsManager.getSetting('speechServerFactory')
if factory:
self._setSpeechSystemsChoice(factory)
server = _settingsManager.getSetting('speechServerInfo')
if server:
self._setSpeechServersChoice(server)
self._cleanupSpeechServers()
self.restoreSettings()
def windowDestroyed(self, widget):
"""Signal handler for the "destroyed" signal for the orcaSetupWindow
GtkWindow widget. Reset orca_state.orcaOS to None, so that the
GUI can be rebuilt from the GtkBuilder file the next time the user
wants to display the configuration GUI.
Arguments:
- widget: the component that generated the signal.
"""
self.keyBindView.set_model(None)
self.getTextAttributesView.set_model(None)
self.pronunciationView.set_model(None)
self.keyBindView.set_headers_visible(False)
self.getTextAttributesView.set_headers_visible(False)
self.pronunciationView.set_headers_visible(False)
self.keyBindView.hide()
self.getTextAttributesView.hide()
self.pronunciationView.hide()
orca_state.orcaOS = None
def showProfileGUI(self, widget):
"""Show profile Dialog to add a new one"""
orca_gui_profile.showProfileUI(self)
def saveProfile(self, profileToSaveLabel):
"""Creates a new profile based on the name profileToSaveLabel and
updates the Preferences dialog combo boxes accordingly."""
if not profileToSaveLabel:
return
profileToSave = profileToSaveLabel.replace(' ', '_').lower()
profile = [profileToSaveLabel, profileToSave]
def saveActiveProfile(newProfile = True):
if newProfile:
activeProfileIter = self.profilesComboModel.append(profile)
self.profilesCombo.set_active_iter(activeProfileIter)
self.prefsDict['profile'] = profile
self.prefsDict['activeProfile'] = profile
self.saveBasicSettings()
self.writeUserPreferences()
availableProfiles = [p[1] for p in self.__getAvailableProfiles()]
if isinstance(profileToSave, str) \
and profileToSave != '' \
and not profileToSave in availableProfiles \
and profileToSave != self._defaultProfile[1]:
saveActiveProfile()
else:
if profileToSave is not None:
message = guilabels.PROFILE_CONFLICT_MESSAGE % \
("<b>%s</b>" % GLib.markup_escape_text(profileToSaveLabel))
dialog = Gtk.MessageDialog(None,
Gtk.DialogFlags.MODAL,
type=Gtk.MessageType.INFO,
buttons=Gtk.ButtonsType.YES_NO)
dialog.set_markup("<b>%s</b>" % guilabels.PROFILE_CONFLICT_LABEL)
dialog.format_secondary_markup(message)
dialog.set_title(guilabels.PROFILE_CONFLICT_TITLE)
response = dialog.run()
if response == Gtk.ResponseType.YES:
dialog.destroy()
saveActiveProfile(False)
else:
dialog.destroy()
def removeProfileButtonClicked(self, widget):
"""Remove profile button clicked handler
If we removed the last profile, a default one will automatically get
added back by the settings manager.
"""
oldProfile = self.getComboBoxList(self.profilesCombo)
message = guilabels.PROFILE_REMOVE_MESSAGE % \
("<b>%s</b>" % GLib.markup_escape_text(oldProfile[0]))
dialog = Gtk.MessageDialog(self.window, Gtk.DialogFlags.MODAL,
type=Gtk.MessageType.INFO,
buttons=Gtk.ButtonsType.YES_NO)
dialog.set_markup("<b>%s</b>" % guilabels.PROFILE_REMOVE_LABEL)
dialog.format_secondary_markup(message)
if dialog.run() == Gtk.ResponseType.YES:
# If we remove the currently used starting profile, fallback on
# the first listed profile, or the default one if there's
# nothing better
newStartingProfile = self.prefsDict.get('startingProfile')
if not newStartingProfile or newStartingProfile == oldProfile:
newStartingProfile = self._defaultProfile
for row in self.profilesComboModel:
rowProfile = row[:]
if rowProfile != oldProfile:
newStartingProfile = rowProfile
break
# Update the current profile to the active profile unless we're
# removing that one, in which case we use the new starting
# profile
newProfile = self.prefsDict.get('activeProfile')
if not newProfile or newProfile == oldProfile:
newProfile = newStartingProfile
_settingsManager.removeProfile(oldProfile[1])
self.loadProfile(newProfile)
# Make sure nothing is referencing the removed profile anymore
startingProfile = self.prefsDict.get('startingProfile')
if not startingProfile or startingProfile == oldProfile:
self.prefsDict['startingProfile'] = newStartingProfile
_settingsManager.setStartingProfile(newStartingProfile)
self.writeUserPreferences()
dialog.destroy()
def loadProfileButtonClicked(self, widget):
"""Load profile button clicked handler"""
if self._isInitialSetup:
return
dialog = Gtk.MessageDialog(None,
Gtk.DialogFlags.MODAL,
type=Gtk.MessageType.INFO,
buttons=Gtk.ButtonsType.YES_NO)
dialog.set_markup("<b>%s</b>" % guilabels.PROFILE_LOAD_LABEL)
dialog.format_secondary_markup(guilabels.PROFILE_LOAD_MESSAGE)
response = dialog.run()
if response == Gtk.ResponseType.YES:
dialog.destroy()
self.loadSelectedProfile()
else:
dialog.destroy()
def loadSelectedProfile(self):
"""Load selected profile"""
activeProfile = self.getComboBoxList(self.profilesCombo)
self.loadProfile(activeProfile)
def loadProfile(self, profile):
"""Load profile"""
self.saveBasicSettings()
self.prefsDict['activeProfile'] = profile
_settingsManager.setProfile(profile[1])
self.prefsDict = _settingsManager.getGeneralSettings(profile[1])
orca.loadUserSettings(skipReloadMessage=True)
self._initGUIState()
braille.checkBrailleSetting()
self._initSpeechState()
self._populateKeyBindings()
self.__initProfileCombo()
| Java |
# -*- coding: utf-8 -*-
# Copyright (C) 2010, 2011, 2012, 2013 Sebastian Wiesner <lunaryorn@gmail.com>
# This library is free software; you can redistribute it and/or modify it
# under the terms of the GNU Lesser General Public License as published by the
# Free Software Foundation; either version 2.1 of the License, or (at your
# option) any later version.
# This library is distributed in the hope that it will be useful, but WITHOUT
# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
# FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License
# for more details.
# You should have received a copy of the GNU Lesser General Public License
# along with this library; if not, write to the Free Software Foundation,
# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
# pylint: disable=anomalous-backslash-in-string
"""
pyudev.pyqt4
============
PyQt4 integration.
:class:`MonitorObserver` integrates device monitoring into the PyQt4\_
mainloop by turning device events into Qt signals.
:mod:`PyQt4.QtCore` from PyQt4\_ must be available when importing this
module.
.. _PyQt4: http://riverbankcomputing.co.uk/software/pyqt/intro
.. moduleauthor:: Sebastian Wiesner <lunaryorn@gmail.com>
"""
from __future__ import (print_function, division, unicode_literals,
absolute_import)
from PyQt4.QtCore import QSocketNotifier, QObject, pyqtSignal
from pyudev._util import text_type
from pyudev.core import Device
from pyudev._qt_base import QUDevMonitorObserverMixin, MonitorObserverMixin
class MonitorObserver(QObject, MonitorObserverMixin):
"""An observer for device events integrating into the :mod:`PyQt4` mainloop.
This class inherits :class:`~PyQt4.QtCore.QObject` to turn device events
into Qt signals:
>>> from pyudev import Context, Monitor
>>> from pyudev.pyqt4 import MonitorObserver
>>> context = Context()
>>> monitor = Monitor.from_netlink(context)
>>> monitor.filter_by(subsystem='input')
>>> observer = MonitorObserver(monitor)
>>> def device_event(device):
... print('event {0} on device {1}'.format(device.action, device))
>>> observer.deviceEvent.connect(device_event)
>>> monitor.start()
This class is a child of :class:`~PyQt4.QtCore.QObject`.
"""
#: emitted upon arbitrary device events
deviceEvent = pyqtSignal(Device)
def __init__(self, monitor, parent=None):
"""
Observe the given ``monitor`` (a :class:`~pyudev.Monitor`):
``parent`` is the parent :class:`~PyQt4.QtCore.QObject` of this
object. It is passed unchanged to the inherited constructor of
:class:`~PyQt4.QtCore.QObject`.
"""
QObject.__init__(self, parent)
self._setup_notifier(monitor, QSocketNotifier)
class QUDevMonitorObserver(QObject, QUDevMonitorObserverMixin):
"""An observer for device events integrating into the :mod:`PyQt4` mainloop.
.. deprecated:: 0.17
Will be removed in 1.0. Use :class:`MonitorObserver` instead.
"""
#: emitted upon arbitrary device events
deviceEvent = pyqtSignal(text_type, Device)
#: emitted, if a device was added
deviceAdded = pyqtSignal(Device)
#: emitted, if a device was removed
deviceRemoved = pyqtSignal(Device)
#: emitted, if a device was changed
deviceChanged = pyqtSignal(Device)
#: emitted, if a device was moved
deviceMoved = pyqtSignal(Device)
def __init__(self, monitor, parent=None):
"""
Observe the given ``monitor`` (a :class:`~pyudev.Monitor`):
``parent`` is the parent :class:`~PyQt4.QtCore.QObject` of this
object. It is passed unchanged to the inherited constructor of
:class:`~PyQt4.QtCore.QObject`.
"""
QObject.__init__(self, parent)
self._setup_notifier(monitor, QSocketNotifier)
| Java |
/**
******************************************************************************
* @file stm32l0xx_hal_usart_ex.h
* @author MCD Application Team
* @brief Header file of USART HAL Extended module.
******************************************************************************
* @attention
*
* <h2><center>© Copyright (c) 2016 STMicroelectronics.
* All rights reserved.</center></h2>
*
* This software component is licensed by ST under BSD 3-Clause license,
* the "License"; You may not use this file except in compliance with the
* License. You may obtain a copy of the License at:
* opensource.org/licenses/BSD-3-Clause
*
******************************************************************************
*/
/* Define to prevent recursive inclusion -------------------------------------*/
#ifndef STM32L0xx_HAL_USART_EX_H
#define STM32L0xx_HAL_USART_EX_H
#ifdef __cplusplus
extern "C" {
#endif
/* Includes ------------------------------------------------------------------*/
#include "stm32l0xx_hal_def.h"
/** @addtogroup STM32L0xx_HAL_Driver
* @{
*/
/** @addtogroup USARTEx
* @{
*/
/* Exported types ------------------------------------------------------------*/
/* Exported constants --------------------------------------------------------*/
/** @defgroup USARTEx_Exported_Constants USARTEx Exported Constants
* @{
*/
/** @defgroup USARTEx_Word_Length USARTEx Word Length
* @{
*/
#define USART_WORDLENGTH_7B ((uint32_t)USART_CR1_M1) /*!< 7-bit long USART frame */
#define USART_WORDLENGTH_8B 0x00000000U /*!< 8-bit long USART frame */
#define USART_WORDLENGTH_9B ((uint32_t)USART_CR1_M0) /*!< 9-bit long USART frame */
/**
* @}
*/
/**
* @}
*/
/* Private macros ------------------------------------------------------------*/
/** @defgroup USARTEx_Private_Macros USARTEx Private Macros
* @{
*/
/** @brief Report the USART clock source.
* @param __HANDLE__ specifies the USART Handle.
* @param __CLOCKSOURCE__ output variable.
* @retval the USART clocking source, written in __CLOCKSOURCE__.
*/
#if defined (STM32L051xx) || defined (STM32L052xx) || defined (STM32L053xx) || defined (STM32L061xx) || defined (STM32L062xx) || defined (STM32L063xx)
#define USART_GETCLOCKSOURCE(__HANDLE__,__CLOCKSOURCE__) \
do { \
if((__HANDLE__)->Instance == USART1) \
{ \
switch(__HAL_RCC_GET_USART1_SOURCE()) \
{ \
case RCC_USART1CLKSOURCE_PCLK2: \
(__CLOCKSOURCE__) = USART_CLOCKSOURCE_PCLK2; \
break; \
case RCC_USART1CLKSOURCE_HSI: \
(__CLOCKSOURCE__) = USART_CLOCKSOURCE_HSI; \
break; \
case RCC_USART1CLKSOURCE_SYSCLK: \
(__CLOCKSOURCE__) = USART_CLOCKSOURCE_SYSCLK; \
break; \
case RCC_USART1CLKSOURCE_LSE: \
(__CLOCKSOURCE__) = USART_CLOCKSOURCE_LSE; \
break; \
default: \
(__CLOCKSOURCE__) = USART_CLOCKSOURCE_UNDEFINED; \
break; \
} \
} \
else if((__HANDLE__)->Instance == USART2) \
{ \
switch(__HAL_RCC_GET_USART2_SOURCE()) \
{ \
case RCC_USART2CLKSOURCE_PCLK1: \
(__CLOCKSOURCE__) = USART_CLOCKSOURCE_PCLK1; \
break; \
case RCC_USART2CLKSOURCE_HSI: \
(__CLOCKSOURCE__) = USART_CLOCKSOURCE_HSI; \
break; \
case RCC_USART2CLKSOURCE_SYSCLK: \
(__CLOCKSOURCE__) = USART_CLOCKSOURCE_SYSCLK; \
break; \
case RCC_USART2CLKSOURCE_LSE: \
(__CLOCKSOURCE__) = USART_CLOCKSOURCE_LSE; \
break; \
default: \
(__CLOCKSOURCE__) = USART_CLOCKSOURCE_UNDEFINED; \
break; \
} \
} \
else \
{ \
(__CLOCKSOURCE__) = USART_CLOCKSOURCE_UNDEFINED; \
} \
} while(0U)
#elif defined(STM32L071xx) || defined (STM32L081xx) || defined(STM32L072xx) || defined (STM32L082xx) || defined(STM32L073xx) || defined (STM32L083xx)
#define USART_GETCLOCKSOURCE(__HANDLE__,__CLOCKSOURCE__) \
do { \
if((__HANDLE__)->Instance == USART1) \
{ \
switch(__HAL_RCC_GET_USART1_SOURCE()) \
{ \
case RCC_USART1CLKSOURCE_PCLK2: \
(__CLOCKSOURCE__) = USART_CLOCKSOURCE_PCLK2; \
break; \
case RCC_USART1CLKSOURCE_HSI: \
(__CLOCKSOURCE__) = USART_CLOCKSOURCE_HSI; \
break; \
case RCC_USART1CLKSOURCE_SYSCLK: \
(__CLOCKSOURCE__) = USART_CLOCKSOURCE_SYSCLK; \
break; \
case RCC_USART1CLKSOURCE_LSE: \
(__CLOCKSOURCE__) = USART_CLOCKSOURCE_LSE; \
break; \
default: \
(__CLOCKSOURCE__) = USART_CLOCKSOURCE_UNDEFINED; \
break; \
} \
} \
else if((__HANDLE__)->Instance == USART2) \
{ \
switch(__HAL_RCC_GET_USART2_SOURCE()) \
{ \
case RCC_USART2CLKSOURCE_PCLK1: \
(__CLOCKSOURCE__) = USART_CLOCKSOURCE_PCLK1; \
break; \
case RCC_USART2CLKSOURCE_HSI: \
(__CLOCKSOURCE__) = USART_CLOCKSOURCE_HSI; \
break; \
case RCC_USART2CLKSOURCE_SYSCLK: \
(__CLOCKSOURCE__) = USART_CLOCKSOURCE_SYSCLK; \
break; \
case RCC_USART2CLKSOURCE_LSE: \
(__CLOCKSOURCE__) = USART_CLOCKSOURCE_LSE; \
break; \
default: \
(__CLOCKSOURCE__) = USART_CLOCKSOURCE_UNDEFINED; \
break; \
} \
} \
else if((__HANDLE__)->Instance == USART4) \
{ \
(__CLOCKSOURCE__) = USART_CLOCKSOURCE_PCLK1; \
} \
else if((__HANDLE__)->Instance == USART5) \
{ \
(__CLOCKSOURCE__) = USART_CLOCKSOURCE_PCLK1; \
} \
else \
{ \
(__CLOCKSOURCE__) = USART_CLOCKSOURCE_UNDEFINED; \
} \
} while(0U)
#else
#define USART_GETCLOCKSOURCE(__HANDLE__,__CLOCKSOURCE__) \
do { \
if((__HANDLE__)->Instance == USART2) \
{ \
switch(__HAL_RCC_GET_USART2_SOURCE()) \
{ \
case RCC_USART2CLKSOURCE_PCLK1: \
(__CLOCKSOURCE__) = USART_CLOCKSOURCE_PCLK1; \
break; \
case RCC_USART2CLKSOURCE_HSI: \
(__CLOCKSOURCE__) = USART_CLOCKSOURCE_HSI; \
break; \
case RCC_USART2CLKSOURCE_SYSCLK: \
(__CLOCKSOURCE__) = USART_CLOCKSOURCE_SYSCLK; \
break; \
case RCC_USART2CLKSOURCE_LSE: \
(__CLOCKSOURCE__) = USART_CLOCKSOURCE_LSE; \
break; \
default: \
(__CLOCKSOURCE__) = USART_CLOCKSOURCE_UNDEFINED; \
break; \
} \
} \
else \
{ \
(__CLOCKSOURCE__) = USART_CLOCKSOURCE_UNDEFINED; \
} \
} while(0U)
#endif
/** @brief Compute the USART mask to apply to retrieve the received data
* according to the word length and to the parity bits activation.
* @note If PCE = 1, the parity bit is not included in the data extracted
* by the reception API().
* This masking operation is not carried out in the case of
* DMA transfers.
* @param __HANDLE__ specifies the USART Handle.
* @retval None, the mask to apply to USART RDR register is stored in (__HANDLE__)->Mask field.
*/
#define USART_MASK_COMPUTATION(__HANDLE__) \
do { \
if ((__HANDLE__)->Init.WordLength == USART_WORDLENGTH_9B) \
{ \
if ((__HANDLE__)->Init.Parity == USART_PARITY_NONE) \
{ \
(__HANDLE__)->Mask = 0x01FFU; \
} \
else \
{ \
(__HANDLE__)->Mask = 0x00FFU; \
} \
} \
else if ((__HANDLE__)->Init.WordLength == USART_WORDLENGTH_8B) \
{ \
if ((__HANDLE__)->Init.Parity == USART_PARITY_NONE) \
{ \
(__HANDLE__)->Mask = 0x00FFU; \
} \
else \
{ \
(__HANDLE__)->Mask = 0x007FU; \
} \
} \
else if ((__HANDLE__)->Init.WordLength == USART_WORDLENGTH_7B) \
{ \
if ((__HANDLE__)->Init.Parity == USART_PARITY_NONE) \
{ \
(__HANDLE__)->Mask = 0x007FU; \
} \
else \
{ \
(__HANDLE__)->Mask = 0x003FU; \
} \
} \
else \
{ \
(__HANDLE__)->Mask = 0x0000U; \
} \
} while(0U)
/**
* @brief Ensure that USART frame length is valid.
* @param __LENGTH__ USART frame length.
* @retval SET (__LENGTH__ is valid) or RESET (__LENGTH__ is invalid)
*/
#define IS_USART_WORD_LENGTH(__LENGTH__) (((__LENGTH__) == USART_WORDLENGTH_7B) || \
((__LENGTH__) == USART_WORDLENGTH_8B) || \
((__LENGTH__) == USART_WORDLENGTH_9B))
/**
* @}
*/
/* Exported functions --------------------------------------------------------*/
/** @addtogroup USARTEx_Exported_Functions
* @{
*/
/** @addtogroup USARTEx_Exported_Functions_Group1
* @{
*/
/* IO operation functions *****************************************************/
/**
* @}
*/
/** @addtogroup USARTEx_Exported_Functions_Group2
* @{
*/
/* Peripheral Control functions ***********************************************/
/**
* @}
*/
/**
* @}
*/
/**
* @}
*/
/**
* @}
*/
#ifdef __cplusplus
}
#endif
#endif /* STM32L0xx_HAL_USART_EX_H */
/************************ (C) COPYRIGHT STMicroelectronics *****END OF FILE****/
| Java |
/****************************************************************************
**
** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies).
** All rights reserved.
** Contact: Nokia Corporation (qt-info@nokia.com)
**
** This file is part of the Qt Mobility Components.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial Usage
** Licensees holding valid Qt Commercial licenses may use this file in
** accordance with the Qt Commercial License Agreement provided with
** the Software or, alternatively, in accordance with the terms
** contained in a written agreement between you and Nokia.
**
** GNU Lesser General Public License Usage
** Alternatively, this file may be used under the terms of the GNU Lesser
** General Public License version 2.1 as published by the Free Software
** Foundation and appearing in the file LICENSE.LGPL included in the
** packaging of this file. Please review the following information to
** ensure the GNU Lesser General Public License version 2.1 requirements
** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
**
** In addition, as a special exception, Nokia gives you certain additional
** rights. These rights are described in the Nokia Qt LGPL Exception
** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
**
** GNU General Public License Usage
** Alternatively, this file may be used under the terms of the GNU
** General Public License version 3.0 as published by the Free Software
** Foundation and appearing in the file LICENSE.GPL included in the
** packaging of this file. Please review the following information to
** ensure the GNU General Public License version 3.0 requirements will be
** met: http://www.gnu.org/copyleft/gpl.html.
**
** If you are unsure which license is appropriate for your use, please
** contact the sales department at qt-sales@nokia.com.
** $QT_END_LICENSE$
**
****************************************************************************/
#ifndef QGEOMAPPINGMANAGERENGINE_H
#define QGEOMAPPINGMANAGERENGINE_H
#include "qgraphicsgeomap.h"
#include <QObject>
#include <QSize>
#include <QPair>
class QLocale;
QTM_BEGIN_NAMESPACE
class QGeoBoundingBox;
class QGeoCoordinate;
class QGeoMapData;
class QGeoMappingManagerPrivate;
class QGeoMapRequestOptions;
class QGeoMappingManagerEnginePrivate;
class Q_LOCATION_EXPORT QGeoMappingManagerEngine : public QObject
{
Q_OBJECT
public:
QGeoMappingManagerEngine(const QMap<QString, QVariant> ¶meters, QObject *parent = 0);
virtual ~QGeoMappingManagerEngine();
QString managerName() const;
int managerVersion() const;
virtual QGeoMapData* createMapData() = 0;
QList<QGraphicsGeoMap::MapType> supportedMapTypes() const;
QList<QGraphicsGeoMap::ConnectivityMode> supportedConnectivityModes() const;
qreal minimumZoomLevel() const;
qreal maximumZoomLevel() const;
void setLocale(const QLocale &locale);
QLocale locale() const;
protected:
QGeoMappingManagerEngine(QGeoMappingManagerEnginePrivate *dd, QObject *parent = 0);
void setSupportedMapTypes(const QList<QGraphicsGeoMap::MapType> &mapTypes);
void setSupportedConnectivityModes(const QList<QGraphicsGeoMap::ConnectivityMode> &connectivityModes);
void setMinimumZoomLevel(qreal minimumZoom);
void setMaximumZoomLevel(qreal maximumZoom);
QGeoMappingManagerEnginePrivate* d_ptr;
private:
void setManagerName(const QString &managerName);
void setManagerVersion(int managerVersion);
Q_DECLARE_PRIVATE(QGeoMappingManagerEngine)
Q_DISABLE_COPY(QGeoMappingManagerEngine)
friend class QGeoServiceProvider;
};
QTM_END_NAMESPACE
#endif
| Java |
/****************************************************************************
**
** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies).
** All rights reserved.
** Contact: Nokia Corporation (qt-info@nokia.com)
**
** This file is part of the documentation of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:BSD$
** You may use this file under the terms of the BSD license as follows:
**
** "Redistribution and use in source and binary forms, with or without
** modification, are permitted provided that the following conditions are
** met:
** * Redistributions of source code must retain the above copyright
** notice, this list of conditions and the following disclaimer.
** * Redistributions in binary form must reproduce the above copyright
** notice, this list of conditions and the following disclaimer in
** the documentation and/or other materials provided with the
** distribution.
** * Neither the name of Nokia Corporation and its Subsidiary(-ies) nor
** the names of its contributors may be used to endorse or promote
** products derived from this software without specific prior written
** permission.
**
** THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
** "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
** LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
** A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
** OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
** SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
** LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
** DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
** THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
** (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
** OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE."
** $QT_END_LICENSE$
**
****************************************************************************/
#include "piechart.h"
#include <QPainter>
#include <QDebug>
PieChart::PieChart(QDeclarativeItem *parent)
: QDeclarativeItem(parent)
{
// need to disable this flag to draw inside a QDeclarativeItem
setFlag(QGraphicsItem::ItemHasNoContents, false);
}
QString PieChart::name() const
{
return m_name;
}
void PieChart::setName(const QString &name)
{
m_name = name;
}
QColor PieChart::color() const
{
return m_color;
}
void PieChart::setColor(const QColor &color)
{
m_color = color;
}
void PieChart::paint(QPainter *painter, const QStyleOptionGraphicsItem *, QWidget *)
{
QPen pen(m_color, 2);
painter->setPen(pen);
painter->setRenderHints(QPainter::Antialiasing, true);
painter->drawPie(boundingRect(), 90 * 16, 290 * 16);
}
//![0]
void PieChart::clearChart()
{
setColor(QColor(Qt::transparent));
update();
emit chartCleared();
}
//![0]
| Java |
/*
MAX1464 library for Arduino
Copyright (C) 2016 Giacomo Mazzamuto <gmazzamuto@gmail.com>
This library is free software; you can redistribute it and/or
modify it under the terms of the GNU Lesser General Public
License as published by the Free Software Foundation; either
version 2.1 of the License, or (at your option) any later version.
This library is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
Lesser General Public License for more details.
You should have received a copy of the GNU Lesser General Public
License along with this library. If not, see <http://www.gnu.org/licenses/>.
*/
/**
* \file
*/
#ifndef MAX1464_H
#define MAX1464_H
#include "lib/AbstractMAX1464.h"
#include <SPI.h>
/**
* @brief Interface to the Maxim %MAX1464 Multichannel Sensor Signal Processor,
* Arduino SPI library version.
*
* This class makes use of the Arduino SPI library with 4-wire data transfer
* mode.
*/
class MAX1464 : public AbstractMAX1464
{
public:
MAX1464(const int chipSelect);
virtual void begin();
virtual void end();
virtual void byteShiftOut(
const uint8_t b, const char *debugMsg = NULL) const;
virtual uint16_t wordShiftIn() const;
private:
SPISettings settings;
};
#endif // MAX1464_H
| Java |
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html lang="en">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>LCOV - doc-coverage.info - Cqrs.EventStore/ProjectionReader.cs</title>
<link rel="stylesheet" type="text/css" href="../gcov.css">
</head>
<body>
<table width="100%" border=0 cellspacing=0 cellpadding=0>
<tr><td class="title">Documentation Coverage Report</td></tr>
<tr><td class="ruler"><img src="../glass.png" width=3 height=3 alt=""></td></tr>
<tr>
<td width="100%">
<table cellpadding=1 border=0 width="100%">
<tr>
<td width="10%" class="headerItem">Current view:</td>
<td width="35%" class="headerValue"><a href="../index.html">top level</a> - <a href="index.html">Cqrs.EventStore</a> - ProjectionReader.cs</td>
<td width="5%"></td>
<td width="15%"></td>
<td width="10%" class="headerCovTableHead">Hit</td>
<td width="10%" class="headerCovTableHead">Total</td>
<td width="15%" class="headerCovTableHead">Coverage</td>
</tr>
<tr>
<td class="headerItem">Version:</td>
<td class="headerValue">4.0</td>
<td></td>
<td class="headerItem">Artefacts:</td>
<td class="headerCovTableEntry">4</td>
<td class="headerCovTableEntry">4</td>
<td class="headerCovTableEntryHi">100.0 %</td>
</tr>
<tr>
<td class="headerItem">Date:</td>
<td class="headerValue">2021-04-11 22:05:22</td>
<td></td>
</tr>
<tr><td><img src="../glass.png" width=3 height=3 alt=""></td></tr>
</table>
</td>
</tr>
<tr><td class="ruler"><img src="../glass.png" width=3 height=3 alt=""></td></tr>
</table>
<table cellpadding=0 cellspacing=0 border=0>
<tr>
<td><br></td>
</tr>
<tr>
<td>
<pre class="sourceHeading"> Line data Source code</pre>
<pre class="source">
<span class="lineNum"> 1 </span> : #region Copyright
<span class="lineNum"> 2 </span> : // // -----------------------------------------------------------------------
<span class="lineNum"> 3 </span> : // // <copyright company="Chinchilla Software Limited">
<span class="lineNum"> 4 </span> : // // Copyright Chinchilla Software Limited. All rights reserved.
<span class="lineNum"> 5 </span> : // // </copyright>
<span class="lineNum"> 6 </span> : // // -----------------------------------------------------------------------
<span class="lineNum"> 7 </span> : #endregion
<span class="lineNum"> 8 </span> :
<span class="lineNum"> 9 </span> : using System;
<span class="lineNum"> 10 </span> : using System.Collections.Generic;
<span class="lineNum"> 11 </span> : using System.Linq;
<span class="lineNum"> 12 </span> : using System.Text;
<span class="lineNum"> 13 </span> : using EventStore.ClientAPI;
<span class="lineNum"> 14 </span> : using Newtonsoft.Json;
<span class="lineNum"> 15 </span> :
<span class="lineNum"> 16 </span> : namespace Cqrs.EventStore
<span class="lineNum"> 17 </span> : {
<span class="lineNum"> 18 </span> : /// <summary>
<span class="lineNum"> 19 </span> : /// Reads projection streams from a Greg Young's Event sTore.
<span class="lineNum"> 20 </span> : /// </summary>
<span class="lineNum"> 21 </span> : /// <typeparam name="TAuthenticationToken">The <see cref="Type"/> of the authentication token.</typeparam>
<span class="lineNum"> 22 </span> : public abstract class ProjectionReader<TAuthenticationToken>
<span class="lineNum"> 23 </span><span class="lineCov"> 1 : {</span>
<span class="lineNum"> 24 </span> : /// <summary>
<span class="lineNum"> 25 </span> : /// The <see cref="IEventStoreConnection"/> used to read and write streams in the Greg Young Event Store.
<span class="lineNum"> 26 </span> : /// </summary>
<span class="lineNum"> 27 </span> : protected IEventStoreConnectionHelper EventStoreConnectionHelper { get; set; }
<span class="lineNum"> 28 </span> :
<span class="lineNum"> 29 </span> : /// <summary>
<span class="lineNum"> 30 </span> : /// The <see cref="IEventDeserialiser{TAuthenticationToken}"/> used to deserialise events.
<span class="lineNum"> 31 </span> : /// </summary>
<span class="lineNum"> 32 </span> : protected IEventDeserialiser<TAuthenticationToken> EventDeserialiser { get; set; }
<span class="lineNum"> 33 </span> :
<span class="lineNum"> 34 </span> : /// <summary>
<span class="lineNum"> 35 </span> : /// Instantiates a new instance of <see cref="ProjectionReader{TAuthenticationToken}"/>.
<span class="lineNum"> 36 </span> : /// </summary>
<span class="lineNum"> 37 </span><span class="lineCov"> 1 : protected ProjectionReader(IEventStoreConnectionHelper eventStoreConnectionHelper, IEventDeserialiser<TAuthenticationToken> eventDeserialiser)</span>
<span class="lineNum"> 38 </span> : {
<span class="lineNum"> 39 </span> : EventStoreConnectionHelper = eventStoreConnectionHelper;
<span class="lineNum"> 40 </span> : EventDeserialiser = eventDeserialiser;
<span class="lineNum"> 41 </span> : }
<span class="lineNum"> 42 </span> :
<span class="lineNum"> 43 </span> : /// <summary>
<span class="lineNum"> 44 </span> : /// Get a collection of data objects from a stream with the provided <paramref name="streamName"/>.
<span class="lineNum"> 45 </span> : /// </summary>
<span class="lineNum"> 46 </span> : /// <param name="streamName">The name of the stream to read events from.</param>
<span class="lineNum"> 47 </span><span class="lineCov"> 1 : protected IEnumerable<dynamic> GetDataByStreamName(string streamName)</span>
<span class="lineNum"> 48 </span> : {
<span class="lineNum"> 49 </span> : StreamEventsSlice eventCollection;
<span class="lineNum"> 50 </span> : using (IEventStoreConnection connection = EventStoreConnectionHelper.GetEventStoreConnection())
<span class="lineNum"> 51 </span> : {
<span class="lineNum"> 52 </span> : eventCollection = connection.ReadStreamEventsBackwardAsync(streamName, StreamPosition.End, 1, false).Result;
<span class="lineNum"> 53 </span> : }
<span class="lineNum"> 54 </span> : var jsonSerialiserSettings = EventDeserialiser.GetSerialisationSettings();
<span class="lineNum"> 55 </span> : var encoder = new UTF8Encoding();
<span class="lineNum"> 56 </span> : return
<span class="lineNum"> 57 </span> : (
<span class="lineNum"> 58 </span> : (
<span class="lineNum"> 59 </span> : (IEnumerable<dynamic>)eventCollection.Events
<span class="lineNum"> 60 </span> : .Select(e => JsonConvert.DeserializeObject(((dynamic)encoder.GetString(e.Event.Data)), jsonSerialiserSettings))
<span class="lineNum"> 61 </span> : .SingleOrDefault()
<span class="lineNum"> 62 </span> : )
<span class="lineNum"> 63 </span> : ??
<span class="lineNum"> 64 </span> : (
<span class="lineNum"> 65 </span> : Enumerable.Empty<dynamic>()
<span class="lineNum"> 66 </span> : )
<span class="lineNum"> 67 </span> : )
<span class="lineNum"> 68 </span> : .Select(x => x.Value);
<span class="lineNum"> 69 </span> : }
<span class="lineNum"> 70 </span> :
<span class="lineNum"> 71 </span> : /// <summary>
<span class="lineNum"> 72 </span> : /// Get a collection of <typeparamref name="TData"/> from a stream with the provided <paramref name="streamName"/>.
<span class="lineNum"> 73 </span> : /// </summary>
<span class="lineNum"> 74 </span> : /// <param name="streamName">The name of the stream to read events from.</param>
<span class="lineNum"> 75 </span><span class="lineCov"> 1 : protected IEnumerable<TData> GetDataByStreamName<TData>(string streamName)</span>
<span class="lineNum"> 76 </span> : {
<span class="lineNum"> 77 </span> : IList<TData> data = GetDataByStreamName(streamName)
<span class="lineNum"> 78 </span> : .Select(e => JsonConvert.DeserializeObject<TData>(e.ToString()))
<span class="lineNum"> 79 </span> : .Cast<TData>()
<span class="lineNum"> 80 </span> : .ToList();
<span class="lineNum"> 81 </span> : return data;
<span class="lineNum"> 82 </span> : }
<span class="lineNum"> 83 </span> : }
<span class="lineNum"> 84 </span> : }
</pre>
</td>
</tr>
</table>
<br>
<table width="100%" border=0 cellspacing=0 cellpadding=0>
<tr><td class="ruler"><img src="../glass.png" width=3 height=3 alt=""></td></tr>
<tr><td class="versionInfo">Generated by: <a href="http://ltp.sourceforge.net/coverage/lcov.php" target="_parent">LCOV version 1.13</a></td></tr>
</table>
<br>
</body>
</html>
| Java |
// The libMesh Finite Element Library.
// Copyright (C) 2002-2020 Benjamin S. Kirk, John W. Peterson, Roy H. Stogner
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
// License as published by the Free Software Foundation; either
// version 2.1 of the License, or (at your option) any later version.
// This library is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
// You should have received a copy of the GNU Lesser General Public
// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
#ifndef LIBMESH_NODE_H
#define LIBMESH_NODE_H
// Local includes
#include "libmesh/point.h"
#include "libmesh/dof_object.h"
#include "libmesh/reference_counted_object.h"
#include "libmesh/auto_ptr.h" // libmesh_make_unique
// C++ includes
#include <iostream>
#include <vector>
namespace libMesh
{
// forward declarations
class Node;
class MeshBase;
class MeshRefinement;
/**
* A \p Node is like a \p Point, but with more information. A \p Node
* is located in space and is associated with some \p (x,y,z)
* coordinates. Additionally, a \p Node may be enumerated with a
* global \p id. Finally, a \p Node may have an arbitrary number of
* degrees of freedom associated with it.
*
* \author Benjamin S. Kirk
* \date 2003
* \brief A geometric point in (x,y,z) space associated with a DOF.
*/
class Node : public Point,
public DofObject,
public ReferenceCountedObject<Node>
{
public:
/**
* Constructor. By default sets all entries to 0. Gives the point 0 in
* \p LIBMESH_DIM dimensions with an \p id of \p Node::invalid_id.
*/
explicit
Node (const Real x=0,
const Real y=0,
const Real z=0,
const dof_id_type id = invalid_id);
/**
* Copy-constructor.
*
* \deprecated - anyone copying a Node would almost certainly be
* better off copying the much cheaper Point or taking a reference
* to the Node.
*/
#ifdef LIBMESH_ENABLE_DEPRECATED
Node (const Node & n);
#endif
/**
* Copy-constructor from a \p Point. Optionally assigned the \p id.
*/
explicit Node (const Point & p,
const dof_id_type id = invalid_id);
/**
* Disambiguate constructing from non-Real scalars
*/
template <typename T,
typename = typename
boostcopy::enable_if_c<ScalarTraits<T>::value,void>::type>
Node (const T x) :
Point (x,0,0)
{ this->set_id() = invalid_id; }
/**
* Destructor.
*/
~Node ();
/**
* Assign to a node from a point.
*/
Node & operator= (const Point & p);
/**
* \returns A \p Node copied from \p n and wrapped in a smart pointer.
*
* \deprecated - anyone copying a Node would almost certainly be
* better off copying the much cheaper Point or taking a reference
* to the Node.
*/
#ifdef LIBMESH_ENABLE_DEPRECATED
static std::unique_ptr<Node> build (const Node & n);
#endif
/**
* \returns A \p Node copied from \p p with id == \p id and wrapped in a smart pointer.
*/
static std::unique_ptr<Node> build (const Point & p,
const dof_id_type id);
/**
* \returns A \p Node created from the specified (x,y,z) positions
* with id == \p id and wrapped in a smart pointer.
*/
static std::unique_ptr<Node> build (const Real x,
const Real y,
const Real z,
const dof_id_type id);
/**
* \returns \p true if the node is active. An active node is
* defined as one for which \p id() is not \p Node::invalid_id.
* Inactive nodes are nodes that are in the mesh but are not
* connected to any elements.
*/
bool active () const;
/**
* \returns \p true if this node equals rhs, false otherwise.
*/
bool operator ==(const Node & rhs) const;
/**
* Prints relevant information about the node.
*/
void print_info (std::ostream & os=libMesh::out) const;
/**
* Prints relevant information about the node to a string.
*/
std::string get_info () const;
#ifdef LIBMESH_HAVE_MPI
unsigned int packed_size() const
{
const unsigned int header_size = 2;
// use "(a+b-1)/b" trick to get a/b to round up
static const unsigned int idtypes_per_Real =
(sizeof(Real) + sizeof(largest_id_type) - 1) / sizeof(largest_id_type);
return header_size + LIBMESH_DIM*idtypes_per_Real +
this->packed_indexing_size();
}
#endif // #ifdef LIBMESH_HAVE_MPI
/**
* \returns The number of nodes connected with this node.
* Currently, this value is invalid (zero) except for
* subdivision meshes.
*/
unsigned int valence() const
{
#ifdef LIBMESH_ENABLE_NODE_VALENCE
return _valence;
#else
libmesh_not_implemented();
return libMesh::invalid_uint;
#endif
}
/**
* Sets the number of nodes connected with this node.
*/
void set_valence(unsigned int val);
/**
* Return which of pid1 and pid2 would be preferred by the current
* load-balancing heuristic applied to this node.
*/
processor_id_type choose_processor_id(processor_id_type pid1, processor_id_type pid2) const;
private:
/**
* This class need access to the node key information,
* but no one else should be able to mess with it.
*/
friend class MeshRefinement;
friend class Elem;
#ifdef LIBMESH_ENABLE_NODE_VALENCE
/**
* Type used to store node valence.
*/
typedef unsigned char valence_idx_t;
/**
* The number of nodes connected with this node.
* Currently, this value is invalid (zero) except for
* subdivision meshes.
*/
valence_idx_t _valence;
#endif
};
// ------------------------------------------------------------
// Global Node functions
inline
std::ostream & operator << (std::ostream & os, const Node & n)
{
n.print_info(os);
return os;
}
//------------------------------------------------------
// Inline functions
inline
Node::Node (const Real x,
const Real y,
const Real z,
const dof_id_type dofid) :
Point(x,y,z)
#ifdef LIBMESH_ENABLE_NODE_VALENCE
,
_valence(0)
#endif
{
this->set_id() = dofid;
}
#ifdef LIBMESH_ENABLE_DEPRECATED
inline
Node::Node (const Node & n) :
Point(n),
DofObject(n),
ReferenceCountedObject<Node>()
#ifdef LIBMESH_ENABLE_NODE_VALENCE
,
_valence(n._valence)
#endif
{
libmesh_deprecated();
}
#endif
inline
Node::Node (const Point & p,
const dof_id_type dofid) :
Point(p)
#ifdef LIBMESH_ENABLE_NODE_VALENCE
,
_valence(0)
#endif
{
// optionally assign the id. We have
// to do it like this otherwise
// Node n = Point p would erase
// the id!
if (dofid != invalid_id)
this->set_id() = dofid;
}
inline
Node::~Node ()
{
}
inline
Node & Node::operator= (const Point & p)
{
(*this)(0) = p(0);
#if LIBMESH_DIM > 1
(*this)(1) = p(1);
#endif
#if LIBMESH_DIM > 2
(*this)(2) = p(2);
#endif
return *this;
}
#ifdef LIBMESH_ENABLE_DEPRECATED
inline
std::unique_ptr<Node> Node::build(const Node & n)
{
libmesh_deprecated();
return libmesh_make_unique<Node>(n);
}
#endif
inline
std::unique_ptr<Node> Node::build(const Point & p,
const dof_id_type id)
{
return libmesh_make_unique<Node>(p,id);
}
inline
std::unique_ptr<Node> Node::build(const Real x,
const Real y,
const Real z,
const dof_id_type id)
{
return libmesh_make_unique<Node>(x,y,z,id);
}
inline
bool Node::active () const
{
return (this->id() != Node::invalid_id);
}
#ifdef LIBMESH_ENABLE_NODE_VALENCE
inline
void Node::set_valence (unsigned int val)
{
_valence = cast_int<valence_idx_t>(val);
}
#else
inline
void Node::set_valence (unsigned int)
{
libmesh_not_implemented();
}
#endif // #ifdef LIBMESH_ENABLE_NODE_VALENCE
} // namespace libMesh
#endif // LIBMESH_NODE_H
| Java |
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html><head><meta http-equiv="Content-Type" content="text/html;charset=iso-8859-1">
<title>GTL: Référence du fichier gtl_image_raw.h</title>
<link href="doxygen.css" rel="stylesheet" type="text/css">
</head><body>
<!-- Généré par Doxygen 1.3.8 -->
<div class="qindex"><a class="qindex" href="index.html">Page principale</a> | <a class="qindex" href="namespaces.html">Liste des namespaces</a> | <a class="qindex" href="hierarchy.html">Hiérarchie des classes</a> | <a class="qindex" href="annotated.html">Liste des classes</a> | <a class="qindex" href="files.html">Liste des fichiers</a> | <a class="qindex" href="namespacemembers.html">Membres de namespace</a> | <a class="qindex" href="functions.html">Membres de classe</a> | <a class="qindex" href="globals.html">Membres de fichier</a></div>
<h1>Référence du fichier gtl_image_raw.h</h1>Classe CImageRAW, pour le chargement des images RAW. <a href="#_details">Plus de détails...</a>
<p>
<code>#include "<a class="el" href="gtl__image_8h-source.html">gtl_image.h</a>"</code><br>
<code>#include <string></code><br>
<p>
<a href="gtl__image__raw_8h-source.html">Aller au code source de ce fichier.</a><table border=0 cellpadding=0 cellspacing=0>
<tr><td></td></tr>
<tr><td colspan=2><br><h2>Namespaces</h2></td></tr>
<tr><td class="memItemLeft" nowrap align=right valign=top>namespace </td><td class="memItemRight" valign=bottom><a class="el" href="namespacegtl.html">gtl</a></td></tr>
<tr><td colspan=2><br><h2>Classes</h2></td></tr>
<tr><td class="memItemLeft" nowrap align=right valign=top>class </td><td class="memItemRight" valign=bottom><a class="el" href="classgtl_1_1_c_image_r_a_w.html">gtl::CImageRAW</a></td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Classe pour le chargement des images RAW. <a href="classgtl_1_1_c_image_r_a_w.html#_details">Plus de détails...</a><br></td></tr>
</table>
<hr><a name="_details"></a><h2>Description détaillée</h2>
Classe CImageRAW, pour le chargement des images RAW.
<p>
<dl compact><dt><b>Date:</b></dt><dd>02/10/2004</dd></dl>
<p>
Définition dans le fichier <a class="el" href="gtl__image__raw_8h-source.html">gtl_image_raw.h</a>.<hr size="1"><address style="align: right;"><small>Généré le Wed Jan 5 23:28:23 2005 pour GTL par
<a href="http://www.doxygen.org/index.html">
<img src="doxygen.png" alt="doxygen" align="middle" border=0 ></a> 1.3.8 </small></address>
</body>
</html>
| Java |
using System.Xml.Serialization;
namespace MDFe.Classes.Informacoes
{
public enum tpComp
{
[XmlEnum("01")]
ValePedagio = 01,
[XmlEnum("02")]
ImpostosTaxasEContribuicoes = 02,
[XmlEnum("03")]
DespesasBancariasEmiosDePagamentoOutras = 03,
[XmlEnum("99")]
Outros = 99
}
} | Java |
#include <errno.h>
#include <sys/types.h>
#include <unistd.h>
#include "ibuf.h"
/** Set the effective read position. */
int ibuf_seek(ibuf* in, unsigned offset)
{
iobuf* io;
unsigned buf_start;
io = &(in->io);
buf_start = io->offset - io->buflen;
if (offset >= buf_start && offset <= io->offset)
io->bufstart = offset - buf_start;
else {
if (lseek(io->fd, offset, SEEK_SET) != (off_t)offset)
IOBUF_SET_ERROR(io);
io->offset = offset;
io->buflen = 0;
io->bufstart = 0;
}
in->count = 0;
io->flags &= ~IOBUF_EOF;
return 1;
}
| Java |
/*---------------------------------------------------------------------------*\
* OpenSG *
* *
* *
* Copyright (C) 2000-2002 by the OpenSG Forum *
* *
* www.opensg.org *
* *
* contact: dirk@opensg.org, gerrit.voss@vossg.org, jbehr@zgdv.de *
* *
\*---------------------------------------------------------------------------*/
/*---------------------------------------------------------------------------*\
* License *
* *
* This library is free software; you can redistribute it and/or modify it *
* under the terms of the GNU Library General Public License as published *
* by the Free Software Foundation, version 2. *
* *
* This library is distributed in the hope that it will be useful, but *
* WITHOUT ANY WARRANTY; without even the implied warranty of *
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU *
* Library General Public License for more details. *
* *
* You should have received a copy of the GNU Library General Public *
* License along with this library; if not, write to the Free Software *
* Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. *
* *
\*---------------------------------------------------------------------------*/
/*---------------------------------------------------------------------------*\
* Changes *
* *
* *
* *
* *
* *
* *
\*---------------------------------------------------------------------------*/
#ifndef _OSGGLUTWINDOW_H_
#define _OSGGLUTWINDOW_H_
#ifdef __sgi
#pragma once
#endif
#if defined(OSG_WITH_GLUT) || defined(OSG_DO_DOC)
#include "OSGGLUTWindowBase.h"
OSG_BEGIN_NAMESPACE
/*! \brief GLUT Window class. See \ref PageWindowGLUT for a description.
\ingroup GrpWindowGLUTObj
\ingroup GrpLibOSGWindowGLUT
\includebasedoc
*/
class OSG_WINDOWGLUT_DLLMAPPING GLUTWindow : public GLUTWindowBase
{
public:
typedef GLUTWindowBase Inherited;
/*---------------------------------------------------------------------*/
/*! \name Sync */
/*! \{ */
virtual void changed(ConstFieldMaskArg whichField,
UInt32 origin,
BitVector detail);
/*! \} */
/*---------------------------------------------------------------------*/
/*! \name Output */
/*! \{ */
virtual void dump( UInt32 uiIndent = 0,
const BitVector bvFlags = 0) const;
/*! \} */
/*---------------------------------------------------------------------*/
/*! \name Window functions */
/*! \{ */
virtual void init(GLInitFunctor oFunc = GLInitFunctor());
/*! \} */
/*---------------------------------------------------------------------*/
/*! \name Redefined */
/*! \{ */
virtual void activate (void);
virtual void terminate(void);
/*! \} */
/*========================= PROTECTED ===============================*/
protected:
// Variables should all be in GLUTWindowBase.
/*---------------------------------------------------------------------*/
/*! \name Constructors */
/*! \{ */
GLUTWindow(void);
GLUTWindow(const GLUTWindow &source);
/*! \} */
/*---------------------------------------------------------------------*/
/*! \name Destructors */
/*! \{ */
virtual ~GLUTWindow(void);
/*! \} */
/*---------------------------------------------------------------------*/
/*! \name Init */
/*! \{ */
static void initMethod(InitPhase ePhase);
/*! \} */
/*---------------------------------------------------------------------*/
/*! \name Window system implementation functions */
/*! \{ */
/*! \} */
/*========================== PRIVATE ================================*/
private:
friend class FieldContainer;
friend class GLUTWindowBase;
// prohibit default functions (move to 'public' if you need one)
void operator =(const GLUTWindow &source);
};
OSG_END_NAMESPACE
#include "OSGGLUTWindow.inl"
#include "OSGGLUTWindowBase.inl"
#endif /* OSG_WITH_GLUT */
#endif /* _OSGGLUTWINDOW_H_ */
| Java |
/* LanguageTool, a natural language style checker
* Copyright (C) 2005 Daniel Naber (http://www.danielnaber.de)
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
* version 2.1 of the License, or (at your option) any later version.
*
* This library is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
* Lesser General Public License for more details.
*
* You should have received a copy of the GNU Lesser General Public
* License along with this library; if not, write to the Free Software
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301
* USA
*/
package org.languagetool.tokenizers.uk;
import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;
import java.util.Map.Entry;
import java.util.regex.Matcher;
import java.util.regex.Pattern;
import java.util.StringTokenizer;
import org.languagetool.tokenizers.Tokenizer;
/**
* Tokenizes a sentence into words.
* Punctuation and whitespace gets its own token.
* Specific to Ukrainian: apostrophes (0x27 and U+2019) not in the list as they are part of the word
*
* @author Andriy Rysin
*/
public class UkrainianWordTokenizer implements Tokenizer {
private static final String SPLIT_CHARS = "\u0020\u00A0"
+ "\u2000\u2001\u2002\u2003\u2004\u2005\u2006\u2007"
+ "\u2008\u2009\u200A\u200B\u200c\u200d\u200e\u200f"
+ "\u2028\u2029\u202a\u202b\u202c\u202d\u202e\u202f"
+ "\u205F\u2060\u2061\u2062\u2063\u206A\u206b\u206c\u206d"
+ "\u206E\u206F\u3000\u3164\ufeff\uffa0\ufff9\ufffa\ufffb"
+ ",.;()[]{}<>!?:/|\\\"«»„”“…¿¡\t\n\r\uE100\uE101\uE102\uE110";
// for handling exceptions
private static final char DECIMAL_COMMA_SUBST = '\uE001'; // some unused character to hide comma in decimal number temporary for tokenizer run
private static final char NON_BREAKING_SPACE_SUBST = '\uE002';
private static final char NON_BREAKING_DOT_SUBST = '\uE003'; // some unused character to hide dot in date temporary for tokenizer run
private static final char NON_BREAKING_COLON_SUBST = '\uE004';
// decimal comma between digits
private static final Pattern DECIMAL_COMMA_PATTERN = Pattern.compile("([\\d]),([\\d])", Pattern.CASE_INSENSITIVE|Pattern.UNICODE_CASE);
private static final String DECIMAL_COMMA_REPL = "$1" + DECIMAL_COMMA_SUBST + "$2";
// space between digits
private static final Pattern DECIMAL_SPACE_PATTERN = Pattern.compile("(?<=^|[\\s(])\\d{1,3}( [\\d]{3})+(?=[\\s(]|$)", Pattern.CASE_INSENSITIVE|Pattern.UNICODE_CASE);
// dots in numbers
private static final Pattern DOTTED_NUMBERS_PATTERN = Pattern.compile("([\\d])\\.([\\d])", Pattern.CASE_INSENSITIVE|Pattern.UNICODE_CASE);
private static final String DOTTED_NUMBERS_REPL = "$1" + NON_BREAKING_DOT_SUBST + "$2";
// colon in numbers
private static final Pattern COLON_NUMBERS_PATTERN = Pattern.compile("([\\d]):([\\d])", Pattern.CASE_INSENSITIVE|Pattern.UNICODE_CASE);
private static final String COLON_NUMBERS_REPL = "$1" + NON_BREAKING_COLON_SUBST + "$2";
// dates
private static final Pattern DATE_PATTERN = Pattern.compile("([\\d]{2})\\.([\\d]{2})\\.([\\d]{4})|([\\d]{4})\\.([\\d]{2})\\.([\\d]{2})|([\\d]{4})-([\\d]{2})-([\\d]{2})", Pattern.CASE_INSENSITIVE|Pattern.UNICODE_CASE);
private static final String DATE_PATTERN_REPL = "$1" + NON_BREAKING_DOT_SUBST + "$2" + NON_BREAKING_DOT_SUBST + "$3";
// braces in words
private static final Pattern BRACE_IN_WORD_PATTERN = Pattern.compile("([а-яіїєґ'])\\(([а-яіїєґ']+)\\)", Pattern.CASE_INSENSITIVE|Pattern.UNICODE_CASE);
private static final char LEFT_BRACE_SUBST = '\uE005';
private static final char RIGHT_BRACE_SUBST = '\uE006';
private static final String BREAKING_PLACEHOLDER = "\uE110";
// abbreviation dot
//TODO: л.с., ч.л./ч. л., ст. л., р. х.
private static final Pattern ABBR_DOT_TYS_PATTERN = Pattern.compile("(тис)\\.([ \u00A0]+[а-яіїєґ])");
private static final Pattern ABBR_DOT_LAT_PATTERN = Pattern.compile("([^а-яіїєґА-ЯІЇЄҐ'-]лат)\\.([ \u00A0]+[a-zA-Z])");
private static final Pattern ABBR_DOT_PROF_PATTERN = Pattern.compile("([Аа]кад|[Пп]роф|[Дд]оц|[Аа]сист|вул|о|р|ім)\\.([\\s\u00A0]+[А-ЯІЇЄҐ])");
// tokenize initials with dot, e.g. "А.", "Ковальчук"
private static final Pattern INITIALS_DOT_PATTERN_SP_2 = Pattern.compile("([А-ЯІЇЄҐ])\\.([\\s\u00A0][А-ЯІЇЄҐ])\\.([\\s\u00A0][А-ЯІЇЄҐ][а-яіїєґ']+)");
private static final String INITIALS_DOT_REPL_SP_2 = "$1" + NON_BREAKING_DOT_SUBST + "$2" + NON_BREAKING_DOT_SUBST + "$3";
private static final Pattern INITIALS_DOT_PATTERN_SP_1 = Pattern.compile("([А-ЯІЇЄҐ])\\.([\\s\u00A0][А-ЯІЇЄҐ][а-яіїєґ']+)");
private static final String INITIALS_DOT_REPL_SP_1 = "$1" + NON_BREAKING_DOT_SUBST + "$2";
private static final Pattern INITIALS_DOT_PATTERN_NSP_2 = Pattern.compile("([А-ЯІЇЄҐ])\\.([А-ЯІЇЄҐ])\\.([А-ЯІЇЄҐ][а-яіїєґ']+)");
private static final String INITIALS_DOT_REPL_NSP_2 = "$1" + NON_BREAKING_DOT_SUBST + BREAKING_PLACEHOLDER + "$2" + NON_BREAKING_DOT_SUBST + BREAKING_PLACEHOLDER + "$3";
private static final Pattern INITIALS_DOT_PATTERN_NSP_1 = Pattern.compile("([А-ЯІЇЄҐ])\\.([А-ЯІЇЄҐ][а-яіїєґ']+)");
private static final String INITIALS_DOT_REPL_NSP_1 = "$1" + NON_BREAKING_DOT_SUBST + BREAKING_PLACEHOLDER + "$2";
// село, місто, річка (якщо з цифрою: секунди, метри, роки) - з роками складно
private static final Pattern ABBR_DOT_KUB_SM_PATTERN = Pattern.compile("((?:[0-9]|кв\\.?|куб\\.?)[\\s\u00A0]+[см])\\.");
private static final Pattern ABBR_DOT_S_G_PATTERN = Pattern.compile("(с)\\.(-г)\\.");
private static final Pattern ABBR_DOT_2_SMALL_LETTERS_PATTERN = Pattern.compile("([^а-яіїєґ'-][векнпрстцч]{1,2})\\.([екмнпрстч]{1,2})\\.");
private static final String ABBR_DOT_2_SMALL_LETTERS_REPL = "$1" + NON_BREAKING_DOT_SUBST + BREAKING_PLACEHOLDER + "$2" + NON_BREAKING_DOT_SUBST;
// скорочення що не можуть бути в кінці речення
private static final Pattern ABBR_DOT_NON_ENDING_PATTERN = Pattern.compile("([^а-яіїєґА-ЯІЇЄҐ'-](?:амер|англ|бл(?:изьк)?|буд|вірм|грец(?:ьк)|див|дол|досл|доц|ел|жін|заст|зв|ім|івр|ісп|італ|к|кв|[1-9]-кімн|кімн|кл|м|н|напр|п|пен|перекл|пл|пор|поч|прибл|пров|просп|[Рр]ед|[Рр]еж|рт|с|[Сс]в|соц|співавт|стор|табл|тел|укр|філол|фр|франц|ч|чайн|ц))\\.(?!$)");
// скорочення що можуть бути в кінці речення
private static final Pattern ABBR_DOT_ENDING_PATTERN = Pattern.compile("([^а-яіїєґА-ЯІЇЄҐ'-]((та|й) ін|е|коп|обл|р|рр|руб|ст|стол|стор|чол|шт))\\.");
private static final Pattern ABBR_DOT_I_T_P_PATTERN = Pattern.compile("([ій][ \u00A0]+т)\\.([ \u00A0]*(д|п|ін))\\.");
// Сьогодні (у четвер. - Ред.), вранці.
// private static final Pattern ABBR_DOT_PATTERN8 = Pattern.compile("([\\s\u00A0]+[–—-][\\s\u00A0]+(?:[Рр]ед|[Аа]вт))\\.([\\)\\]])");
private static final Pattern ABBR_DOT_RED_AVT_PATTERN = Pattern.compile("([\\s\u00A0]+(?:[Рр]ед|[Аа]вт))\\.([\\)\\]])");
// ellipsis
private static final String ELLIPSIS = "...";
private static final String ELLIPSIS_SUBST = "\uE100";
private static final String ELLIPSIS2 = "!..";
private static final String ELLIPSIS2_SUBST = "\uE101";
private static final String ELLIPSIS3 = "?..";
private static final String ELLIPSIS3_SUBST = "\uE102";
private static final String SOFT_HYPHEN_WRAP = "\u00AD\n";
private static final String SOFT_HYPHEN_WRAP_SUBST = "\uE103";
// url
private static final Pattern URL_PATTERN = Pattern.compile("^(https?|ftp)://[^\\s/$.?#].[^\\s]*$", Pattern.CASE_INSENSITIVE);
private static final int URL_START_REPLACE_CHAR = 0xE300;
public UkrainianWordTokenizer() {
}
@Override
public List<String> tokenize(String text) {
HashMap<String, String> urls = new HashMap<>();
text = cleanup(text);
if( text.contains(",") ) {
text = DECIMAL_COMMA_PATTERN.matcher(text).replaceAll(DECIMAL_COMMA_REPL);
}
// check for urls
if( text.contains("tp") ) { // https?|ftp
Matcher matcher = URL_PATTERN.matcher(text);
int urlReplaceChar = URL_START_REPLACE_CHAR;
while( matcher.find() ) {
String urlGroup = matcher.group();
String replaceChar = String.valueOf((char)urlReplaceChar);
urls.put(replaceChar, urlGroup);
text = matcher.replaceAll(replaceChar);
urlReplaceChar++;
}
}
// if period is not the last character in the sentence
int dotIndex = text.indexOf(".");
boolean dotInsideSentence = dotIndex >= 0 && dotIndex < text.length()-1;
if( dotInsideSentence ){
if( text.contains(ELLIPSIS) ) {
text = text.replace(ELLIPSIS, ELLIPSIS_SUBST);
}
if( text.contains(ELLIPSIS2) ) {
text = text.replace(ELLIPSIS2, ELLIPSIS2_SUBST);
}
if( text.contains(ELLIPSIS3) ) {
text = text.replace(ELLIPSIS3, ELLIPSIS3_SUBST);
}
text = DATE_PATTERN.matcher(text).replaceAll(DATE_PATTERN_REPL);
text = DOTTED_NUMBERS_PATTERN.matcher(text).replaceAll(DOTTED_NUMBERS_REPL);
text = ABBR_DOT_2_SMALL_LETTERS_PATTERN.matcher(text).replaceAll(ABBR_DOT_2_SMALL_LETTERS_REPL);
text = ABBR_DOT_TYS_PATTERN.matcher(text).replaceAll("$1" + NON_BREAKING_DOT_SUBST + "$2");
text = ABBR_DOT_LAT_PATTERN.matcher(text).replaceAll("$1" + NON_BREAKING_DOT_SUBST + "$2");
text = ABBR_DOT_PROF_PATTERN.matcher(text).replaceAll("$1" + NON_BREAKING_DOT_SUBST + "$2");
text = INITIALS_DOT_PATTERN_SP_2.matcher(text).replaceAll(INITIALS_DOT_REPL_SP_2);
text = INITIALS_DOT_PATTERN_SP_1.matcher(text).replaceAll(INITIALS_DOT_REPL_SP_1);
text = INITIALS_DOT_PATTERN_NSP_2.matcher(text).replaceAll(INITIALS_DOT_REPL_NSP_2);
text = INITIALS_DOT_PATTERN_NSP_1.matcher(text).replaceAll(INITIALS_DOT_REPL_NSP_1);
text = ABBR_DOT_KUB_SM_PATTERN.matcher(text).replaceAll("$1" + BREAKING_PLACEHOLDER + NON_BREAKING_DOT_SUBST);
text = ABBR_DOT_S_G_PATTERN.matcher(text).replaceAll("$1" + NON_BREAKING_DOT_SUBST + "$2" + NON_BREAKING_DOT_SUBST);
text = ABBR_DOT_I_T_P_PATTERN.matcher(text).replaceAll("$1" + NON_BREAKING_DOT_SUBST + "$2" + NON_BREAKING_DOT_SUBST);
text = ABBR_DOT_RED_AVT_PATTERN.matcher(text).replaceAll("$1" + NON_BREAKING_DOT_SUBST + "$2");
text = ABBR_DOT_NON_ENDING_PATTERN.matcher(text).replaceAll("$1" + NON_BREAKING_DOT_SUBST);
}
text = ABBR_DOT_ENDING_PATTERN.matcher(text).replaceAll("$1" + NON_BREAKING_DOT_SUBST);
// 2 000 000
Matcher spacedDecimalMatcher = DECIMAL_SPACE_PATTERN.matcher(text);
if( spacedDecimalMatcher.find() ) {
StringBuffer sb = new StringBuffer();
do {
String splitNumber = spacedDecimalMatcher.group(0);
String splitNumberAdjusted = splitNumber.replace(' ', NON_BREAKING_SPACE_SUBST);
splitNumberAdjusted = splitNumberAdjusted.replace('\u00A0', NON_BREAKING_SPACE_SUBST);
spacedDecimalMatcher.appendReplacement(sb, splitNumberAdjusted);
} while( spacedDecimalMatcher.find() );
spacedDecimalMatcher.appendTail(sb);
text = sb.toString();
}
// 12:25
if( text.contains(":") ) {
text = COLON_NUMBERS_PATTERN.matcher(text).replaceAll(COLON_NUMBERS_REPL);
}
// ВКПБ(о)
if( text.contains("(") ) {
text = BRACE_IN_WORD_PATTERN.matcher(text).replaceAll("$1" + LEFT_BRACE_SUBST + "$2" + RIGHT_BRACE_SUBST);
}
if( text.contains(SOFT_HYPHEN_WRAP) ) {
text = text.replace(SOFT_HYPHEN_WRAP, SOFT_HYPHEN_WRAP_SUBST);
}
List<String> tokenList = new ArrayList<>();
StringTokenizer st = new StringTokenizer(text, SPLIT_CHARS, true);
while (st.hasMoreElements()) {
String token = st.nextToken();
if( token.equals(BREAKING_PLACEHOLDER) )
continue;
token = token.replace(DECIMAL_COMMA_SUBST, ',');
token = token.replace(NON_BREAKING_COLON_SUBST, ':');
token = token.replace(NON_BREAKING_SPACE_SUBST, ' ');
token = token.replace(LEFT_BRACE_SUBST, '(');
token = token.replace(RIGHT_BRACE_SUBST, ')');
// outside of if as we also replace back sentence-ending abbreviations
token = token.replace(NON_BREAKING_DOT_SUBST, '.');
if( dotInsideSentence ){
token = token.replace(ELLIPSIS_SUBST, ELLIPSIS);
token = token.replace(ELLIPSIS2_SUBST, ELLIPSIS2);
token = token.replace(ELLIPSIS3_SUBST, ELLIPSIS3);
}
token = token.replace(SOFT_HYPHEN_WRAP_SUBST, SOFT_HYPHEN_WRAP);
if( ! urls.isEmpty() ) {
for(Entry<String, String> entry : urls.entrySet()) {
token = token.replace(entry.getKey(), entry.getValue());
}
}
tokenList.add( token );
}
return tokenList;
}
private static String cleanup(String text) {
text = text
.replace('\u2019', '\'')
.replace('\u02BC', '\'')
.replace('\u2018', '\'')
.replace('`', '\'')
.replace('´', '\'')
.replace('\u2011', '-'); // we handle \u2013 in tagger so we can base our rule on it
return text;
}
}
| Java |
/**
* Copyright (C) 2012 Orbeon, Inc.
*
* This program is free software; you can redistribute it and/or modify it under the terms of the
* GNU Lesser General Public License as published by the Free Software Foundation; either version
* 2.1 of the License, or (at your option) any later version.
*
* This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY;
* without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
* See the GNU Lesser General Public License for more details.
*
* The full text of the license is available at http://www.gnu.org/copyleft/lesser.html
*/
package org.orbeon.oxf.processor.serializer;
import org.apache.commons.fileupload.FileItem;
import org.apache.commons.fileupload.disk.DiskFileItem;
import org.apache.log4j.Logger;
import org.dom4j.Document;
import org.orbeon.oxf.common.OXFException;
import org.orbeon.oxf.pipeline.api.PipelineContext;
import org.orbeon.oxf.pipeline.api.XMLReceiver;
import org.orbeon.oxf.processor.*;
import org.orbeon.oxf.processor.serializer.store.ResultStore;
import org.orbeon.oxf.processor.serializer.store.ResultStoreOutputStream;
import org.orbeon.oxf.util.LoggerFactory;
import org.orbeon.oxf.util.NetUtils;
import org.orbeon.oxf.xforms.processor.XFormsResourceServer;
import org.orbeon.oxf.xml.XMLUtils;
import org.orbeon.oxf.xml.XPathUtils;
import org.xml.sax.SAXException;
import javax.xml.parsers.DocumentBuilderFactory;
import java.io.File;
import java.io.FileOutputStream;
import java.io.IOException;
import java.io.OutputStream;
/**
* The File Serializer serializes text and binary documents to files on disk.
*/
public class FileSerializer extends ProcessorImpl {
private static Logger logger = LoggerFactory.createLogger(FileSerializer.class);
public static final String FILE_SERIALIZER_CONFIG_NAMESPACE_URI = "http://orbeon.org/oxf/xml/file-serializer-config";
public static final String DIRECTORY_PROPERTY = "directory";
// NOTE: Those are also in HttpSerializerBase
private static final boolean DEFAULT_FORCE_CONTENT_TYPE = false;
private static final boolean DEFAULT_IGNORE_DOCUMENT_CONTENT_TYPE = false;
private static final boolean DEFAULT_FORCE_ENCODING = false;
private static final boolean DEFAULT_IGNORE_DOCUMENT_ENCODING = false;
private static final boolean DEFAULT_APPEND = false;
private static final boolean DEFAULT_MAKE_DIRECTORIES = false;
static {
try {
// Create factory
DocumentBuilderFactory documentBuilderFactory = (DocumentBuilderFactory) Class.forName("orbeon.apache.xerces.jaxp.DocumentBuilderFactoryImpl").newInstance();
// Configure factory
documentBuilderFactory.setNamespaceAware(true);
}
catch (Exception e) {
throw new OXFException(e);
}
}
public FileSerializer() {
addInputInfo(new ProcessorInputOutputInfo(INPUT_CONFIG, FILE_SERIALIZER_CONFIG_NAMESPACE_URI));
addInputInfo(new ProcessorInputOutputInfo(INPUT_DATA));
// We don't declare the "data" output here, as this is an optional output.
// If we declare it, we'll the XPL engine won't be happy when don't connect anything to that output.
}
private static class Config {
private String directory;
private String file;
private String scope;
private boolean proxyResult;
private String url;
private boolean append;
private boolean makeDirectories;
private boolean cacheUseLocalCache;
private boolean forceContentType;
private String requestedContentType;
private boolean ignoreDocumentContentType;
private boolean forceEncoding;
private String requestedEncoding;
private boolean ignoreDocumentEncoding;
public Config(Document document) {
// Directory and file
directory = XPathUtils.selectStringValueNormalize(document, "/config/directory");
file = XPathUtils.selectStringValueNormalize(document, "/config/file");
// Scope
scope = XPathUtils.selectStringValueNormalize(document, "/config/scope");
// Proxy result
proxyResult = ProcessorUtils.selectBooleanValue(document, "/config/proxy-result", false);
// URL
url = XPathUtils.selectStringValueNormalize(document, "/config/url");
// Cache control
cacheUseLocalCache = ProcessorUtils.selectBooleanValue(document, "/config/cache-control/use-local-cache", CachedSerializer.DEFAULT_CACHE_USE_LOCAL_CACHE);
// Whether to append or not
append = ProcessorUtils.selectBooleanValue(document, "/config/append", DEFAULT_APPEND);
// Whether to append or not
makeDirectories = ProcessorUtils.selectBooleanValue(document, "/config/make-directories", DEFAULT_MAKE_DIRECTORIES);
// Content-type and Encoding
requestedContentType = XPathUtils.selectStringValueNormalize(document, "/config/content-type");
forceContentType = ProcessorUtils.selectBooleanValue(document, "/config/force-content-type", DEFAULT_FORCE_CONTENT_TYPE);
// TODO: We don't seem to be using the content type in the file serializer.
// Maybe this is something that was left over from the days when the file serializer was also serializing XML.
if (forceContentType)
throw new OXFException("The force-content-type element requires a content-type element.");
ignoreDocumentContentType = ProcessorUtils.selectBooleanValue(document, "/config/ignore-document-content-type", DEFAULT_IGNORE_DOCUMENT_CONTENT_TYPE);
requestedEncoding = XPathUtils.selectStringValueNormalize(document, "/config/encoding");
forceEncoding = ProcessorUtils.selectBooleanValue(document, "/config/force-encoding", DEFAULT_FORCE_ENCODING);
if (forceEncoding && (requestedEncoding == null || requestedEncoding.equals("")))
throw new OXFException("The force-encoding element requires an encoding element.");
ignoreDocumentEncoding = ProcessorUtils.selectBooleanValue(document, "/config/ignore-document-encoding", DEFAULT_IGNORE_DOCUMENT_ENCODING);
}
public String getDirectory() {
return directory;
}
public String getFile() {
return file;
}
public String getScope() {
return scope;
}
public boolean isProxyResult() {
return proxyResult;
}
public String getUrl() {
return url;
}
public boolean isAppend() {
return append;
}
public boolean isMakeDirectories() {
return makeDirectories;
}
public boolean isCacheUseLocalCache() {
return cacheUseLocalCache;
}
public boolean isForceContentType() {
return forceContentType;
}
public boolean isForceEncoding() {
return forceEncoding;
}
public boolean isIgnoreDocumentContentType() {
return ignoreDocumentContentType;
}
public boolean isIgnoreDocumentEncoding() {
return ignoreDocumentEncoding;
}
public String getRequestedContentType() {
return requestedContentType;
}
public String getRequestedEncoding() {
return requestedEncoding;
}
}
@Override
public void start(PipelineContext context) {
try {
// Read config
final Config config = readCacheInputAsObject(context, getInputByName(INPUT_CONFIG), new CacheableInputReader<Config>() {
public Config read(PipelineContext context, ProcessorInput input) {
return new Config(readInputAsDOM4J(context, input));
}
});
final ProcessorInput dataInput = getInputByName(INPUT_DATA);
// Get file object
final String directory = config.getDirectory() != null ? config.getDirectory() : getPropertySet().getString(DIRECTORY_PROPERTY);
final File file = NetUtils.getFile(directory, config.getFile(), config.getUrl(), getLocationData(), config.isMakeDirectories());
// NOTE: Caching here is broken, so we never cache. This is what we should do in case
// we want caching:
// o for a given file, store a hash of the content stored (or the input key?)
// o then when we check whether we need to modify the file, check against the key
// AND the validity
// Delete file if it exists, unless we append
if (!config.isAppend() && file.exists()) {
final boolean deleted = file.delete();
// We test on file.exists() here again so we don't complain that the file can't be deleted if it got
// deleted just between our last test and the delete operation.
if (!deleted && file.exists())
throw new OXFException("Can't delete file: " + file);
}
// Create file if needed
file.createNewFile();
FileOutputStream fileOutputStream = new FileOutputStream(file, config.isAppend());
writeToFile(context, config, dataInput, fileOutputStream);
} catch (Exception e) {
throw new OXFException(e);
}
}
private void writeToFile(PipelineContext context, final Config config, ProcessorInput dataInput, final OutputStream fileOutputStream) throws IOException {
try {
if (config.cacheUseLocalCache) {
// If caching of the data is enabled, use the caching API
// We return a ResultStore
final boolean[] read = new boolean[1];
ResultStore filter = (ResultStore) readCacheInputAsObject(context, dataInput, new CacheableInputReader() {
public Object read(PipelineContext context, ProcessorInput input) {
read[0] = true;
if (logger.isDebugEnabled())
logger.debug("Output not cached");
try {
ResultStoreOutputStream resultStoreOutputStream = new ResultStoreOutputStream(fileOutputStream);
readInputAsSAX(context, input, new BinaryTextXMLReceiver(null, resultStoreOutputStream, true,
config.forceContentType, config.requestedContentType, config.ignoreDocumentContentType,
config.forceEncoding, config.requestedEncoding, config.ignoreDocumentEncoding));
resultStoreOutputStream.close();
return resultStoreOutputStream;
} catch (IOException e) {
throw new OXFException(e);
}
}
});
// If the output was obtained from the cache, just write it
if (!read[0]) {
if (logger.isDebugEnabled())
logger.debug("Serializer output cached");
filter.replay(fileOutputStream);
}
} else {
// Caching is not enabled
readInputAsSAX(context, dataInput, new BinaryTextXMLReceiver(null, fileOutputStream, true,
config.forceContentType, config.requestedContentType, config.ignoreDocumentContentType,
config.forceEncoding, config.requestedEncoding, config.ignoreDocumentEncoding));
fileOutputStream.close();
}
} finally {
if (fileOutputStream != null)
fileOutputStream.close();
}
}
/**
* Case where a response must be generated.
*/
@Override
public ProcessorOutput createOutput(String name) {
final ProcessorOutput output = new ProcessorOutputImpl(FileSerializer.this, name) {
public void readImpl(PipelineContext pipelineContext, XMLReceiver xmlReceiver) {
OutputStream fileOutputStream = null;
try {
//Get the input and config
final Config config = getConfig(pipelineContext);
final ProcessorInput dataInput = getInputByName(INPUT_DATA);
// Determine scope
final int scope;
if ("request".equals(config.getScope())) {
scope = NetUtils.REQUEST_SCOPE;
} else if ("session".equals(config.getScope())) {
scope = NetUtils.SESSION_SCOPE;
} else if ("application".equals(config.getScope())) {
scope = NetUtils.APPLICATION_SCOPE;
} else {
throw new OXFException("Invalid context requested: " + config.getScope());
}
// We use the commons fileupload utilities to write to file
final FileItem fileItem = NetUtils.prepareFileItem(scope);
fileOutputStream = fileItem.getOutputStream();
writeToFile(pipelineContext, config, dataInput, fileOutputStream);
// Create file if it doesn't exist
final File storeLocation = ((DiskFileItem) fileItem).getStoreLocation();
storeLocation.createNewFile();
// Get the url of the file
final String resultURL;
{
final String localURL = ((DiskFileItem) fileItem).getStoreLocation().toURI().toString();
if ("session".equals(config.getScope()) && config.isProxyResult())
resultURL = XFormsResourceServer.jProxyURI(localURL, config.getRequestedContentType());
else
resultURL = localURL;
}
xmlReceiver.startDocument();
xmlReceiver.startElement("", "url", "url", XMLUtils.EMPTY_ATTRIBUTES);
xmlReceiver.characters(resultURL.toCharArray(), 0, resultURL.length());
xmlReceiver.endElement("", "url", "url");
xmlReceiver.endDocument();
}
catch (SAXException e) {
throw new OXFException(e);
}
catch (IOException e) {
throw new OXFException(e);
}
finally {
if (fileOutputStream != null) {
try {
fileOutputStream.close();
}
catch (IOException e) {
throw new OXFException(e);
}
}
}
}
};
addOutput(name, output);
return output;
}
protected Config getConfig(PipelineContext pipelineContext) {
// Read config
return readCacheInputAsObject(pipelineContext, getInputByName(INPUT_CONFIG), new CacheableInputReader<Config>() {
public Config read(PipelineContext context, ProcessorInput input) {
return new Config(readInputAsDOM4J(context, input));
}
});
}
}
| Java |
/***
Copyright (c) 2011, 2014 Hércules S. S. José
Este arquivo é parte do programa Imobiliária Web.
Imobiliária Web é um software livre; você pode redistribui-lo e/ou
modificá-lo dentro dos termos da Licença Pública Geral Menor GNU como
publicada pela Fundação do Software Livre (FSF); na versão 2.1 da
Licença.
Este programa é distribuído na esperança que possa ser util,
mas SEM NENHUMA GARANTIA; sem uma garantia implicita de ADEQUAÇÂO a qualquer
MERCADO ou APLICAÇÃO EM PARTICULAR. Veja a Licença Pública Geral Menor GNU em
português para maiores detalhes.
Você deve ter recebido uma cópia da Licença Pública Geral Menor GNU sob o
nome de "LICENSE.TXT" junto com este programa, se não, acesse o site HSlife no
endereco www.hslife.com.br ou escreva para a Fundação do Software Livre(FSF) Inc.,
51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA.
Para mais informações sobre o programa Imobiliária Web e seus autores acesso o
endereço www.hslife.com.br, pelo e-mail contato@hslife.com.br ou escreva para
Hércules S. S. José, Av. Ministro Lafaeyte de Andrade, 1683 - Bl. 3 Apt 404,
Marco II - Nova Iguaçu, RJ, Brasil.
***/
package br.com.hslife.imobiliaria.logic;
import java.util.List;
import br.com.hslife.imobiliaria.exception.BusinessException;
import br.com.hslife.imobiliaria.model.Usuario;
public interface IUsuario {
public void cadastrar(Usuario usuario) throws BusinessException;
public void editar(Usuario usuario) throws BusinessException;
public void habilitar(Long id) throws BusinessException;
public Usuario buscar(Long id) throws BusinessException;
public List<Usuario> buscar(Usuario usuario) throws BusinessException;
public List<Usuario> buscarTodos() throws BusinessException;
public Usuario buscarPorLogin(String login) throws BusinessException;
public List<Usuario> buscarTodosPorLogin(String login) throws BusinessException;
}
| Java |
/**
* DSS - Digital Signature Services
* Copyright (C) 2015 European Commission, provided under the CEF programme
*
* This file is part of the "DSS - Digital Signature Services" project.
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
* version 2.1 of the License, or (at your option) any later version.
*
* This library is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
* Lesser General Public License for more details.
*
* You should have received a copy of the GNU Lesser General Public
* License along with this library; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
*/
package eu.europa.esig.dss.pades.timestamp;
import static org.junit.Assert.assertNotNull;
import static org.junit.jupiter.api.Assertions.assertEquals;
import java.io.IOException;
import java.io.InputStream;
import java.util.List;
import org.apache.pdfbox.pdmodel.PDDocument;
import org.apache.pdfbox.pdmodel.interactive.digitalsignature.PDSignature;
import org.junit.jupiter.api.Test;
import eu.europa.esig.dss.model.DSSDocument;
import eu.europa.esig.dss.model.InMemoryDocument;
import eu.europa.esig.dss.pades.PAdESTimestampParameters;
import eu.europa.esig.dss.pades.signature.PAdESService;
import eu.europa.esig.dss.test.signature.PKIFactoryAccess;
public class PDFTimestampServiceTest extends PKIFactoryAccess {
@Test
public void timestampAlone() throws IOException {
PAdESService service = new PAdESService(getCompleteCertificateVerifier());
service.setTspSource(getGoodTsa());
PAdESTimestampParameters parameters = new PAdESTimestampParameters();
DSSDocument document = new InMemoryDocument(getClass().getResourceAsStream("/sample.pdf"));
DSSDocument timestamped = service.timestamp(document, parameters);
try (InputStream is = timestamped.openStream(); PDDocument doc = PDDocument.load(is)) {
List<PDSignature> signatureDictionaries = doc.getSignatureDictionaries();
assertEquals(1, signatureDictionaries.size());
PDSignature pdSignature = signatureDictionaries.get(0);
assertNotNull(pdSignature);
assertEquals("Adobe.PPKLite", pdSignature.getFilter());
assertEquals("ETSI.RFC3161", pdSignature.getSubFilter());
}
}
@Override
protected String getSigningAlias() {
return null;
}
}
| Java |
/**
*/
package net.opengis.gml311;
/**
* <!-- begin-user-doc -->
* A representation of the model object '<em><b>Abstract Parametric Curve Surface Type</b></em>'.
* <!-- end-user-doc -->
*
* <!-- begin-model-doc -->
*
*
* <!-- end-model-doc -->
*
*
* @see net.opengis.gml311.Gml311Package#getAbstractParametricCurveSurfaceType()
* @model extendedMetaData="name='AbstractParametricCurveSurfaceType' kind='empty'"
* @generated
*/
public interface AbstractParametricCurveSurfaceType extends AbstractSurfacePatchType {
} // AbstractParametricCurveSurfaceType
| Java |
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<!--NewPage-->
<HTML>
<HEAD>
<!-- Generated by javadoc (build 1.6.0_21) on Thu Aug 05 10:04:40 JST 2010 -->
<TITLE>
All Classes (estraier)
</TITLE>
<META NAME="date" CONTENT="2010-08-05">
<LINK REL ="stylesheet" TYPE="text/css" HREF="stylesheet.css" TITLE="Style">
</HEAD>
<BODY BGCOLOR="white">
<FONT size="+1" CLASS="FrameHeadingFont">
<B>All Classes</B></FONT>
<BR>
<TABLE BORDER="0" WIDTH="100%" SUMMARY="">
<TR>
<TD NOWRAP><FONT CLASS="FrameItemFont"><A HREF="estraier/Cmd.html" title="class in estraier">Cmd</A>
<BR>
<A HREF="estraier/Condition.html" title="class in estraier">Condition</A>
<BR>
<A HREF="estraier/Database.html" title="class in estraier">Database</A>
<BR>
<A HREF="estraier/DatabaseInformer.html" title="interface in estraier"><I>DatabaseInformer</I></A>
<BR>
<A HREF="estraier/Document.html" title="class in estraier">Document</A>
<BR>
<A HREF="estraier/Result.html" title="class in estraier">Result</A>
<BR>
</FONT></TD>
</TR>
</TABLE>
</BODY>
</HTML>
| Java |
// The libMesh Finite Element Library.
// Copyright (C) 2002-2020 Benjamin S. Kirk, John W. Peterson, Roy H. Stogner
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
// License as published by the Free Software Foundation; either
// version 2.1 of the License, or (at your option) any later version.
// This library is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
// You should have received a copy of the GNU Lesser General Public
// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
#include "libmesh/diff_context.h"
#include "libmesh/diff_physics.h"
#include "libmesh/system.h"
namespace libMesh
{
DifferentiablePhysics::~DifferentiablePhysics()
{
DifferentiablePhysics::clear_physics();
}
void DifferentiablePhysics::clear_physics ()
{
_time_evolving.resize(0);
}
void DifferentiablePhysics::init_physics (const System & sys)
{
// give us flags for every variable that might be time evolving
_time_evolving.resize(sys.n_vars(), false);
}
void DifferentiablePhysics::time_evolving (unsigned int var,
unsigned int order)
{
if (order != 1 && order != 2)
libmesh_error_msg("Input order must be 1 or 2!");
if (_time_evolving.size() <= var)
_time_evolving.resize(var+1, 0);
_time_evolving[var] = order;
if (order == 1)
_first_order_vars.insert(var);
else
_second_order_vars.insert(var);
}
bool DifferentiablePhysics::nonlocal_mass_residual(bool request_jacobian,
DiffContext & c)
{
FEMContext & context = cast_ref<FEMContext &>(c);
for (auto var : IntRange<unsigned int>(0, context.n_vars()))
{
if (!this->is_time_evolving(var))
continue;
if (c.get_system().variable(var).type().family != SCALAR)
continue;
const std::vector<dof_id_type> & dof_indices =
context.get_dof_indices(var);
const unsigned int n_dofs = cast_int<unsigned int>
(dof_indices.size());
DenseSubVector<Number> & Fs = context.get_elem_residual(var);
DenseSubMatrix<Number> & Kss = context.get_elem_jacobian( var, var );
const libMesh::DenseSubVector<libMesh::Number> & Us =
context.get_elem_solution(var);
for (unsigned int i=0; i != n_dofs; ++i)
{
Fs(i) -= Us(i);
if (request_jacobian)
Kss(i,i) -= context.elem_solution_rate_derivative;
}
}
return request_jacobian;
}
bool DifferentiablePhysics::_eulerian_time_deriv (bool request_jacobian,
DiffContext & context)
{
// For any problem we need time derivative terms
request_jacobian =
this->element_time_derivative(request_jacobian, context);
// For a moving mesh problem we may need the pseudoconvection term too
return this->eulerian_residual(request_jacobian, context) &&
request_jacobian;
}
} // namespace libMesh
| Java |
#define _XOPEN_SOURCE
#include <stdlib.h>
#include "zdtmtst.h"
#include <sys/types.h>
#include <sys/stat.h>
#include <fcntl.h>
#include <unistd.h>
#include <sys/wait.h>
#include <termios.h>
#include <sys/ioctl.h>
const char *test_doc = "Check a controlling terminal, if a proper fd belongs to another session leader";
const char *test_author = "Andrey Vagin <avagin@openvz.org>";
int main(int argc, char ** argv)
{
int fdm, fds, exit_code = 1, status;
task_waiter_t t;
char *slavename;
pid_t sid_b, sid_a, pid;
int pfd[2];
test_init(argc, argv);
task_waiter_init(&t);
if (pipe(pfd) == -1) {
pr_perror("pipe");
return 1;
}
fdm = open("/dev/ptmx", O_RDWR);
if (fdm == -1) {
pr_perror("Can't open a master pseudoterminal");
return 1;
}
grantpt(fdm);
unlockpt(fdm);
slavename = ptsname(fdm);
pid = test_fork();
if (pid == 0) {
if (setsid() == -1) {
pr_perror("setsid");
return 1;
}
close(pfd[0]);
/* set up a controlling terminal */
fds = open(slavename, O_RDWR | O_NOCTTY);
if (fds == -1) {
pr_perror("Can't open a slave pseudoterminal %s", slavename);
return 1;
}
ioctl(fds, TIOCSCTTY, 1);
pid = test_fork();
if (pid == 0) {
if (setsid() == -1) {
pr_perror("setsid");
return 1;
}
close(pfd[1]);
task_waiter_complete(&t, 1);
test_waitsig();
exit(0);
}
close(fds);
close(pfd[1]);
task_waiter_wait4(&t, 1);
task_waiter_complete(&t, 0);
test_waitsig();
kill(pid, SIGTERM);
wait(&status);
exit(status);
}
close(pfd[1]);
if (read(pfd[0], &sid_a, 1) != 0) {
pr_perror("read");
goto out;
}
if (ioctl(fdm, TIOCGSID, &sid_b) == -1) {
pr_perror("The tty is not a controlling");
goto out;
}
task_waiter_wait4(&t, 0);
test_daemon();
test_waitsig();
if (ioctl(fdm, TIOCGSID, &sid_a) == -1) {
fail("The tty is not a controlling");
goto out;
}
if (sid_b != sid_a) {
fail("The tty is controlling for someone else");
goto out;
}
exit_code = 0;
out:
kill(pid, SIGTERM);
wait(&status);
if (status == 0 && exit_code == 0)
pass();
return exit_code;
}
| Java |
/*
Simple DirectMedia Layer
Java source code (C) 2009-2011 Sergii Pylypenko
This software is provided 'as-is', without any express or implied
warranty. In no event will the authors be held liable for any damages
arising from the use of this software.
Permission is granted to anyone to use this software for any purpose,
including commercial applications, and to alter it and redistribute it
freely, subject to the following restrictions:
1. The origin of this software must not be misrepresented; you must not
claim that you wrote the original software. If you use this software
in a product, an acknowledgment in the product documentation would be
appreciated but is not required.
2. Altered source versions must be plainly marked as such, and must not be
misrepresented as being the original software.
3. This notice may not be removed or altered from any source distribution.
*/
package net.sourceforge.clonekeenplus;
import java.lang.String;
import java.util.ArrayList;
import java.util.Arrays;
import java.lang.reflect.Field;
// Autogenerated by hand with a command:
// grep 'SDLK_' SDL_keysym.h | sed 's/SDLK_\([a-zA-Z0-9_]\+\).*[=] \([0-9]\+\).*/public static final int SDLK_\1 = \2;/' >> Keycodes.java
class SDL_1_2_Keycodes {
public static final int SDLK_UNKNOWN = 0;
public static final int SDLK_BACKSPACE = 8;
public static final int SDLK_TAB = 9;
public static final int SDLK_CLEAR = 12;
public static final int SDLK_RETURN = 13;
public static final int SDLK_PAUSE = 19;
public static final int SDLK_ESCAPE = 27;
public static final int SDLK_SPACE = 32;
public static final int SDLK_EXCLAIM = 33;
public static final int SDLK_QUOTEDBL = 34;
public static final int SDLK_HASH = 35;
public static final int SDLK_DOLLAR = 36;
public static final int SDLK_AMPERSAND = 38;
public static final int SDLK_QUOTE = 39;
public static final int SDLK_LEFTPAREN = 40;
public static final int SDLK_RIGHTPAREN = 41;
public static final int SDLK_ASTERISK = 42;
public static final int SDLK_PLUS = 43;
public static final int SDLK_COMMA = 44;
public static final int SDLK_MINUS = 45;
public static final int SDLK_PERIOD = 46;
public static final int SDLK_SLASH = 47;
public static final int SDLK_0 = 48;
public static final int SDLK_1 = 49;
public static final int SDLK_2 = 50;
public static final int SDLK_3 = 51;
public static final int SDLK_4 = 52;
public static final int SDLK_5 = 53;
public static final int SDLK_6 = 54;
public static final int SDLK_7 = 55;
public static final int SDLK_8 = 56;
public static final int SDLK_9 = 57;
public static final int SDLK_COLON = 58;
public static final int SDLK_SEMICOLON = 59;
public static final int SDLK_LESS = 60;
public static final int SDLK_EQUALS = 61;
public static final int SDLK_GREATER = 62;
public static final int SDLK_QUESTION = 63;
public static final int SDLK_AT = 64;
public static final int SDLK_LEFTBRACKET = 91;
public static final int SDLK_BACKSLASH = 92;
public static final int SDLK_RIGHTBRACKET = 93;
public static final int SDLK_CARET = 94;
public static final int SDLK_UNDERSCORE = 95;
public static final int SDLK_BACKQUOTE = 96;
public static final int SDLK_a = 97;
public static final int SDLK_b = 98;
public static final int SDLK_c = 99;
public static final int SDLK_d = 100;
public static final int SDLK_e = 101;
public static final int SDLK_f = 102;
public static final int SDLK_g = 103;
public static final int SDLK_h = 104;
public static final int SDLK_i = 105;
public static final int SDLK_j = 106;
public static final int SDLK_k = 107;
public static final int SDLK_l = 108;
public static final int SDLK_m = 109;
public static final int SDLK_n = 110;
public static final int SDLK_o = 111;
public static final int SDLK_p = 112;
public static final int SDLK_q = 113;
public static final int SDLK_r = 114;
public static final int SDLK_s = 115;
public static final int SDLK_t = 116;
public static final int SDLK_u = 117;
public static final int SDLK_v = 118;
public static final int SDLK_w = 119;
public static final int SDLK_x = 120;
public static final int SDLK_y = 121;
public static final int SDLK_z = 122;
public static final int SDLK_DELETE = 127;
public static final int SDLK_WORLD_0 = 160;
public static final int SDLK_WORLD_1 = 161;
public static final int SDLK_WORLD_2 = 162;
public static final int SDLK_WORLD_3 = 163;
public static final int SDLK_WORLD_4 = 164;
public static final int SDLK_WORLD_5 = 165;
public static final int SDLK_WORLD_6 = 166;
public static final int SDLK_WORLD_7 = 167;
public static final int SDLK_WORLD_8 = 168;
public static final int SDLK_WORLD_9 = 169;
public static final int SDLK_WORLD_10 = 170;
public static final int SDLK_WORLD_11 = 171;
public static final int SDLK_WORLD_12 = 172;
public static final int SDLK_WORLD_13 = 173;
public static final int SDLK_WORLD_14 = 174;
public static final int SDLK_WORLD_15 = 175;
public static final int SDLK_WORLD_16 = 176;
public static final int SDLK_WORLD_17 = 177;
public static final int SDLK_WORLD_18 = 178;
public static final int SDLK_WORLD_19 = 179;
public static final int SDLK_WORLD_20 = 180;
public static final int SDLK_WORLD_21 = 181;
public static final int SDLK_WORLD_22 = 182;
public static final int SDLK_WORLD_23 = 183;
public static final int SDLK_WORLD_24 = 184;
public static final int SDLK_WORLD_25 = 185;
public static final int SDLK_WORLD_26 = 186;
public static final int SDLK_WORLD_27 = 187;
public static final int SDLK_WORLD_28 = 188;
public static final int SDLK_WORLD_29 = 189;
public static final int SDLK_WORLD_30 = 190;
public static final int SDLK_WORLD_31 = 191;
public static final int SDLK_WORLD_32 = 192;
public static final int SDLK_WORLD_33 = 193;
public static final int SDLK_WORLD_34 = 194;
public static final int SDLK_WORLD_35 = 195;
public static final int SDLK_WORLD_36 = 196;
public static final int SDLK_WORLD_37 = 197;
public static final int SDLK_WORLD_38 = 198;
public static final int SDLK_WORLD_39 = 199;
public static final int SDLK_WORLD_40 = 200;
public static final int SDLK_WORLD_41 = 201;
public static final int SDLK_WORLD_42 = 202;
public static final int SDLK_WORLD_43 = 203;
public static final int SDLK_WORLD_44 = 204;
public static final int SDLK_WORLD_45 = 205;
public static final int SDLK_WORLD_46 = 206;
public static final int SDLK_WORLD_47 = 207;
public static final int SDLK_WORLD_48 = 208;
public static final int SDLK_WORLD_49 = 209;
public static final int SDLK_WORLD_50 = 210;
public static final int SDLK_WORLD_51 = 211;
public static final int SDLK_WORLD_52 = 212;
public static final int SDLK_WORLD_53 = 213;
public static final int SDLK_WORLD_54 = 214;
public static final int SDLK_WORLD_55 = 215;
public static final int SDLK_WORLD_56 = 216;
public static final int SDLK_WORLD_57 = 217;
public static final int SDLK_WORLD_58 = 218;
public static final int SDLK_WORLD_59 = 219;
public static final int SDLK_WORLD_60 = 220;
public static final int SDLK_WORLD_61 = 221;
public static final int SDLK_WORLD_62 = 222;
public static final int SDLK_WORLD_63 = 223;
public static final int SDLK_WORLD_64 = 224;
public static final int SDLK_WORLD_65 = 225;
public static final int SDLK_WORLD_66 = 226;
public static final int SDLK_WORLD_67 = 227;
public static final int SDLK_WORLD_68 = 228;
public static final int SDLK_WORLD_69 = 229;
public static final int SDLK_WORLD_70 = 230;
public static final int SDLK_WORLD_71 = 231;
public static final int SDLK_WORLD_72 = 232;
public static final int SDLK_WORLD_73 = 233;
public static final int SDLK_WORLD_74 = 234;
public static final int SDLK_WORLD_75 = 235;
public static final int SDLK_WORLD_76 = 236;
public static final int SDLK_WORLD_77 = 237;
public static final int SDLK_WORLD_78 = 238;
public static final int SDLK_WORLD_79 = 239;
public static final int SDLK_WORLD_80 = 240;
public static final int SDLK_WORLD_81 = 241;
public static final int SDLK_WORLD_82 = 242;
public static final int SDLK_WORLD_83 = 243;
public static final int SDLK_WORLD_84 = 244;
public static final int SDLK_WORLD_85 = 245;
public static final int SDLK_WORLD_86 = 246;
public static final int SDLK_WORLD_87 = 247;
public static final int SDLK_WORLD_88 = 248;
public static final int SDLK_WORLD_89 = 249;
public static final int SDLK_WORLD_90 = 250;
public static final int SDLK_WORLD_91 = 251;
public static final int SDLK_WORLD_92 = 252;
public static final int SDLK_WORLD_93 = 253;
public static final int SDLK_WORLD_94 = 254;
public static final int SDLK_WORLD_95 = 255;
public static final int SDLK_KP0 = 256;
public static final int SDLK_KP1 = 257;
public static final int SDLK_KP2 = 258;
public static final int SDLK_KP3 = 259;
public static final int SDLK_KP4 = 260;
public static final int SDLK_KP5 = 261;
public static final int SDLK_KP6 = 262;
public static final int SDLK_KP7 = 263;
public static final int SDLK_KP8 = 264;
public static final int SDLK_KP9 = 265;
public static final int SDLK_KP_PERIOD = 266;
public static final int SDLK_KP_DIVIDE = 267;
public static final int SDLK_KP_MULTIPLY = 268;
public static final int SDLK_KP_MINUS = 269;
public static final int SDLK_KP_PLUS = 270;
public static final int SDLK_KP_ENTER = 271;
public static final int SDLK_KP_EQUALS = 272;
public static final int SDLK_UP = 273;
public static final int SDLK_DOWN = 274;
public static final int SDLK_RIGHT = 275;
public static final int SDLK_LEFT = 276;
public static final int SDLK_INSERT = 277;
public static final int SDLK_HOME = 278;
public static final int SDLK_END = 279;
public static final int SDLK_PAGEUP = 280;
public static final int SDLK_PAGEDOWN = 281;
public static final int SDLK_F1 = 282;
public static final int SDLK_F2 = 283;
public static final int SDLK_F3 = 284;
public static final int SDLK_F4 = 285;
public static final int SDLK_F5 = 286;
public static final int SDLK_F6 = 287;
public static final int SDLK_F7 = 288;
public static final int SDLK_F8 = 289;
public static final int SDLK_F9 = 290;
public static final int SDLK_F10 = 291;
public static final int SDLK_F11 = 292;
public static final int SDLK_F12 = 293;
public static final int SDLK_F13 = 294;
public static final int SDLK_F14 = 295;
public static final int SDLK_F15 = 296;
public static final int SDLK_NUMLOCK = 300;
public static final int SDLK_CAPSLOCK = 301;
public static final int SDLK_SCROLLOCK = 302;
public static final int SDLK_RSHIFT = 303;
public static final int SDLK_LSHIFT = 304;
public static final int SDLK_RCTRL = 305;
public static final int SDLK_LCTRL = 306;
public static final int SDLK_RALT = 307;
public static final int SDLK_LALT = 308;
public static final int SDLK_RMETA = 309;
public static final int SDLK_LMETA = 310;
public static final int SDLK_LSUPER = 311;
public static final int SDLK_RSUPER = 312;
public static final int SDLK_MODE = 313;
public static final int SDLK_COMPOSE = 314;
public static final int SDLK_HELP = 315;
public static final int SDLK_PRINT = 316;
public static final int SDLK_SYSREQ = 317;
public static final int SDLK_BREAK = 318;
public static final int SDLK_MENU = 319;
public static final int SDLK_POWER = 320;
public static final int SDLK_EURO = 321;
public static final int SDLK_UNDO = 322;
public static final int SDLK_NO_REMAP = 512;
}
// Autogenerated by hand with a command:
// grep 'SDL_SCANCODE_' SDL_scancode.h | sed 's/SDL_SCANCODE_\([a-zA-Z0-9_]\+\).*[=] \([0-9]\+\).*/public static final int SDLK_\1 = \2;/' >> Keycodes.java
class SDL_1_3_Keycodes {
public static final int SDLK_UNKNOWN = 0;
public static final int SDLK_A = 4;
public static final int SDLK_B = 5;
public static final int SDLK_C = 6;
public static final int SDLK_D = 7;
public static final int SDLK_E = 8;
public static final int SDLK_F = 9;
public static final int SDLK_G = 10;
public static final int SDLK_H = 11;
public static final int SDLK_I = 12;
public static final int SDLK_J = 13;
public static final int SDLK_K = 14;
public static final int SDLK_L = 15;
public static final int SDLK_M = 16;
public static final int SDLK_N = 17;
public static final int SDLK_O = 18;
public static final int SDLK_P = 19;
public static final int SDLK_Q = 20;
public static final int SDLK_R = 21;
public static final int SDLK_S = 22;
public static final int SDLK_T = 23;
public static final int SDLK_U = 24;
public static final int SDLK_V = 25;
public static final int SDLK_W = 26;
public static final int SDLK_X = 27;
public static final int SDLK_Y = 28;
public static final int SDLK_Z = 29;
public static final int SDLK_1 = 30;
public static final int SDLK_2 = 31;
public static final int SDLK_3 = 32;
public static final int SDLK_4 = 33;
public static final int SDLK_5 = 34;
public static final int SDLK_6 = 35;
public static final int SDLK_7 = 36;
public static final int SDLK_8 = 37;
public static final int SDLK_9 = 38;
public static final int SDLK_0 = 39;
public static final int SDLK_RETURN = 40;
public static final int SDLK_ESCAPE = 41;
public static final int SDLK_BACKSPACE = 42;
public static final int SDLK_TAB = 43;
public static final int SDLK_SPACE = 44;
public static final int SDLK_MINUS = 45;
public static final int SDLK_EQUALS = 46;
public static final int SDLK_LEFTBRACKET = 47;
public static final int SDLK_RIGHTBRACKET = 48;
public static final int SDLK_BACKSLASH = 49;
public static final int SDLK_NONUSHASH = 50;
public static final int SDLK_SEMICOLON = 51;
public static final int SDLK_APOSTROPHE = 52;
public static final int SDLK_GRAVE = 53;
public static final int SDLK_COMMA = 54;
public static final int SDLK_PERIOD = 55;
public static final int SDLK_SLASH = 56;
public static final int SDLK_CAPSLOCK = 57;
public static final int SDLK_F1 = 58;
public static final int SDLK_F2 = 59;
public static final int SDLK_F3 = 60;
public static final int SDLK_F4 = 61;
public static final int SDLK_F5 = 62;
public static final int SDLK_F6 = 63;
public static final int SDLK_F7 = 64;
public static final int SDLK_F8 = 65;
public static final int SDLK_F9 = 66;
public static final int SDLK_F10 = 67;
public static final int SDLK_F11 = 68;
public static final int SDLK_F12 = 69;
public static final int SDLK_PRINTSCREEN = 70;
public static final int SDLK_SCROLLLOCK = 71;
public static final int SDLK_PAUSE = 72;
public static final int SDLK_INSERT = 73;
public static final int SDLK_HOME = 74;
public static final int SDLK_PAGEUP = 75;
public static final int SDLK_DELETE = 76;
public static final int SDLK_END = 77;
public static final int SDLK_PAGEDOWN = 78;
public static final int SDLK_RIGHT = 79;
public static final int SDLK_LEFT = 80;
public static final int SDLK_DOWN = 81;
public static final int SDLK_UP = 82;
public static final int SDLK_NUMLOCKCLEAR = 83;
public static final int SDLK_KP_DIVIDE = 84;
public static final int SDLK_KP_MULTIPLY = 85;
public static final int SDLK_KP_MINUS = 86;
public static final int SDLK_KP_PLUS = 87;
public static final int SDLK_KP_ENTER = 88;
public static final int SDLK_KP_1 = 89;
public static final int SDLK_KP_2 = 90;
public static final int SDLK_KP_3 = 91;
public static final int SDLK_KP_4 = 92;
public static final int SDLK_KP_5 = 93;
public static final int SDLK_KP_6 = 94;
public static final int SDLK_KP_7 = 95;
public static final int SDLK_KP_8 = 96;
public static final int SDLK_KP_9 = 97;
public static final int SDLK_KP_0 = 98;
public static final int SDLK_KP_PERIOD = 99;
public static final int SDLK_NONUSBACKSLASH = 100;
public static final int SDLK_APPLICATION = 101;
public static final int SDLK_POWER = 102;
public static final int SDLK_KP_EQUALS = 103;
public static final int SDLK_F13 = 104;
public static final int SDLK_F14 = 105;
public static final int SDLK_F15 = 106;
public static final int SDLK_F16 = 107;
public static final int SDLK_F17 = 108;
public static final int SDLK_F18 = 109;
public static final int SDLK_F19 = 110;
public static final int SDLK_F20 = 111;
public static final int SDLK_F21 = 112;
public static final int SDLK_F22 = 113;
public static final int SDLK_F23 = 114;
public static final int SDLK_F24 = 115;
public static final int SDLK_EXECUTE = 116;
public static final int SDLK_HELP = 117;
public static final int SDLK_MENU = 118;
public static final int SDLK_SELECT = 119;
public static final int SDLK_STOP = 120;
public static final int SDLK_AGAIN = 121;
public static final int SDLK_UNDO = 122;
public static final int SDLK_CUT = 123;
public static final int SDLK_COPY = 124;
public static final int SDLK_PASTE = 125;
public static final int SDLK_FIND = 126;
public static final int SDLK_MUTE = 127;
public static final int SDLK_VOLUMEUP = 128;
public static final int SDLK_VOLUMEDOWN = 129;
public static final int SDLK_KP_COMMA = 133;
public static final int SDLK_KP_EQUALSAS400 = 134;
public static final int SDLK_INTERNATIONAL1 = 135;
public static final int SDLK_INTERNATIONAL2 = 136;
public static final int SDLK_INTERNATIONAL3 = 137;
public static final int SDLK_INTERNATIONAL4 = 138;
public static final int SDLK_INTERNATIONAL5 = 139;
public static final int SDLK_INTERNATIONAL6 = 140;
public static final int SDLK_INTERNATIONAL7 = 141;
public static final int SDLK_INTERNATIONAL8 = 142;
public static final int SDLK_INTERNATIONAL9 = 143;
public static final int SDLK_LANG1 = 144;
public static final int SDLK_LANG2 = 145;
public static final int SDLK_LANG3 = 146;
public static final int SDLK_LANG4 = 147;
public static final int SDLK_LANG5 = 148;
public static final int SDLK_LANG6 = 149;
public static final int SDLK_LANG7 = 150;
public static final int SDLK_LANG8 = 151;
public static final int SDLK_LANG9 = 152;
public static final int SDLK_ALTERASE = 153;
public static final int SDLK_SYSREQ = 154;
public static final int SDLK_CANCEL = 155;
public static final int SDLK_CLEAR = 156;
public static final int SDLK_PRIOR = 157;
public static final int SDLK_RETURN2 = 158;
public static final int SDLK_SEPARATOR = 159;
public static final int SDLK_OUT = 160;
public static final int SDLK_OPER = 161;
public static final int SDLK_CLEARAGAIN = 162;
public static final int SDLK_CRSEL = 163;
public static final int SDLK_EXSEL = 164;
public static final int SDLK_KP_00 = 176;
public static final int SDLK_KP_000 = 177;
public static final int SDLK_THOUSANDSSEPARATOR = 178;
public static final int SDLK_DECIMALSEPARATOR = 179;
public static final int SDLK_CURRENCYUNIT = 180;
public static final int SDLK_CURRENCYSUBUNIT = 181;
public static final int SDLK_KP_LEFTPAREN = 182;
public static final int SDLK_KP_RIGHTPAREN = 183;
public static final int SDLK_KP_LEFTBRACE = 184;
public static final int SDLK_KP_RIGHTBRACE = 185;
public static final int SDLK_KP_TAB = 186;
public static final int SDLK_KP_BACKSPACE = 187;
public static final int SDLK_KP_A = 188;
public static final int SDLK_KP_B = 189;
public static final int SDLK_KP_C = 190;
public static final int SDLK_KP_D = 191;
public static final int SDLK_KP_E = 192;
public static final int SDLK_KP_F = 193;
public static final int SDLK_KP_XOR = 194;
public static final int SDLK_KP_POWER = 195;
public static final int SDLK_KP_PERCENT = 196;
public static final int SDLK_KP_LESS = 197;
public static final int SDLK_KP_GREATER = 198;
public static final int SDLK_KP_AMPERSAND = 199;
public static final int SDLK_KP_DBLAMPERSAND = 200;
public static final int SDLK_KP_VERTICALBAR = 201;
public static final int SDLK_KP_DBLVERTICALBAR = 202;
public static final int SDLK_KP_COLON = 203;
public static final int SDLK_KP_HASH = 204;
public static final int SDLK_KP_SPACE = 205;
public static final int SDLK_KP_AT = 206;
public static final int SDLK_KP_EXCLAM = 207;
public static final int SDLK_KP_MEMSTORE = 208;
public static final int SDLK_KP_MEMRECALL = 209;
public static final int SDLK_KP_MEMCLEAR = 210;
public static final int SDLK_KP_MEMADD = 211;
public static final int SDLK_KP_MEMSUBTRACT = 212;
public static final int SDLK_KP_MEMMULTIPLY = 213;
public static final int SDLK_KP_MEMDIVIDE = 214;
public static final int SDLK_KP_PLUSMINUS = 215;
public static final int SDLK_KP_CLEAR = 216;
public static final int SDLK_KP_CLEARENTRY = 217;
public static final int SDLK_KP_BINARY = 218;
public static final int SDLK_KP_OCTAL = 219;
public static final int SDLK_KP_DECIMAL = 220;
public static final int SDLK_KP_HEXADECIMAL = 221;
public static final int SDLK_LCTRL = 224;
public static final int SDLK_LSHIFT = 225;
public static final int SDLK_LALT = 226;
public static final int SDLK_LGUI = 227;
public static final int SDLK_RCTRL = 228;
public static final int SDLK_RSHIFT = 229;
public static final int SDLK_RALT = 230;
public static final int SDLK_RGUI = 231;
public static final int SDLK_MODE = 257;
public static final int SDLK_AUDIONEXT = 258;
public static final int SDLK_AUDIOPREV = 259;
public static final int SDLK_AUDIOSTOP = 260;
public static final int SDLK_AUDIOPLAY = 261;
public static final int SDLK_AUDIOMUTE = 262;
public static final int SDLK_MEDIASELECT = 263;
public static final int SDLK_WWW = 264;
public static final int SDLK_MAIL = 265;
public static final int SDLK_CALCULATOR = 266;
public static final int SDLK_COMPUTER = 267;
public static final int SDLK_AC_SEARCH = 268;
public static final int SDLK_AC_HOME = 269;
public static final int SDLK_AC_BACK = 270;
public static final int SDLK_AC_FORWARD = 271;
public static final int SDLK_AC_STOP = 272;
public static final int SDLK_AC_REFRESH = 273;
public static final int SDLK_AC_BOOKMARKS = 274;
public static final int SDLK_BRIGHTNESSDOWN = 275;
public static final int SDLK_BRIGHTNESSUP = 276;
public static final int SDLK_DISPLAYSWITCH = 277;
public static final int SDLK_KBDILLUMTOGGLE = 278;
public static final int SDLK_KBDILLUMDOWN = 279;
public static final int SDLK_KBDILLUMUP = 280;
public static final int SDLK_EJECT = 281;
public static final int SDLK_SLEEP = 282;
public static final int SDLK_NO_REMAP = 512;
}
class SDL_Keys
{
public static String [] names = null;
public static Integer [] values = null;
public static String [] namesSorted = null;
public static Integer [] namesSortedIdx = null;
public static Integer [] namesSortedBackIdx = null;
static final int JAVA_KEYCODE_LAST = 255; // Android 2.3 added several new gaming keys, Android 3.1 added even more - keep in sync with javakeycodes.h
static
{
ArrayList<String> Names = new ArrayList<String> ();
ArrayList<Integer> Values = new ArrayList<Integer> ();
Field [] fields = SDL_1_2_Keycodes.class.getDeclaredFields();
if( Globals.Using_SDL_1_3 )
{
fields = SDL_1_3_Keycodes.class.getDeclaredFields();
}
try {
for(Field f: fields)
{
Values.add(f.getInt(null));
Names.add(f.getName().substring(5).toUpperCase());
}
} catch(IllegalAccessException e) {};
// Sort by value
for( int i = 0; i < Values.size(); i++ )
{
for( int j = i; j < Values.size(); j++ )
{
if( Values.get(i) > Values.get(j) )
{
int x = Values.get(i);
Values.set(i, Values.get(j));
Values.set(j, x);
String s = Names.get(i);
Names.set(i, Names.get(j));
Names.set(j, s);
}
}
}
names = Names.toArray(new String[0]);
values = Values.toArray(new Integer[0]);
namesSorted = Names.toArray(new String[0]);
namesSortedIdx = new Integer[values.length];
namesSortedBackIdx = new Integer[values.length];
Arrays.sort(namesSorted);
for( int i = 0; i < namesSorted.length; i++ )
{
for( int j = 0; j < namesSorted.length; j++ )
{
if( namesSorted[i].equals( names[j] ) )
{
namesSortedIdx[i] = j;
namesSortedBackIdx[j] = i;
break;
}
}
}
}
}
| Java |
/*-------------------------------------------------------------------------
| RXTX License v 2.1 - LGPL v 2.1 + Linking Over Controlled Interface.
| RXTX is a native interface to serial ports in java.
| Copyright 1997-2007 by Trent Jarvi tjarvi@qbang.org and others who
| actually wrote it. See individual source files for more information.
|
| A copy of the LGPL v 2.1 may be found at
| http://www.gnu.org/licenses/lgpl.txt on March 4th 2007. A copy is
| here for your convenience.
|
| This library is free software; you can redistribute it and/or
| modify it under the terms of the GNU Lesser General Public
| License as published by the Free Software Foundation; either
| version 2.1 of the License, or (at your option) any later version.
|
| This library is distributed in the hope that it will be useful,
| but WITHOUT ANY WARRANTY; without even the implied warranty of
| MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
| Lesser General Public License for more details.
|
| An executable that contains no derivative of any portion of RXTX, but
| is designed to work with RXTX by being dynamically linked with it,
| is considered a "work that uses the Library" subject to the terms and
| conditions of the GNU Lesser General Public License.
|
| The following has been added to the RXTX License to remove
| any confusion about linking to RXTX. We want to allow in part what
| section 5, paragraph 2 of the LGPL does not permit in the special
| case of linking over a controlled interface. The intent is to add a
| Java Specification Request or standards body defined interface in the
| future as another exception but one is not currently available.
|
| http://www.fsf.org/licenses/gpl-faq.html#LinkingOverControlledInterface
|
| As a special exception, the copyright holders of RXTX give you
| permission to link RXTX with independent modules that communicate with
| RXTX solely through the Sun Microsytems CommAPI interface version 2,
| regardless of the license terms of these independent modules, and to copy
| and distribute the resulting combined work under terms of your choice,
| provided that every copy of the combined work is accompanied by a complete
| copy of the source code of RXTX (the version of RXTX used to produce the
| combined work), being distributed under the terms of the GNU Lesser General
| Public License plus this exception. An independent module is a
| module which is not derived from or based on RXTX.
|
| Note that people who make modified versions of RXTX are not obligated
| to grant this special exception for their modified versions; it is
| their choice whether to do so. The GNU Lesser General Public License
| gives permission to release a modified version without this exception; this
| exception also makes it possible to release a modified version which
| carries forward this exception.
|
| You should have received a copy of the GNU Lesser General Public
| License along with this library; if not, write to the Free
| Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
| All trademarks belong to their respective owners.
--------------------------------------------------------------------------*/
package gnu.io;
import java.io.*;
import java.util.*;
import java.lang.Math;
/**
* @author Trent Jarvi
* @version %I%, %G%
* @since JDK1.0
*/
final class RS485 extends RS485Port {
static
{
//System.loadLibrary( "rxtxRS485" );
Initialize();
}
/** Initialize the native library */
private native static void Initialize();
/** Actual RS485Port wrapper class */
/** Open the named port */
public RS485( String name ) throws PortInUseException {
fd = open( name );
}
private native int open( String name ) throws PortInUseException;
/** File descriptor */
private int fd;
/** DSR flag **/
static boolean dsrFlag = false;
/** Output stream */
private final RS485OutputStream out = new RS485OutputStream();
public OutputStream getOutputStream() { return out; }
/** Input stream */
private final RS485InputStream in = new RS485InputStream();
public InputStream getInputStream() { return in; }
/** Set the RS485Port parameters */
public void setRS485PortParams( int b, int d, int s, int p )
throws UnsupportedCommOperationException
{
nativeSetRS485PortParams( b, d, s, p );
speed = b;
dataBits = d;
stopBits = s;
parity = p;
}
/** Set the native RS485 port parameters */
private native void nativeSetRS485PortParams( int speed, int dataBits,
int stopBits, int parity ) throws UnsupportedCommOperationException;
/** Line speed in bits-per-second */
private int speed=9600;
public int getBaudRate() { return speed; }
/** Data bits port parameter */
private int dataBits=DATABITS_8;
public int getDataBits() { return dataBits; }
/** Stop bits port parameter */
private int stopBits=RS485Port.STOPBITS_1;
public int getStopBits() { return stopBits; }
/** Parity port parameter */
private int parity= RS485Port.PARITY_NONE;
public int getParity() { return parity; }
/** Flow control */
private int flowmode = RS485Port.FLOWCONTROL_NONE;
public void setFlowControlMode( int flowcontrol ) {
try { setflowcontrol( flowcontrol ); }
catch( IOException e ) {
e.printStackTrace();
return;
}
flowmode=flowcontrol;
}
public int getFlowControlMode() { return flowmode; }
native void setflowcontrol( int flowcontrol ) throws IOException;
/*
linux/drivers/char/n_hdlc.c? FIXME
taj@www.linux.org.uk
*/
/** Receive framing control
*/
public void enableReceiveFraming( int f )
throws UnsupportedCommOperationException
{
throw new UnsupportedCommOperationException( "Not supported" );
}
public void disableReceiveFraming() {}
public boolean isReceiveFramingEnabled() { return false; }
public int getReceiveFramingByte() { return 0; }
/** Receive timeout control */
private int timeout = 0;
public native int NativegetReceiveTimeout();
public native boolean NativeisReceiveTimeoutEnabled();
public native void NativeEnableReceiveTimeoutThreshold(int time, int threshold,int InputBuffer);
public void disableReceiveTimeout(){
enableReceiveTimeout(0);
}
public void enableReceiveTimeout( int time ){
if( time >= 0 ) {
timeout = time;
NativeEnableReceiveTimeoutThreshold( time , threshold, InputBuffer );
}
else {
System.out.println("Invalid timeout");
}
}
public boolean isReceiveTimeoutEnabled(){
return(NativeisReceiveTimeoutEnabled());
}
public int getReceiveTimeout(){
return(NativegetReceiveTimeout( ));
}
/** Receive threshold control */
private int threshold = 0;
public void enableReceiveThreshold( int thresh ){
if(thresh >=0)
{
threshold=thresh;
NativeEnableReceiveTimeoutThreshold(timeout, threshold, InputBuffer);
}
else /* invalid thresh */
{
System.out.println("Invalid Threshold");
}
}
public void disableReceiveThreshold() {
enableReceiveThreshold(0);
}
public int getReceiveThreshold(){
return threshold;
}
public boolean isReceiveThresholdEnabled(){
return(threshold>0);
}
/** Input/output buffers */
/** FIXME I think this refers to
FOPEN(3)/SETBUF(3)/FREAD(3)/FCLOSE(3)
taj@www.linux.org.uk
These are native stubs...
*/
private int InputBuffer=0;
private int OutputBuffer=0;
public void setInputBufferSize( int size )
{
InputBuffer=size;
}
public int getInputBufferSize()
{
return(InputBuffer);
}
public void setOutputBufferSize( int size )
{
OutputBuffer=size;
}
public int getOutputBufferSize()
{
return(OutputBuffer);
}
/** Line status methods */
public native boolean isDTR();
public native void setDTR( boolean state );
public native void setRTS( boolean state );
private native void setDSR( boolean state );
public native boolean isCTS();
public native boolean isDSR();
public native boolean isCD();
public native boolean isRI();
public native boolean isRTS();
/** Write to the port */
public native void sendBreak( int duration );
private native void writeByte( int b ) throws IOException;
private native void writeArray( byte b[], int off, int len )
throws IOException;
private native void drain() throws IOException;
/** RS485 read methods */
private native int nativeavailable() throws IOException;
private native int readByte() throws IOException;
private native int readArray( byte b[], int off, int len )
throws IOException;
/** RS485 Port Event listener */
private RS485PortEventListener SPEventListener;
/** Thread to monitor data */
private MonitorThread monThread;
/** Process RS485PortEvents */
native void eventLoop();
private int dataAvailable=0;
public void sendEvent( int event, boolean state ) {
switch( event ) {
case RS485PortEvent.DATA_AVAILABLE:
dataAvailable=1;
if( monThread.Data ) break;
return;
case RS485PortEvent.OUTPUT_BUFFER_EMPTY:
if( monThread.Output ) break;
return;
/*
if( monThread.DSR ) break;
return;
if (isDSR())
{
if (!dsrFlag)
{
dsrFlag = true;
RS485PortEvent e = new RS485PortEvent(this, RS485PortEvent.DSR, !dsrFlag, dsrFlag );
}
}
else if (dsrFlag)
{
dsrFlag = false;
RS485PortEvent e = new RS485PortEvent(this, RS485PortEvent.DSR, !dsrFlag, dsrFlag );
}
*/
case RS485PortEvent.CTS:
if( monThread.CTS ) break;
return;
case RS485PortEvent.DSR:
if( monThread.DSR ) break;
return;
case RS485PortEvent.RI:
if( monThread.RI ) break;
return;
case RS485PortEvent.CD:
if( monThread.CD ) break;
return;
case RS485PortEvent.OE:
if( monThread.OE ) break;
return;
case RS485PortEvent.PE:
if( monThread.PE ) break;
return;
case RS485PortEvent.FE:
if( monThread.FE ) break;
return;
case RS485PortEvent.BI:
if( monThread.BI ) break;
return;
default:
System.err.println("unknown event:"+event);
return;
}
RS485PortEvent e = new RS485PortEvent(this, event, !state, state );
if( SPEventListener != null ) SPEventListener.RS485Event( e );
}
/** Add an event listener */
public void addEventListener( RS485PortEventListener lsnr )
throws TooManyListenersException
{
if( SPEventListener != null ) throw new TooManyListenersException();
SPEventListener = lsnr;
monThread = new MonitorThread();
monThread.start();
}
/** Remove the RS485 port event listener */
public void removeEventListener() {
SPEventListener = null;
if( monThread != null ) {
monThread.interrupt();
monThread = null;
}
}
public void notifyOnDataAvailable( boolean enable ) { monThread.Data = enable; }
public void notifyOnOutputEmpty( boolean enable ) { monThread.Output = enable; }
public void notifyOnCTS( boolean enable ) { monThread.CTS = enable; }
public void notifyOnDSR( boolean enable ) { monThread.DSR = enable; }
public void notifyOnRingIndicator( boolean enable ) { monThread.RI = enable; }
public void notifyOnCarrierDetect( boolean enable ) { monThread.CD = enable; }
public void notifyOnOverrunError( boolean enable ) { monThread.OE = enable; }
public void notifyOnParityError( boolean enable ) { monThread.PE = enable; }
public void notifyOnFramingError( boolean enable ) { monThread.FE = enable; }
public void notifyOnBreakInterrupt( boolean enable ) { monThread.BI = enable; }
/** Close the port */
private native void nativeClose();
public void close() {
setDTR(false);
setDSR(false);
nativeClose();
super.close();
fd = 0;
}
/** Finalize the port */
protected void finalize() {
if( fd > 0 ) close();
}
/** Inner class for RS485OutputStream */
class RS485OutputStream extends OutputStream {
public void write( int b ) throws IOException {
writeByte( b );
}
public void write( byte b[] ) throws IOException {
writeArray( b, 0, b.length );
}
public void write( byte b[], int off, int len ) throws IOException {
writeArray( b, off, len );
}
public void flush() throws IOException {
drain();
}
}
/** Inner class for RS485InputStream */
class RS485InputStream extends InputStream {
public int read() throws IOException {
dataAvailable=0;
return readByte();
}
public int read( byte b[] ) throws IOException
{
return read ( b, 0, b.length);
}
public int read( byte b[], int off, int len ) throws IOException
{
dataAvailable=0;
int i=0, Minimum=0;
int intArray[] =
{
b.length,
InputBuffer,
len
};
/*
find the lowest nonzero value
timeout and threshold are handled on the native side
see NativeEnableReceiveTimeoutThreshold in
RS485Imp.c
*/
while(intArray[i]==0 && i < intArray.length) i++;
Minimum=intArray[i];
while( i < intArray.length )
{
if(intArray[i] > 0 )
{
Minimum=Math.min(Minimum,intArray[i]);
}
i++;
}
Minimum=Math.min(Minimum,threshold);
if(Minimum == 0) Minimum=1;
int Available=available();
int Ret = readArray( b, off, Minimum);
return Ret;
}
public int available() throws IOException {
return nativeavailable();
}
}
class MonitorThread extends Thread {
/** Note: these have to be separate boolean flags because the
RS485PortEvent constants are NOT bit-flags, they are just
defined as integers from 1 to 10 -DPL */
private boolean CTS=false;
private boolean DSR=false;
private boolean RI=false;
private boolean CD=false;
private boolean OE=false;
private boolean PE=false;
private boolean FE=false;
private boolean BI=false;
private boolean Data=false;
private boolean Output=false;
MonitorThread() { }
public void run() {
eventLoop();
}
}
}
| Java |
/*
* cron4j - A pure Java cron-like scheduler
*
* Copyright (C) 2007-2010 Carlo Pelliccia (www.sauronsoftware.it)
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU Lesser General Public License version
* 2.1, as published by the Free Software Foundation.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU Lesser General Public License 2.1 for more details.
*
* You should have received a copy of the GNU Lesser General Public
* License version 2.1 along with this program.
* If not, see <http://www.gnu.org/licenses/>.
*/
package example;
import it.sauronsoftware.cron4j.Scheduler;
import it.sauronsoftware.cron4j.TaskExecutor;
import java.io.IOException;
import javax.servlet.RequestDispatcher;
import javax.servlet.ServletContext;
import javax.servlet.ServletException;
import javax.servlet.http.HttpServlet;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
/**
* This servlet enables the user to view and control any ongoing task execution.
* The HTML layout is generated calling the /WEB-INF/ongoing.jsp page.
*/
public class ExecutionServlet extends HttpServlet {
private static final long serialVersionUID = 1L;
protected void doGet(HttpServletRequest req, HttpServletResponse resp)
throws ServletException, IOException {
// Retrieves the servlet context.
ServletContext context = getServletContext();
// Retrieves the scheduler.
Scheduler scheduler = (Scheduler) context
.getAttribute(Constants.SCHEDULER);
// Retrieves the executors.
TaskExecutor[] executors = scheduler.getExecutingTasks();
// Registers the executors in the request.
req.setAttribute("executors", executors);
// Action requested?
String action = req.getParameter("action");
if ("pause".equals(action)) {
String id = req.getParameter("id");
TaskExecutor executor = find(executors, id);
if (executor != null && executor.isAlive() && !executor.isStopped()
&& executor.canBePaused() && !executor.isPaused()) {
executor.pause();
}
} else if ("resume".equals(action)) {
String id = req.getParameter("id");
TaskExecutor executor = find(executors, id);
if (executor != null && executor.isAlive() && !executor.isStopped()
&& executor.canBePaused() && executor.isPaused()) {
executor.resume();
}
} else if ("stop".equals(action)) {
String id = req.getParameter("id");
TaskExecutor executor = find(executors, id);
if (executor != null && executor.isAlive()
&& executor.canBeStopped() && !executor.isStopped()) {
executor.stop();
}
}
// Layout.
String page = "/WEB-INF/ongoing.jsp";
RequestDispatcher dispatcher = req.getRequestDispatcher(page);
dispatcher.include(req, resp);
}
private TaskExecutor find(TaskExecutor[] executors, String id) {
if (id == null) {
return null;
}
for (int i = 0; i < executors.length; i++) {
String aux = executors[i].getGuid();
if (aux.equals(id)) {
return executors[i];
}
}
return null;
}
}
| Java |
<?xml version="1.0" encoding="utf-8"?>
<!DOCTYPE TS>
<TS version="2.1" language="da_DK">
<context>
<name>ShowDesktop</name>
<message>
<location filename="../showdesktop.cpp" line="48"/>
<source>Show desktop</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../showdesktop.cpp" line="58"/>
<source>Show Desktop: Global shortcut '%1' cannot be registered</source>
<translation>Vis Skrivebord: Global genvej '%1' kan ikke registreres</translation>
</message>
<message>
<location filename="../showdesktop.cpp" line="63"/>
<source>Show Desktop</source>
<translation>Vis Skrivebord</translation>
</message>
</context>
</TS>
| Java |
package org.reprap.comms;
import java.io.IOException;
import org.reprap.Device;
import org.reprap.ReprapException;
/**
*
*/
public abstract class IncomingMessage {
/**
* The actual content portion of a packet, not the frilly bits
*/
private byte [] payload;
/**
*
*/
IncomingContext incomingContext;
/**
*
*/
public class InvalidPayloadException extends ReprapException {
private static final long serialVersionUID = -5403970405132990115L;
public InvalidPayloadException() {
super();
}
public InvalidPayloadException(String arg) {
super(arg);
}
}
/**
* Receive a message matching context criteria
* @param incomingContext the context in which to receive messages
* @throws IOException
*/
public IncomingMessage(IncomingContext incomingContext) throws IOException {
this.incomingContext = incomingContext;
Communicator comm = incomingContext.getCommunicator();
comm.receiveMessage(this);
}
/**
* Send a given message and return the incoming response. Re-try
* if there is a comms problem.
* @param message
* @throws IOException
*/
public IncomingMessage(Device device, OutgoingMessage message, long timeout) throws IOException {
Communicator comm = device.getCommunicator();
for(int i=0;i<3;i++) { // Allow 3 retries.
//System.out.println("Retry: " + i);
incomingContext = comm.sendMessage(device, message);
try {
comm.receiveMessage(this, timeout);
} catch (IOException e) {
e.printStackTrace();
System.err.println("IO error/timeout, resending");
// Just to prevent any unexpected spinning
try {
Thread.sleep(1);
} catch (InterruptedException e1) {
e1.printStackTrace();
}
continue;
}
return;
}
// If it's not going to respond, try to continue regardless.
System.err.println("Resend limit exceeded. Failing without reported error.");
}
/**
* Implemented by subclasses to allow them to indicate if they
* understand or expect a given packetType. This is used to
* decide if a received packet should be accepted or possibly discarded.
* @param packetType the type of packet to receive
* @return true if the packetType matches what is expected
*/
protected abstract boolean isExpectedPacketType(byte packetType);
/**
* @return payload
*/
public byte[] getPayload() {
return payload;
}
/**
* Called by the framework to provide data to the IncomingMessage.
* This should not normally be called by a user.
* @param payload The completed message to insert into the IncomingMessage
* @return true is the data was accepted, otherwise false.
*/
public boolean receiveData(byte [] payload) {
// We assume the packet was for us, etc. But we need to
// know it contains the correct contents
if (payload == null || payload.length == 0)
return false;
if (isExpectedPacketType(payload[0])) {
this.payload = (byte[])payload.clone();
return true;
} else {
// That's not what we were after, so discard and wait for more
return false;
}
}
}
| Java |
package com.puppycrawl.tools.checkstyle.coding;
public class InputEqualsAvoidNull {
public boolean equals(Object o) {
return false;
}
/**
* methods that should get flagged
* @return
*/
public void flagForEquals() {
Object o = new Object();
String s = "pizza";
o.equals("hot pizza");
o.equals(s = "cold pizza");
o.equals(((s = "cold pizza")));
o.equals("cheese" + "ham" + "sauce");
o.equals(("cheese" + "ham") + "sauce");
o.equals((("cheese" + "ham")) + "sauce");
}
/**
* methods that should get flagged
*/
public void flagForEqualsIgnoreCase() {
String s = "pizza";
s.equalsIgnoreCase("hot pizza");
s.equalsIgnoreCase(s = "cold pizza");
s.equalsIgnoreCase(((s = "cold pizza")));
s.equalsIgnoreCase("cheese" + "ham" + "sauce");
s.equalsIgnoreCase(("cheese" + "ham") + "sauce");
s.equalsIgnoreCase((("cheese" + "ham")) + "sauce");
}
/**
* methods that should get flagged
*/
public void flagForBoth() {
Object o = new Object();
String s = "pizza";
o.equals("hot pizza");
o.equals(s = "cold pizza");
o.equals(((s = "cold pizza")));
o.equals("cheese" + "ham" + "sauce");
o.equals(("cheese" + "ham") + "sauce");
o.equals((("cheese" + "ham")) + "sauce");
s.equalsIgnoreCase("hot pizza");
s.equalsIgnoreCase(s = "cold pizza");
s.equalsIgnoreCase(((s = "cold pizza")));
s.equalsIgnoreCase("cheese" + "ham" + "sauce");
s.equalsIgnoreCase(("cheese" + "ham") + "sauce");
s.equalsIgnoreCase((("cheese" + "ham")) + "sauce");
}
/**
* methods that should not get flagged
*
* @return
*/
public void noFlagForEquals() {
Object o = new Object();
String s = "peperoni";
o.equals(s += "mushrooms");
(s = "thin crust").equals("thick crust");
(s += "garlic").equals("basil");
("Chicago Style" + "NY Style").equals("California Style" + "Any Style");
equals("peppers");
"onions".equals(o);
o.equals(new Object());
o.equals(equals(o));
equals("yummy");
new Object().equals("more cheese");
InputEqualsAvoidNullOutter outter = new InputEqualsAvoidNullOutter();
outter.new InputEqualsAvoidNullInner().equals("eat pizza and enjoy inner classes");
}
/**
* methods that should not get flagged
*/
public void noFlagForEqualsIgnoreCase() {
String s = "peperoni";
String s1 = "tasty";
s.equalsIgnoreCase(s += "mushrooms");
s1.equalsIgnoreCase(s += "mushrooms");
(s = "thin crust").equalsIgnoreCase("thick crust");
(s += "garlic").equalsIgnoreCase("basil");
("Chicago Style" + "NY Style").equalsIgnoreCase("California Style" + "Any Style");
"onions".equalsIgnoreCase(s);
s.equalsIgnoreCase(new String());
s.equals(s1);
new String().equalsIgnoreCase("more cheese");
}
public void noFlagForBoth() {
Object o = new Object();
String s = "peperoni";
String s1 = "tasty";
o.equals(s += "mushrooms");
(s = "thin crust").equals("thick crust");
(s += "garlic").equals("basil");
("Chicago Style" + "NY Style").equals("California Style" + "Any Style");
equals("peppers");
"onions".equals(o);
o.equals(new Object());
o.equals(equals(o));
equals("yummy");
new Object().equals("more cheese");
InputEqualsAvoidNullOutter outter = new InputEqualsAvoidNullOutter();
outter.new InputEqualsAvoidNullInner().equals("eat pizza and enjoy inner classes");
s.equalsIgnoreCase(s += "mushrooms");
s1.equalsIgnoreCase(s += "mushrooms");
(s = "thin crust").equalsIgnoreCase("thick crust");
(s += "garlic").equalsIgnoreCase("basil");
("Chicago Style" + "NY Style").equalsIgnoreCase("California Style" + "Any Style");
"onions".equalsIgnoreCase(s);
s.equalsIgnoreCase(new String());
s.equals(s1);
new String().equalsIgnoreCase("more cheese");
}
}
class InputEqualsAvoidNullOutter {
public class InputEqualsAvoidNullInner {
public boolean equals(Object o) {
return true;
}
}
}
| Java |
ALTER TABLE mailmessages RENAME TO old_mailmessages;
CREATE TABLE mailmessages (
id INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL,
type INTEGER NOT NULL,
parentfolderid INTEGER NOT NULL,
previousparentfolderid INTEGER NOT NULL,
sender VARCHAR,
recipients VARCHAR,
subject VARCHAR,
stamp TIMESTAMP,
status INTEGER,
parentaccountid INTEGER,
frommailbox VARCHAR,
mailfile VARCHAR,
serveruid VARCHAR,
size INTEGER,
contenttype INTEGER,
responseid INTEGER,
responsetype INTEGER,
receivedstamp TIMESTAMP,
copyserveruid VARCHAR NOT NULL DEFAULT '',
restorefolderid INTEGER NOT NULL DEFAULT 0,
listid VARCHAR NOT NULL DEFAULT '',
rfcid VARCHAR NOT NULL DEFAULT '',
FOREIGN KEY (parentfolderid) REFERENCES mailfolders(id),
FOREIGN KEY (parentaccountid) REFERENCES mailaccounts(id));
INSERT INTO mailmessages SELECT * FROM old_mailmessages;
DROP TABLE old_mailmessages;
CREATE INDEX parentfolderid_idx ON mailmessages("parentfolderid");
CREATE INDEX parentaccountid_idx ON mailmessages("parentaccountid");
CREATE INDEX frommailbox_idx ON mailmessages("frommailbox");
CREATE INDEX stamp_idx ON mailmessages("stamp");
| Java |
package models;
import java.util.List;
/**
* The model class to store the sorting information
*
* @author Sandro
*
*/
public class Sort {
private String text;
private String supplier;
private String status;
private String dateCreateStart;
private String dateCreateEnd;
private String dateUpdateStart;
private String dateUpdateEnd;
private String sort;
private List<String> recordsChecked;
public Sort() {
}
/**
* The constructor of the sort class
*
* @param text the search value of the text field
* @param supplier the search value of the supplier field
* @param status the search value of the status field
* @param format the search value of the format field
* @param dateUpdateStart the search value of the date start field
* @param dateUpdateEnd the search value of the date end field
* @param sort the sort type value
* @param recordsChecked the UUID's of the records selected
*/
public Sort(String text, String supplier, String status, String dateCreateStart, String dateCreateEnd,
String dateUpdateStart, String dateUpdateEnd, String sort,
List<String> recordsChecked) {
this.text = text;
this.supplier = supplier;
this.status = status;
this.dateCreateStart = dateCreateStart;
this.dateCreateEnd = dateCreateEnd;
this.dateUpdateStart = dateUpdateStart;
this.dateUpdateEnd = dateUpdateEnd;
this.sort = sort;
this.recordsChecked = recordsChecked;
}
public String getText() {
return text;
}
public void setText(String text) {
this.text = text;
}
public String getSupplier() {
return supplier;
}
public void setSupplier(String supplier) {
this.supplier = supplier;
}
public String getStatus() {
return status;
}
public void setStatus(String status) {
this.status = status;
}
public String getDateCreateStart() {
return dateCreateStart;
}
public void setDateCreateStart(String dateCreateStart) {
this.dateCreateStart = dateCreateStart;
}
public String getDateCreateEnd() {
return dateCreateEnd;
}
public void setDateCreateEnd(String dateCreateEnd) {
this.dateCreateEnd = dateCreateEnd;
}
public String getDateUpdateStart() {
return dateUpdateStart;
}
public void setDateUpdateStart(String dateUpdateStart) {
this.dateUpdateStart = dateUpdateStart;
}
public String getDateUpdateEnd() {
return dateUpdateEnd;
}
public void setDateUpdateEnd(String dateUpdateEnd) {
this.dateUpdateEnd = dateUpdateEnd;
}
public String getSort() {
return sort;
}
public void setSort(String sort) {
this.sort = sort;
}
public List<String> getRecordsChecked() {
return recordsChecked;
}
public void setRecordsChecked(List<String> recordsChecked) {
this.recordsChecked = recordsChecked;
}
}
| Java |
#include "derivations.hh"
#include "store-api.hh"
#include "globals.hh"
#include "util.hh"
#include "worker-protocol.hh"
#include "fs-accessor.hh"
#include "istringstream_nocopy.hh"
namespace nix {
void DerivationOutput::parseHashInfo(bool & recursive, Hash & hash) const
{
recursive = false;
string algo = hashAlgo;
if (string(algo, 0, 2) == "r:") {
recursive = true;
algo = string(algo, 2);
}
HashType hashType = parseHashType(algo);
if (hashType == htUnknown)
throw Error(format("unknown hash algorithm ‘%1%’") % algo);
hash = parseHash(hashType, this->hash);
}
Path BasicDerivation::findOutput(const string & id) const
{
auto i = outputs.find(id);
if (i == outputs.end())
throw Error(format("derivation has no output ‘%1%’") % id);
return i->second.path;
}
bool BasicDerivation::willBuildLocally() const
{
return get(env, "preferLocalBuild") == "1" && canBuildLocally();
}
bool BasicDerivation::substitutesAllowed() const
{
return get(env, "allowSubstitutes", "1") == "1";
}
bool BasicDerivation::isBuiltin() const
{
return string(builder, 0, 8) == "builtin:";
}
bool BasicDerivation::canBuildLocally() const
{
return platform == settings.thisSystem
|| isBuiltin()
#if __linux__
|| (platform == "i686-linux" && settings.thisSystem == "x86_64-linux")
|| (platform == "armv6l-linux" && settings.thisSystem == "armv7l-linux")
|| (platform == "armv5tel-linux" && (settings.thisSystem == "armv7l-linux" || settings.thisSystem == "armv6l-linux"))
#elif __FreeBSD__
|| (platform == "i686-linux" && settings.thisSystem == "x86_64-freebsd")
|| (platform == "i686-linux" && settings.thisSystem == "i686-freebsd")
#endif
;
}
Path writeDerivation(ref<Store> store,
const Derivation & drv, const string & name, bool repair)
{
PathSet references;
references.insert(drv.inputSrcs.begin(), drv.inputSrcs.end());
for (auto & i : drv.inputDrvs)
references.insert(i.first);
/* Note that the outputs of a derivation are *not* references
(that can be missing (of course) and should not necessarily be
held during a garbage collection). */
string suffix = name + drvExtension;
string contents = drv.unparse();
return settings.readOnlyMode
? store->computeStorePathForText(suffix, contents, references)
: store->addTextToStore(suffix, contents, references, repair);
}
/* Read string `s' from stream `str'. */
static void expect(std::istream & str, const string & s)
{
char s2[s.size()];
str.read(s2, s.size());
if (string(s2, s.size()) != s)
throw FormatError(format("expected string ‘%1%’") % s);
}
/* Read a C-style string from stream `str'. */
static string parseString(std::istream & str)
{
string res;
expect(str, "\"");
int c;
while ((c = str.get()) != '"')
if (c == '\\') {
c = str.get();
if (c == 'n') res += '\n';
else if (c == 'r') res += '\r';
else if (c == 't') res += '\t';
else res += c;
}
else res += c;
return res;
}
static Path parsePath(std::istream & str)
{
string s = parseString(str);
if (s.size() == 0 || s[0] != '/')
throw FormatError(format("bad path ‘%1%’ in derivation") % s);
return s;
}
static bool endOfList(std::istream & str)
{
if (str.peek() == ',') {
str.get();
return false;
}
if (str.peek() == ']') {
str.get();
return true;
}
return false;
}
static StringSet parseStrings(std::istream & str, bool arePaths)
{
StringSet res;
while (!endOfList(str))
res.insert(arePaths ? parsePath(str) : parseString(str));
return res;
}
static Derivation parseDerivation(const string & s)
{
Derivation drv;
istringstream_nocopy str(s);
expect(str, "Derive([");
/* Parse the list of outputs. */
while (!endOfList(str)) {
DerivationOutput out;
expect(str, "("); string id = parseString(str);
expect(str, ","); out.path = parsePath(str);
expect(str, ","); out.hashAlgo = parseString(str);
expect(str, ","); out.hash = parseString(str);
expect(str, ")");
drv.outputs[id] = out;
}
/* Parse the list of input derivations. */
expect(str, ",[");
while (!endOfList(str)) {
expect(str, "(");
Path drvPath = parsePath(str);
expect(str, ",[");
drv.inputDrvs[drvPath] = parseStrings(str, false);
expect(str, ")");
}
expect(str, ",["); drv.inputSrcs = parseStrings(str, true);
expect(str, ","); drv.platform = parseString(str);
expect(str, ","); drv.builder = parseString(str);
/* Parse the builder arguments. */
expect(str, ",[");
while (!endOfList(str))
drv.args.push_back(parseString(str));
/* Parse the environment variables. */
expect(str, ",[");
while (!endOfList(str)) {
expect(str, "("); string name = parseString(str);
expect(str, ","); string value = parseString(str);
expect(str, ")");
drv.env[name] = value;
}
expect(str, ")");
return drv;
}
Derivation readDerivation(const Path & drvPath)
{
try {
return parseDerivation(readFile(drvPath));
} catch (FormatError & e) {
throw Error(format("error parsing derivation ‘%1%’: %2%") % drvPath % e.msg());
}
}
Derivation Store::derivationFromPath(const Path & drvPath)
{
assertStorePath(drvPath);
ensurePath(drvPath);
auto accessor = getFSAccessor();
try {
return parseDerivation(accessor->readFile(drvPath));
} catch (FormatError & e) {
throw Error(format("error parsing derivation ‘%1%’: %2%") % drvPath % e.msg());
}
}
static void printString(string & res, const string & s)
{
res += '"';
for (const char * i = s.c_str(); *i; i++)
if (*i == '\"' || *i == '\\') { res += "\\"; res += *i; }
else if (*i == '\n') res += "\\n";
else if (*i == '\r') res += "\\r";
else if (*i == '\t') res += "\\t";
else res += *i;
res += '"';
}
template<class ForwardIterator>
static void printStrings(string & res, ForwardIterator i, ForwardIterator j)
{
res += '[';
bool first = true;
for ( ; i != j; ++i) {
if (first) first = false; else res += ',';
printString(res, *i);
}
res += ']';
}
string Derivation::unparse() const
{
string s;
s.reserve(65536);
s += "Derive([";
bool first = true;
for (auto & i : outputs) {
if (first) first = false; else s += ',';
s += '('; printString(s, i.first);
s += ','; printString(s, i.second.path);
s += ','; printString(s, i.second.hashAlgo);
s += ','; printString(s, i.second.hash);
s += ')';
}
s += "],[";
first = true;
for (auto & i : inputDrvs) {
if (first) first = false; else s += ',';
s += '('; printString(s, i.first);
s += ','; printStrings(s, i.second.begin(), i.second.end());
s += ')';
}
s += "],";
printStrings(s, inputSrcs.begin(), inputSrcs.end());
s += ','; printString(s, platform);
s += ','; printString(s, builder);
s += ','; printStrings(s, args.begin(), args.end());
s += ",[";
first = true;
for (auto & i : env) {
if (first) first = false; else s += ',';
s += '('; printString(s, i.first);
s += ','; printString(s, i.second);
s += ')';
}
s += "])";
return s;
}
bool isDerivation(const string & fileName)
{
return hasSuffix(fileName, drvExtension);
}
bool BasicDerivation::isFixedOutput() const
{
return outputs.size() == 1 &&
outputs.begin()->first == "out" &&
outputs.begin()->second.hash != "";
}
DrvHashes drvHashes;
/* Returns the hash of a derivation modulo fixed-output
subderivations. A fixed-output derivation is a derivation with one
output (`out') for which an expected hash and hash algorithm are
specified (using the `outputHash' and `outputHashAlgo'
attributes). We don't want changes to such derivations to
propagate upwards through the dependency graph, changing output
paths everywhere.
For instance, if we change the url in a call to the `fetchurl'
function, we do not want to rebuild everything depending on it
(after all, (the hash of) the file being downloaded is unchanged).
So the *output paths* should not change. On the other hand, the
*derivation paths* should change to reflect the new dependency
graph.
That's what this function does: it returns a hash which is just the
hash of the derivation ATerm, except that any input derivation
paths have been replaced by the result of a recursive call to this
function, and that for fixed-output derivations we return a hash of
its output path. */
Hash hashDerivationModulo(Store & store, Derivation drv)
{
/* Return a fixed hash for fixed-output derivations. */
if (drv.isFixedOutput()) {
DerivationOutputs::const_iterator i = drv.outputs.begin();
return hashString(htSHA256, "fixed:out:"
+ i->second.hashAlgo + ":"
+ i->second.hash + ":"
+ i->second.path);
}
/* For other derivations, replace the inputs paths with recursive
calls to this function.*/
DerivationInputs inputs2;
for (auto & i : drv.inputDrvs) {
Hash h = drvHashes[i.first];
if (!h) {
assert(store.isValidPath(i.first));
Derivation drv2 = readDerivation(i.first);
h = hashDerivationModulo(store, drv2);
drvHashes[i.first] = h;
}
inputs2[printHash(h)] = i.second;
}
drv.inputDrvs = inputs2;
return hashString(htSHA256, drv.unparse());
}
DrvPathWithOutputs parseDrvPathWithOutputs(const string & s)
{
size_t n = s.find("!");
return n == s.npos
? DrvPathWithOutputs(s, std::set<string>())
: DrvPathWithOutputs(string(s, 0, n), tokenizeString<std::set<string> >(string(s, n + 1), ","));
}
Path makeDrvPathWithOutputs(const Path & drvPath, const std::set<string> & outputs)
{
return outputs.empty()
? drvPath
: drvPath + "!" + concatStringsSep(",", outputs);
}
bool wantOutput(const string & output, const std::set<string> & wanted)
{
return wanted.empty() || wanted.find(output) != wanted.end();
}
PathSet BasicDerivation::outputPaths() const
{
PathSet paths;
for (auto & i : outputs)
paths.insert(i.second.path);
return paths;
}
Source & readDerivation(Source & in, Store & store, BasicDerivation & drv)
{
drv.outputs.clear();
auto nr = readNum<size_t>(in);
for (size_t n = 0; n < nr; n++) {
auto name = readString(in);
DerivationOutput o;
in >> o.path >> o.hashAlgo >> o.hash;
store.assertStorePath(o.path);
drv.outputs[name] = o;
}
drv.inputSrcs = readStorePaths<PathSet>(store, in);
in >> drv.platform >> drv.builder;
drv.args = readStrings<Strings>(in);
nr = readNum<size_t>(in);
for (size_t n = 0; n < nr; n++) {
auto key = readString(in);
auto value = readString(in);
drv.env[key] = value;
}
return in;
}
Sink & operator << (Sink & out, const BasicDerivation & drv)
{
out << drv.outputs.size();
for (auto & i : drv.outputs)
out << i.first << i.second.path << i.second.hashAlgo << i.second.hash;
out << drv.inputSrcs << drv.platform << drv.builder << drv.args;
out << drv.env.size();
for (auto & i : drv.env)
out << i.first << i.second;
return out;
}
std::string hashPlaceholder(const std::string & outputName)
{
// FIXME: memoize?
return "/" + printHash32(hashString(htSHA256, "nix-output:" + outputName));
}
}
| Java |
/****************************************************************************
**
** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies).
** All rights reserved.
** Contact: Nokia Corporation (qt-info@nokia.com)
**
** This file is part of the QtGui module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial Usage
** Licensees holding valid Qt Commercial licenses may use this file in
** accordance with the Qt Commercial License Agreement provided with the
** Software or, alternatively, in accordance with the terms contained in
** a written agreement between you and Nokia.
**
** GNU Lesser General Public License Usage
** Alternatively, this file may be used under the terms of the GNU Lesser
** General Public License version 2.1 as published by the Free Software
** Foundation and appearing in the file LICENSE.LGPL included in the
** packaging of this file. Please review the following information to
** ensure the GNU Lesser General Public License version 2.1 requirements
** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
**
** In addition, as a special exception, Nokia gives you certain additional
** rights. These rights are described in the Nokia Qt LGPL Exception
** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
**
** GNU General Public License Usage
** Alternatively, this file may be used under the terms of the GNU
** General Public License version 3.0 as published by the Free Software
** Foundation and appearing in the file LICENSE.GPL included in the
** packaging of this file. Please review the following information to
** ensure the GNU General Public License version 3.0 requirements will be
** met: http://www.gnu.org/copyleft/gpl.html.
**
** If you have questions regarding the use of this file, please contact
** Nokia at qt-info@nokia.com.
** $QT_END_LICENSE$
**
****************************************************************************/
#include "qwindowsmobilestyle.h"
#include "qwindowsmobilestyle_p.h"
#if !defined(QT_NO_STYLE_WINDOWSMOBILE) || defined(QT_PLUGIN)
#include "qpainterpath.h"
#include "qapplication.h"
#include "qdesktopwidget.h"
#include "qwidget.h"
#include "qdockwidget.h"
#include "qframe.h"
#include "qmenu.h"
#include "qpaintengine.h"
#include "qpainter.h"
#include "qgroupbox.h"
#include "qstyleoption.h"
#include "qlistview.h"
#include "qdrawutil.h"
#include "qtoolbar.h"
#include "qabstractscrollarea.h"
#include "qabstractbutton.h"
#include "qcombobox.h"
#include "qabstractscrollarea.h"
#include "qframe.h"
#include "qscrollbar.h"
#include "qabstractitemview.h"
#include "qmenubar.h"
#include "qtoolbutton.h"
#include "qtextedit.h"
#include "qdialog.h"
#include "qdebug.h"
#include "qtabwidget.h"
#ifdef Q_WS_WINCE
#include "qt_windows.h"
#include "qguifunctions_wince.h"
extern bool qt_wince_is_high_dpi(); //defined in qguifunctions_wince.cpp
extern bool qt_wince_is_smartphone(); //defined in qguifunctions_wince.cpp
extern bool qt_wince_is_windows_mobile_65(); //defined in qguifunctions_wince.cpp
#endif // Q_WS_WINCE
#include "qstylehelper_p.h"
QT_BEGIN_NAMESPACE
static const int windowsItemFrame = 1; // menu item frame width
static const int windowsMobileitemViewCheckBoxSize = 13;
static const int windowsMobileFrameGroupBoxOffset = 9;
static const int windowsMobileIndicatorSize = 14;
static const int windowsMobileExclusiveIndicatorSize = 14;
static const int windowsMobileSliderThickness = 6;
static const int windowsMobileIconSize = 16;
static const int PE_IndicatorArrowUpBig = 0xf000101;
static const int PE_IndicatorArrowDownBig = 0xf000102;
static const int PE_IndicatorArrowLeftBig = 0xf000103;
static const int PE_IndicatorArrowRightBig = 0xf000104;
/* XPM */
static const char *const radiobutton_xpm[] = {
"30 30 2 1",
" c None",
". c #000000",
" ........ ",
" .............. ",
" .... .... ",
" .... .... ",
" ... ... ",
" ... ... ",
" .. .. ",
" .. .. ",
" ... ... ",
" .. .. ",
" .. .. ",
".. ..",
".. ..",
".. ..",
".. ..",
".. ..",
".. ..",
".. ..",
".. ..",
" .. .. ",
" .. .. ",
" ... ... ",
" .. .. ",
" .. .. ",
" ... ... ",
" ... ... ",
" .... .... ",
" .... .... ",
" .............. ",
" ........ "};
/* XPM */
static const char * const radiobutton_low_xpm[] = {
"15 15 2 1",
" c None",
". c #000000",
" ..... ",
" .. .. ",
" . . ",
" . . ",
" . . ",
". .",
". .",
". .",
". .",
". .",
" . . ",
" . . ",
" . . ",
" .. .. ",
" ..... "};
/* XPM */
static const char * const arrowleft_big_xpm[] = {
"9 17 2 1",
" c None",
". c #000000",
" .",
" ..",
" ...",
" ....",
" .....",
" ......",
" .......",
" ........",
".........",
" ........",
" .......",
" ......",
" .....",
" ....",
" ...",
" ..",
" ."};
/* XPM */
static const char * const arrowleft_xpm[] = {
"8 15 2 1",
" c None",
". c #000000",
" .",
" ..",
" ...",
" ....",
" .....",
" ......",
" .......",
"........",
" .......",
" ......",
" .....",
" ....",
" ...",
" ..",
" ."};
/* XPM */
static const char *const horlines_xpm[] = {
"2 2 2 1",
" c None",
". c #000000",
" ",
".."};
/* XPM */
static const char *const vertlines_xpm[] = {
"2 2 2 1",
" c None",
". c #000000",
". ",
". "};
/* XPM */
static const char *const radiochecked_xpm[] = {
"18 18 2 1",
" c None",
". c #000000",
" ...... ",
" .......... ",
" .............. ",
" .............. ",
" ................ ",
" ................ ",
"..................",
"..................",
"..................",
"..................",
"..................",
"..................",
" ................ ",
" ................ ",
" .............. ",
" .............. ",
" .......... ",
" ...... "};
/* XPM */
static const char * const radiochecked_low_xpm[] = {
"9 9 2 1",
" c None",
". c #000000",
" ... ",
" ....... ",
" ....... ",
".........",
".........",
".........",
" ....... ",
" ....... ",
" ... "};
static const char *const arrowdown_xpm[] = {
"15 8 2 1",
" c None",
". c #000000",
"...............",
" ............. ",
" ........... ",
" ......... ",
" ....... ",
" ..... ",
" ... ",
" . "};
static const char *const arrowdown_big_xpm[] = {
"17 9 2 1",
" c None",
". c #000000",
".................",
" ............... ",
" ............. ",
" ........... ",
" ......... ",
" ....... ",
" ..... ",
" ... ",
" . "};
/* XPM */
static const char *const checkedlight_xpm[] = {
"24 24 2 1",
" c None",
". c #000000",
" ",
" ",
" ",
" ",
" ",
" . ",
" .. ",
" ... ",
" .... ",
" ..... ",
" ...... ",
" . ...... ",
" .. ...... ",
" ... ...... ",
" .... ...... ",
" .......... ",
" ......... ",
" ....... ",
" ..... ",
" ... ",
" . ",
" ",
" ",
" "};
/* XPM */
static const char *const checkedbold_xpm[] = {
"26 26 2 1",
" c None",
". c #000000",
" ",
" ",
" ",
" ",
" ",
" ",
" .. ",
" ... ",
" .... ",
" ..... ",
" .. ...... ",
" ... ....... ",
" .... ....... ",
" ..... ....... ",
" ...... ....... ",
" .............. ",
" ............ ",
" .......... ",
" ........ ",
" ...... ",
" .... ",
" .. ",
" ",
" ",
" ",
" "};
/* XPM */
static const char * const checkedbold_low_xpm[] = {
"9 8 2 1",
" c None",
". c #000000",
" .",
" ..",
". ...",
".. ... ",
"... ... ",
" ..... ",
" ... ",
" . "};
/* XPM */
static const char * const checkedlight_low_xpm[] = {
"8 8 2 1",
" c None",
". c #000000",
" .",
" ..",
" ...",
". ... ",
".. ... ",
"..... ",
" ... ",
" . "};
/* XPM */
static const char * const highlightedradiobutton_xpm[] = {
"30 30 3 1",
" c None",
". c #000000",
"+ c #0078CC",
" ........ ",
" .............. ",
" ....++++++++.... ",
" ....++++++++++++.... ",
" ...++++ ++++... ",
" ...+++ +++... ",
" ..++ ++.. ",
" ..++ ++.. ",
" ...++ ++... ",
" ..++ ++.. ",
" ..++ ++.. ",
"..++ ++..",
"..++ ++..",
"..++ ++..",
"..++ ++..",
"..++ ++..",
"..++ ++..",
"..++ ++..",
"..++ ++..",
" ..++ ++.. ",
" ..++ ++.. ",
" ...++ ++... ",
" ..++ ++.. ",
" ..++ ++.. ",
" ...+++ +++... ",
" ...++++ ++++... ",
" ....++++++++++++.... ",
" ....++++++++.... ",
" .............. ",
" ........ "};
/* XPM */
static const char * const highlightedradiobutton_low_xpm[] = {
"15 15 3 1",
" c None",
". c #000000",
"+ c #3192D6",
" ..... ",
" ..+++++.. ",
" .++ ++. ",
" .+ +. ",
" .+ +. ",
".+ +.",
".+ +.",
".+ +.",
".+ +.",
".+ +.",
" .+ +. ",
" .+ +. ",
" .++ ++. ",
" ..+++++.. ",
" ..... "};
/* XPM */
static const char * const cross_big_xpm[] = {
"28 28 4 1",
" c #09454A",
". c #218C98",
"+ c #47D8E5",
"@ c #FDFFFC",
" ",
" ",
" ++++++++++++++++++++++++ ",
" ++++++++++++++++++++++++ ",
" ++....................++ ",
" ++....................++ ",
" ++..@@@..........@@@..++ ",
" ++..@@@@........@@@@..++ ",
" ++..@@@@@......@@@@@..++ ",
" ++...@@@@@....@@@@@...++ ",
" ++....@@@@@..@@@@@....++ ",
" ++.....@@@@@@@@@@.....++ ",
" ++......@@@@@@@@......++ ",
" ++.......@@@@@@.......++ ",
" ++.......@@@@@@.......++ ",
" ++......@@@@@@@@......++ ",
" ++.....@@@@@@@@@@.....++ ",
" ++....@@@@@..@@@@@....++ ",
" ++...@@@@@....@@@@@...++ ",
" ++..@@@@@......@@@@@..++ ",
" ++..@@@@........@@@@..++ ",
" ++..@@@..........@@@..++ ",
" ++....................++ ",
" ++....................++ ",
" ++++++++++++++++++++++++ ",
" ++++++++++++++++++++++++ ",
" ",
" "};
/* XPM */
static const char * const cross_small_xpm[] = {
"14 14 4 1",
" c #09454A",
". c #218C98",
"+ c #47D8E5",
"@ c #FCFFFC",
" ",
" ++++++++++++ ",
" +..........+ ",
" +.@@....@@.+ ",
" +.@@@..@@@.+ ",
" +..@@@@@@..+ ",
" +...@@@@...+ ",
" +...@@@@...+ ",
" +..@@@@@@..+ ",
" +.@@@..@@@.+ ",
" +.@@....@@.+ ",
" +..........+ ",
" ++++++++++++ ",
" "};
/* XPM */
static const char * const max_big_xpm[] = {
"28 28 4 1",
" c #09454A",
". c #218C98",
"+ c #47D8E5",
"@ c #FDFFFC",
" ",
" ",
" ++++++++++++++++++++++++ ",
" ++++++++++++++++++++++++ ",
" ++....................++ ",
" ++....................++ ",
" ++....................++ ",
" ++....................++ ",
" ++..@@@@@@@@@@@@@@@@..++ ",
" ++..@@@@@@@@@@@@@@@@..++ ",
" ++..@@@@@@@@@@@@@@@@..++ ",
" ++..@@@@@@@@@@@@@@@@..++ ",
" ++..@@............@@..++ ",
" ++..@@............@@..++ ",
" ++..@@............@@..++ ",
" ++..@@............@@..++ ",
" ++..@@............@@..++ ",
" ++..@@............@@..++ ",
" ++..@@@@@@@@@@@@@@@@..++ ",
" ++..@@@@@@@@@@@@@@@@..++ ",
" ++....................++ ",
" ++....................++ ",
" ++....................++ ",
" ++....................++ ",
" ++++++++++++++++++++++++ ",
" ++++++++++++++++++++++++ ",
" ",
" "};
/* XPM */
static const char * const max_small_xpm[] = {
"14 14 4 1",
" c #09454A",
". c #218C98",
"+ c #47D8E5",
"@ c #FCFFFC",
" ",
" ++++++++++++ ",
" +..........+ ",
" +..........+ ",
" +.@@@@@@@@.+ ",
" +.@@@@@@@@.+ ",
" +.@......@.+ ",
" +.@......@.+ ",
" +.@......@.+ ",
" +.@@@@@@@@.+ ",
" +..........+ ",
" +..........+ ",
" ++++++++++++ ",
" "};
/* XPM */
static const char * const normal_big_xpm[] = {
"28 28 4 1",
" c #09454A",
". c #218C98",
"+ c #47D8E5",
"@ c #FDFFFC",
" ",
" ",
" ++++++++++++++++++++++++ ",
" ++++++++++++++++++++++++ ",
" ++....................++ ",
" ++....................++ ",
" ++..@@@@@@@@@@@@@@@@..++ ",
" ++..@@@@@@@@@@@@@@@@..++ ",
" ++..@@............@@..++ ",
" ++..@@............@@..++ ",
" ++..@@............@@..++ ",
" ++..@@............@@..++ ",
" ++..@@............@@..++ ",
" ++..@@............@@..++ ",
" ++..@@............@@..++ ",
" ++..@@............@@..++ ",
" ++..@@............@@..++ ",
" ++..@@............@@..++ ",
" ++..@@............@@..++ ",
" ++..@@............@@..++ ",
" ++..@@@@@@@@@@@@@@@@..++ ",
" ++..@@@@@@@@@@@@@@@@..++ ",
" ++....................++ ",
" ++....................++ ",
" ++++++++++++++++++++++++ ",
" ++++++++++++++++++++++++ ",
" ",
" "};
/* XPM */
static const char * const normal_small_xpm[] = {
"14 14 4 1",
" c #09454A",
". c #218C98",
"+ c #47D8E5",
"@ c #FCFFFC",
" ",
" ++++++++++++ ",
" +..........+ ",
" +.@@@@@@@@.+ ",
" +.@......@.+ ",
" +.@......@.+ ",
" +.@......@.+ ",
" +.@......@.+ ",
" +.@......@.+ ",
" +.@......@.+ ",
" +.@@@@@@@@.+ ",
" +..........+ ",
" ++++++++++++ ",
" "};
/* XPM */
static const char * const min_big_xpm[] = {
"28 28 4 1",
" c #09454A",
". c #218C98",
"+ c #47D8E5",
"@ c #FDFFFC",
" ",
" ",
" ++++++++++++++++++++++++ ",
" ++++++++++++++++++++++++ ",
" ++....................++ ",
" ++....................++ ",
" ++....................++ ",
" ++....................++ ",
" ++....................++ ",
" ++....................++ ",
" ++....................++ ",
" ++....................++ ",
" ++....................++ ",
" ++....................++ ",
" ++....................++ ",
" ++....................++ ",
" ++....................++ ",
" ++....................++ ",
" ++..@@@@@@@@@@@@@@@@..++ ",
" ++..@@@@@@@@@@@@@@@@..++ ",
" ++....................++ ",
" ++....................++ ",
" ++....................++ ",
" ++....................++ ",
" ++++++++++++++++++++++++ ",
" ++++++++++++++++++++++++ ",
" ",
" "};
/* XPM */
static const char * const min_small_xpm[] = {
"14 14 4 1",
" c #09454A",
". c #218C98",
"+ c #47D8E5",
"@ c #FCFFFC",
" ",
" ++++++++++++ ",
" +..........+ ",
" +..........+ ",
" +..........+ ",
" +..........+ ",
" +..........+ ",
" +..........+ ",
" +..........+ ",
" +.@@@@@@@@.+ ",
" +..........+ ",
" +..........+ ",
" ++++++++++++ ",
" "};
#ifdef Q_WS_WINCE_WM
static char * sbhandleup_xpm[] = {
"26 41 45 1",
" c None",
". c #000000",
"+ c #E7E7E7",
"@ c #D6D7D6",
"# c #949294",
"$ c #737573",
"% c #636563",
"& c #636163",
"* c #5A5D5A",
"= c #5A595A",
"- c #525552",
"; c #525152",
"> c #4A4D4A",
", c #7B797B",
"' c #CECFCE",
") c #CED3CE",
"! c #6B6D6B",
"~ c #6B696B",
"{ c #737173",
"] c #7B7D7B",
"^ c #848684",
"/ c #848284",
"( c #8C8A8C",
"_ c #8C8E8C",
": c #B5B2B5",
"< c #FFFFFF",
"[ c #949694",
"} c #B5B6B5",
"| c #9C9A9C",
"1 c #ADAEAD",
"2 c #9C9E9C",
"3 c #BDBABD",
"4 c #BDBEBD",
"5 c #F7F3F7",
"6 c #C6C3C6",
"7 c #C6C7C6",
"8 c #A5A2A5",
"9 c #CECBCE",
"0 c #FFFBFF",
"a c #ADAAAD",
"b c #A5A6A5",
"c c #D6D3D6",
"d c #B5BAB5",
"e c #DEDFDE",
"f c #DEDBDE",
"..........................",
"+@#$%%&&&**===---;;;;>=,'+",
"+@#$%%&&&**===---;;;;>=$'+",
")$!!~~%%&&&**===---;;;;>;'",
"#{$]],,$${{{!!~~%%%&&&*-;]",
"#{$]],,$${{{!!~~%%%&&&*-;]",
",$^//]],,$${{{!!~~%%%&&*;*",
",,(^^//]],$${!!!!!~~%%%&-*",
",,(^^//]],$${!!!!!~~%%%&-*",
"]]_((^^//]$!%%~!{{!!~~%%-*",
"//#__((^^]{:<<:~!{{{!!~~=*",
"//#__((^^]{:<<:~!{{{!!~~=&",
"//###__(/$:<<<<:~{${{!!~*&",
"^^[[##_^]:<<<<<<}!{$${{!*%",
"^^[[##_^]:<<<<<<}!{$${{!*%",
"((|[[#_/:<<<<<<<<}!$$${{&~",
"((||[#^1<<<<1:<<<<}!$$$$&~",
"((||[#^1<<<<1:<<<<}!$$$$&~",
"__2|#(1<<<<}],}<<<<}{$,$%~",
"##2|_1<<<<}^((]3<<<<}{$,~!",
"##2|_1<<<<}^((]3<<<<}{$,~!",
"##2#1<<<<3^###(/4<<<<}{,~{",
"##2#1<<<<3^###(/4<<<<}{,~!",
"[[2_5<<<4(#|[[#_/6<<<<,,!{",
"[|2_5<<4_[||||[[_/7<<<,]{$",
"[|2_5<<4_[||||[[_/7<<<,]{$",
"||8_5<6#|2222|||[_/9<<,]{$",
"228#06[28888222||[_/'<,/$,",
"228#06[28888222||[_/'<,/$,",
"22a|6[8bbbb88822||[(/c](,]",
"881b8baaabbbb88222|[(^(_,]",
"881b8baaabbbb88222|[(^(_,]",
"88111111aaabbb88822|[###]/",
"bb:::11111aaabbb8822||[[/^",
"bb:::11111aaabbb8822||[[//",
"bb:::::1111aaabbb8822||[/(",
"3a1::::::1111aaabb8822|_^8",
"da1::::::1111aaabb8822|_^8",
"e1aaabbbb888822||[[##__((@",
"+e4:aaabbbb88822||[[[#[b@+",
"+e4:aaabbbb88822||[[[#[bf+"};
static char * sbhandledown_xpm[] = {
"26 40 46 1",
" c None",
". c #E7E7E7",
"+ c #DEDFDE",
"@ c #BDBEBD",
"# c #B5B2B5",
"$ c #ADAAAD",
"% c #A5A6A5",
"& c #A5A2A5",
"* c #9C9E9C",
"= c #9C9A9C",
"- c #949694",
"; c #949294",
"> c #D6D7D6",
", c #DEDBDE",
"' c #D6DBD6",
") c #ADAEAD",
"! c #8C8E8C",
"~ c #8C8A8C",
"{ c #BDBABD",
"] c #848684",
"^ c #B5BAB5",
"/ c #848284",
"( c #848A84",
"_ c #7B7D7B",
": c #7B797B",
"< c #C6C3C6",
"[ c #D6D3D6",
"} c #FFFBFF",
"| c #CECFCE",
"1 c #FFFFFF",
"2 c #737573",
"3 c #F7F3F7",
"4 c #CECBCE",
"5 c #737173",
"6 c #C6C7C6",
"7 c #6B6D6B",
"8 c #B5B6B5",
"9 c #6B696B",
"0 c #636563",
"a c #636163",
"b c #5A5D5A",
"c c #5A595A",
"d c #525552",
"e c #525152",
"f c #4A4D4A",
"g c #C6CBC6",
".+@#$$$%%%%&&&**==---;-%>.",
".+@#$$$%%%%&&&**==---;-%,.",
"')$$$%%%%&&&&**==--;;!!~~>",
"{$)######))))$$$%%&&**=!]&",
"^$)######))))$$$%%&&**=!]&",
"%%#####))))$$$%%%&&**==-/(",
"%%###)))))$$$%%%&&**==--/]",
"%%###)))))$$$%%%&&**==--//",
"&&))))))$$$%%%&&&**=-;;;_/",
"&&)%&%$$$%%%%&&***=-~]~!:_",
"&&)%&%$$$%%%%&&***=-~]~!:_",
"**$=<-&%%%%&&&**==-~/[_~:_",
"**&;}<-*&&&&***==-!/|1:/2:",
"**&;}<-*&&&&***==-!/|1:/2:",
"==&!31<;=****===-!/411:_5:",
"-=*!311@!-====--!/6111:_52",
"-=*!311@!-====--!/6111:_52",
"--*!3111@~;=--;!/<1111::75",
";;*;)1111{];;;~/@111185:95",
";;*;)1111{];;;~/@111185:97",
";;*=!)11118]~~_{1111852:97",
";;*=!)11118]~~_{1111852:97",
"!!*=;~)11118_:81111852:207",
"~~==-;])1111)#1111872222a9",
"~~==-;])1111)#1111872222a9",
"~~=--;!/#111111118722255a0",
"]]--;;!]_#11111187522557b0",
"]]--;;!]_#11111187522557b0",
"//;;;!!~/2#1111#95255779ba",
"//;!!~~]]_5#11#975557799cb",
"//;!!~~]]_5#11#975557799ca",
"__!~~]]//_27009755779900db",
"::~]]//__:2257777799000adb",
"::~]]//__:2257777799000adb",
":2]//__::225557799000aabeb",
";52__::225557799000aaabde_",
";52__::225557799000aaabde_",
"[2779900aaabbcccdddeeeefeg",
".>;200aaabbcccdddeeeefc:|.",
".>;200aaabbcccdddeeeefc2|."};
static char * sbgripdown_xpm[] = {
"26 34 39 1",
" c None",
". c #949294",
"+ c #9C9E9C",
"@ c #9C9A9C",
"# c #949694",
"$ c #8C8E8C",
"% c #8C8A8C",
"& c #848684",
"* c #848284",
"= c #7B7D7B",
"- c #7B797B",
"; c #6B696B",
"> c #636563",
", c #737573",
"' c #636163",
") c #737173",
"! c #5A5D5A",
"~ c #6B6D6B",
"{ c #5A595A",
"] c #B5B6B5",
"^ c #BDBEBD",
"/ c #ADAEAD",
"( c #BDBABD",
"_ c #525552",
": c #313031",
"< c #525152",
"[ c #ADAAAD",
"} c #BDBAB5",
"| c #4A4D4A",
"1 c #4A494A",
"2 c #C6C3C6",
"3 c #C6CBC6",
"4 c #E7E7E7",
"5 c #DEDFDE",
"6 c #E7E3E7",
"7 c #DEE3DE",
"8 c #CECBCE",
"9 c #8C928C",
"0 c #CECFCE",
"..+++@@@###...$$%&&**==-;>",
"$.++@@@@##...$$%%&**==-->>",
"$$+@@@@###..$$%%&&*==--,>>",
"$$@@@@###..$$%%&&**==-,,>'",
"%%@@@###..$$$%&&**==--,,''",
"%%@@###..$$$%&&**==--,,)''",
"%%@###...$$%%&&*==--,,))'!",
"&&###...$$%%&&**==--,)))!!",
"&&##...$$%%&&**==--,,))~!!",
"&&#...$$%%&&**==--,,))~~!{",
"**...$$%%&&**==--,,))~~;!{",
"**..$$%%&&**===--,)))~~;{{",
"**.$$%%&]^&===//,,))~~;;{{",
"==$$%%&&]^*==-((,))~~;;>{_",
"==$%%&&***::--,,::~~;;;>__",
"==%%&&&**=::-,,)::~~;;>>__",
"--%&&&**==--,,)))~~;;>>>__",
"--&&&**==--,,)))~~;;>>>'_<",
",-&&**==]^-,))[[~;;>>>''<<",
",,&**==-]^-)))}};;>>>'''<<",
",,**==--,,::)~~;::>>'''!<<",
"))*==--,,)::~~;;::>'''!!<|",
"))==--,,)))~~;;;>>'''!!!||",
"))=--,,)))~~;;;>>'''!!!{||",
"~~--,,)))~~;;;>>'''!!!{{||",
"~~-,,)))~~;;>>>'''!!!{{{|1",
";;,,)))~~;;>>>'''!!!{{{_1<",
"~;,)))~~;;>>>'''!!!{{{__1'",
"%>~))~~;;>>>'''!!!{{{__|1$",
"2>>~~~;;>>>''!!!{{{{__<113",
"4%'';;;>>>''!!!{{{{__<11%4",
"45-!!'>>>''!!!{{{{_<|11)64",
"447+!{{___<<<||||1111|+444",
"444489~__<<<||||111>$04444"};
static char * sbgripup_xpm[] = {
"26 34 38 1",
" c None",
". c #E7E7E7",
"+ c #D6DBD6",
"@ c #C6C7C6",
"# c #B5B6B5",
"$ c #ADAEAD",
"% c #ADAAAD",
"& c #A5A6A5",
"* c #A5A2A5",
"= c #BDBEBD",
"- c #DEDFDE",
"; c #C6CBC6",
"> c #9C9E9C",
", c #E7E3E7",
"' c #BDBABD",
") c #B5B2B5",
"! c #9C9A9C",
"~ c #DEE3DE",
"{ c #949694",
"] c #D6D7D6",
"^ c #949294",
"/ c #DEDBDE",
"( c #8C8E8C",
"_ c #8C8A8C",
": c #848684",
"< c #D6D3CE",
"[ c #CECBCE",
"} c #D6D3D6",
"| c #848284",
"1 c #313031",
"2 c #7B7D7B",
"3 c #CECFCE",
"4 c #CECBC6",
"5 c #7B797B",
"6 c #737573",
"7 c #737173",
"8 c #6B6D6B",
"9 c #6B696B",
"....+@#$$%%%%&&&***$=-....",
"...;$$$$$%%%&&&&**>>>>@...",
".,'$$)#'#####)))$$$%*!!$~.",
".=$)#'''####))))$$$%%*!{'.",
"]$$''''#####)))$$$%%%&*{^/",
"=$#'''#####)))$$$$%%&&&!^#",
"$$'''#####))))$$$%%%&&*>(!",
"$$''#####))))$$$%%%&&&*>(^",
"$$######))))$$$$%%&&&**>(_",
"%$#####))))$$$$%%%&&***>__",
"%$####))))$$$$%%%&&&**>>__",
"%%###)))))$$$%%%&&&**>>>_:",
"%%##))))<])$$%[[&&***>>!::",
"%%#)))))<]$$%%}<&&**>>!!:|",
"&%)))))$$$11%%&&11*>>>!!:|",
"&&))))$$$$11%&&&11*>>!!{||",
"&&)))$$$$$%%%&&&**>>!!!{|2",
"&&))$$$$$%%%&&&**>>>!!{{|2",
"*&)$$$$$3]%&&&4@*>>!!{{{22",
"**$$$$$%3]%&&&<<>>!!!{{^25",
"**$$$$%%%%11&**>11!!{{^^25",
"**$$$%%%%&11***>11!!{{^^55",
"**$$%%%%&&&***>>!!!{{^^(55",
">>$%%%%&&&***>>>!!{{^^((56",
">>%%%%&&&&***>>!!!{{^^((66",
">>%%%&&&&***>>!!!{{^^((_67",
"!>%%&&&&***>>>!!{{{^^(__67",
"!!%&&&&***>>>!!!{{^^((_:77",
"!!&&&&***>>>!!!{{^^((__:77",
"!!&&&****>>!!!{{^^^(__::78",
"{!&&****>>>!!{{{^^((_::|88",
"{{&****>>>!!!{{^^((__:||88",
"{{****>>>!!!{{^^^(__::|289",
"{{***>>>!!!{{{^^((_::||289"};
static char * sbgripmiddle_xpm[] = {
"26 2 12 1",
" c None",
". c #949294",
"+ c #A5A2A5",
"@ c #9C9E9C",
"# c #9C9A9C",
"$ c #949694",
"% c #8C8E8C",
"& c #8C8A8C",
"* c #848684",
"= c #848284",
"- c #7B7D7B",
"; c #6B696B",
"..++@@@###$$$..%%&&*==--;;",
"..++@@@###$$$..%%&&*==--;;"};
static char * listviewhighmiddle_xpm[] = {
"8 46 197 2",
" c None",
". c #66759E",
"+ c #6C789D",
"@ c #6A789E",
"# c #6B789E",
"$ c #6A779D",
"% c #6C789C",
"& c #6F7D9B",
"* c #6F7D9A",
"= c #9DB6EE",
"- c #9DB6ED",
"; c #9CB6ED",
"> c #A1B6EF",
", c #A2B6F0",
"' c #93AAE9",
") c #95ABEA",
"! c #94ABEA",
"~ c #94A9E8",
"{ c #8BA8EA",
"] c #8BA7EA",
"^ c #8AA7EA",
"/ c #8EAAE8",
"( c #8FAAE8",
"_ c #88A2E7",
": c #8CA3E8",
"< c #8BA3E7",
"[ c #8BA3E8",
"} c #8BA2E7",
"| c #8CA2E7",
"1 c #8DA2E7",
"2 c #87A1E8",
"3 c #87A1E9",
"4 c #86A0E8",
"5 c #86A1E7",
"6 c #87A2E7",
"7 c #859EE9",
"8 c #849DE9",
"9 c #869EE9",
"0 c #869FE9",
"a c #7C9BEA",
"b c #7C9CEA",
"c c #7B9CEA",
"d c #7C9BE9",
"e c #7E9CE9",
"f c #7B9AEA",
"g c #7C99E9",
"h c #7C9AEA",
"i c #7B9AE8",
"j c #7A9AEA",
"k c #7996E1",
"l c #7C96E4",
"m c #7B96E3",
"n c #7B95E3",
"o c #7E95E5",
"p c #7E95E6",
"q c #7292E1",
"r c #7490DF",
"s c #7591E0",
"t c #7590DF",
"u c #7392E1",
"v c #6D8CDE",
"w c #6F8EDD",
"x c #6E8DDD",
"y c #6E8DDE",
"z c #6F8EDE",
"A c #6E8EDE",
"B c #718EDD",
"C c #728EDD",
"D c #6B89E0",
"E c #6C89DF",
"F c #6D89E0",
"G c #6D89DF",
"H c #6C88DF",
"I c #6D88DF",
"J c #6D86DD",
"K c #6086E0",
"L c #6686E0",
"M c #6586E0",
"N c #6486E0",
"O c #6485E0",
"P c #6786DF",
"Q c #5F85E0",
"R c #6583DE",
"S c #6683DE",
"T c #6682DD",
"U c #6086DF",
"V c #5F86E0",
"W c #567ED7",
"X c #567ED8",
"Y c #557DD7",
"Z c #5A7FD8",
"` c #6281DA",
" . c #5379D9",
".. c #5278D9",
"+. c #547BD8",
"@. c #4C73D7",
"#. c #4B72D2",
"$. c #4C73D4",
"%. c #4C73D3",
"&. c #4B72D4",
"*. c #4F75D3",
"=. c #5074D2",
"-. c #4971D0",
";. c #4871D0",
">. c #335ECF",
",. c #325ECB",
"'. c #335ECD",
"). c #335ECE",
"!. c #325DCD",
"~. c #2E59C9",
"{. c #3059C9",
"]. c #2F59C9",
"^. c #2F59C8",
"/. c #2B59CA",
"(. c #3355C6",
"_. c #3354C5",
":. c #3156C7",
"<. c #3056C7",
"[. c #3355C7",
"}. c #3355C5",
"|. c #254EBF",
"1. c #1F51C1",
"2. c #234FC0",
"3. c #234FBF",
"4. c #2350C0",
"5. c #1E50BE",
"6. c #1D50C0",
"7. c #264DBE",
"8. c #264CBD",
"9. c #254DBE",
"0. c #244EBF",
"a. c #254DBF",
"b. c #234CBF",
"c. c #244CC0",
"d. c #244BC0",
"e. c #234BC0",
"f. c #234BBF",
"g. c #234CBE",
"h. c #2049B7",
"i. c #2A49B5",
"j. c #2749B5",
"k. c #2749B6",
"l. c #2D49B4",
"m. c #2649B6",
"n. c #2946B5",
"o. c #2A48B6",
"p. c #2947B5",
"q. c #2946B6",
"r. c #2848B6",
"s. c #2549B5",
"t. c #2648B6",
"u. c #2744B5",
"v. c #2744B4",
"w. c #2744AF",
"x. c #2543B4",
"y. c #2543B2",
"z. c #2442B2",
"A. c #2442B3",
"B. c #2442B5",
"C. c #2543B3",
"D. c #1F40B1",
"E. c #1E40B1",
"F. c #243EAE",
"G. c #273BAC",
"H. c #263DAC",
"I. c #253CAB",
"J. c #273CAB",
"K. c #273CAC",
"L. c #263BAA",
"M. c #253CAE",
"N. c #263BA6",
"O. c #253BA5",
"P. c #253AA5",
"Q. c #253BA6",
"R. c #253CA7",
"S. c #263AA6",
"T. c #243CA6",
"U. c #253CA5",
"V. c #273BA8",
"W. c #2F4DA4",
"X. c #2F4DA3",
"Y. c #1B2F85",
"Z. c #B5B5B6",
"`. c #B5B5B5",
" + c #B5B6B6",
".+ c #B5B4B6",
"++ c #C2C3C5",
"@+ c #C0C3C3",
"#+ c #C1C3C4",
"$+ c #E3E3E3",
"%+ c #E3E3E4",
"&+ c #E4E3E4",
"*+ c #E2E3E4",
"=+ c #ECEEEB",
"-+ c #EBEDEA",
";+ c #EEF0ED",
">+ c #EFF0EE",
". + @ @ # # $ % ",
"& & * & & & & & ",
"= = - = = ; > , ",
"' ) ! ! ! ) ' ~ ",
"{ ] { { { ^ / ( ",
"_ : < [ : } | 1 ",
"2 2 2 3 2 4 5 6 ",
"7 7 7 7 7 8 9 0 ",
"a b a a a c d e ",
"f g h h h h i j ",
"k l m m m n o p ",
"q q q q q q q q ",
"r r s s s t q u ",
"v w x y z A B C ",
"D E F F G F H I ",
"J K L M N O P Q ",
"R R S S S T U V ",
"W W X X X Y Z ` ",
" . . . . ...+.W ",
" . . . . ..... .",
"@.#.$.$.%.&.*.=.",
"-.-.;.-.-.-.-.-.",
">.,.'.).).!.!.>.",
"~.{.].^.].^././.",
"(.(.(.(.(._.:.<.",
"(.(.[.[.[.[.(.}.",
"|.1.2.3.3.4.5.6.",
"7.7.7.7.7.8.9.0.",
"a.b.c.d.c.e.f.g.",
"h.i.j.k.j.k.l.m.",
"n.o.p.q.r.p.s.t.",
"u.u.v.u.u.u.u.u.",
"w.x.y.z.A.y.B.C.",
"D.D.E.D.D.D.D.D.",
"D.D.E.D.D.D.D.D.",
"F.G.H.I.J.K.L.M.",
"N.N.O.N.N.P.Q.R.",
"N.N.S.N.N.N.N.N.",
"T.N.T.T.T.U.N.V.",
"W.W.X.W.W.W.W.W.",
"W.W.W.W.W.W.W.W.",
"Y.Y.Y.Y.Y.Y.Y.Y.",
"Z.`. + +.+Z.`.`.",
"++@+#+#+#+#+@+@+",
"$+%+&+&+*+%+%+%+",
"=+-+;+-+-+>+-+-+"};
static char * listviewhighcornerleft_xpm[] = {
"100 46 1475 2",
" c None",
". c #FBFBFC",
"+ c #E8EAE7",
"@ c #758DC3",
"# c #42599E",
"$ c #28418A",
"% c #19418F",
"& c #3F5695",
"* c #415896",
"= c #435A98",
"- c #445C99",
"; c #465E9B",
"> c #48609B",
", c #49629C",
"' c #4A639D",
") c #49639D",
"! c #4A629D",
"~ c #4B639D",
"{ c #4B649D",
"] c #4C659D",
"^ c #4D669D",
"/ c #4E689D",
"( c #506A9D",
"_ c #516A9D",
": c #536B9C",
"< c #546C9C",
"[ c #566D9B",
"} c #576D9B",
"| c #586E9C",
"1 c #5B6F9D",
"2 c #61739D",
"3 c #63749E",
"4 c #64749E",
"5 c #68769E",
"6 c #6A779E",
"7 c #6B789E",
"8 c #66759E",
"9 c #6C789D",
"0 c #EEF0ED",
"a c #D0D3DC",
"b c #3E51A3",
"c c #28428B",
"d c #29428C",
"e c #425996",
"f c #455C99",
"g c #485F9C",
"h c #49619E",
"i c #4A63A0",
"j c #4B64A1",
"k c #4B65A1",
"l c #4C66A2",
"m c #4D67A2",
"n c #4F69A1",
"o c #516AA1",
"p c #536CA0",
"q c #556DA1",
"r c #576EA0",
"s c #586F9F",
"t c #586E9F",
"u c #596F9E",
"v c #5A6F9E",
"w c #5C709E",
"x c #5E719E",
"y c #5F729F",
"z c #62739F",
"A c #63739E",
"B c #64749D",
"C c #65749E",
"D c #69769D",
"E c #6C799E",
"F c #6D799F",
"G c #707D9F",
"H c #717F9E",
"I c #6E7AA1",
"J c #6C789E",
"K c #6F7C9C",
"L c #6F7D9B",
"M c #2A4AA0",
"N c #4971D0",
"O c #4C72D8",
"P c #5472C0",
"Q c #5573BF",
"R c #5774BF",
"S c #5875BF",
"T c #5976C1",
"U c #5A76C1",
"V c #5C78C2",
"W c #5E7AC2",
"X c #607CC3",
"Y c #627EC3",
"Z c #637FC4",
"` c #6581C5",
" . c #6682C6",
".. c #6783C7",
"+. c #6984C8",
"@. c #6B85C9",
"#. c #6D87CA",
"$. c #6F89CB",
"%. c #718CCD",
"&. c #748ECF",
"*. c #7690D0",
"=. c #7992D2",
"-. c #7A93D3",
";. c #7C95D5",
">. c #7F98D7",
",. c #8099D8",
"'. c #859CDB",
"). c #8AA0DD",
"!. c #8DA3DF",
"~. c #8FA5E0",
"{. c #90A5E0",
"]. c #91A6E1",
"^. c #91A5E1",
"/. c #90A4E0",
"(. c #8EA3DE",
"_. c #92A6E2",
":. c #8FA4DF",
"<. c #90A5DE",
"[. c #90A5DC",
"}. c #90A6DB",
"|. c #91A6E0",
"1. c #93A7E2",
"2. c #95AAE6",
"3. c #99AEEA",
"4. c #9AB2EA",
"5. c #99B1E9",
"6. c #99B1E7",
"7. c #98AFE6",
"8. c #93A8E2",
"9. c #97ACE7",
"0. c #9AB3EB",
"a. c #9DB5ED",
"b. c #9DB6EE",
"c. c #375095",
"d. c #4056AD",
"e. c #506DCD",
"f. c #4360CC",
"g. c #345ED6",
"h. c #335ECF",
"i. c #355ED6",
"j. c #355FD6",
"k. c #365FD6",
"l. c #355FD0",
"m. c #3760D5",
"n. c #3A63D4",
"o. c #3C63D1",
"p. c #3B63CD",
"q. c #3B63C9",
"r. c #3B62C9",
"s. c #3D63C8",
"t. c #4065C5",
"u. c #4567C5",
"v. c #496BC5",
"w. c #4F70C7",
"x. c #5273C8",
"y. c #5475CA",
"z. c #5777CB",
"A. c #5879CD",
"B. c #5A7BCE",
"C. c #5D7DCF",
"D. c #5F7ECF",
"E. c #617FD0",
"F. c #6381D1",
"G. c #6583D2",
"H. c #6785D2",
"I. c #6886D3",
"J. c #6A88D4",
"K. c #6C89D5",
"L. c #6E8BD6",
"M. c #708CD7",
"N. c #718DD8",
"O. c #738EDA",
"P. c #748FDB",
"Q. c #7691DC",
"R. c #7893DD",
"S. c #7994DD",
"T. c #7A96DE",
"U. c #7B97DF",
"V. c #7C98E0",
"W. c #7E9AE2",
"X. c #7F9BE3",
"Y. c #829DE4",
"Z. c #849FE5",
"`. c #87A0E6",
" + c #88A1E7",
".+ c #89A2E6",
"++ c #8CA3E7",
"@+ c #8EA5E9",
"#+ c #8EA6E9",
"$+ c #8FA7E9",
"%+ c #8FA8E8",
"&+ c #8FA9E8",
"*+ c #91A9E8",
"=+ c #90A7E8",
"-+ c #8FA8EA",
";+ c #90AAEA",
">+ c #93ABEA",
",+ c #95ABEA",
"'+ c #93ABE9",
")+ c #94ABEA",
"!+ c #90A9EA",
"~+ c #93AAE9",
"{+ c #273E7E",
"]+ c #345ED5",
"^+ c #3D60CE",
"/+ c #3D60CF",
"(+ c #345ECF",
"_+ c #335ED0",
":+ c #355FD3",
"<+ c #3A60CE",
"[+ c #3A5FCB",
"}+ c #385FC9",
"|+ c #3B60C8",
"1+ c #3C63CB",
"2+ c #3E64CB",
"3+ c #4166CA",
"4+ c #4568C9",
"5+ c #4A6CC7",
"6+ c #4F71C8",
"7+ c #5172CA",
"8+ c #5475CE",
"9+ c #5678D3",
"0+ c #597CD6",
"a+ c #5C7ED7",
"b+ c #5E7FD8",
"c+ c #6181D9",
"d+ c #6383DA",
"e+ c #6585DA",
"f+ c #6786DB",
"g+ c #6988DC",
"h+ c #6B8ADD",
"i+ c #6D8BDE",
"j+ c #6F8DDE",
"k+ c #718EDF",
"l+ c #728FE0",
"m+ c #7390E1",
"n+ c #7390E2",
"o+ c #7491E3",
"p+ c #7592E4",
"q+ c #7693E4",
"r+ c #7794E5",
"s+ c #7894E5",
"t+ c #7995E6",
"u+ c #7B96E6",
"v+ c #7C97E7",
"w+ c #7D9AE8",
"x+ c #7F9CE9",
"y+ c #829DE9",
"z+ c #849EE9",
"A+ c #859EE9",
"B+ c #87A0E7",
"C+ c #8AA2E7",
"D+ c #8BA3E8",
"E+ c #89A2E7",
"F+ c #8CA6EA",
"G+ c #8BA6EA",
"H+ c #8BA7EA",
"I+ c #8CA3E8",
"J+ c #8BA8EA",
"K+ c #8CA7EA",
"L+ c #8CA8EA",
"M+ c #4659C7",
"N+ c #355ECF",
"O+ c #3660CF",
"P+ c #3860CE",
"Q+ c #3961CD",
"R+ c #3B61CB",
"S+ c #3B61CA",
"T+ c #3D62CA",
"U+ c #3D63CA",
"V+ c #4165CB",
"W+ c #456ACB",
"X+ c #4B6FCD",
"Y+ c #5174CE",
"Z+ c #5275D1",
"`+ c #5477D4",
" @ c #5678D9",
".@ c #587ADB",
"+@ c #597BDB",
"@@ c #5B7DDC",
"#@ c #5E7FDC",
"$@ c #6081DD",
"%@ c #6283DE",
"&@ c #6484DF",
"*@ c #6787E0",
"=@ c #6989E1",
"-@ c #6B8BE1",
";@ c #6D8DE2",
">@ c #6F8EE3",
",@ c #718FE4",
"'@ c #7290E4",
")@ c #7491E5",
"!@ c #7692E6",
"~@ c #7793E5",
"{@ c #7894E6",
"]@ c #7895E7",
"^@ c #7996E8",
"/@ c #7A97E8",
"(@ c #7B98E9",
"_@ c #7D99E8",
":@ c #7F9AE8",
"<@ c #7F9BE9",
"[@ c #7F9CEA",
"}@ c #859EE8",
"|@ c #859FE8",
"1@ c #85A0E9",
"2@ c #869FE9",
"3@ c #86A1E7",
"4@ c #86A0E9",
"5@ c #87A1E7",
"6@ c #88A2E7",
"7@ c #87A1E9",
"8@ c #5A6FCA",
"9@ c #365FCF",
"0@ c #345ED0",
"a@ c #385FCC",
"b@ c #385FCE",
"c@ c #3A61CC",
"d@ c #3B62CD",
"e@ c #3E64CD",
"f@ c #4167CF",
"g@ c #4469CF",
"h@ c #486CD1",
"i@ c #4D71D2",
"j@ c #5175D4",
"k@ c #5376D6",
"l@ c #5578DA",
"m@ c #5679DC",
"n@ c #587BDD",
"o@ c #5A7DDE",
"p@ c #5D80DE",
"q@ c #5F82DF",
"r@ c #6284DF",
"s@ c #6585E0",
"t@ c #6787E1",
"u@ c #6988E2",
"v@ c #6B8AE2",
"w@ c #6D8CE3",
"x@ c #6E8DE3",
"y@ c #708EE4",
"z@ c #718FE3",
"A@ c #7391E4",
"B@ c #7592E5",
"C@ c #7895E5",
"D@ c #7996E6",
"E@ c #7A97E6",
"F@ c #7B98E7",
"G@ c #7A98E8",
"H@ c #7B99E9",
"I@ c #7E9AE9",
"J@ c #7D9AE9",
"K@ c #7E9AEA",
"L@ c #809CE9",
"M@ c #819DE8",
"N@ c #7F9BEA",
"O@ c #819DE9",
"P@ c #819CE9",
"Q@ c #839EE9",
"R@ c #839EE8",
"S@ c #839DEA",
"T@ c #859FE9",
"U@ c #87A0E8",
"V@ c #86A0E8",
"W@ c #87A1E8",
"X@ c #3760CF",
"Y@ c #3A61CE",
"Z@ c #3A62CD",
"`@ c #3F66CE",
" # c #4368D0",
".# c #466CD2",
"+# c #496DD5",
"@# c #4E72D6",
"## c #5175D8",
"$# c #5276DA",
"%# c #5578DC",
"&# c #577ADC",
"*# c #597CDD",
"=# c #5B7DDD",
"-# c #5D7FDE",
";# c #5E81DE",
"># c #6183DF",
",# c #6386DF",
"'# c #6687E0",
")# c #6888E0",
"!# c #6A89E1",
"~# c #6C8AE1",
"{# c #6E8CE2",
"]# c #6F8DE2",
"^# c #7390E4",
"/# c #7390E3",
"(# c #7491E4",
"_# c #7693E5",
":# c #7895E6",
"<# c #7896E6",
"[# c #7997E7",
"}# c #7B97E7",
"|# c #7B98E8",
"1# c #7C98E8",
"2# c #7E9BE9",
"3# c #809CEA",
"4# c #819CEA",
"5# c #839DE9",
"6# c #365FD0",
"7# c #3660D0",
"8# c #3961CF",
"9# c #3B63CF",
"0# c #3D64D0",
"a# c #4067D0",
"b# c #4469D2",
"c# c #466BD3",
"d# c #496ED5",
"e# c #4C71D6",
"f# c #4E72D8",
"g# c #5074D9",
"h# c #5376DB",
"i# c #5578DB",
"j# c #587ADC",
"k# c #5B7CDC",
"l# c #5D7EDD",
"m# c #5F80DD",
"n# c #6081DE",
"o# c #6383DE",
"p# c #6686DF",
"q# c #6887E0",
"r# c #6988E0",
"s# c #6B89E1",
"t# c #6C8AE0",
"u# c #6E8CE1",
"v# c #708EE2",
"w# c #718FE2",
"x# c #7290E3",
"y# c #7391E2",
"z# c #7492E1",
"A# c #7592E2",
"B# c #7691E3",
"C# c #7591E3",
"D# c #7692E3",
"E# c #7693E3",
"F# c #7793E4",
"G# c #7893E4",
"H# c #7994E5",
"I# c #7D97E8",
"J# c #7E98E8",
"K# c #7D98E8",
"L# c #7D99E9",
"M# c #7D9BEA",
"N# c #7D9CEA",
"O# c #7E99E8",
"P# c #7D9AEA",
"Q# c #7C9BEA",
"R# c #7C9CEA",
"S# c #355FCF",
"T# c #3860D0",
"U# c #3A62D0",
"V# c #3C64D1",
"W# c #4167D1",
"X# c #4369D3",
"Y# c #466BD4",
"Z# c #486DD5",
"`# c #4A6ED7",
" $ c #4C70D8",
".$ c #5478D9",
"+$ c #577BDA",
"@$ c #597DDB",
"#$ c #5B7EDB",
"$$ c #5D7FDC",
"%$ c #6182DE",
"&$ c #6284DE",
"*$ c #6485DF",
"=$ c #6586DF",
"-$ c #6787DF",
";$ c #6888DF",
">$ c #6A8ADF",
",$ c #6C8BE0",
"'$ c #6D8CE0",
")$ c #6E8DE1",
"!$ c #6F8DE1",
"~$ c #708EE1",
"{$ c #718FE0",
"]$ c #728FE1",
"^$ c #7390E0",
"/$ c #738FE0",
"($ c #7490E1",
"_$ c #7590E1",
":$ c #7591E1",
"<$ c #7592E1",
"[$ c #7692E2",
"}$ c #7794E2",
"|$ c #7894E3",
"1$ c #7996E3",
"2$ c #7A96E5",
"3$ c #7B98E6",
"4$ c #7B9AE8",
"5$ c #7C99E8",
"6$ c #7C96E5",
"7$ c #7D97E7",
"8$ c #7C99E9",
"9$ c #7B9AE9",
"0$ c #7B9AEA",
"a$ c #5B6DCF",
"b$ c #305EC8",
"c$ c #335ECE",
"d$ c #305ECA",
"e$ c #345FCF",
"f$ c #3761D0",
"g$ c #3A62D1",
"h$ c #3C64D2",
"i$ c #4066D3",
"j$ c #466BD5",
"k$ c #486ED6",
"l$ c #4A6ED6",
"m$ c #4D71D8",
"n$ c #4F72D9",
"o$ c #5073D9",
"p$ c #4F72D8",
"q$ c #5074D8",
"r$ c #5276D9",
"s$ c #587ADA",
"t$ c #5B7CDB",
"u$ c #5D7EDC",
"v$ c #5F7FDD",
"w$ c #6081DC",
"x$ c #6182DD",
"y$ c #6283DD",
"z$ c #6484DE",
"A$ c #6585DD",
"B$ c #6787DE",
"C$ c #6988DF",
"D$ c #6A89DE",
"E$ c #6C8ADF",
"F$ c #6D8BDF",
"G$ c #6E8CE0",
"H$ c #6F8DE0",
"I$ c #718EE0",
"J$ c #728FDF",
"K$ c #728FDE",
"L$ c #7290E0",
"M$ c #7190E0",
"N$ c #7291E0",
"O$ c #7191E0",
"P$ c #7392E1",
"Q$ c #7493E1",
"R$ c #7594E1",
"S$ c #7594E2",
"T$ c #7694E2",
"U$ c #7695E2",
"V$ c #7A96E4",
"W$ c #7895E2",
"X$ c #7A96E2",
"Y$ c #7A96E3",
"Z$ c #7B96E3",
"`$ c #7996E1",
" % c #7C96E4",
".% c #305EC9",
"+% c #315ECC",
"@% c #325ECE",
"#% c #3760D0",
"$% c #3962D1",
"%% c #3E66D3",
"&% c #4268D4",
"*% c #446BD5",
"=% c #476CD6",
"-% c #496ED7",
";% c #4B6FD7",
">% c #4C70D7",
",% c #4E71D7",
"'% c #5074D7",
")% c #5276D8",
"!% c #5376D8",
"~% c #5779DA",
"{% c #597ADA",
"]% c #5A7BDB",
"^% c #5B7CDA",
"/% c #5D7EDB",
"(% c #5E7FDB",
"_% c #6182DB",
":% c #6384DC",
"<% c #6586DD",
"[% c #6686DC",
"}% c #6887DD",
"|% c #6988DD",
"1% c #6A8ADE",
"2% c #6B8BDE",
"3% c #6C8CDE",
"4% c #6E8DDF",
"5% c #6E8CDF",
"6% c #6D8DDF",
"7% c #6C8BDF",
"8% c #6F8DDF",
"9% c #718FDF",
"0% c #7290DF",
"a% c #7391E0",
"b% c #7491E0",
"c% c #7292E1",
"d% c #3959C5",
"e% c #345BC5",
"f% c #315EC8",
"g% c #355BC5",
"h% c #325EC8",
"i% c #315ECB",
"j% c #345DCC",
"k% c #335ECD",
"l% c #345ECD",
"m% c #355FCE",
"n% c #3862D0",
"o% c #3E66D2",
"p% c #456BD5",
"q% c #476CD5",
"r% c #4B6ED7",
"s% c #4B6FD6",
"t% c #4B6FD5",
"u% c #4D71D6",
"v% c #5073D7",
"w% c #5174D7",
"x% c #5275D8",
"y% c #5577D8",
"z% c #5678D8",
"A% c #5779D9",
"B% c #587AD8",
"C% c #597CD9",
"D% c #5B7DD9",
"E% c #5D7FDA",
"F% c #5F80DB",
"G% c #6182DC",
"H% c #6484DC",
"I% c #6585DC",
"J% c #6787DD",
"K% c #6988DE",
"L% c #6B8ADE",
"M% c #6B8ADF",
"N% c #6989DE",
"O% c #6B89DE",
"P% c #6E8BDF",
"Q% c #708CDE",
"R% c #708DDF",
"S% c #708FDF",
"T% c #728EDF",
"U% c #6F8EDD",
"V% c #728EDD",
"W% c #7390DF",
"X% c #7490DF",
"Y% c #335DC8",
"Z% c #3759C5",
"`% c #3859C5",
" & c #335EC8",
".& c #325DCA",
"+& c #345CCB",
"@& c #335DCC",
"#& c #345DCD",
"$& c #355FCD",
"%& c #3861D0",
"&& c #3B64D1",
"*& c #3E65D2",
"=& c #4168D3",
"-& c #456AD5",
";& c #4B6ED5",
">& c #4C6FD4",
",& c #4D70D5",
"'& c #4F72D6",
")& c #5173D6",
"!& c #5375D7",
"~& c #5476D8",
"{& c #5577D7",
"]& c #5477D8",
"^& c #5677D8",
"/& c #5879D9",
"(& c #597AD9",
"_& c #5C7DDA",
":& c #6080DC",
"<& c #6080DB",
"[& c #6181DC",
"}& c #6282DC",
"|& c #6383DD",
"1& c #6484DD",
"2& c #6686DE",
"3& c #6685DE",
"4& c #6786DE",
"5& c #6687DE",
"6& c #6887DE",
"7& c #6987DE",
"8& c #6788DF",
"9& c #6785DF",
"0& c #6B89DF",
"a& c #6C89DF",
"b& c #6F8DDD",
"c& c #6D8CDE",
"d& c #445BBB",
"e& c #3759BE",
"f& c #375AC6",
"g& c #355CC8",
"h& c #345CCA",
"i& c #355ECC",
"j& c #365FCD",
"k& c #3761CE",
"l& c #3A63D0",
"m& c #3D65D1",
"n& c #466AD4",
"o& c #476BD4",
"p& c #486CD3",
"q& c #4A6ED4",
"r& c #4B6ED4",
"s& c #4E71D6",
"t& c #4F71D5",
"u& c #5072D6",
"v& c #5274D7",
"w& c #5273D7",
"x& c #5274D6",
"y& c #5476D7",
"z& c #5779D8",
"A& c #587AD9",
"B& c #5A7CDA",
"C& c #5C7DDB",
"D& c #5D7EDA",
"E& c #6081DA",
"F& c #6181DB",
"G& c #6283DC",
"H& c #6483DD",
"I& c #6483DE",
"J& c #6585DE",
"K& c #6786DF",
"L& c #6886DE",
"M& c #6887DF",
"N& c #6987DF",
"O& c #6A88DF",
"P& c #6786E0",
"Q& c #6A86DE",
"R& c #6B89E0",
"S& c #365BC8",
"T& c #365CC8",
"U& c #375DCA",
"V& c #375FCB",
"W& c #3860CD",
"X& c #3C63D0",
"Y& c #4167D2",
"Z& c #4268D2",
"`& c #4368D2",
" * c #4367D2",
".* c #4568D2",
"+* c #466AD2",
"@* c #496CD3",
"#* c #4A6DD3",
"$* c #4A6DD4",
"%* c #4D70D4",
"&* c #4F72D5",
"** c #4C70D4",
"=* c #4E72D5",
"-* c #5173D5",
";* c #5375D6",
">* c #597BDA",
",* c #5B7DDA",
"'* c #5C7EDB",
")* c #5D7FDB",
"!* c #5E80DB",
"~* c #5E81DA",
"{* c #5F81DB",
"]* c #5F82DB",
"^* c #6384DD",
"/* c #6384DE",
"(* c #6585DF",
"_* c #6486E0",
":* c #6583DD",
"<* c #6386E0",
"[* c #6686E0",
"}* c #6B86DD",
"|* c #6D86DD",
"1* c #6086E0",
"2* c #5573CD",
"3* c #3959C3",
"4* c #3959C4",
"5* c #3759C0",
"6* c #375BC7",
"7* c #365CC7",
"8* c #395FCC",
"9* c #3B62CE",
"0* c #3E64D0",
"a* c #4066D1",
"b* c #4166D1",
"c* c #4064CF",
"d* c #4065CF",
"e* c #4266D0",
"f* c #4468D1",
"g* c #4569D1",
"h* c #476BD2",
"i* c #466AD1",
"j* c #476AD2",
"k* c #456AD1",
"l* c #496DD2",
"m* c #4A6FD3",
"n* c #496ED2",
"o* c #4B70D4",
"p* c #4D71D4",
"q* c #4E72D4",
"r* c #5073D4",
"s* c #5174D5",
"t* c #5175D5",
"u* c #5276D6",
"v* c #5377D6",
"w* c #5478D7",
"x* c #5579D7",
"y* c #567AD8",
"z* c #577BD9",
"A* c #597CD8",
"B* c #5A7DD9",
"C* c #5A7ED9",
"D* c #5B7FDA",
"E* c #5C80DA",
"F* c #5D80DA",
"G* c #5E81DB",
"H* c #5D80DB",
"I* c #6082DC",
"J* c #6183DD",
"K* c #6183DE",
"L* c #6082DB",
"M* c #6282DE",
"N* c #6682DE",
"O* c #6583DE",
"P* c #3759BF",
"Q* c #375AC2",
"R* c #375AC1",
"S* c #375AC4",
"T* c #395DCA",
"U* c #3A5ECA",
"V* c #3C60CC",
"W* c #3D61CD",
"X* c #3D61CC",
"Y* c #3C61CD",
"Z* c #3E62CD",
"`* c #3F64CE",
" = c #4266CF",
".= c #4468D0",
"+= c #4267CF",
"@= c #4166CE",
"#= c #4065CE",
"$= c #4166CD",
"%= c #4267CE",
"&= c #456AD0",
"*= c #4368CE",
"== c #4468CF",
"-= c #4569D0",
";= c #486BD1",
">= c #4B6FD3",
",= c #4C70D3",
"'= c #4F73D4",
")= c #5275D5",
"!= c #5477D6",
"~= c #577BD7",
"{= c #587CD8",
"]= c #577CD8",
"^= c #597DD9",
"/= c #5A7DDA",
"(= c #597DDA",
"_= c #587CDA",
":= c #5A7EDA",
"<= c #567BD8",
"[= c #557AD9",
"}= c #567BD9",
"|= c #577CD9",
"1= c #587DD9",
"2= c #587ED9",
"3= c #577ED8",
"4= c #587DD8",
"5= c #587ED8",
"6= c #567ED7",
"7= c #526ABD",
"8= c #3759C1",
"9= c #385BC7",
"0= c #395CC8",
"a= c #3B5DC9",
"b= c #3B5ECA",
"c= c #3A5FCA",
"d= c #3B60CC",
"e= c #3C61CC",
"f= c #3D62CD",
"g= c #3E63CD",
"h= c #3C61CB",
"i= c #3C61CA",
"j= c #3D62CB",
"k= c #3F64CC",
"l= c #4065CD",
"m= c #4669D0",
"n= c #476AD0",
"o= c #496BD1",
"p= c #4A6DD2",
"q= c #4B6ED2",
"r= c #4D71D3",
"s= c #4E73D4",
"t= c #4F74D4",
"u= c #5075D5",
"v= c #5276D5",
"w= c #5377D7",
"x= c #5278D7",
"y= c #5277D6",
"z= c #5378D7",
"A= c #5379D8",
"B= c #5379D9",
"C= c #5278D8",
"D= c #5178D7",
"E= c #3355C0",
"F= c #3556C1",
"G= c #395AC6",
"H= c #385AC7",
"I= c #395BC7",
"J= c #395EC9",
"K= c #395FCA",
"L= c #3B60CA",
"M= c #3B60CB",
"N= c #375DC7",
"O= c #385EC8",
"P= c #395FC9",
"Q= c #3A60CA",
"R= c #3D63CC",
"S= c #4367CF",
"T= c #476BD1",
"U= c #4A6ED2",
"V= c #4B6FD2",
"W= c #4C6FD2",
"X= c #4D70D1",
"Y= c #4E71D2",
"Z= c #4E72D2",
"`= c #4E74D4",
" - c #4E75D5",
".- c #4E75D4",
"+- c #4F75D3",
"@- c #5075D2",
"#- c #5075D3",
"$- c #5177D7",
"%- c #5178D8",
"&- c #4F75D5",
"*- c #5076D5",
"=- c #4F76D6",
"-- c #5279D9",
";- c #3C52B1",
">- c #3656C3",
",- c #3757C5",
"'- c #3758C6",
")- c #3759C6",
"!- c #375BC6",
"~- c #385CC7",
"{- c #385DC8",
"]- c #365CC6",
"^- c #355BC6",
"/- c #355CC6",
"(- c #365DC7",
"_- c #375EC8",
":- c #375CC6",
"<- c #385EC6",
"[- c #3A5FC7",
"}- c #3C60C8",
"|- c #3D61C9",
"1- c #3E62CA",
"2- c #4063CC",
"3- c #4165CE",
"4- c #4268D0",
"5- c #4269D1",
"6- c #436AD2",
"7- c #446AD2",
"8- c #456BD2",
"9- c #496CD1",
"0- c #4C6CD0",
"a- c #4D6CCF",
"b- c #4E6DD0",
"c- c #4F6ECF",
"d- c #4E6FCF",
"e- c #4C70CF",
"f- c #4A71D0",
"g- c #4F6FCF",
"h- c #4B71D0",
"i- c #4A72D1",
"j- c #4B73D4",
"k- c #4F70D0",
"l- c #4C73D3",
"m- c #4C73D6",
"n- c #4B72D2",
"o- c #4B71D1",
"p- c #4C73D7",
"q- c #3354C0",
"r- c #3152BE",
"s- c #3052BE",
"t- c #3051BF",
"u- c #2E4FBF",
"v- c #2E4FBE",
"w- c #2E50BF",
"x- c #2F50BF",
"y- c #3156C4",
"z- c #2F56C5",
"A- c #2E57C5",
"B- c #2F57C5",
"C- c #3057C6",
"D- c #3258C6",
"E- c #3459C7",
"F- c #365AC7",
"G- c #385BC8",
"H- c #3B5DCA",
"I- c #3B5DCB",
"J- c #3C5ECC",
"K- c #3C60CD",
"L- c #3C62CE",
"M- c #3D65D0",
"N- c #3D66D1",
"O- c #4166D2",
"P- c #4667D2",
"Q- c #4A67D1",
"R- c #4C68D0",
"S- c #4C69CF",
"T- c #4D6BCE",
"U- c #4E6DCD",
"V- c #4E6ECE",
"W- c #4E6DCE",
"X- c #4970D0",
"Y- c #4770D0",
"Z- c #4B6BCE",
"`- c #4A6CCE",
" ; c #496DCF",
".; c #476FD0",
"+; c #4870D0",
"@; c #486DCF",
"#; c #242F79",
"$; c #2F41AC",
"%; c #2040B8",
"&; c #2041B8",
"*; c #2243B3",
"=; c #2243B8",
"-; c #2343B8",
";; c #2444B8",
">; c #2445B8",
",; c #2445B6",
"'; c #2445B7",
"); c #2444B9",
"!; c #2949BE",
"~; c #2649BF",
"{; c #234BBF",
"]; c #224CBF",
"^; c #224AC0",
"/; c #244CC0",
"(; c #254DC0",
"_; c #254DC1",
":; c #264DC2",
"<; c #274EC3",
"[; c #274CC3",
"}; c #274DC4",
"|; c #254DC5",
"1; c #214EC5",
"2; c #204FC6",
"3; c #1F50C8",
"4; c #2151C9",
"5; c #2B53C8",
"6; c #3154C7",
"7; c #3255C6",
"8; c #2F57C7",
"9; c #2C58C9",
"0; c #2D59CA",
"a; c #2D58C9",
"b; c #2E5BCC",
"c; c #325ECC",
"d; c #325ECB",
"e; c #1F40B1",
"f; c #1F40B2",
"g; c #1F40B3",
"h; c #2A44BD",
"i; c #2845BE",
"j; c #2745BE",
"k; c #2646BF",
"l; c #2546BE",
"m; c #2347BF",
"n; c #2147BF",
"o; c #2048C0",
"p; c #1D48C0",
"q; c #1C48C0",
"r; c #1B47C0",
"s; c #1C48BF",
"t; c #1E49BE",
"u; c #214ABD",
"v; c #244CBD",
"w; c #264DBE",
"x; c #254EC0",
"y; c #214FC2",
"z; c #1B51C5",
"A; c #1C51C7",
"B; c #2250C8",
"C; c #2A52C8",
"D; c #3254C6",
"E; c #3355C5",
"F; c #3154C8",
"G; c #3355C6",
"H; c #2F57C8",
"I; c #2E58C9",
"J; c #2E59C9",
"K; c #3059C9",
"L; c #2040B6",
"M; c #2743BB",
"N; c #2844BC",
"O; c #2743BD",
"P; c #2844BE",
"Q; c #2844BD",
"R; c #2346BE",
"S; c #2047BF",
"T; c #1E48C0",
"U; c #1D47C0",
"V; c #1D49BF",
"W; c #1F49BF",
"X; c #204ABE",
"Y; c #254DBF",
"Z; c #234EC0",
"`; c #2050C1",
" > c #1C51C3",
".> c #1F51C6",
"+> c #2651C8",
"@> c #2D53C7",
"#> c #3155C6",
"$> c #3155C7",
"%> c #3355C7",
"&> c #3254C7",
"*> c #1E40B1",
"=> c #2141B8",
"-> c #2442B9",
";> c #2744BB",
">> c #2945BB",
",> c #2A45BB",
"'> c #2944BA",
")> c #2745BB",
"!> c #2545BC",
"~> c #2246BD",
"{> c #2047BE",
"]> c #1F47BD",
"^> c #1D48BE",
"/> c #1E49C0",
"(> c #1F4AC0",
"_> c #214BBF",
":> c #244CBE",
"<> c #254DBE",
"[> c #244DBE",
"}> c #224FBF",
"|> c #2051C1",
"1> c #2151C3",
"2> c #2252C5",
"3> c #2151C1",
"4> c #2851C6",
"5> c #2A50C6",
"6> c #2E54C6",
"7> c #1F51C2",
"8> c #1D52C5",
"9> c #2651C9",
"0> c #2950C7",
"a> c #2D40A5",
"b> c #2040B0",
"c> c #1F40B0",
"d> c #223CAE",
"e> c #233CAE",
"f> c #253BAC",
"g> c #253BAD",
"h> c #233CB0",
"i> c #213EB2",
"j> c #1F3FB4",
"k> c #1E40B6",
"l> c #1F3FB7",
"m> c #1E3EB8",
"n> c #1F3FB8",
"o> c #2040B7",
"p> c #2141B6",
"q> c #2140B7",
"r> c #2241B6",
"s> c #2342B5",
"t> c #2442B6",
"u> c #2543B5",
"v> c #2643B4",
"w> c #2544B6",
"x> c #2346B8",
"y> c #2247B9",
"z> c #2048BC",
"A> c #1F48BF",
"B> c #2049C0",
"C> c #214AC0",
"D> c #224BBF",
"E> c #234CBE",
"F> c #244DBF",
"G> c #234CBF",
"H> c #264DC0",
"I> c #274EBF",
"J> c #264DBF",
"K> c #254EBF",
"L> c #2050C0",
"M> c #1F51C1",
"N> c #1E42A4",
"O> c #263BA6",
"P> c #253BA7",
"Q> c #253CA7",
"R> c #1E41A5",
"S> c #1F40AF",
"T> c #273AAC",
"U> c #1E40B0",
"V> c #1F40B5",
"W> c #1F40B6",
"X> c #1F40B8",
"Y> c #1E40B8",
"Z> c #1F3EB8",
"`> c #203FB7",
" , c #2240B6",
"., c #2341B7",
"+, c #2345B9",
"@, c #2147BB",
"#, c #2148BA",
"$, c #2049BB",
"%, c #2049BD",
"&, c #2049BF",
"*, c #224BBE",
"=, c #244DBD",
"-, c #244CBF",
";, c #182969",
">, c #273BAD",
",, c #2739AB",
"', c #263AAC",
"), c #243CAE",
"!, c #233DAE",
"~, c #213EAF",
"{, c #1F3FB0",
"], c #2040B4",
"^, c #1F3FB6",
"/, c #1E3EB7",
"(, c #2240B7",
"_, c #2341B6",
":, c #2543B4",
"<, c #2644B3",
"[, c #2544B5",
"}, c #2545B5",
"|, c #2547B6",
"1, c #2548B7",
"2, c #2349BA",
"3, c #1F49BE",
"4, c #2149BD",
"5, c #2049BE",
"6, c #214BBE",
"7, c #2249BE",
"8, c #234CBD",
"9, c #2149BE",
"0, c #1E49BF",
"a, c #253BA9",
"b, c #253BAB",
"c, c #263AAB",
"d, c #213DAF",
"e, c #203EAF",
"f, c #1D40AF",
"g, c #1D40B0",
"h, c #1E40B4",
"i, c #2241B7",
"j, c #2643B6",
"k, c #2744B5",
"l, c #2643B5",
"m, c #2346B6",
"n, c #2147B7",
"o, c #2644B6",
"p, c #2247B7",
"q, c #2248B8",
"r, c #2647B7",
"s, c #2549B7",
"t, c #2645B7",
"u, c #2148B8",
"v, c #2847B6",
"w, c #2549B6",
"x, c #2849B6",
"y, c #2049B7",
"z, c #2A49B5",
"A, c #243BA4",
"B, c #253BA5",
"C, c #253BA6",
"D, c #263AA7",
"E, c #263AA8",
"F, c #2739AA",
"G, c #243CAD",
"H, c #223DAE",
"I, c #1F3EAF",
"J, c #1E3FB0",
"K, c #1D40B1",
"L, c #1E3FB1",
"M, c #1F3FB3",
"N, c #1F3FB5",
"O, c #2140B6",
"P, c #2140B8",
"Q, c #2744B4",
"R, c #2746B6",
"S, c #2947B6",
"T, c #2946B5",
"U, c #2A48B6",
"V, c #3551A8",
"W, c #1F399C",
"X, c #143D9F",
"Y, c #263BA5",
"Z, c #273BA8",
"`, c #273BAA",
" ' c #263AAD",
".' c #233CAD",
"+' c #213DAE",
"@' c #203FB2",
"#' c #2342B6",
"$' c #2443B6",
"%' c #2543B6",
"&' c #2644B5",
"*' c #133D9E",
"=' c #263BA7",
"-' c #263BA9",
";' c #273BA9",
">' c #263AAA",
",' c #2539AB",
"'' c #2639AB",
")' c #253AAC",
"!' c #243BAD",
"~' c #223DAF",
"{' c #203FB0",
"]' c #2040B1",
"^' c #2140B3",
"/' c #2543B1",
"(' c #2744AF",
"_' c #1A3CA0",
":' c #1D3BA2",
"<' c #233BA4",
"[' c #263AA5",
"}' c #253AA5",
"|' c #263AA6",
"1' c #263BA4",
"2' c #243BA5",
"3' c #263BA8",
"4' c #223EAF",
"5' c #3B4CA5",
"6' c #1D379A",
"7' c #1E389C",
"8' c #1E399F",
"9' c #1F3BA2",
"0' c #1F3BA3",
"a' c #213BA4",
"b' c #233AA3",
"c' c #243AA3",
"d' c #2539A4",
"e' c #253AA6",
"f' c #243BA7",
"g' c #253CAA",
"h' c #253CAC",
"i' c #253CAD",
"j' c #253CAE",
"k' c #243DAE",
"l' c #213FAF",
"m' c #223FAF",
"n' c #2040AF",
"o' c #253D93",
"p' c #1D3894",
"q' c #1F379A",
"r' c #1E389B",
"s' c #1D399C",
"t' c #1C3A9D",
"u' c #1B3A9D",
"v' c #183B9E",
"w' c #163C9E",
"x' c #153C9E",
"y' c #163B9D",
"z' c #173B9D",
"A' c #193A9D",
"B' c #1C3A9E",
"C' c #1F3AA1",
"D' c #223AA4",
"E' c #253BA8",
"F' c #273BA7",
"G' c #263CAB",
"H' c #263CAC",
"I' c #243EAE",
"J' c #273BAC",
"K' c #2A3795",
"L' c #1F389B",
"M' c #1D389B",
"N' c #1C399C",
"O' c #1B399C",
"P' c #1A3A9D",
"Q' c #1D399B",
"R' c #1B399B",
"S' c #1A3A9C",
"T' c #1B3A9F",
"U' c #1D3AA0",
"V' c #203BA2",
"W' c #203BA3",
"X' c #2639A6",
"Y' c #1B3692",
"Z' c #1C3794",
"`' c #1D3796",
" ) c #1E3898",
".) c #1E389A",
"+) c #1F399B",
"@) c #1A399C",
"#) c #193A9E",
"$) c #1A3BA0",
"%) c #1C3BA2",
"&) c #1D3CA3",
"*) c #203CA4",
"=) c #223BA5",
"-) c #3C4699",
";) c #2B4595",
">) c #1C3793",
",) c #1D3895",
"') c #1E3897",
")) c #1F3998",
"!) c #1F3999",
"~) c #1F399A",
"{) c #1E399C",
"]) c #1C3B9E",
"^) c #1D3BA0",
"/) c #1E3CA2",
"() c #223CA5",
"_) c #243CA6",
":) c #596FA9",
"<) c #3B4894",
"[) c #314993",
"}) c #29499F",
"|) c #28489E",
"1) c #2B4BA1",
"2) c #2C4BA1",
"3) c #2D4CA2",
"4) c #2E4CA3",
"5) c #2F4CA4",
"6) c #2E4CA4",
"7) c #2F4DA3",
"8) c #2F4DA4",
"9) c #D3D5D2",
"0) c #3B4794",
"a) c #314791",
"b) c #304892",
"c) c #304893",
"d) c #2F4995",
"e) c #2F4997",
"f) c #2D4A9A",
"g) c #2A4A9D",
"h) c #294A9F",
"i) c #284AA0",
"j) c #294AA0",
"k) c #2B4AA1",
"l) c #2D4CA3",
"m) c #C9CAC9",
"n) c #455D9B",
"o) c #242F78",
"p) c #1B2F85",
"q) c #C6C3C8",
"r) c #B5B2B6",
"s) c #B5B7B4",
"t) c #B5B7B3",
"u) c #B5B2B5",
"v) c #B5B3B4",
"w) c #B5B5B4",
"x) c #B5B6B3",
"y) c #B5B4B4",
"z) c #B5B3B5",
"A) c #B5B4B5",
"B) c #B5B5B5",
"C) c #B5B5B3",
"D) c #B5B5B6",
"E) c #BAC3BE",
"F) c #B9C3BD",
"G) c #C1C3C4",
"H) c #BFC3C2",
"I) c #B9C3BE",
"J) c #BBC3BF",
"K) c #BDC3C1",
"L) c #C0C3C3",
"M) c #BEC3C1",
"N) c #C2C3C5",
"O) c #E6E3E8",
"P) c #E0E2DF",
"Q) c #E1E1E1",
"R) c #E2E1E3",
"S) c #E4E1E6",
"T) c #E4E2E7",
"U) c #E4E2E6",
"V) c #E3E3E4",
"W) c #E2E3E3",
"X) c #E1E3E2",
"Y) c #E3E3E3",
"Z) c #E3E3E2",
"`) c #EBEDEA",
" ! c #EAECE9",
".! c #E9EBE8",
"+! c #ECEEEB",
". . + @ # $ $ $ $ $ $ $ % $ $ $ $ $ % $ $ $ $ $ $ % $ $ $ $ $ % $ $ $ $ $ $ $ $ $ % $ $ & * = - ; > , , ' ) ! ! ~ { ] ^ / ( _ : < [ } | | 1 2 3 3 4 4 4 4 4 4 4 5 6 4 4 4 5 6 7 8 9 4 5 6 7 8 9 6 7 8 9 ",
"0 a b % $ $ $ $ $ $ $ $ $ $ $ $ $ $ $ $ $ $ $ $ $ $ $ $ $ $ $ $ c d d d d $ $ $ $ $ c d e f g h i i i i j k l m n o p q r s t u v w x y z 4 A B C D 9 9 E 9 E F G H I F J K L L L L J K L L L L L L L L ",
"@ % M N O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O O P Q R S T U V W X Y Z ` ...+.@.#.$.%.&.*.=.-.;.>.,.'.).!.~.{.].^./.(._.:.<.[.}.|.1.2.3.4.5.6.7.8.9.0.a.b.b.b.b.b.b.",
"c.$ d.O e.f.g.g.g.h.g.g.g.g.g.h.h.g.g.g.g.g.h.h.g.g.i.j.k.l.m.n.o.p.q.r.s.t.u.v.w.x.y.z.A.B.C.D.E.F.G.H.I.J.K.L.M.N.O.P.Q.R.S.T.U.V.W.X.Y.Z.`. +.+++@+#+$+@+$+%+&+*+=+$+-+;+>+,+'+)+!+;+>+,+~+,+>+,+~+,+",
"$ {+N N f.f.f.f.h.h.h.g.f.f.h.h.h.h.g.f.f.h.h.h.h.]+^+/+(+h._+:+<+[+}+|+1+2+3+4+5+6+7+8+9+0+a+b+c+d+e+f+g+h+i+j+k+l+m+n+o+p+q+r+s+t+u+v+w+x+y+z+A+B+.+C+D+E+D+F+G+H+C+I+F+G+J+K+L+H+F+G+J+K+L+H+J+H+J+H+",
"{+{+N N M+M+h.h.h.h.h.h.h.h.h.h.h.h.h.h.h.h.h.h.h.h.N+N+h.h.(+O+P+P+Q+R+S+T+U+V+W+X+Y+Z+`+ @.@+@@@#@$@%@&@*@=@-@;@>@,@'@)@!@~@{@]@^@/@(@_@:@<@[@[@y+}@|@1@A+1@2@3@ +2@4@2@5@C+D+6@D+7@5@C+D+6@I+C+D+6@I+",
"{+{+8@N M+M+h.h.h.h.h.h.h.h.h.h.h.h.h.h.h.h.h.h.h.h.h.h.h.h.9@9@0@N+a@b@c@d@e@f@g@h@i@j@k@l@m@n@o@p@q@r@s@t@u@v@w@x@y@z@A@B@q+r+C@D@E@F@G@H@_@I@J@K@<@L@M@N@O@P@Q@R@S@T@A+A+U@V@W@W@A+2@U@V@W@W@U@V@W@W@",
"{+{+8@N f.M+h.h.h.h.h.h.h.h.h.h.h.h.h.h.h.h.h.h.h.h.h.h.h.h.(+(+(+9@9@X@Y@Z@e@`@ #.#+#@###$#%#&#*#=#-#;#>#,#'#)#!#~#{#]#z@^#/#(#p+_#r+:#s+t+<#[#}#|#|#1#_@|#_@_@2#L@3#4#y+y+5#z+z+z+5#z+z+z+z+A+A+A+A+A+",
"{+{+8@8@f.f.h.h.h.h.h.h.h.h.h.h.h.h.h.h.h.h.h.h.h.h.h.h.h.h.h.h.h.(+6#7#8#9#0#a#b#c#d#e#f#g#h#i#j#k#l#m#n#o#&@p#q#r#s#t#u#v#w#x#x#y#y#z#A#B#C#D#E#E#F#G#H#F#H#H#u+v+I#J#K#L#J@J@M#N#O#P#M#M#M#N#M#Q#Q#R#",
"$ {+8@e.f.f.h.h.h.h.h.h.h.h.h.h.h.h.h.h.h.h.h.h.h.h.h.h.h.h.h.h.h.S#l.7#T#U#V#W#X#Y#Z#`# $f#g###.$+$@$#$$$$@%$&$*$=$-$;$>$,$'$)$!$~$~${$]$^$/$($($_$_$:$<$_$<$[$}$|$|$1$2$2$3$}#4$5$6$7$8$8$9$8$8$8$0$8$",
"$ {+a$e.f.f.h.h.h.h.h.h.h.h.h.b$h.c$c$c$c$c$d$c$c$c$c$c$c$c$c$c$c$e$e$7#f$g$h$i$X#j$k$l$m$n$o$p$q$r$l@s$t$u$v$w$x$y$z$A$B$C$D$E$F$G$G$H$I$J$J$K$K$J$L$L$L$L$L$M$N$O$P$Q$R$S$T$U$1$V$T$W$X$Y$1$V$Y$Z$`$ %",
"$ $ a$a$f.f.b$b$b$b$b$b$b$b$b$b$b$b$b$b$b$b$b$b$.%b$b$b$.%d$+%+%@%h.e$l.#%$%h$%%&%*%=%-%;%>%,%'%)%!% @ @~%{%]%^%/%(%w$_%:%<%[%}%|%D$1%2%3%4%5%4%4%6%5%5%4%4%4%5%7%5%8%9%L$0%a%a%a%P$b%P$P$z#z#z#P$c%c%c%",
"$ $ 8@e.f.f.d%b$b$b$b$b$d%b$b$b$b$b$b$e%f%b$b$b$b$b$g%h%b$.%i%i%j%k%l%m%X@n%h$o%&%p%q%`#r%s%t%u%v%w%x%y% @z%A%B%C%D%E%F%G%:%H%I%[%J%}%K%|%D$K%D$D$L%M%M%M%M%M%D$N%O%i+P%j+Q%R%S%T%0%U%V%W%W%W%W%X%X%X%X%",
"$ $ 8@8@f.f.d%d%b$b$b$b$d%d%b$b$b$h%Y%Z%Z%h%f%f%h%Y%`%`% &h%h%.&+&@&#&$&X@%&&&*&=&-&j$Z#+#;&>&,&'&)&)&!&~&{&]&^&/&(&^%_&(%:&<&[&}&|&1&A$A$2&3&4&4&5&B$6&7&B$7&8&9&6&7&0&a&a&i+i+i+b&a&a&j+U%c&U%j+U%c&U%",
"$ $ 8@8@d&e&d%d%d%d%d%d%d%d%d%d%d%`%d%d%d%d%`%`%`%d%d%d%d%`%`%f&g&h&j%i&j&k&l&m&=&X#Y#n&o&p&q&r&>&s&t&t&u&v&w&x&y&{&z&A&B&C&D&(%(%F%F%E&F&}&}&|&G&|&H&1&I%I&A$1&}&z$z$J&K&L&M&N&O&0&P&Q&0&a&R&a&a&a&R&a&",
"{+$ 8@8@e&e&d%d%d%d%d%d%d%d%d%d%d%d%d%d%d%d%d%d%d%d%d%d%d%d%d%`%f&S&T&U&V&W&Y@X&Y&Z&`& *.*+*@*#*@*r&$*#*r&%*&***=*-*;*y&z%A%z&A&A&>*B&,*,*'*)*!*!*~*{*F&}&{*}&{*]*G%G%y$^*/*J&(*2&_*:*<*=$[*}*<*=$<*|*1*",
"{+{+8@2*e&e&d%d%d%d%d%d%d%d%d%e&3*4*4*4*4*4*5*4*4*4*4*4*4*4*4*4*`%f&6*6*7*8*9*0*a*b*c*d*e*f*g*h*i*j*+*k*h*l*m*n*m*o*p*q*r*s*t*u*v*w*x*y*y*z*A*B*C*D*E*F*G*E*G*F*H*G*F*~*]*{*I*x$J*K*L*G%K*M*o#o#I&N*O*O*",
"{+{+8@2*e&e&e&e&e&e&e&e&e&e&e&e&e&e&e&P*e&e&e&e&e&e&P*P*e&e&e&P*P*5*Q*R*S*T*U*V*W*X*Y*Z*`*d* =.=+=@=#=$=%=g@&=*===-=i*;=l*>=,=q*'=s*)=k@!=x*~={=]=^=/=(=_=:=(=<=<=]=[=}=|=]=]=1=2=3=|=4=5=2=2=2=3=6=6=6=",
"{+{+7=e.e&e&e&e&e&e&e&e&e&e&e&e&e&e&e&e&e&e&e&e&e&e&e&e&e&e&e&e&e&e&P*P*8=9=0=a=b=U*c=d=e=f=e@#=g=h=i=i=j=k=k=l=%===m=n=o=p=q=,=r=s=t=u=v=v*w=x=x=y=z=z=A=z=A=B=C=B=D=C=B=x=B=B=B=B=B=B=B=B=B=B=B=B=B=B=",
"{+{+7=7=e&e&e&e&E=E=e&e&e&e&E=E=E=e&e&e&e&E=E=E=e&e&e&e&E=E=e&e&e&e&E=E=E=F=d%G=G=H=I=J=K=L=M=R+}+N=O=P=Q=j=i=h=R=e@@=S=-=T=h@l*U=V=W=X=Y=Z=`= - - -.-+-@- -#-$-%-$-&-*-$-=-%-----C=$-%---------B=B=B=B=",
"{+{+7=7=;-;-E=E=E=E=E=E=E=E=E=E=E=E=E=E=E=E=E=E=E=E=E=E=E=E=E=E=E=E=E=E=E=E=>-,-'-)-!-6*~-{-{-]-^-/-/-(-_-:-N=<-[-}-|-1-2-3- =4-5-6-7-8-9-0-0-a-b-c-d-e-f-g-h-h-i-j-k-h-h-i-j-l-m-n-o-i-j-l-m-n-j-l-p-n-",
"{+{+7=7=;-;-E=E=E=E=E=E=E=E=q-r-s-t-t-u-u-v-v-v-u-w-x-u-u-u-u-u-u-u-u-v-v-u-u-u-u-u-v-v-u-u-u-u-v-v-u-y-z-A-B-C-D-E-E-F-G-H-I-J-K-L-M-N-O-P-Q-R-S-T-U-U-V-W-V-e-X-Y-Z-`- ;.;Y-N N +;@;.;Y-N N N N N N N ",
"#;#;d&d&$;$;%;%;%;%;%;%;%;%;&;*;=;-;-;-;;;>;,;>;>;>;;;>;>;>;>;>;>;>;>;>;';);>;>;>;>;>;';>;>;>;>;>;';);!;~;{;];^;/;(;_;_;:;<;[;};};|;1;2;3;4;5;6;7;8;9;9;0;a;0;0;b;h.a;0;0;b;h.c;h.d;0;b;h.c;h.d;h.c;h.d;",
"#;#;;-;-$;$;e;e;e;e;e;e;e;e;e;e;e;f;f;f;f;e;e;e;f;f;f;f;f;f;f;f;f;f;f;f;g;%;f;f;f;f;f;g;f;f;f;f;f;g;%;h;i;j;k;l;m;n;o;p;q;r;r;s;t;u;v;w;x;y;z;A;B;C;6;D;E;F;G;G;H;I;F;G;G;H;I;J;J;K;G;H;I;J;J;K;I;J;J;K;",
"#;#;;-;-$;$;e;e;e;e;e;e;e;e;e;e;e;e;e;e;e;e;e;e;e;e;e;e;e;e;e;e;e;e;e;e;e;L;e;e;e;e;e;e;e;e;e;e;e;e;L;M;N;O;P;Q;i;i;k;R;S;T;U;q;q;V;W;X;{;Y;Z;`; >.>+>@>#>+>$>6;#>#>+>%>&>G;G;G;G;G;&>G;G;G;G;G;G;G;G;G;",
"#;#;d.;-$;$;e;e;e;e;e;e;e;e;e;e;e;e;e;e;e;e;e;e;e;e;e;e;e;e;e;e;e;e;e;e;e;*>e;e;e;e;e;e;e;e;e;e;e;e;*>=>->;>>>,>'>'>)>!>~>{>]>^>^>V;V;/>(>_>:><>[>}>|>1>2>3>2>4>5>6>7>8>9>0>G;G;G;G;9>0>G;G;G;G;G;G;G;G;",
"#;#;d.d.a>a>e;e;e;e;e;e;e;e;e;e;b>b>c>c>c>c>c>b>e;e;e;e;e;e;e;e;e;e;e;e;e;e;d>e>f>g>h>i>j>k>l>l>m>m>n>n>o>o>p>q>r>r>s>t>u>v>v>u>w>';x>y>z>t;A>B>C>D>E>E>F>G>F>H>H>I>F>Y;J>w;K>L>K>M>J>w;K>L>K>M>K>L>K>M>",
"#;#;d.d.a>a>N>e;N>O>O>O>N>e;N>O>O>P>Q>R>S>R>Q>O>O>O>N>e;N>O>O>O>N>e;N>N>O>T>e;e;e;U>U>U>U>f;V>W>o>o>o>o>X>X>Y>Y>n>n>Z>Z>`> ,.,t>t>u>u>w>+,@,#,$,%,A>&,*,=,B>[>-,w;<>C>[>-,w;w;w;w;w;-,w;w;w;w;w;w;w;w;w;",
"#;;,;-;-a>a>N>N>N>O>O>O>N>N>N>O>O>O>O>N>N>N>O>O>O>O>N>N>N>O>O>O>N>N>N>N>O>>,,,,,,,',g>),!,~,{,{,*>U>e;f;],o>%;o>^,^,/,/,l>q>(,_,t>u>:,<,v>[,},|,1,2,%,%,3,4,5,6,7,8,9,5,6,0,G>G>Y;G>6,0,G>G>Y;G>G>G>Y;G>",
";,;,;-;-O>O>O>O>O>O>O>O>O>O>O>O>O>O>O>O>O>O>O>O>O>O>O>O>O>O>O>O>O>O>O>O>O>O>P>a,b,',',c,c,f>),e>d,e,{,{,U>U>f,f,U>U>g,g,*>g;h,^,^,`>`>q>i,t>j,k,k,l,w>m,n,o,p,q,r,s,t,p,u,v,w,x,y,z,u,v,w,x,y,z,w,x,y,z,",
";,;,b b O>O>O>O>O>O>O>O>O>O>O>O>O>O>O>O>O>O>O>O>O>O>O>O>O>O>O>O>O>O>O>O>O>O>A,A,A,B,C,D,E,F,c,',g>G,!,H,~,e,{,I,J,J,K,K,U>f,f,J,L,M,N,L;O,i,P,.,l,Q,k,k,k,k,k,k,R,v,k,k,k,R,v,S,T,U,k,R,v,S,T,U,v,S,T,U,",
";,;,b V,W,W,X,X,O>X,X,X,X,X,O>X,X,X,X,X,X,O>X,X,X,X,X,X,O>X,X,X,X,X,O>X,X,O>O>O>O>B,B,B,B,Y,O>O>Z,`,T>T> '',g>.'+'e,{,{,e,+'+'e,e,{,J,K,e;@'N,O,#'$'%'%'j,%'j,&'k,k,%'j,&'k,k,k,k,k,&'k,k,k,k,k,k,k,k,k,",
";,;,b V,W,W,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,*'O>O>O>O>O>O>O>O>B,B,A,A,B,C,='-'`,;'>'>',''')'!'!'e>e>~'~'~,~,{'{,*>*>e;]']']']']']'^'/']']']'^'/':,(':,]'^'/':,(':,/':,(':,",
";,;,V,V,W,W,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,_':'<'['}'|'|'O>O>O>O>O>O>O>Y,Y,1'1'B,B,2'2'C,3'-'>'c,)')'!'),4'{'e;]'e;*>*>e;e;e;e;e;e;e;e;e;e;e;e;e;e;e;e;e;e;e;e;e;e;e;e;",
";,;,5'5'W,W,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,W,6'6'6'7'8'9'0'a'b'c'd'd'}'}'O>O>O>O>O>O>O>O>Y,1'1'['['e'e'f'g'h'i'j'k'G,),!,l'j'm'n'b>b>),m'b>e;e;e;e;e;b>e;e;e;e;e;e;e;e;e;",
";,;,b b o'o'p'p'p'p'p'p'p'p'p'p'p'p'p'p'p'p'p'p'p'p'p'p'p'p'p'p'p'p'p'p'p'W,q'q'q'r's't'u'v'w'x'y'z'A'B'C'D'2'2'B,B,O>O>O>O>O>O>O>O>O>O>O>Y,Y,C,C,='='='E'F'3'3'3'G'Z,='F'F'G'H'I'J'F'F'G'H'I'J'G'H'I'J'",
";,;,b b K'K'p'p'p'p'p'p'p'p'p'p'p'p'p'p'p'p'p'p'p'p'p'p'p'p'p'p'p'p'p'p'p'p'W,W,W,W,W,L'L'q'r'M'N'O'P'u'N's'Q'R'S'A'T'U'C'V'9'0'W'D'}'X'|'O>O>B,B,O>O>O>O>O>O>O>O>O>O>O>O>O>O>O>O>O>O>O>O>O>O>O>O>O>O>O>",
";,;,b b K'K'p'p'p'p'p'p'p'p'p'p'p'p'p'p'p'p'p'p'p'p'p'p'p'p'p'p'p'p'p'p'p'p'Y'Y'Y'Z'`' ).)+)+)+)W,W,W,W,L'L'q'q'r'r's'M'N'P'@)A'#)$)%)&)*)=)B,|'|'O>O>O>O>O>O>O>O>O>O>O>O>O>O>O>O>O>O>O>O>O>O>O>O>O>O>O>",
"{+;,$ -);)K'p'p'o'p'p'p'p'p'o'p'p'p'p'p'p'o'p'p'p'p'p'p'o'p'p'p'p'p'o'o'p'p'p'p'p'p'p'p'p'p'>)>)Y'Y'>)Z',)')))!)~)+)W,W,W,W,W,W,W,W,W,W,W,L'L'{)s't'])^)/)])/)/)O>()])/)/)O>()O>_)O>/)O>()O>_)O>()O>_)O>",
":);,;,;)<)<)<)<)<)<)<)<)<)<)<)<)<)<)<)<)<)<)<)<)<)<)<)<)<)<)<)<)<)<)<)<)<)[)M M M M M M M M M M M M M M M M M M })})|)|)})M M 1)2)3)4)5)6)6)6)7)7)8)8)8)8)8)8)8)8)8)8)8)8)8)8)8)8)8)8)8)8)8)8)8)8)8)8)8)",
"9)#;;,;,$ -)<)<)<)<)<)<)<)<)<)<)<)<)<)<)<)<)<)<)<)<)<)<)<)<)<)<)<)<)<)<)<)0)a)a)a)b)c)d)e)f)g)h)i)i)j)j)M M M M M M M M M M M })})})})M k)k)M M k)l)8)8)8)8)8)8)8)8)8)8)8)8)8)8)8)8)8)8)8)8)8)8)8)8)8)8)",
"+ 9)m)n)$ #;#;#;#;#;#;#;#;#;#;#;#;#;#;#;#;#;#;#;#;#;#;#;#;#;#;#;#;#;#;#;#;o)p)p)p)p)p)p)p)p)p)p)p)p)p)p)p)p)p)p)p)p)p)p)p)p)p)p)p)p)p)p)p)p)p)p)p)p)p)p)p)p)p)p)p)p)p)p)p)p)p)p)p)p)p)p)p)p)p)p)p)p)p)p)",
"+ + 9)a m)q)r)s)r)s)r)s)r)s)r)r)s)r)s)r)s)r)r)s)r)s)r)s)r)s)r)s)r)s)r)s)r)t)u)v)w)x)x)w)y)z)A)A)B)B)B)B)w)w)C)C)w)w)B)B)B)B)B)w)w)w)w)B)B)B)B)B)B)B)B)B)B)B)B)B)B)B)B)B)B)B)B)B)D)B)B)B)B)B)D)B)B)B)D)B)",
". + + 9)9)9)q)E)q)E)q)E)q)E)q)q)E)q)E)q)E)q)q)E)q)E)q)E)q)E)q)E)q)E)q)E)q)F)G)H)E)I)J)K)H)L)L)L)L)L)L)L)H)H)M)M)H)H)L)L)G)L)L)H)H)H)H)L)L)L)L)L)L)L)L)L)L)L)L)L)L)L)L)L)L)L)L)L)N)L)L)L)L)L)N)L)L)L)N)L)",
". . 0 . + O)P)O)P)O)P)O)P)O)P)P)O)P)O)P)O)P)P)O)P)O)P)O)P)O)P)O)P)O)P)O)P)O)Q)R)S)T)U)V)W)X)W)W)V)V)V)V)V)V)V)V)Y)Y)Z)Z)Y)Z)Z)Y)Y)V)V)V)V)V)V)V)V)V)V)V)V)V)V)V)V)V)V)V)V)V)V)V)Y)V)V)V)V)V)Y)V)V)V)Y)V)",
". . . 0 0 0 . 0 0 0 + 0 + 0 + 0 + 0 + 0 + 0 0 + 0 + 0 + 0 + 0 + 0 + 0 + 0 0 `) !+ + + .! !`)`)`)`)`)`)`)`)`)`)`)`)`)`)`)`)`)`)`)`)`)`)`)`)`)`)`)`)`)`)`)`)`)`)`)`)`)`)`)`)`)`)`)+!`)`)`)`)`)+!`)`)`)+!`)"};
static char * listviewhighcornerright_xpm[] = {
"100 46 780 2",
" c None",
". c #6A779D",
"+ c #6C789C",
"@ c #6C789D",
"# c #6B789D",
"$ c #6A779E",
"% c #66759E",
"& c #64749E",
"* c #63749E",
"= c #61739D",
"- c #576D9B",
"; c #556C9C",
"> c #4D679D",
", c #4A649D",
"' c #49629D",
") c #465E9C",
"! c #40579C",
"~ c #3B5394",
"{ c #2C4E97",
"] c #314993",
"^ c #2B4595",
"/ c #1B4296",
"( c #253D93",
"_ c #19418F",
": c #0F3C96",
"< c #42599E",
"[ c #758DC3",
"} c #E8EAE7",
"| c #EEF0ED",
"1 c #FBFBFC",
"2 c #6F7D9B",
"3 c #6F7D9A",
"4 c #6E7B9C",
"5 c #67759E",
"6 c #63739E",
"7 c #62739D",
"8 c #596F9C",
"9 c #4A639D",
"0 c #47609C",
"a c #445B9F",
"b c #3E5697",
"c c #2E509A",
"d c #2D509A",
"e c #2D4F99",
"f c #2D4F98",
"g c #28418A",
"h c #3E51A3",
"i c #D0D3DC",
"j c #A1B6EF",
"k c #A2B6F0",
"l c #A1B6F0",
"m c #A3B6F0",
"n c #A0B6EF",
"o c #9DB6EE",
"p c #9CB5EF",
"q c #9CB2F0",
"r c #9FB5EE",
"s c #9CB4EB",
"t c #9AB3EC",
"u c #9AB0EC",
"v c #9DB3EB",
"w c #9BB4EC",
"x c #9BB4EE",
"y c #9BB1EF",
"z c #9BB0F0",
"A c #90ACF0",
"B c #93ABEE",
"C c #91A8EB",
"D c #8BA3E8",
"E c #88A1E7",
"F c #809DE9",
"G c #7A99E8",
"H c #7491E5",
"I c #698AE4",
"J c #6184E3",
"K c #507EDC",
"L c #4E7CDB",
"M c #4F7DDC",
"N c #5479DA",
"O c #567BDC",
"P c #577CDD",
"Q c #5074DA",
"R c #5174DB",
"S c #5175DC",
"T c #5276DD",
"U c #4D71DE",
"V c #4C72D8",
"W c #3A6CE0",
"X c #2B49A6",
"Y c #E0E2DF",
"Z c #93AAE9",
"` c #94A9E8",
" . c #94AAE9",
".. c #93A9E9",
"+. c #92AAE9",
"@. c #8DA9E8",
"#. c #8CA7E9",
"$. c #92ABE9",
"%. c #8EAAE9",
"&. c #8EA9E9",
"*. c #8FAAE9",
"=. c #8CA8E9",
"-. c #8CA2E7",
";. c #86A1E6",
">. c #839EE9",
",. c #7F9CE9",
"'. c #7A97E8",
"). c #7693E7",
"!. c #6E8EE8",
"~. c #678AE9",
"{. c #5D84E3",
"]. c #577CDF",
"^. c #4E77DF",
"/. c #4A70DB",
"(. c #4870DB",
"_. c #4870DC",
":. c #4770E3",
"<. c #496FDC",
"[. c #486EDB",
"}. c #466FE4",
"|. c #466EE3",
"1. c #4167D9",
"2. c #4066D8",
"3. c #3F66D8",
"4. c #3D64D7",
"5. c #3960DA",
"6. c #476DD9",
"7. c #446EE5",
"8. c #305EC8",
"9. c #8EAAE8",
"0. c #8FAAE8",
"a. c #91AAE9",
"b. c #8FA9E8",
"c. c #8BA8E8",
"d. c #8AA7E9",
"e. c #8BA5EA",
"f. c #8AA7E8",
"g. c #87A2E6",
"h. c #859FE8",
"i. c #7F9DE8",
"j. c #7C9AE8",
"k. c #7B95E7",
"l. c #7090E8",
"m. c #6B8BE9",
"n. c #6386E6",
"o. c #5881E1",
"p. c #5479DE",
"q. c #4D74DE",
"r. c #476EDB",
"s. c #446EE1",
"t. c #446EE0",
"u. c #446EDF",
"v. c #446DE0",
"w. c #426ADF",
"x. c #3C64DA",
"y. c #4360CC",
"z. c #D3D5D2",
"A. c #E6E3E8",
"B. c #8DA2E7",
"C. c #8CA6EA",
"D. c #8DA3E9",
"E. c #88A2E7",
"F. c #87A1E7",
"G. c #8AA1E7",
"H. c #849EE9",
"I. c #7D9AE9",
"J. c #7B98E8",
"K. c #7796E5",
"L. c #7191E7",
"M. c #688CE9",
"N. c #6687E5",
"O. c #5C83E1",
"P. c #557BDE",
"Q. c #4F76DE",
"R. c #4C72DE",
"S. c #456EDF",
"T. c #426AD9",
"U. c #4269D9",
"V. c #4269D8",
"W. c #3D64D9",
"X. c #3A61DA",
"Y. c #345ED6",
"Z. c #335ECF",
"`. c #C6C3C8",
" + c #86A1E7",
".+ c #87A2E7",
"++ c #87A0E7",
"@+ c #859EE8",
"#+ c #849DE9",
"$+ c #7E9BE9",
"%+ c #7A99E9",
"&+ c #7A95E5",
"*+ c #7593E7",
"=+ c #6F8EE9",
"-+ c #668AE5",
";+ c #6386E0",
">+ c #5B82DF",
",+ c #5379DE",
"'+ c #5075DE",
")+ c #4B6FDC",
"!+ c #446AD7",
"~+ c #4269D6",
"{+ c #4269D5",
"]+ c #3E65D7",
"^+ c #C9CAC9",
"/+ c #869EE9",
"(+ c #859FE9",
"_+ c #849FE9",
":+ c #829DE8",
"<+ c #819DE8",
"[+ c #7B9AE9",
"}+ c #7A96E6",
"|+ c #7290E8",
"1+ c #698CE6",
"2+ c #6689E0",
"3+ c #5D84E0",
"4+ c #587FDF",
"5+ c #5377DD",
"6+ c #4B74DE",
"7+ c #496BD8",
"8+ c #7C9BE9",
"9+ c #7E9CE9",
"0+ c #7D9AEA",
"a+ c #7D9BEA",
"b+ c #7D98E8",
"c+ c #7C98E8",
"d+ c #7796E4",
"e+ c #7592E6",
"f+ c #7390E1",
"g+ c #698DE0",
"h+ c #6588DE",
"i+ c #5E84E0",
"j+ c #5880DF",
"k+ c #5479DC",
"l+ c #4F75DE",
"m+ c #4A6FDB",
"n+ c #436AD7",
"o+ c #3F65D7",
"p+ c #BAC3BE",
"q+ c #7B9AE8",
"r+ c #7B9AEA",
"s+ c #7A9AEA",
"t+ c #7B99E9",
"u+ c #7D97E7",
"v+ c #7D95E6",
"w+ c #7D95E5",
"x+ c #7C95E6",
"y+ c #7493E3",
"z+ c #7290DF",
"A+ c #6C8DDE",
"B+ c #6B89E1",
"C+ c #6486DF",
"D+ c #5D81DF",
"E+ c #567DDE",
"F+ c #4F73DE",
"G+ c #496EDA",
"H+ c #355ED6",
"I+ c #345ED5",
"J+ c #7E95E5",
"K+ c #7C97E8",
"L+ c #7C97E7",
"M+ c #7B94E6",
"N+ c #7A95E4",
"O+ c #7695E5",
"P+ c #7694E4",
"Q+ c #7994E6",
"R+ c #7995E4",
"S+ c #7594E4",
"T+ c #7391E2",
"U+ c #6E8EDE",
"V+ c #6B8ADE",
"W+ c #6688DF",
"X+ c #5F84E0",
"Y+ c #5980E0",
"Z+ c #4D72DD",
"`+ c #456BD7",
" @ c #4168D6",
".@ c #3C64D7",
"+@ c #335ED0",
"@@ c #4659C7",
"#@ c #7292E1",
"$@ c #7392E1",
"%@ c #7492E1",
"&@ c #718FDF",
"*@ c #6F8EDE",
"=@ c #6D8BDE",
"-@ c #6B88DF",
";@ c #597FDF",
">@ c #557ADD",
",@ c #5176DC",
"'@ c #4D74DD",
")@ c #496DDA",
"!@ c #3860D8",
"~@ c #7391E0",
"{@ c #7290DE",
"]@ c #6D8EDD",
"^@ c #6D8DDD",
"/@ c #7190E0",
"(@ c #6C8DDD",
"_@ c #6B89DF",
":@ c #6487E0",
"<@ c #6085DF",
"[@ c #5F81DE",
"}@ c #567EDE",
"|@ c #4F74D9",
"1@ c #466BD7",
"2@ c #4067D5",
"3@ c #3C63D7",
"4@ c #335ED3",
"5@ c #335ED1",
"6@ c #718EDD",
"7@ c #728EDD",
"8@ c #748EDD",
"9@ c #708EDD",
"0@ c #6F8DDD",
"a@ c #6E8DDD",
"b@ c #6C8ADE",
"c@ c #6C89DF",
"d@ c #6988DF",
"e@ c #6387DF",
"f@ c #6282DE",
"g@ c #5681E0",
"h@ c #577BDD",
"i@ c #5277DB",
"j@ c #4D73D8",
"k@ c #4A70D8",
"l@ c #436AD5",
"m@ c #3F66D6",
"n@ c #3C63D8",
"o@ c #3960D8",
"p@ c #3860D7",
"q@ c #335ED2",
"r@ c #345ED4",
"s@ c #6C88DF",
"t@ c #6D88DF",
"u@ c #6B89DE",
"v@ c #6888DF",
"w@ c #6587E0",
"x@ c #6989DF",
"y@ c #6687E0",
"z@ c #6287E0",
"A@ c #6281DD",
"B@ c #5881E0",
"C@ c #557ADB",
"D@ c #5176D9",
"E@ c #4E75D7",
"F@ c #4A6FD8",
"G@ c #476BD6",
"H@ c #4067D6",
"I@ c #3C62D7",
"J@ c #3C60D4",
"K@ c #365ED1",
"L@ c #345ED3",
"M@ c #6786DF",
"N@ c #5F85E0",
"O@ c #5F86E0",
"P@ c #6186DF",
"Q@ c #6286E0",
"R@ c #6284DF",
"S@ c #6384DF",
"T@ c #5B7FDE",
"U@ c #577DDC",
"V@ c #557BDA",
"W@ c #5278D8",
"X@ c #4E76D6",
"Y@ c #4C72D7",
"Z@ c #486DD8",
"`@ c #4469D6",
" # c #3F62D2",
".# c #3C60CF",
"+# c #345ECF",
"@# c #6086DF",
"## c #6085E0",
"$# c #6285DF",
"%# c #6383DD",
"&# c #6481DC",
"*# c #6380DD",
"=# c #6183DE",
"-# c #6083DD",
";# c #6081DC",
"># c #6080DD",
",# c #6083DE",
"'# c #6181DC",
")# c #6280DD",
"!# c #577EDB",
"~# c #557CD7",
"{# c #4F76D6",
"]# c #4E74D7",
"^# c #466CD7",
"/# c #3B64D6",
"(# c #4261CD",
"_# c #375FCE",
":# c #5A7FD8",
"<# c #6281DA",
"[# c #5F81D8",
"}# c #5C80D8",
"|# c #557DD7",
"1# c #577ED8",
"2# c #567ED7",
"3# c #587DD8",
"4# c #577DD8",
"5# c #587ED8",
"6# c #567DD8",
"7# c #5379D9",
"8# c #5177D7",
"9# c #4D74D5",
"0# c #486ED9",
"a# c #4068D4",
"b# c #3D65D2",
"c# c #4361CC",
"d# c #345ECE",
"e# c #325DCF",
"f# c #2C5AD1",
"g# c #3959C5",
"h# c #547BD8",
"i# c #567DD7",
"j# c #557BD8",
"k# c #5279D9",
"l# c #5278D9",
"m# c #4D74D6",
"n# c #4B71D8",
"o# c #496CD8",
"p# c #4669D7",
"q# c #3D66D3",
"r# c #3F62CF",
"s# c #4260CC",
"t# c #5379D8",
"u# c #4E75D4",
"v# c #4C73D7",
"w# c #476CD7",
"x# c #4869D0",
"y# c #4067D2",
"z# c #3D64D1",
"A# c #4261CC",
"B# c #395FCE",
"C# c #4F75D3",
"D# c #5074D2",
"E# c #5174D1",
"F# c #5175D1",
"G# c #4F74D3",
"H# c #4C73D5",
"I# c #4C73D4",
"J# c #4A72D1",
"K# c #4B70CF",
"L# c #506CCC",
"M# c #4D6BCE",
"N# c #4167D0",
"O# c #3D65D1",
"P# c #3F63CF",
"Q# c #3B5FCD",
"R# c #3159CD",
"S# c #4971D0",
"T# c #4870CF",
"U# c #4C6FCF",
"V# c #4E6CCE",
"W# c #4E6BCE",
"X# c #4769CF",
"Y# c #3D66D0",
"Z# c #3C65D1",
"`# c #4062CE",
" $ c #3D5FCD",
".$ c #365FCF",
"+$ c #325DCD",
"@$ c #2D5AD0",
"#$ c #3859C5",
"$$ c #355FCF",
"%$ c #355ECF",
"&$ c #335ECE",
"*$ c #305CCD",
"=$ c #2B5ACE",
"-$ c #3056C9",
";$ c #2553C6",
">$ c #2153C8",
",$ c #1F4FC7",
"'$ c #274CC5",
")$ c #214AC7",
"!$ c #1C48C8",
"~$ c #1244C9",
"{$ c #1043C9",
"]$ c #1144C9",
"^$ c #2A45BE",
"/$ c #2744B5",
"($ c #1D49C0",
"_$ c #2B58DE",
":$ c #002D94",
"<$ c #2B59CA",
"[$ c #2A59CA",
"}$ c #2E57C8",
"|$ c #3255C6",
"1$ c #3355C5",
"2$ c #1C52C8",
"3$ c #1D50C7",
"4$ c #234FC6",
"5$ c #264CC5",
"6$ c #1D48C7",
"7$ c #1245C8",
"8$ c #1F44C2",
"9$ c #2945BE",
"0$ c #2A45BD",
"a$ c #2040BF",
"b$ c #3156C7",
"c$ c #3056C7",
"d$ c #3354C5",
"e$ c #3355C6",
"f$ c #3255C5",
"g$ c #3254C5",
"h$ c #1952C7",
"i$ c #1951C8",
"j$ c #2050C7",
"k$ c #274CC4",
"l$ c #244CC6",
"m$ c #1F49C7",
"n$ c #1E47C5",
"o$ c #2045C3",
"p$ c #1C44BF",
"q$ c #2045BE",
"r$ c #2040B8",
"s$ c #3254C6",
"t$ c #3055C6",
"u$ c #2A54C6",
"v$ c #2353C7",
"w$ c #3054C5",
"x$ c #2F55C5",
"y$ c #2A54C5",
"z$ c #2553C5",
"A$ c #2F54C5",
"B$ c #3155C6",
"C$ c #2A54C7",
"D$ c #1A52C8",
"E$ c #204FC2",
"F$ c #264DC6",
"G$ c #234BC5",
"H$ c #1D48C1",
"I$ c #1E48BF",
"J$ c #2646BE",
"K$ c #2B45BD",
"L$ c #1E43BE",
"M$ c #2643BF",
"N$ c #2243BF",
"O$ c #3049BC",
"P$ c #1E50BE",
"Q$ c #1D50C0",
"R$ c #1D50BF",
"S$ c #1852C1",
"T$ c #1E51C0",
"U$ c #214FBF",
"V$ c #2050C0",
"W$ c #244EBF",
"X$ c #2151C0",
"Y$ c #234FBF",
"Z$ c #2350C0",
"`$ c #2351C0",
" % c #244FBF",
".% c #2250C0",
"+% c #2051C0",
"@% c #1E50C0",
"#% c #244DBE",
"$% c #274DBF",
"%% c #244CBF",
"&% c #1C48C0",
"*% c #2247BF",
"=% c #2C44BD",
"-% c #1C44BE",
";% c #1444BF",
">% c #1841BF",
",% c #1F40BF",
"'% c #254DBE",
")% c #224FBE",
"!% c #224FBF",
"~% c #234EBF",
"{% c #254CBD",
"]% c #244DBD",
"^% c #244CBD",
"/% c #264DBE",
"(% c #264DBD",
"_% c #214BC0",
":% c #1D48C0",
"<% c #2347BF",
"[% c #2B44BD",
"}% c #2444BE",
"|% c #0F42BF",
"1% c #0641BF",
"2% c #0F41BF",
"3% c #1741BE",
"4% c #1F40BD",
"5% c #234BBF",
"6% c #234CBE",
"7% c #214BBE",
"8% c #244CBE",
"9% c #214ABE",
"0% c #214ABF",
"a% c #1F48C0",
"b% c #2746BE",
"c% c #1F43BE",
"d% c #0941BE",
"e% c #0342BA",
"f% c #0242BC",
"g% c #1241B8",
"h% c #1F40B7",
"i% c #2F41AC",
"j% c #2644AE",
"k% c #2D49B4",
"l% c #2649B6",
"m% c #2949B7",
"n% c #2849B5",
"o% c #2149B8",
"p% c #1E49B9",
"q% c #1F48B8",
"r% c #1F49B9",
"s% c #2545B6",
"t% c #2744B7",
"u% c #2844B7",
"v% c #2043B8",
"w% c #1241B7",
"x% c #1340B8",
"y% c #0D41B8",
"z% c #1941B8",
"A% c #1F40B8",
"B% c #203FB8",
"C% c #2549B5",
"D% c #2648B6",
"E% c #2547B7",
"F% c #2248B7",
"G% c #2048B7",
"H% c #2346B6",
"I% c #2146B6",
"J% c #2247B7",
"K% c #2148B7",
"L% c #2743B4",
"M% c #2643B5",
"N% c #2542B6",
"O% c #1D42B7",
"P% c #0E42B8",
"Q% c #0C41B8",
"R% c #1341B8",
"S% c #1740B8",
"T% c #1C41B8",
"U% c #1F40B1",
"V% c #2644B5",
"W% c #2544B5",
"X% c #2544B4",
"Y% c #2444B5",
"Z% c #2444B4",
"`% c #2744B4",
" & c #2241B7",
".& c #1D41B8",
"+& c #0B42B8",
"@& c #0942B8",
"#& c #0C42B8",
"$& c #0F41B8",
"%& c #1641B8",
"&& c #2442B5",
"*& c #2543B3",
"=& c #2342B2",
"-& c #2341B4",
";& c #2141B3",
">& c #2141B5",
",& c #2140B5",
"'& c #2040B5",
")& c #1C40B7",
"!& c #1B41B3",
"~& c #0142B6",
"{& c #0E41B7",
"]& c #1141B7",
"^& c #1440B2",
"/& c #113FB0",
"(& c #1440B0",
"_& c #213EAF",
":& c #233DAE",
"<& c #223EAF",
"[& c #1E40B1",
"}& c #173EAD",
"|& c #1440AF",
"1& c #0D40AF",
"2& c #0941B0",
"3& c #0D3FAE",
"4& c #1B3CAC",
"5& c #233CAD",
"6& c #203FB0",
"7& c #273BAD",
"8& c #1D40B0",
"9& c #2040B1",
"0& c #1E40B0",
"a& c #1C40B0",
"b& c #1B3DAC",
"c& c #143DAC",
"d& c #193DAD",
"e& c #1B3DAD",
"f& c #173DAD",
"g& c #153DAC",
"h& c #1C3CAC",
"i& c #243CAD",
"j& c #213FB0",
"k& c #263BAA",
"l& c #253CAE",
"m& c #273AAC",
"n& c #273AAD",
"o& c #253BAD",
"p& c #1D3CAC",
"q& c #243BAD",
"r& c #1E3CAC",
"s& c #263BAD",
"t& c #1A3DAC",
"u& c #143DAB",
"v& c #163DAC",
"w& c #1A3CAC",
"x& c #1F3CAD",
"y& c #263BAB",
"z& c #263BA6",
"A& c #1E42A4",
"B& c #2D40A5",
"C& c #253BA6",
"D& c #253CA7",
"E& c #263AA5",
"F& c #253BA7",
"G& c #1E3BA6",
"H& c #193DA6",
"I& c #173DA5",
"J& c #143DA6",
"K& c #1A3DA7",
"L& c #133DA6",
"M& c #123DA5",
"N& c #1A3CA7",
"O& c #243BA6",
"P& c #263AA7",
"Q& c #273BA7",
"R& c #263AA6",
"S& c #223BA6",
"T& c #1D3BA6",
"U& c #173CA6",
"V& c #133DA5",
"W& c #1B3DA6",
"X& c #193DA5",
"Y& c #123DA4",
"Z& c #163CA5",
"`& c #213CA6",
" * c #273BA8",
".* c #263BA7",
"+* c #253BA5",
"@* c #263BA5",
"#* c #1C3BA6",
"$* c #1B3BA9",
"%* c #133BA8",
"&* c #0A3BA7",
"** c #083AA6",
"=* c #123CA5",
"-* c #0839A8",
";* c #0239A6",
">* c #123AA8",
",* c #1F49C8",
"'* c #2F4DA4",
")* c #2E4DA3",
"!* c #384CA4",
"~* c #3C4DA7",
"{* c #394EA7",
"]* c #3B4CA5",
"^* c #3C52B1",
"/* c #3551A8",
"(* c #3759BE",
"_* c #4161C7",
":* c #0033A8",
"<* c #596FA9",
"[* c #2F4DA3",
"}* c #2D4BA5",
"|* c #2E4CA4",
"1* c #2C4AA5",
"2* c #2D4BA4",
"3* c #354DA4",
"4* c #3A4BA4",
"5* c #394DA6",
"6* c #4056AD",
"7* c #445BBB",
"8* c #B5B7B4",
"9* c #1B2F85",
"0* c #242F79",
"a* c #B5B5B5",
"b* c #B5B2B6",
"c* c #C0C3C3",
"d* c #E3E3E4",
"e* c #EBEDEA",
". + @ + # $ % & # $ % & # $ % & # $ % & & * = - ; > , ' ) ! ~ { { { { { { { ] ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ / / / ( / / / / / / / / / / / / / / / / / / / / / / / / / / / / / / / / / _ _ / / : / < [ } | | | 1 1 ",
"2 2 2 2 3 2 4 @ 3 2 4 @ 3 2 4 @ 3 2 4 @ # 5 6 7 8 ; > 9 0 a b c d e f { { { ] ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ( ( ( ( ( ( ( ( ( / / / / / / / / / / / / / / / / / _ _ _ _ _ _ _ _ _ _ _ g g _ / / : : : h i } 1 | 1 ",
"j k l m n o p q n o p q r s t u v w x y z A B C D E F G H I J K L M N O P O O Q R S T T T T T T T T T T T T T T T T T T U U U U U U U U U U U U U U U U U U U U U U U U U U U U V V V U U W X : [ Y | | ",
"Z ` . ...+.@.#...+.@.#.Z $.%.&.Z $.*.=.-.;.>.,.'.).!.~.{.].^./.(._.:.<.[.}.|.1.2.3.4.5.5.5.5.5.5.5.5.5.5.5.5.5.5.5.5.5.5.5.5.5.5.5.5.5.5.5.5.5.5.5.5.5.5.5.5.5.5.5.5.5.5.5.5.5.5.5.5.5.6.7.8.: h Y } 1 ",
"9.0.a.b.c.c.d.e.f.c.d.e.f.c.d.e.f.c.d.e.g.h.i.j.k.l.m.n.o.p.q.r.s.s.t.u.u.v.w.x.4.4.5.5.5.5.5.5.5.5.5.5.5.5.5.5.5.5.5.5.5.5.5.5.5.5.5.5.5.5.5.5.5.5.5.5.5.5.5.5.5.5.5.5.5.5.5.5.5.5.5.y.5.7.6.: / z.A.} ",
"-.B.C.D.-.E.g.F.G.E.g.F.G.E.g.F.G.E.g.F.H.I.J.K.L.M.N.O.P.Q.R.S.T.U.V.V.U.U.W.X.5.5.5.5.5.5.5.5.5.5.5.5.5.5.5.5.5.5.Y.Y.Y.Y.Y.Y.Y.Y.Y.Y.Y.Y.Y.Y.Y.Y.Y.Y.Y.Y.Y.Y.Y.Y.Y.Y.Y.Y.Y.Y.Y.Y.Z.y.Y.7.7.: : `.z.} ",
" +.+g.;.++F.@+#+++F.@+#+++F.@+#+++F.@+#+$+%+&+*+=+-+;+>+,+'+)+!+~+{+]+{+{+4.4.5.5.5.5.5.5.5.5.5.5.5.5.5.5.5.Y.Y.5.5.Y.Y.Y.Y.Y.Y.Y.Y.Y.Y.Y.Y.Y.Y.Y.Y.Y.Y.Y.Y.Y.Y.Y.Y.Y.Y.Y.Y.Y.Z.Z.Z.y.y.5.7.7.: : ^+z.Y ",
"/+(+_+#+H.H.>.:+H.H.>.:+H.H.>.:+H.H.>.<+[+}+*+|+1+2+3+4+5+6+7+{+{+4.4.4.4.4.4.5.5.5.5.5.5.5.5.5.5.5.5.5.5.5.Y.Y.Y.Y.Y.Y.Y.5.Y.Y.Y.Y.Y.Y.Y.Y.5.Y.Y.5.5.5.5.Y.Y.Y.Y.Y.Y.Z.Z.Z.Z.y.y.y.y.y.y.7.7.: : ^+i } ",
"8+9+0+0+a+0+0+b+a+0+0+b+a+0+0+b+a+0+0+c+d+e+f+g+h+i+j+k+l+m+n+o+4.4.4.4.5.5.5.5.5.5.Y.Y.5.5.Y.Y.Y.Y.Y.Y.Y.Y.Y.Y.Y.Y.Y.Y.Y.Y.Y.Y.Y.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Y.Y.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.7.7.: : p+z.Y ",
"q+r+r+s+t+u+v+w+t+u+v+w+t+u+v+w+t+u+x+&+y+z+A+B+C+D+E+5+F+G+~+4.4.4.4.5.5.5.5.5.H+Y.Y.Y.Y.Y.Y.Y.Y.I+Y.Z.Y.Y.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.7.7.: : `.z.A.",
"J+v+K+L+M+N+O+P+Q+R+O+P+Q+R+O+P+Q+R+O+S+T+U+V+W+X+Y+P.T Z+`+ @4.4..@5.5.5.5.5.5.Y.Y.Y.I+I+I+I+I++@+@Z.Z.Y.Y.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.@@Z.7.7.: : p+z.Y ",
"#@$@$@%@%@$@#@&@#@#@#@&@#@#@#@&@#@#@#@*@=@-@;+i+;@>@,@'@)@ @4.X.5.5.H+Y.Y.Y.!@Y.Y.I++@+@Z.Z.+@Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.y.Z.6.6.: : `.z.A.",
"#@$@~@~@~@{@]@^@/@{@]@^@/@{@]@^@/@{@]@(@_@:@<@[@}@k+|@V 1@2@3@5.5.5.Y.Y.I+4@I+5@+@Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.y.Z.6.6.: : p+z.Y ",
"6@7@8@9@0@a@b@c@a@a@b@c@a@a@b@c@a@a@b@d@e@<@f@g@h@i@j@k@l@m@n@o@o@p@Y.I+q@q@r@+@Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.y.Z.6.6.: : `.z.A.",
"s@t@u@_@_@v@w@w@x@v@w@w@x@v@y@y@x@v@:@z@A@B@P C@D@E@F@G@H@I@J@K@5@+@+@+@r@I+L@Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.@@Z.W W : : p+z.Y ",
"M@N@O@P@C+Q@Q@R@C+;+Q@R@C+;+;+S@C+Q@Q@R@T@U@V@W@X@Y@Z@`@4. #.#+#Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.8.Z.Z.Z.Z.8.8.Z.Z.y.@@@@W W : : `.z.A.",
"@#O@O@##$#%#&#*#=#-#;#>#,#-#;#>#,#-#'#)#!#~#W@{#]#k@^#H@/#(#_#Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.8.8.Z.Z.Z.Z.Z.Z.Z.8.8.8.8.8.8.8.8.8.8.8.Z.Z.y.y.@@W W : : p+z.Y ",
":#<#[#}#|#1#2#3#4#5#1#4#4#1#1#4#4#1#1#6#7#8#9#V 0#`+a#b#c#d#e#Z.Z.Z.f#Z.Z.Z.f#f#f#f#f#f#f#f#f#f#g#g#g#g#g#8.8.8.8.8.8.8.8.8.g#g#g#g#8.g#8.8.8.8.8.8.8.8.8.8.8.8.8.8.8.8.8.8.8.8.8.8.y.y.@@W W : : `.z.A.",
"h#2#i#6#|#j#7#k#|#j#7#7#|#j#7#7#|#j#7#l#8#m#n#n#o#p#q#r#s#d#e#Z.Z.Z.f#f#f#f#Z.f#f#g#g#g#g#g#g#g#g#g#g#g#g#8.8.8.g#g#8.8.8.8.8.8.8.8.8.8.8.8.8.8.8.8.8.8.8.8.8.8.8.8.8.y.y.y.y.8.8.8.y.y.@@W W : : p+z.Y ",
"l#7#7#l#7#7#7#W@7#7#7#W@7#7#k#W@t#7#7#W@u#v#n#w#x#y#z#A#B#Z.e#f#f#Z.f#f#f#Z.Z.g#g#g#g#g#g#g#g#g#g#g#g#g#g#g#g#g#g#g#g#g#g#g#8.8.8.g#g#g#g#8.8.g#g#g#g#g#g#8.8.g#8.8.y.8.8.y.y.8.y.y.y.y.@@W W : : `.z.A.",
"C#D#E#F#G#H#I#J#G#H#I#J#G#H#I#J#G#H#I#J#K#L#M#N#O#P#s#Q#+#f#R#f#f#f#f#g#g#g#g#g#g#g#g#g#g#g#g#g#g#g#g#g#g#g#g#g#g#g#g#g#g#g#g#g#g#g#g#g#g#g#g#g#g#g#g#g#g#g#g#g#g#g#g#g#g#@@@@y.y.@@@@y.y.W W : : p+z.Y ",
"S#S#S#S#S#T#S#U#S#T#S#U#S#T#S#U#S#T#S#U#V#W#X#Y#Z#`# $.$+$@$#$g#g#g#g#g#g#g#g#g#g#g#g#g#g#g#g#g#g#g#g#g#g#g#g#g#g#g#g#g#g#g#g#g#g#g#g#g#g#g#g#g#g#g#g#g#g#g#g#g#g#g#@@@@@@@@@@@@@@@@@@y.y.W W : : `.z.A.",
"+$Z..$$$%$+$&$*$%$+$&$*$%$+$&$*$%$+$&$*$=$-$;$>$,$'$)$!$~${$]$^$^$^$^$^$^$^$^$^$^$^$^$^$^$^$^$^$^$^$^$^$^$^$^$^$^$^$^$^$^$^$^$^$^$^$^$^$^$^$^$^$^$^$^$^$^$^$^$^$^$^$^$^$^$^$^$/$/$/$/$($($_$_$:$:$p+z.Y ",
"<$<$<$<$<$[$}$|$<$[$}$|$<$[$}$|$<$[$}$|$1$2$3$4$5$)$6$7$8$9$0$a$a$a$a$a$^$^$^$^$^$^$^$^$^$^$^$^$^$^$^$^$^$^$^$^$^$^$^$^$^$^$^$^$^$^$^$^$^$^$^$/$/$/$^$^$^$/$/$/$/$/$/$/$/$/$/$/$/$/$/$($($_$_$:$:$`.z.A.",
"b$c$c$c$d$e$e$f$g$|$|$1$d$e$e$1$d$e$e$1$h$i$j$k$l$m$n$o$p$9$q$a$a$a$a$a$a$a$a$^$a$a$^$^$^$^$^$^$a$r$r$r$^$^$^$^$^$^$^$^$^$^$^$^$^$^$^$^$^$^$/$/$/$/$/$/$/$/$/$/$/$/$/$/$/$/$/$/$/$/$/$($($_$_$:$:$p+z.Y ",
"e$1$s$s$1$t$u$v$w$x$y$z$A$x$u$v$g$B$C$>$D$E$F$G$H$I$J$K$L$M$N$a$a$a$a$a$a$a$a$^$r$r$a$^$^$^$a$r$r$r$r$r$/$^$r$^$^$^$/$/$/$/$/$/$/$/$/$/$/$/$/$/$/$/$/$/$/$/$/$/$/$/$/$/$/$/$/$/$/$/$/$O$($_$_$:$:$`.z.A.",
"P$Q$R$S$T$U$V$W$X$Y$Z$W$`$ %.%W$+%U$@%#%$%%%&%($*%=%-%;%>%>%,%r$r$r$r$r$a$a$a$/$/$/$r$r$r$r$r$r$/$/$/$/$/$/$/$/$/$/$/$/$/$/$/$/$/$/$/$/$/$/$/$/$/$/$/$/$/$/$/$/$/$/$/$/$/$/$/$/$/$/$/$O$($_$_$:$:$p+z.Y ",
"'%W$)%!%~%{%'%]%~%^%'%]%~%^%'%]%~%^%/%(%_%&%:%<%[%}%|%1%2%3%4%r$r$r$r$r$r$r$r$r$r$r$r$r$r$r$r$r$/$r$/$/$r$r$r$/$/$/$/$/$/$/$/$/$/$/$/$/$/$/$/$/$/$/$/$/$/$/$/$/$/$/$/$/$/$r$/$/$/$/$/$O$($_$_$:$:$`.z.A.",
"5%6%'%'%6%7%8%9%6%7%8%9%6%7%8%9%6%7%8%0%&%a%<%b%[%c%d%e%f%g%h%r$r$r$r$r$r$r$r$r$r$r$r$r$r$r$/$r$r$r$r$r$r$r$r$r$r$r$r$r$r$r$r$r$r$r$r$/$/$/$/$/$/$/$/$/$/$/$/$/$/$r$r$/$/$r$r$/$r$i%j%O$($_$_$:$:$p+z.Y ",
"k%l%m%n%o%o%p%q%o%o%r%q%o%o%r%q%o%o%p%q%s%t%/$u%v%w%x%y%z%A%B%r$r$r$r$r$r$r$r$r$r$r$r$r$r$r$r$r$r$r$r$r$r$/$/$/$/$/$/$/$r$r$i%i%i%r$r$i%i%i%i%i%i%i%i%i%i%i%i%r$/$/$j%j%j%j%j%j%j%j%j%O$($_$_$:$:$`.z.A.",
"C%D%E%F%G%H%I%J%K%H%I%J%K%H%I%J%K%H%I%J%L%M%N%O%P%Q%R%S%T%A%B%r$r$r$r$r$r$r$r$r$r$r$r$r$r$r$U%U%r$r$i%i%/$/$r$r$/$/$/$/$r$r$i%i%i%i%i%i%i%i%i%i%i%i%i%i%j%i%j%j%j%j%j%j%j%j%j%j%j%j%j%O$($_$_$:$:$p+z.Y ",
"/$/$/$/$V%V%W%X%W%Y%Y%Z%W%W%Y%Z%W%W%W%`%`% &B%.&+&@&#&$&%&A%B%r$r$r$U%U%U%U%r$U%U%U%U%U%U%U%U%U%U%i%i%i%i%i%i%i%i%/$/$/$i%i%i%i%i%i%i%i%i%j%j%j%j%i%i%i%i%i%j%j%j%i%i%j%j%j%j%j%j%j%j%O$($_$_$:$:$`.z.A.",
"&&*&=&-&=&;&>&,&=&;&>&,&=&;&>&,&=&;&>&'&)&!&~&{&]&^&/&(&_&:&<&U%U%U%U%U%U%U%U%U%U%U%U%U%i%i%U%U%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%O$($_$_$:$:$p+z.Y ",
"U%U%U%U%U%U%U%U%U%U%U%U%U%U%U%U%U%U%U%U%[&}&|&1&2&3&4&5&_&6&U%7&U%U%U%U%U%U%U%U%i%i%U%U%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%O$O$_$_$:$:$`.z.A.",
"U%U%U%U%U%U%[&8&U%9&[&0&U%9&[&0&U%9&[&a&:&b&c&d&e&f&g&h&i&<&j&U%U%U%U%U%U%U%U%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%O$O$_$_$:$:$p+z.Y ",
"k&l&m&7&7&n&o&p&7&n&q&r&s&s&q&r&s&n&o&p&t&u&u&g&v&w&x&q&n&m&y&7&7&U%U%7&z&7&z&U%A&B&i%i%B&B&i%i%B&B&B&B&B&B&B&B&B&B&B&B&B&B&B&B&B&B&B&B&B&B&B&B&B&B&B&B&B&B&B&B&B&B&B&B&B&B&B&B&B&i%B&O$O$_$_$:$:$`.z.A.",
"C&D&E&z&z&E&F&G&z&E&F&G&z&E&F&G&z&E&F&G&H&I&J&K&L&M&N&O&P&Q&z&z&z&z&z&z&z&z&z&z&z&z&B&B&B&B&B&B&B&B&B&B&B&B&B&B&B&B&B&B&B&B&B&B&B&B&B&B&B&B&B&B&B&B&B&B&B&B&B&B&B&B&B&B&B&B&B&B&B&B&B&O$O$_$_$:$:$p+z.Y ",
"z&z&z&z&R&S&T&U&R&S&T&U&R&S&T&U&R&S&T&U&V&V&W&X&Y&Z&`&C&R&z&z&z&z&z&z&z&z&z&z&B&B&B&B&B&B&B&B&B&B&B&B&B&B&B&B&B&B&B&B&B&B&B&B&B&B&B&B&B&B&B&B&B&B&B&B&B&B&B&B&B&B&B&B&B&B&B&B&B&B&B&B&O$O$_$_$:$:$^+z.A.",
"z& *.*+*@*#*$*%*@*#*$*%*@*#*$*%*@*#*$*%*&***=*-*;*>*k&P&+*z&z&z&z&z&z&z&z&z&z&z&z&z&z&z&z&z&z&z&z&z&z&z&z&z&z&z&z&z&z&z&B&B&B&B&z&z&z&B&B&B&z&B&B&B&B&B&B&B&B&B&B&B&B&B&B&B&B&B&B&/$O$O$@@_$,*:$/ ^+z.Y ",
"'*'*'*'*'*'*'*'*'*'*'*'*'*'*'*'*'*'*'*'*'*'*'*'*'*'*)*'*!*~*{*]*^*^*^*/*/*/*/*/*/*/*^*/*/*/*/*/*/*/*/*/*/*/*/*/*/*/*/*/*^*/*/*/*/*/*h h ^*h h ^*^*h h ^*^*^*^*h ^*^*^*^*h ^*^*^*(*_*_*_*_*_$:*:$<*`.z.} ",
"'*'*'*'*'*[*}*|*'*[*}*|*'*[*}*|*'*[*}*|*1*1*2*}*}*2*[*)*3*4*5*/*/*/*/*/*/*/*/*/*/*/*/*/*/*/*/*/*/*/*/*/*/*/*/*/*/*/*/*/*/*/*/*/*/*/*/*/*/*/*h h h h h h h h h h h h h h h h 6*7*_*_*_*_*^*:*:$: 8*z.Y } ",
"9*9*9*9*9*9*9*9*9*9*9*9*9*9*9*9*9*9*9*9*9*9*9*9*9*9*9*9*9*9*9*9*9*9*9*9*9*9*9*0*0*0*0*0*0*0*0*0*0*0*0*0*0*0*0*0*0*0*0*0*0*0*0*0*0*0*0*0*0*0*0*0*0*0*0*0*0*0*0*0*0*0*0*0*0*0*0*0*0*0*0*0*( <*8*^+z.Y } 1 ",
"a*a*a*a*a*a*a*a*a*a*a*a*a*a*a*a*a*a*a*a*a*a*a*a*a*a*a*a*a*a*a*8*b*8*b*8*b*8*b*b*8*b*8*b*8*b*8*b*8*b*8*b*8*b*8*b*8*b*8*b*8*b*8*b*8*b*8*b*8*b*8*b*8*b*8*b*8*b*8*b*8*b*8*b*8*b*8*b*8*8*8*8*b*8*`.z.A.Y | | ",
"c*c*c*c*c*c*c*c*c*c*c*c*c*c*c*c*c*c*c*c*c*c*c*c*c*c*c*c*c*c*c*p+`.p+`.p+`.p+`.`.p+`.p+`.p+`.p+`.p+`.p+`.p+`.p+`.p+`.p+`.p+`.p+`.p+`.p+`.p+`.p+`.p+`.p+`.p+`.p+`.p+`.p+`.p+`.p+`.p+^+`.^+^+z.z.Y Y | | 1 ",
"d*d*d*d*d*d*d*d*d*d*d*d*d*d*d*d*d*d*d*d*d*d*d*d*d*d*d*d*d*d*d*A.Y A.Y A.Y A.Y Y A.Y A.Y A.Y A.Y A.Y A.Y A.Y A.Y A.Y A.Y A.Y A.Y A.Y A.Y A.Y A.Y A.Y A.Y A.Y A.Y A.Y A.Y A.Y A.Y A.Y A.Y } } | | | | 1 1 ",
"e*e*e*e*e*e*e*e*e*e*e*e*e*e*e*e*e*e*e*e*e*e*e*e*e*e*e*e*e*e*e*} | } | } | } | | } | } | } | } | } | } | } | } | } | } | } | } | } | } | } | } | } | } | } | } | } | } | } | } | } | | | | 1 | | | 1 1 1 "};
static char * tabmiddle_xpm[] = {
"33 42 32 1",
" c None",
". c #CECFEF",
"+ c #CECBE7",
"@ c #C6C7E7",
"# c #C6CBE7",
"$ c #BDBEDE",
"% c #BDC3DE",
"& c #CECBEF",
"* c #B5B6D6",
"= c #ADAECE",
"- c #ADB2CE",
"; c #BDBAD6",
"> c #B5BAD6",
", c #C6C3DE",
"' c #ADAAC6",
") c #B5B2CE",
"! c #B5B6CE",
"~ c #A5A2BD",
"{ c #A5A6BD",
"] c #9C9EB5",
"^ c #9CA2BD",
"/ c #ADAEC6",
"( c #C6C3E7",
"_ c #9C9AB5",
": c #A5A6C6",
"< c #949AAD",
"[ c #A5AAC6",
"} c #9496AD",
"| c #BDBADE",
"1 c #BDBED6",
"2 c #9CA2B5",
"3 c #A5AABD",
"..........................+@.#.#.",
"........................$@%&#.#..",
"......................**$$@@&#.#.",
".....................=-;>,%+@.#..",
"....................'')!$$@@&#.#.",
"...................~{=)$$@@&#.#..",
"..................]^'/;;(%&#.#...",
"................._]:/*>,%&@.#.#..",
".................<{[)!$%+@.#.#...",
"................}~{=!$%@@.#......",
"................]^/-|$@@.#.......",
"................]'/*;@@&#........",
"...............<~[)>,%&#.#.......",
"...............]~=)$%+#.#........",
"...............]'/;1@@.#.........",
"...............~{)*,%&#..........",
"...............2/-$$@#...........",
"...............~[*>(@&#..........",
"...............^=)$%+#...........",
"...............{'*>(@.#..........",
"...............^=)$%+#...........",
"...............{'*>(@.#..........",
"...............^=)$%+#...........",
"...............{'*>(@.#..........",
"...............^=)$%+#...........",
"...............{'*>(@.#..........",
"...............^=)$%+#...........",
"...............{'*>@@.#..........",
"...............^=!$%&#...........",
"...............{/*;@@.#..........",
"...............{)!$%&#...........",
"..............]'/;1@@.#..........",
"..............23)>,%&#...........",
"..............~=-$$@@.#..........",
".............]{/*;@@.#...........",
"............<^[)>,%&#............",
"............]{/!$%@@.#...........",
"..........]^[-!$%@@.#............",
".........]^3/!>$@@.#.............",
".......<]^3/!>$@@&#..............",
".....<]2{[/!>$%@&#.#.............",
"}<<_]2{3/-!>$%@&#.#.............."};
static char * tabselectedbeginn_xpm[] = {
"33 39 28 1",
" c None",
". c #CECFEF",
"+ c #EFF3EF",
"@ c #FFFBFF",
"# c #F7FBF7",
"$ c #FFFFFF",
"% c #EFEFEF",
"& c #F7F7F7",
"* c #DEDFDE",
"= c #E7E7E7",
"- c #D6D3D6",
"; c #DEE3DE",
"> c #EFEBEF",
", c #F7F3F7",
"' c #CECBCE",
") c #CECFCE",
"! c #D6D7D6",
"~ c #DEDBDE",
"{ c #E7EBE7",
"] c #C6C7C6",
"^ c #E7E3E7",
"/ c #BDC3BD",
"( c #CED3CE",
"_ c #BDBABD",
": c #C6C3C6",
"< c #C6CBC6",
"[ c #D6DBD6",
"} c #BDBEBD",
"..........................+@#$#$$",
"........................%%&&@#$#$",
"......................*==%%&&@#$$",
"....................--*;>%,&@#$#$",
"...................')!~={,+@#$#$$",
"...................]-!^=%%&&@#$#$",
"................../'(~;>%&&@#$#$$",
"................._])!*={,&@#$#$$$",
"................_])~*>%&&$#$$$$$$",
"................:<!^{,&@#$$$$$$$$$$",
"..............])~;%+@#$$$$$$$$$$$",
"..............]-[={&&$#$$$$$$$$$$",
".............])!^=,&@#$$$$$$$$$$$",
"............:'-*^%+@#$$$$$$$$$$$$",
"............])~*>%&&$#$$$$$$$$$$$",
"...........:'!*={,&@#$$$$$$$$$$$$",
"..........:'-~^=,+@#$$$$$$$$$$$$$",
".......}]'-~^=%,&@#$$$$$$$$$$$$$$",
".....}:])-~^=%,+@#$#$$$$$$$$$$$$$",
"}}}:]')-!*^=%,&@#$#$$$$$$$$$$$$$$"};
static char * tabselectedend_xpm[] = {
"33 42 33 1",
" c None",
". c #FFFFFF",
"+ c #CECBE7",
"@ c #C6C7E7",
"# c #CECFEF",
"$ c #C6CBE7",
"% c #BDBEDE",
"& c #BDC3DE",
"* c #CECBEF",
"= c #B5B6D6",
"- c #ADAECE",
"; c #ADB2CE",
"> c #BDBAD6",
", c #B5BAD6",
"' c #C6C3DE",
") c #ADAAC6",
"! c #B5B2CE",
"~ c #B5B6CE",
"{ c #A5A2BD",
"] c #A5A6BD",
"^ c #9C9EB5",
"/ c #9CA2BD",
"( c #ADAEC6",
"_ c #C6C3E7",
": c #9C9AB5",
"< c #A5A6C6",
"[ c #949AAD",
"} c #A5AAC6",
"| c #9496AD",
"1 c #BDBADE",
"2 c #BDBED6",
"3 c #9CA2B5",
"4 c #A5AABD",
"..........................+@#$#$#",
"........................%@&*$#$##",
"......................==%%@@*$#$#",
".....................-;>,'&+@#$##",
"....................))!~%%@@*$#$#",
"...................{]-!%%@@*$#$##",
"..................^/)(>>_&*$#$###",
".................:^<(=,'&*@#$#$##",
".................[]}!~%&+@#$#$###",
"................|{]-~%&@@#$######",
"................^/(;1%@@#$#######",
"................^)(=>@@*$########",
"...............[{}!,'&*$#$#######",
"...............^{-!%&+$#$########",
"...............^)(>2@@#$#########",
"...............{]!='&*$##########",
"...............3(;%%@$###########",
"...............{}=,_@*$##########",
".............../-!%&+$###########",
"...............])=,_@#$##########",
".............../-!%&+$###########",
"...............])=,_@#$##########",
".............../-!%&+$###########",
"...............])=,_@#$##########",
".............../-!%&+$###########",
"...............])=,_@#$##########",
".............../-!%&+$###########",
"...............])=,@@#$##########",
".............../-~%&*$###########",
"...............](=>@@#$##########",
"...............]!~%&*$###########",
"..............^)(>2@@#$##########",
"..............34!,'&*$###########",
"..............{-;%%@@#$##########",
".............^](=>@@#$###########",
"............[/}!,'&*$############",
"............^](~%&@@#$###########",
"..........^/};~%&@@#$############",
".........^/4(~,%@@#$#############",
".......[^/4(~,%@@*$##############",
".....[^3]}(~,%&@*$#$#############",
"|[[:^3]4(;~,%&@*$#$##############"};
static char * tabend_xpm[] = {
"33 42 3 1",
" c None",
". c #CECFEF",
"+ c #FFFFFF",
"..........................+++++++",
"........................+++++++++",
"......................+++++++++++",
".....................++++++++++++",
"....................+++++++++++++",
"...................++++++++++++++",
"..................+++++++++++++++",
".................++++++++++++++++",
".................++++++++++++++++",
"................+++++++++++++++++",
"................+++++++++++++++++",
"................+++++++++++++++++",
"...............++++++++++++++++++",
"...............++++++++++++++++++",
"...............++++++++++++++++++",
"...............++++++++++++++++++",
"...............++++++++++++++++++",
"...............++++++++++++++++++",
"...............++++++++++++++++++",
"...............++++++++++++++++++",
"...............++++++++++++++++++",
"...............++++++++++++++++++",
"...............++++++++++++++++++",
"...............++++++++++++++++++",
"...............++++++++++++++++++",
"...............++++++++++++++++++",
"...............++++++++++++++++++",
"...............++++++++++++++++++",
"...............++++++++++++++++++",
"...............++++++++++++++++++",
"...............++++++++++++++++++",
"..............+++++++++++++++++++",
"..............+++++++++++++++++++",
"..............+++++++++++++++++++",
".............++++++++++++++++++++",
"............+++++++++++++++++++++",
"............+++++++++++++++++++++",
"..........+++++++++++++++++++++++",
".........++++++++++++++++++++++++",
".......++++++++++++++++++++++++++",
".....++++++++++++++++++++++++++++",
"+++++++++++++++++++++++++++++++++"};
QColor fromHsl(QColor c)
{
const qreal h = c.hueF();
const qreal s = c.saturationF();
const qreal l = c.valueF();
qreal ca[3] = {0, 0, 0};
if (s == 0 || h == 1) {
// achromatic case
ca[0] = ca[1] = ca[2] = l;
} else {
// chromatic case
qreal temp2;
if (l < qreal(0.5))
temp2 = l * (qreal(1.0) + s);
else
temp2 = l + s - (l * s);
const qreal temp1 = (qreal(2.0) * l) - temp2;
qreal temp3[3] = { h + (qreal(1.0) / qreal(3.0)),
h,
h - (qreal(1.0) / qreal(3.0)) };
for (int i = 0; i != 3; ++i) {
if (temp3[i] < qreal(0.0))
temp3[i] += qreal(1.0);
else if (temp3[i] > qreal(1.0))
temp3[i] -= qreal(1.0);
const qreal sixtemp3 = temp3[i] * qreal(6.0);
if (sixtemp3 < qreal(1.0))
ca[i] = ((temp1 + (temp2 - temp1) * sixtemp3));
else if ((temp3[i] * qreal(2.0)) < qreal(1.0))
ca[i] = (temp2);
else if ((temp3[i] * qreal(3.0)) < qreal(2.0))
ca[i] = temp1 + (temp2 -temp1) * (qreal(2.0) /qreal(3.0) - temp3[i]) * qreal(6.0);
else ca[i] = temp1;
}
}
return QColor::fromRgbF(ca[0], ca[1], ca[2]);
}
#define Q_MAX_3(a, b, c) ( ( a > b && a > c) ? a : (b > c ? b : c) )
#define Q_MIN_3(a, b, c) ( ( a < b && a < c) ? a : (b < c ? b : c) )
QColor toHsl(QColor c)
{
QColor color;
qreal h;
qreal s;
qreal l;
const qreal r = c.redF();
const qreal g = c.greenF();
const qreal b = c.blueF();
const qreal max = Q_MAX_3(r, g, b);
const qreal min = Q_MIN_3(r, g, b);
const qreal delta = max - min;
const qreal delta2 = max + min;
const qreal lightness = qreal(0.5) * delta2;
l = (lightness);
if (qFuzzyIsNull(delta)) {
// achromatic case, hue is undefined
h = 0;
s = 0;
} else {
// chromatic case
qreal hue = 0;
if (lightness < qreal(0.5))
s = ((delta / delta2));
else
s = ((delta / (qreal(2.0) - delta2)));
if (qFuzzyCompare(r, max)) {
hue = ((g - b) /delta);
} else if (qFuzzyCompare(g, max)) {
hue = (2.0 + (b - r) / delta);
} else if (qFuzzyCompare(b, max)) {
hue = (4.0 + (r - g) / delta);
} else {
Q_ASSERT_X(false, "QColor::toHsv", "internal error");
}
hue *= 60.0;
if (hue < 0.0)
hue += 360.0;
h = (hue * 100);
}
h = h / 36000;
return QColor::fromHsvF(h, s, l);
}
void tintColor(QColor &color, QColor tintColor, qreal _saturation)
{
tintColor = toHsl(tintColor);
color = toHsl(color);
qreal hue = tintColor.hueF();
qreal saturation = color.saturationF();
if (_saturation)
saturation = _saturation;
qreal lightness = color.valueF();
color.setHsvF(hue, saturation, lightness);
color = fromHsl(color);
color.toRgb();
}
void tintImagePal(QImage *image, QColor color, qreal saturation)
{
QVector<QRgb> colorTable = image->colorTable();
for (int i=2;i< colorTable.size();i++) {
QColor c(toHsl(colorTable.at(i)));
tintColor(c, color, saturation);
colorTable[i] = c.rgb();
}
image->setColorTable(colorTable);
}
void tintImage(QImage *image, QColor color, qreal saturation)
{
*image = image->convertToFormat(QImage::Format_RGB32);
for (int x = 0; x < image->width(); x++)
for (int y = 0; y < image->height(); y++) {
QColor c(image->pixel(x,y));
tintColor(c, color, saturation);
image->setPixel(x, y, c.rgb());
}
}
#endif //Q_WS_WINCE_WM
enum QSliderDirection { SliderUp, SliderDown, SliderLeft, SliderRight };
#ifdef Q_WS_WINCE_WM
void QWindowsMobileStylePrivate::tintImagesButton(QColor color)
{
if (currentTintButton == color)
return;
currentTintButton = color;
imageTabEnd = QImage(tabend_xpm);
imageTabSelectedEnd = QImage(tabselectedend_xpm);
imageTabSelectedBegin = QImage(tabselectedbeginn_xpm);
imageTabMiddle = QImage(tabmiddle_xpm);
tintImage(&imageTabEnd, color, 0.0);
tintImage(&imageTabSelectedEnd, color, 0.0);
tintImage(&imageTabSelectedBegin, color, 0.0);
tintImage(&imageTabMiddle, color, 0.0);
if (!doubleControls) {
int height = imageTabMiddle.height() / 2 + 1;
imageTabEnd = imageTabEnd.scaledToHeight(height);
imageTabMiddle = imageTabMiddle.scaledToHeight(height);
imageTabSelectedEnd = imageTabSelectedEnd.scaledToHeight(height);
imageTabSelectedBegin = imageTabSelectedBegin.scaledToHeight(height);
}
}
void QWindowsMobileStylePrivate::tintImagesHigh(QColor color)
{
if (currentTintHigh == color)
return;
currentTintHigh = color;
tintListViewHighlight(color);
imageScrollbarHandleUpHigh = imageScrollbarHandleUp;
imageScrollbarHandleDownHigh = imageScrollbarHandleDown;
tintImagePal(&imageScrollbarHandleDownHigh, color, qreal(0.8));
tintImagePal(&imageScrollbarHandleUpHigh, color, qreal(0.8));
}
void QWindowsMobileStylePrivate::tintListViewHighlight(QColor color)
{
imageListViewHighlightCornerRight = QImage(listviewhighcornerright_xpm);
tintImage(&imageListViewHighlightCornerRight, color, qreal(0.0));
imageListViewHighlightCornerLeft = QImage(listviewhighcornerleft_xpm);
tintImage(&imageListViewHighlightCornerLeft, color, qreal(0.0));
imageListViewHighlightMiddle = QImage(listviewhighmiddle_xpm);
tintImage(&imageListViewHighlightMiddle, color, qreal(0.0));
int height = imageListViewHighlightMiddle.height();
if (!doubleControls) {
height = height / 2;
imageListViewHighlightCornerRight = imageListViewHighlightCornerRight.scaledToHeight(height);
imageListViewHighlightCornerLeft = imageListViewHighlightCornerLeft.scaledToHeight(height);
imageListViewHighlightMiddle = imageListViewHighlightMiddle.scaledToHeight(height);
}
}
#endif //Q_WS_WINCE_WM
void QWindowsMobileStylePrivate::setupWindowsMobileStyle65()
{
#ifdef Q_WS_WINCE_WM
wm65 = qt_wince_is_windows_mobile_65();
if (wm65) {
imageScrollbarHandleUp = QImage(sbhandleup_xpm);
imageScrollbarHandleDown = QImage(sbhandledown_xpm);
imageScrollbarGripUp = QImage(sbgripup_xpm);
imageScrollbarGripDown = QImage(sbgripdown_xpm);
imageScrollbarGripMiddle = QImage(sbgripmiddle_xpm);
if (!doubleControls) {
imageScrollbarHandleUp = imageScrollbarHandleUp.scaledToHeight(imageScrollbarHandleUp.height() / 2);
imageScrollbarHandleDown = imageScrollbarHandleDown.scaledToHeight(imageScrollbarHandleDown.height() / 2);
imageScrollbarGripMiddle = imageScrollbarGripMiddle.scaledToHeight(imageScrollbarGripMiddle.height() / 2);
imageScrollbarGripUp = imageScrollbarGripUp.scaledToHeight(imageScrollbarGripUp.height() / 2);
imageScrollbarGripDown = imageScrollbarGripDown.scaledToHeight(imageScrollbarGripDown.height() / 2);
} else {
}
tintImagesHigh(Qt::blue);
}
#endif //Q_WS_WINCE_WM
}
void QWindowsMobileStylePrivate::drawTabBarTab(QPainter *painter, const QStyleOptionTab *tab)
{
#ifndef QT_NO_TABBAR
#ifdef Q_WS_WINCE_WM
if (wm65) {
tintImagesButton(tab->palette.button().color());
QRect r;
r.setTopLeft(tab->rect.topRight() - QPoint(imageTabMiddle.width(), 0));
r.setBottomRight(tab->rect.bottomRight());
if (tab->state & QStyle::State_Selected) {
painter->fillRect(tab->rect, tab->palette.window());
} else {
painter->fillRect(tab->rect, QColor(imageTabMiddle.pixel(0,0)));
}
if (tab->selectedPosition == QStyleOptionTab::NextIsSelected) {
painter->drawImage(r, imageTabSelectedBegin);
} else if (tab->position == QStyleOptionTab::End ||
tab->position == QStyleOptionTab::OnlyOneTab) {
if (!(tab->state & QStyle::State_Selected)) {
painter->drawImage(r, imageTabEnd);
}
} else if (tab->state & QStyle::State_Selected) {
painter->drawImage(r, imageTabSelectedEnd);
} else {
painter->drawImage(r, imageTabMiddle);
}
if (tab->position == QStyleOptionTab::Beginning && ! (tab->state & QStyle::State_Selected)) {
painter->drawImage(tab->rect.topLeft() - QPoint(imageTabMiddle.width() * 0.60, 0), imageTabSelectedEnd);
}
//imageTabBarBig
return;
}
#endif //Q_WS_WINCE_WM
painter->save();
painter->setPen(tab->palette.shadow().color());
if (doubleControls) {
QPen pen = painter->pen();
pen.setWidth(2);
pen.setCapStyle(Qt::FlatCap);
painter->setPen(pen);
}
if(tab->shape == QTabBar::RoundedNorth) {
if (tab->state & QStyle::State_Selected) {
painter->fillRect(tab->rect, tab->palette.light());
painter->drawLine(tab->rect.topRight(), tab->rect.bottomRight());
}
else {
painter->fillRect(tab->rect, tab->palette.button());
painter->drawLine(tab->rect.bottomLeft() , tab->rect.bottomRight());
painter->drawLine(tab->rect.topRight(), tab->rect.bottomRight());
}
}
else if(tab->shape == QTabBar::RoundedSouth) {
if (tab->state & QStyle::State_Selected) {
painter->fillRect(tab->rect.adjusted(0,-2,0,0), tab->palette.light());
painter->drawLine(tab->rect.topRight(), tab->rect.bottomRight());
}
else {
painter->fillRect(tab->rect, tab->palette.button());
if (doubleControls)
painter->drawLine(tab->rect.topLeft() + QPoint(0,1), tab->rect.topRight() + QPoint(0,1));
else
painter->drawLine(tab->rect.topLeft(), tab->rect.topRight());
painter->drawLine(tab->rect.topRight(), tab->rect.bottomRight());
}
}
else if(tab->shape == QTabBar::RoundedEast) {
if (tab->state & QStyle::State_Selected) {
painter->fillRect(tab->rect, tab->palette.light());
painter->drawLine(tab->rect.topLeft(), tab->rect.topRight());
}
else {
painter->fillRect(tab->rect, tab->palette.button());
painter->drawLine(tab->rect.topLeft(), tab->rect.bottomLeft());
painter->drawLine(tab->rect.topLeft(), tab->rect.topRight());
}
}
else if(tab->shape == QTabBar::RoundedWest) {
if (tab->state & QStyle::State_Selected) {
painter->fillRect(tab->rect, tab->palette.light());
painter->drawLine(tab->rect.bottomLeft(), tab->rect.bottomRight());
}
else {
painter->fillRect(tab->rect, tab->palette.button());
painter->drawLine(tab->rect.topRight(), tab->rect.bottomRight());
painter->drawLine(tab->rect.bottomLeft(), tab->rect.bottomRight());
}
}
painter->restore();
#endif //QT_NO_TABBAR
}
void QWindowsMobileStylePrivate::drawPanelItemViewSelected(QPainter *painter, const QStyleOptionViewItemV4 *option, QRect rect)
{
#ifdef Q_WS_WINCE_WM
if (wm65) {
QRect r;
if (rect.isValid())
r = rect;
else
r = option->rect;
tintImagesHigh(option->palette.highlight().color());
painter->setPen(QColor(Qt::lightGray));
if (option->viewItemPosition == QStyleOptionViewItemV4::Middle) {
painter->drawImage(r, imageListViewHighlightMiddle);
} else if (option->viewItemPosition == QStyleOptionViewItemV4::Beginning) {
painter->drawImage(r.adjusted(10, 0, 0, 0), imageListViewHighlightMiddle);
} else if (option->viewItemPosition == QStyleOptionViewItemV4::End) {
painter->drawImage(r.adjusted(0, 0, -10, 0), imageListViewHighlightMiddle);
} else {
painter->drawImage(r.adjusted(10, 0, -10, 0), imageListViewHighlightMiddle);
}
QImage cornerLeft = imageListViewHighlightCornerLeft;
QImage cornerRight = imageListViewHighlightCornerRight;
int width = r.width() > cornerRight.width() ? r.width() : cornerRight.width();
if ((width * 2) > r.width()) {
width = (r.width() - 5) / 2;
}
cornerLeft = cornerLeft.scaled(width, r.height());
cornerRight = cornerRight.scaled(width, r.height());
if ((option->viewItemPosition == QStyleOptionViewItemV4::Beginning) || (option->viewItemPosition == QStyleOptionViewItemV4::OnlyOne) || !option->viewItemPosition) {
painter->drawImage(r.topLeft(), cornerLeft);
}
if ((option->viewItemPosition == QStyleOptionViewItemV4::End) || (option->viewItemPosition == QStyleOptionViewItemV4::OnlyOne) || !option->viewItemPosition) {
painter->drawImage(r.topRight() - QPoint(cornerRight.width(),0), cornerRight);
}
return;
}
#endif //Q_WS_WINCE_WM
QPalette::ColorGroup cg = option->state & QStyle::State_Enabled
? QPalette::Normal : QPalette::Disabled;
if (rect.isValid())
painter->fillRect(rect, option->palette.brush(cg, QPalette::Highlight));
else
painter->fillRect(option->rect, option->palette.brush(cg, QPalette::Highlight));
}
void QWindowsMobileStylePrivate::drawScrollbarGrip(QPainter *p, QStyleOptionSlider *newScrollbar, const QStyleOptionComplex *option, bool drawCompleteFrame)
{
#ifdef Q_WS_WINCE_WM
if (wm65) {
if (newScrollbar->orientation == Qt::Horizontal) {
QTransform transform;
transform.rotate(-90);
QRect r = newScrollbar->rect;
p->drawImage(r.adjusted(10, 0, -10, 0), imageScrollbarGripMiddle.transformed(transform));
p->drawImage(r.topLeft(), imageScrollbarGripUp.transformed(transform));
p->drawImage(r.topRight() - QPoint(imageScrollbarGripDown.height() - 1, 0), imageScrollbarGripDown.transformed(transform));
} else {
QRect r = newScrollbar->rect;
p->drawImage(r.adjusted(0, 10, 0, -10), imageScrollbarGripMiddle);
p->drawImage(r.topLeft(), imageScrollbarGripUp);
p->drawImage(r.bottomLeft() - QPoint(0, imageScrollbarGripDown.height() - 1), imageScrollbarGripDown);
}
return ;
}
#endif
if (newScrollbar->orientation == Qt::Horizontal) {
p->fillRect(newScrollbar->rect,option->palette.button());
QRect r = newScrollbar->rect;
p->drawLine(r.topLeft(), r.bottomLeft());
p->drawLine(r.topRight(), r.bottomRight());
if (smartphone) {
p->drawLine(r.topLeft(), r.topRight());
p->drawLine(r.bottomLeft(), r.bottomRight());
}
}
else {
p->fillRect(newScrollbar->rect,option->palette.button());
QRect r = newScrollbar->rect;
p->drawLine(r.topLeft(), r.topRight());
p->drawLine(r.bottomLeft(), r.bottomRight());
if (smartphone) {
p->drawLine(r.topLeft(), r.bottomLeft());
p->drawLine(r.topRight(), r.bottomRight());
}
}
if (newScrollbar->state & QStyle::State_HasFocus) {
QStyleOptionFocusRect fropt;
fropt.QStyleOption::operator=(*newScrollbar);
fropt.rect.setRect(newScrollbar->rect.x() + 2, newScrollbar->rect.y() + 2,
newScrollbar->rect.width() - 5,
newScrollbar->rect.height() - 5);
}
int gripMargin = doubleControls ? 4 : 2;
int doubleLines = doubleControls ? 2 : 1;
//If there is a frame around the scrollbar (abstractScrollArea),
//then the margin is different, because of the missing frame
int gripMarginFrame = doubleControls ? 3 : 1;
if (drawCompleteFrame)
gripMarginFrame = 0;
//draw grips
if (!smartphone)
if (newScrollbar->orientation == Qt::Horizontal) {
for (int i = -3; i < 3; i += 2) {
p->drawLine(
QPoint(newScrollbar->rect.center().x() + i * doubleLines + 1,
newScrollbar->rect.top() + gripMargin +gripMarginFrame),
QPoint(newScrollbar->rect.center().x() + i * doubleLines + 1,
newScrollbar->rect.bottom() - gripMargin));
}
} else {
for (int i = -2; i < 4 ; i += 2) {
p->drawLine(
QPoint(newScrollbar->rect.left() + gripMargin + gripMarginFrame ,
newScrollbar->rect.center().y() + 1 + i * doubleLines - 1),
QPoint(newScrollbar->rect.right() - gripMargin,
newScrollbar->rect.center().y() + 1 + i * doubleLines - 1));
}
}
if (!smartphone) {
QRect r;
if (doubleControls)
r = option->rect.adjusted(1, 1, -1, 0);
else
r = option->rect.adjusted(0, 0, -1, 0);
if (drawCompleteFrame && doubleControls)
r.adjust(0, 0, 0, -1);
//Check if the scrollbar is part of an abstractItemView and draw the frame according
if (drawCompleteFrame)
p->drawRect(r);
else
if (newScrollbar->orientation == Qt::Horizontal)
p->drawLine(r.topLeft(), r.topRight());
else
p->drawLine(r.topLeft(), r.bottomLeft());
}
}
void QWindowsMobileStylePrivate::drawScrollbarHandleUp(QPainter *p, QStyleOptionSlider *opt, bool completeFrame, bool )
{
#ifdef Q_WS_WINCE_WM
if (wm65) {
tintImagesHigh(opt->palette.highlight().color());
QRect r = opt->rect;
if (opt->orientation == Qt::Horizontal) {
QTransform transform;
transform.rotate(-90);
if (opt->state & QStyle::State_Sunken)
p->drawImage(r.topLeft(), imageScrollbarHandleUpHigh.transformed(transform));
else
p->drawImage(r.topLeft(), imageScrollbarHandleUp.transformed(transform));
} else {
if (opt->state & QStyle::State_Sunken)
p->drawImage(r.topLeft(), imageScrollbarHandleUpHigh);
else
p->drawImage(r.topLeft(), imageScrollbarHandleUp);
}
return ;
}
#endif //Q_WS_WINCE_WM
QBrush fill = opt->palette.button();
if (opt->state & QStyle::State_Sunken)
fill = opt->palette.shadow();
QStyleOption arrowOpt = *opt;
if (doubleControls)
arrowOpt.rect = opt->rect.adjusted(4, 6, -5, -3);
else
arrowOpt.rect = opt->rect.adjusted(5, 6, -4, -3);
bool horizontal = (opt->orientation == Qt::Horizontal);
if (horizontal) {
p->fillRect(opt->rect,fill);
QRect r = opt->rect.adjusted(0,0,1,0);
p->drawLine(r.topRight(), r.bottomRight());
if (doubleControls)
arrowOpt.rect.adjust(0, -2 ,0, -2);
q_func()->proxy()->drawPrimitive(QStyle::PE_IndicatorArrowLeft, &arrowOpt, p, 0);
} else {
p->fillRect(opt->rect,fill);
QRect r = opt->rect.adjusted(0, 0, 0, 1);
p->drawLine(r.bottomLeft(), r.bottomRight());
if (completeFrame)
arrowOpt.rect.adjust(-2, 0, -2, 0);
if (doubleControls)
arrowOpt.rect.adjust(0, -4 , 0, -4);
if (completeFrame && doubleControls)
arrowOpt.rect.adjust(2, 0, 2, 0);
q_func()->proxy()->drawPrimitive(QStyle::PE_IndicatorArrowUp, &arrowOpt, p, 0);
}
}
void QWindowsMobileStylePrivate::drawScrollbarHandleDown(QPainter *p, QStyleOptionSlider *opt, bool completeFrame, bool secondScrollBar)
{
#ifndef QT_NO_SCROLLBAR
#ifdef Q_WS_WINCE_WM
if (wm65) {
tintImagesHigh(opt->palette.highlight().color());
QRect r = opt->rect;
if (opt->orientation == Qt::Horizontal) {
QTransform transform;
transform.rotate(-90);
if (opt->state & QStyle::State_Sunken)
p->drawImage(r.topLeft(), imageScrollbarHandleDownHigh.transformed(transform));
else
p->drawImage(r.topLeft(), imageScrollbarHandleDown.transformed(transform));
} else {
if (opt->state & QStyle::State_Sunken)
p->drawImage(r.topLeft(), imageScrollbarHandleDownHigh);
else
p->drawImage(r.topLeft(), imageScrollbarHandleDown);
}
return ;
}
#endif //Q_WS_WINCE_WM
QBrush fill = opt->palette.button();
if (opt->state & QStyle::State_Sunken)
fill = opt->palette.shadow();
QStyleOption arrowOpt = *opt;
if (doubleControls)
arrowOpt.rect = opt->rect.adjusted(4, 0, -5, 3);
else
arrowOpt.rect = opt->rect.adjusted(5, 6, -4, -3);
bool horizontal = (opt->orientation == Qt::Horizontal);
if (horizontal) {
p->fillRect(opt->rect,fill);
QRect r = opt->rect.adjusted(0, 0, 0, 0);
p->drawLine(r.topLeft(), r.bottomLeft());
if (secondScrollBar)
p->drawLine(r.topRight(), r.bottomRight());
if (doubleControls)
arrowOpt.rect.adjust(0, 4, 0, 4 );
q_func()->proxy()->drawPrimitive(QStyle::PE_IndicatorArrowRight, &arrowOpt, p, 0);
} else {
p->fillRect(opt->rect,fill);
QRect r = opt->rect.adjusted(0, -1, 0, -1);
p->drawLine(r.topLeft(), r.topRight());
if (secondScrollBar)
p->drawLine(r.bottomLeft() + QPoint(0,1), r.bottomRight() + QPoint(0, 1));
if (completeFrame)
arrowOpt.rect.adjust(-2, 0, -2, 0);
if (doubleControls)
arrowOpt.rect.adjust(1, 0, 1, 0 );
if (completeFrame && doubleControls)
arrowOpt.rect.adjust(1, 0, 1, 0);
q_func()->proxy()->drawPrimitive(QStyle::PE_IndicatorArrowDown, &arrowOpt, p, 0);
}
#endif //QT_NO_SCROLLBAR
}
void QWindowsMobileStylePrivate::drawScrollbarGroove(QPainter *p,const QStyleOptionSlider *opt)
{
#ifndef QT_NO_SCROLLBAR
#ifdef Q_OS_WINCE_WM
if (wm65) {
p->fillRect(opt->rect, QColor(231, 231, 231));
return ;
}
#endif
QBrush fill;
if (smartphone) {
fill = opt->palette.light();
p->fillRect(opt->rect, fill);
fill = opt->palette.button();
QImage image;
#ifndef QT_NO_IMAGEFORMAT_XPM
if (opt->orientation == Qt::Horizontal)
image = QImage(vertlines_xpm);
else
image = QImage(horlines_xpm);
#endif
image.setColor(1, opt->palette.button().color().rgb());
fill.setTextureImage(image);
}
else {
fill = opt->palette.light();
}
p->fillRect(opt->rect, fill);
#endif //QT_NO_SCROLLBAR
}
QWindowsMobileStyle::QWindowsMobileStyle(QWindowsMobileStylePrivate &dd) : QWindowsStyle(dd) {
qApp->setEffectEnabled(Qt::UI_FadeMenu, false);
qApp->setEffectEnabled(Qt::UI_AnimateMenu, false);
}
QWindowsMobileStyle::QWindowsMobileStyle() : QWindowsStyle(*new QWindowsMobileStylePrivate) {
qApp->setEffectEnabled(Qt::UI_FadeMenu, false);
qApp->setEffectEnabled(Qt::UI_AnimateMenu, false);
}
QWindowsMobileStylePrivate::QWindowsMobileStylePrivate() :QWindowsStylePrivate() {
#ifdef Q_WS_WINCE
doubleControls = qt_wince_is_high_dpi();
smartphone = qt_wince_is_smartphone();
#else
doubleControls = false;
smartphone = false;
#endif //Q_WS_WINCE
#ifndef QT_NO_IMAGEFORMAT_XPM
imageArrowDown = QImage(arrowdown_xpm);
imageArrowUp = QImage(arrowdown_xpm).mirrored();
imageArrowLeft = QImage(arrowleft_xpm);
imageArrowRight = QImage(arrowleft_xpm).mirrored(true, false);
if (doubleControls) {
imageRadioButton = QImage(radiobutton_xpm);
imageRadioButtonChecked = QImage(radiochecked_xpm);
imageChecked = QImage(checkedlight_xpm);
imageCheckedBold = QImage(checkedbold_xpm);
imageRadioButtonHighlighted = QImage(highlightedradiobutton_xpm);
imageClose = QImage(cross_big_xpm);
imageMaximize = QImage(max_big_xpm);
imageMinimize = QImage(min_big_xpm);
imageNormalize = QImage(normal_big_xpm);
} else {
imageRadioButton = QImage(radiobutton_low_xpm);
imageRadioButtonChecked = QImage(radiochecked_low_xpm);
imageChecked = QImage(checkedlight_low_xpm);
imageCheckedBold = QImage(checkedbold_low_xpm);
imageRadioButtonHighlighted = QImage(highlightedradiobutton_low_xpm);
imageClose = QImage(cross_small_xpm);
imageMaximize = QImage(max_small_xpm);
imageMinimize = QImage(min_small_xpm);
imageNormalize = QImage(normal_small_xpm);
}
setupWindowsMobileStyle65();
imageArrowDownBig = QImage(arrowdown_big_xpm);
imageArrowUpBig = QImage(arrowdown_big_xpm).mirrored();
imageArrowLeftBig = QImage(arrowleft_big_xpm);
imageArrowRightBig = QImage(arrowleft_big_xpm).mirrored(true, false);
#endif
}
void QWindowsMobileStyle::drawPrimitive(PrimitiveElement element, const QStyleOption *option,
QPainter *painter, const QWidget *widget) const {
QWindowsMobileStylePrivate *d = const_cast<QWindowsMobileStylePrivate*>(d_func());
bool doRestore = false;
QRect rect = option->rect;
painter->setClipping(false);
switch (element) {
case PE_PanelButtonTool: {
int penSize = 1;
if (d->doubleControls)
penSize = 2;
if (widget)
if (QWidget *parent = widget->parentWidget())
#ifndef QT_NO_TABWIDGET
if (qobject_cast<QTabWidget *>(parent->parentWidget())) {
#else
if (false) {
#endif //QT_NO_TABBAR
rect.adjust(0,2*penSize,0,-1*penSize);
qDrawPlainRect(painter, rect, option->palette.shadow().color(), penSize, &option->palette.light());
if (option->state & (State_Sunken))
qDrawPlainRect(painter, rect, option->palette.shadow().color(), penSize, &option->palette.shadow());
}
else {
if (!(option->state & State_AutoRaise) || (option->state & (State_Sunken | State_On)))
qDrawPlainRect(painter,option->rect.adjusted(0, penSize, 0, -1 * penSize) ,
option->palette.button().color(), 0, &option->palette.button());
if (option->state & (State_Sunken)) {
qDrawPlainRect(painter, rect, option->palette.shadow().color(), penSize, &option->palette.light());
}
if (option->state & (State_On)){
QBrush fill = QBrush(option->palette.light().color());
painter->fillRect(rect.adjusted(windowsItemFrame , windowsItemFrame ,
-windowsItemFrame , -windowsItemFrame ), fill);
qDrawPlainRect(painter, rect, option->palette.shadow().color(), penSize, &option->palette.light());
}
}
break; }
case PE_IndicatorButtonDropDown:
if (d->doubleControls)
qDrawPlainRect(painter, option->rect, option->palette.shadow().color(), 2, &option->palette.button());
else
qDrawPlainRect(painter, option->rect, option->palette.shadow().color(), 1, &option->palette.button());
break;
#ifndef QT_NO_TABBAR
case PE_IndicatorTabTear:
if (const QStyleOptionTab *tab = qstyleoption_cast<const QStyleOptionTab *>(option)) {
bool rtl = tab->direction == Qt::RightToLeft;
QRect rect = tab->rect;
QPainterPath path;
rect.setTop(rect.top() + ((tab->state & State_Selected) ? 1 : 3));
rect.setBottom(rect.bottom() - ((tab->state & State_Selected) ? 0 : 2));
path.moveTo(QPoint(rtl ? rect.right() : rect.left(), rect.top()));
int count = 3;
for(int jags = 1; jags <= count; ++jags, rtl = !rtl)
path.lineTo(QPoint(rtl ? rect.left() : rect.right(), rect.top() + jags * rect.height()/count));
painter->setPen(QPen(tab->palette.light(), qreal(.8)));
painter->setBrush(tab->palette.background());
painter->setRenderHint(QPainter::Antialiasing);
painter->drawPath(path);
}
break;
#endif //QT_NO_TABBAR
#ifndef QT_NO_TOOLBAR
case PE_IndicatorToolBarSeparator: {
painter->save();
QPoint p1, p2;
if (option->state & State_Horizontal) {
p1 = QPoint(option->rect.width()/2, 0);
p2 = QPoint(p1.x(), option->rect.height());
} else {
p1 = QPoint(0, option->rect.height()/2);
p2 = QPoint(option->rect.width(), p1.y());
}
painter->setPen(option->palette.mid().color());
if (d->doubleControls) {
QPen pen = painter->pen();
pen.setWidth(2);
pen.setCapStyle(Qt::FlatCap);
painter->setPen(pen);
}
painter->drawLine(p1, p2);
painter->restore();
break; }
#endif // QT_NO_TOOLBAR
case PE_IndicatorToolBarHandle:
painter->save();
painter->translate(option->rect.x(), option->rect.y());
if (option->state & State_Horizontal) {
int x = option->rect.width() / 2 - 4;
if (QApplication::layoutDirection() == Qt::RightToLeft)
x -= 2;
if (option->rect.height() > 4) {
qDrawWinButton(painter,x-1,0,7,option->rect.height(), option->palette, false, 0);
qDrawShadePanel(painter, x, 1, 3, option->rect.height() - 1,
option->palette, false, 0);
qDrawShadePanel(painter, x + 3, 1, 3, option->rect.height() - 1,
option->palette, false, 0);
painter->setPen(option->palette.button().color());
}
} else {
if (option->rect.width() > 4) {
int y = option->rect.height() / 2 - 4;
qDrawShadePanel(painter, 2, y, option->rect.width() - 2, 3,
option->palette, false, 0);
qDrawShadePanel(painter, 2, y + 3, option->rect.width() - 2, 3,
option->palette, false, 0);
}
}
painter->restore();
break;
#ifndef QT_NO_PROGRESSBAR
case PE_IndicatorProgressChunk: {
bool vertical = false;
if (const QStyleOptionProgressBarV2 *pb2 = qstyleoption_cast<const QStyleOptionProgressBarV2 *>(option))
vertical = (pb2->orientation == Qt::Vertical);
if (!vertical) {
painter->fillRect(option->rect.x(), option->rect.y()+2, option->rect.width(), option->rect.height()-4,
option->palette.brush(QPalette::Highlight));
} else {
painter->fillRect(option->rect.x()+2, option->rect.y(), option->rect.width()-4, option->rect.height(),
option->palette.brush(QPalette::Highlight));
}
}
break;
#endif // QT_NO_PROGRESSBAR
case PE_FrameButtonTool: {
#ifndef QT_NO_DOCKWIDGET
if (widget && widget->inherits("QDockWidgetTitleButton")) {
if (const QDockWidget *dw = qobject_cast<const QDockWidget *>(widget->parent()))
if (dw->isFloating()){
qDrawPlainRect(painter,option->rect.adjusted(1, 1, 0, 0),
option->palette.shadow().color(),1,&option->palette.button());
return;
}
}
#endif // QT_NO_DOCKWIDGET
QBrush fill;
bool stippled;
bool panel = (element == PE_PanelButtonTool);
if ((!(option->state & State_Sunken ))
&& (!(option->state & State_Enabled)
|| ((option->state & State_Enabled ) && !(option->state & State_MouseOver)))
&& (option->state & State_On)) {
fill = QBrush(option->palette.light().color(), Qt::Dense4Pattern);
stippled = true;
} else {
fill = option->palette.brush(QPalette::Button);
stippled = false;
}
if (option->state & (State_Raised | State_Sunken | State_On)) {
if (option->state & State_AutoRaise) {
if(option->state & (State_Enabled | State_Sunken | State_On)){
if (panel)
qDrawPlainRect(painter, option->rect,option->palette.shadow().color(),d->doubleControls, &fill);
else
qDrawPlainRect(painter, option->rect,option->palette.shadow().color(),d->doubleControls, &fill);
}
if (stippled) {
painter->setPen(option->palette.button().color());
painter->drawRect(option->rect.adjusted(1, 1, -2, -2));
}
} else {
qDrawPlainRect(painter, option->rect,option->palette.shadow().color(),d->doubleControls, &fill);
}
} else {
painter->fillRect(option->rect, fill);
}
break; }
case PE_FrameFocusRect:
if (const QStyleOptionFocusRect *fropt = qstyleoption_cast<const QStyleOptionFocusRect *>(option)) {
//### check for d->alt_down
int penSize;
d->doubleControls ? penSize = 2 : penSize = 1;
bool alternateFocusStyle = false;
if (!widget)
alternateFocusStyle = true;
#ifndef QT_NO_COMBOBOX
if (qobject_cast<const QComboBox*>(widget))
alternateFocusStyle = true;
#endif
if (!(fropt->state & State_KeyboardFocusChange) && !styleHint(SH_UnderlineShortcut, option))
return;
QRect r = option->rect;
painter->save();
painter->setBackgroundMode(Qt::TransparentMode);
if (alternateFocusStyle) {
QColor bg_col = fropt->backgroundColor;
if (!bg_col.isValid())
bg_col = painter->background().color();
// Create an "XOR" color.
QColor patternCol((bg_col.red() ^ 0xff) & 0xff,
(bg_col.green() ^ 0xff) & 0xff,
(bg_col.blue() ^ 0xff) & 0xff);
painter->setBrush(QBrush(patternCol, Qt::Dense4Pattern));
painter->setBrushOrigin(r.topLeft());
}
else {
painter->setPen(option->palette.highlight().color());
painter->setBrush(option->palette.highlight());
}
painter->setPen(Qt::NoPen);
painter->setBrushOrigin(r.topLeft());
painter->drawRect(r.left(), r.top(), r.width(), penSize); // Top
painter->drawRect(r.left(), r.bottom(), r.width() + penSize - 1, penSize); // Bottom
painter->drawRect(r.left(), r.top(), penSize, r.height()); // Left
painter->drawRect(r.right(), r.top(), penSize, r.height()); // Right
painter->restore();
}
break;
case PE_PanelButtonBevel: {
QBrush fill;
bool panel = element != PE_FrameButtonBevel;
painter->setBrushOrigin(option->rect.topLeft());
if (!(option->state & State_Sunken) && (option->state & State_On))
fill = QBrush(option->palette.light().color(), Qt::Dense4Pattern);
else
fill = option->palette.brush(QPalette::Button);
if (option->state & (State_Raised | State_On | State_Sunken)) {
if (d->doubleControls)
qDrawPlainRect(painter, option->rect,option->palette.shadow().color(),2,&fill);
else
qDrawPlainRect(painter, option->rect,option->palette.shadow().color(),1,&fill);
} else {
if (panel)
painter->fillRect(option->rect, fill);
else
painter->drawRect(option->rect);
}
break; }
case PE_FrameGroupBox:
if (const QStyleOptionFrame *frame = qstyleoption_cast<const QStyleOptionFrame *>(option)) {
const QStyleOptionFrameV2 *frame2 = qstyleoption_cast<const QStyleOptionFrameV2 *>(option);
if (frame2 && !(frame2->features & QStyleOptionFrameV2::Flat)) {
QPen oldPen = painter->pen();
QRect r = frame->rect;
painter->setPen(frame->palette.shadow().color());
painter->fillRect(r.x(), r.y(), r.x() + r.width()-1,
r.y() + r.height() - windowsMobileFrameGroupBoxOffset,
frame->palette.light());
painter ->drawLine(r.topLeft() + QPoint(-2, 1), r.topRight()+ QPoint(0, 1));
if (d->doubleControls)
painter ->drawLine(r.topLeft() + QPoint(-2, 2), r.topRight()+ QPoint(0, 2));
painter->setPen(oldPen);
}
}
break;
case PE_IndicatorCheckBox: {
QBrush fill;
QRect r = d->doubleControls ? option->rect.adjusted(0,1,0,-1) : option->rect;
if (option->state & State_NoChange)
fill = QBrush(option->palette.shadow().color(), Qt::Dense4Pattern);
else if (option->state & State_Sunken)
fill = option->palette.button();
else if (option->state & State_Enabled)
fill = option->palette.base();
else
fill = option->palette.background();
painter->save();
doRestore = true;
if (d->doubleControls && (option->state & State_NoChange))
painter->fillRect(r, fill);
else
painter->fillRect(option->rect, fill);
painter->setPen(option->palette.shadow().color());
painter->drawLine(r.topLeft(), r.topRight());
painter->drawLine(r.topRight(), r.bottomRight());
painter->drawLine(r.bottomLeft(), r.bottomRight());
painter->drawLine(r.bottomLeft(), r.topLeft());
if (d->doubleControls) {
QRect r0 = r.adjusted(1, 1, -1, -1);
painter->drawLine(r0.topLeft(), r0.topRight());
painter->drawLine(r0.topRight(), r0.bottomRight());
painter->drawLine(r0.bottomLeft(), r0.bottomRight());
painter->drawLine(r0.bottomLeft(), r0.topLeft());
}
if (option->state & State_HasFocus) {
painter->setPen(option->palette.highlight().color());
QRect r2 = d->doubleControls ? r.adjusted(2, 2, -2, -2) : r.adjusted(1, 1, -1, -1);
painter->drawLine(r2.topLeft(), r2.topRight());
painter->drawLine(r2.topRight(), r2.bottomRight());
painter->drawLine(r2.bottomLeft(), r2.bottomRight());
painter->drawLine(r2.bottomLeft(), r2.topLeft());
if (d->doubleControls) {
QRect r3 = r2.adjusted(1, 1, -1, -1);
painter->drawLine(r3.topLeft(), r3.topRight());
painter->drawLine(r3.topRight(), r3.bottomRight());
painter->drawLine(r3.bottomLeft(), r3.bottomRight());
painter->drawLine(r3.bottomLeft(), r3.topLeft());
}
painter->setPen(option->palette.shadow().color());
}
//fall through...
}
case PE_IndicatorViewItemCheck:
case PE_Q3CheckListIndicator: {
if (!doRestore) {
painter->save();
doRestore = true;
}
if (element == PE_Q3CheckListIndicator || element == PE_IndicatorViewItemCheck) {
painter->setPen(option->palette.shadow().color());
if (option->state & State_NoChange)
painter->setBrush(option->palette.brush(QPalette::Button));
if (d->doubleControls) {
QRect r = QRect(option->rect.x(), option->rect.y(), windowsMobileitemViewCheckBoxSize * 2, windowsMobileitemViewCheckBoxSize * 2);
qDrawPlainRect(painter, r, option->palette.shadow().color(), 2);
} else {
QRect r = QRect(option->rect.x(), option->rect.y(), windowsMobileitemViewCheckBoxSize, windowsMobileitemViewCheckBoxSize);
qDrawPlainRect(painter, r, option->palette.shadow().color(), 1);
}
if (option->state & State_Enabled)
d->imageChecked.setColor(1, option->palette.shadow().color().rgba());
else
d->imageChecked.setColor(1, option->palette.dark().color().rgba());
if (!(option->state & State_Off)) {
if (d->doubleControls)
painter->drawImage(option->rect.x(), option->rect.y(), d->imageChecked);
else
painter->drawImage(option->rect.x() + 3, option->rect.y() + 3, d->imageChecked);
}
}
else {
if (option->state & State_NoChange)
d->imageCheckedBold.setColor(1, option->palette.dark().color().rgba());
else if (option->state & State_Enabled)
d->imageCheckedBold.setColor(1, option->palette.shadow().color().rgba());
else
d->imageCheckedBold.setColor(1, option->palette.dark().color().rgba());
if (!(option->state & State_Off)) {
if (d->doubleControls)
painter->drawImage(option->rect.x() + 2, option->rect.y(), d->imageCheckedBold);
else
painter->drawImage(option->rect.x() + 3, option->rect.y() + 3, d->imageCheckedBold);
}
}
if (doRestore)
painter->restore();
break; }
case PE_IndicatorRadioButton: {
painter->save();
if (option->state & State_HasFocus) {
d->imageRadioButtonHighlighted.setColor(1, option->palette.shadow().color().rgba());
d->imageRadioButtonHighlighted.setColor(2, option->palette.highlight().color().rgba());
painter->drawImage(option->rect.x(), option->rect.y(), d->imageRadioButtonHighlighted);
}
else {
d->imageRadioButton.setColor(1, option->palette.shadow().color().rgba());
painter->drawImage(option->rect.x(), option->rect.y(), d->imageRadioButton);
}
if (option->state & (State_Sunken | State_On)) {
if (option->state & State_Enabled)
d->imageRadioButtonChecked.setColor(1, option->palette.shadow().color().rgba());
else
d->imageRadioButtonChecked.setColor(1, option->palette.dark().color().rgba());
static const int offset = d->doubleControls ? 6 : 3;
painter->drawImage(option->rect.x() + offset, option->rect.y() + offset, d->imageRadioButtonChecked);
}
painter->restore();
break; }
case PE_PanelButtonCommand:
if (const QStyleOptionButton *button = qstyleoption_cast<const QStyleOptionButton *>(option)) {
QBrush fill;
State flags = option->state;
QPalette pal = option->palette;
QRect r = option->rect;
if ((flags & State_Sunken || flags & State_On) )
fill = pal.brush(QPalette::Shadow);
else
fill = pal.brush(QPalette::Button);
int singleLine = 1;
int doubleLine = 2;
if (d->doubleControls) {
singleLine = 2;
doubleLine = 4;
}
if (button->features & QStyleOptionButton::DefaultButton && flags & State_Sunken) {
if (d->doubleControls) {
qDrawPlainRect(painter, r, pal.shadow().color(), 1, &fill);
qDrawPlainRect(painter, r.adjusted(1, 1, -1, 1), pal.shadow().color(), 1, &fill);
}
else {
qDrawPlainRect(painter, r, pal.shadow().color(), 1, &fill);
}
} else if (flags & (State_Raised | State_Sunken | State_On | State_Sunken)) {
qDrawPlainRect(painter, r, pal.shadow().color(), singleLine, &fill);
} else {
painter->fillRect(r, fill);
}
}
break;
case PE_FrameDefaultButton: {
painter->save();
painter->setPen(option->palette.shadow().color());
QRect rect = option->rect;
if (d->doubleControls) {
rect.adjust(1, 1, -2, -2);
painter->drawRect(rect);
painter->drawRect(rect.adjusted(1, 1, -1, -1));
}
else {
rect.adjust(2, 2, -3, -3);
painter->drawRect(rect);
}
painter->restore();
break; }
case PE_IndicatorSpinPlus:
case PE_IndicatorSpinMinus: {
QRect r = option->rect;
int fw = proxy()->pixelMetric(PM_DefaultFrameWidth, option, widget)+2;
QRect br = r.adjusted(fw, fw, -fw, -fw);
int offset = (option->state & State_Sunken) ? 1 : 0;
int step = (br.width() + 4) / 5;
painter->fillRect(br.x() + offset, br.y() + offset +br.height() / 2 - step / 2,
br.width(), step, option->palette.buttonText());
if (element == PE_IndicatorSpinPlus)
painter->fillRect(br.x() + br.width() / 2 - step / 2 + offset, br.y() + offset+4,
step, br.height() - 7, option->palette.buttonText());
break; }
case PE_IndicatorSpinUp:
case PE_IndicatorSpinDown: {
painter->save();
QPoint points[7];
switch (element) {
case PE_IndicatorSpinUp:
points[0] = QPoint(-2, -4);
points[1] = QPoint(-2, 2);
points[2] = QPoint(-1, -3);
points[3] = QPoint(-1, 1);
points[4] = QPoint(0, -2);
points[5] = QPoint(0, 0);
points[6] = QPoint(1, -1);
break;
case PE_IndicatorSpinDown:
points[0] = QPoint(0, -4);
points[1] = QPoint(0, 2);
points[2] = QPoint(-1, -3);
points[3] = QPoint(-1, 1);
points[4] = QPoint(-2, -2);
points[5] = QPoint(-2, 0);
points[6] = QPoint(-3, -1);
break;
default:
break;
}
if (option->state & State_Sunken)
painter->translate(proxy()->pixelMetric(PM_ButtonShiftHorizontal),
proxy()->pixelMetric(PM_ButtonShiftVertical));
if (option->state & State_Enabled) {
painter->translate(option->rect.x() + option->rect.width() / 2,
option->rect.y() + option->rect.height() / 2);
painter->setPen(option->palette.buttonText().color());
painter->drawLine(points[0], points[1]);
painter->drawLine(points[2], points[3]);
painter->drawLine(points[4], points[5]);
painter->drawPoint(points[6]);
} else {
painter->translate(option->rect.x() + option->rect.width() / 2 + 1,
option->rect.y() + option->rect.height() / 2 + 1);
painter->setPen(option->palette.light().color());
painter->drawLine(points[0], points[1]);
painter->drawLine(points[2], points[3]);
painter->drawLine(points[4], points[5]);
painter->drawPoint(points[6]);
painter->translate(-1, -1);
painter->setPen(option->palette.mid().color());
painter->drawLine(points[0], points[1]);
painter->drawLine(points[2], points[3]);
painter->drawLine(points[4], points[5]);
painter->drawPoint(points[6]);
}
painter->restore();
break; }
case PE_IndicatorArrowUpBig:
case PE_IndicatorArrowDownBig:
case PE_IndicatorArrowLeftBig:
case PE_IndicatorArrowRightBig:
case PE_IndicatorArrowUp:
case PE_IndicatorArrowDown:
case PE_IndicatorArrowRight:
case PE_IndicatorArrowLeft: {
painter->save();
if (d->doubleControls) {
QColor color;
if (option->state & State_Sunken)
color = option->palette.light().color();
else
color = option->palette.buttonText().color();
QImage image;
int xoffset, yoffset;
bool isTabBarArrow = widget && widget->parent()
&& widget->inherits("QToolButton")
&& widget->parent()->inherits("QTabBar");
switch (element) {
case PE_IndicatorArrowUp:
image = d->imageArrowUp;
xoffset = 1;
yoffset = 12;
break;
case PE_IndicatorArrowDown:
image = d->imageArrowDown;
xoffset = 1;
yoffset =12;
break;
case PE_IndicatorArrowLeft:
image = d->imageArrowLeft;
xoffset = 8;
yoffset = isTabBarArrow ? 12 : 2;
break;
case PE_IndicatorArrowRight:
image = d->imageArrowRight;
xoffset = 8;
yoffset = isTabBarArrow ? 12 : 2;
break;
case PE_IndicatorArrowUpBig:
image = d->imageArrowUpBig;
xoffset = 3;
yoffset = 12;
break;
case PE_IndicatorArrowDownBig:
image = d->imageArrowDownBig;
xoffset = 2;
yoffset =12;
break;
case PE_IndicatorArrowLeftBig:
image = d->imageArrowLeftBig;
xoffset = 8;
yoffset = 2;
break;
case PE_IndicatorArrowRightBig:
image = d->imageArrowRightBig;
xoffset = 8;
yoffset = 2;
break;
default:
break;
}
image.setColor(1, color.rgba());
painter->drawImage(option->rect.x() + xoffset, option->rect.y() + yoffset, image);
}
else {
QPoint points[7];
switch (element) {
case PE_IndicatorArrowUp:
case PE_IndicatorArrowUpBig:
points[0] = QPoint(-3, 1);
points[1] = QPoint(3, 1);
points[2] = QPoint(-2, 0);
points[3] = QPoint(2, 0);
points[4] = QPoint(-1, -1);
points[5] = QPoint(1, -1);
points[6] = QPoint(0, -2);
break;
case PE_IndicatorArrowDown:
case PE_IndicatorArrowDownBig:
points[0] = QPoint(-3, -1);
points[1] = QPoint(3, -1);
points[2] = QPoint(-2, 0);
points[3] = QPoint(2, 0);
points[4] = QPoint(-1, 1);
points[5] = QPoint(1, 1);
points[6] = QPoint(0, 2);
break;
case PE_IndicatorArrowRight:
case PE_IndicatorArrowRightBig:
points[0] = QPoint(-2, -3);
points[1] = QPoint(-2, 3);
points[2] = QPoint(-1, -2);
points[3] = QPoint(-1, 2);
points[4] = QPoint(0, -1);
points[5] = QPoint(0, 1);
points[6] = QPoint(1, 0);
break;
case PE_IndicatorArrowLeft:
case PE_IndicatorArrowLeftBig:
points[0] = QPoint(0, -3);
points[1] = QPoint(0, 3);
points[2] = QPoint(-1, -2);
points[3] = QPoint(-1, 2);
points[4] = QPoint(-2, -1);
points[5] = QPoint(-2, 1);
points[6] = QPoint(-3, 0);
break;
default:
break;
}
if (option->state & State_Sunken)
painter->setPen(option->palette.light().color());
else
painter->setPen(option->palette.buttonText().color());
if (option->state & State_Enabled) {
painter->translate(option->rect.x() + option->rect.width() / 2,
option->rect.y() + option->rect.height() / 2 - 1);
painter->drawLine(points[0], points[1]);
painter->drawLine(points[2], points[3]);
painter->drawLine(points[4], points[5]);
painter->drawPoint(points[6]);
} else {
painter->translate(option->rect.x() + option->rect.width() / 2,
option->rect.y() + option->rect.height() / 2 - 1);
painter->setPen(option->palette.mid().color());
painter->drawLine(points[0], points[1]);
painter->drawLine(points[2], points[3]);
painter->drawLine(points[4], points[5]);
painter->drawPoint(points[6]);
}
}
painter->restore();
break; }
#ifndef QT_NO_TABWIDGET
case PE_FrameTabWidget:
if (const QStyleOptionTabWidgetFrame *tab = qstyleoption_cast<const QStyleOptionTabWidgetFrame *>(option)) {
QRect rect = option->rect;
QPalette pal = option->palette;
painter->save();
QBrush fill = pal.light();
painter->fillRect(rect, fill);
painter->setPen(pal.shadow().color());
if (d->doubleControls) {
QPen pen = painter->pen();
pen.setWidth(2);
pen.setCapStyle(Qt::FlatCap);
painter->setPen(pen);
}
switch (tab->shape) {
case QTabBar::RoundedNorth:
#ifdef Q_WS_WINCE_WM
if (!d->wm65)
#endif
{
if (d->doubleControls)
painter->drawLine(rect.topLeft() + QPoint(0, 1), rect.topRight() + QPoint(0, 1));
else
painter->drawLine(rect.topLeft(), rect.topRight());
}
break;
case QTabBar::RoundedSouth:
#ifdef Q_WS_WINCE_WM
if (!d->wm65)
#endif
{
if (d->doubleControls)
painter->drawLine(rect.bottomLeft(), rect.bottomRight());
else
painter->drawLine(rect.bottomLeft(), rect.bottomRight());
}
break;
case QTabBar::RoundedEast:
#ifdef Q_WS_WINCE_WM
if (!d->wm65)
#endif
painter->drawLine(rect.topRight(), rect.bottomRight());
break;
case QTabBar::RoundedWest:
#ifdef Q_WS_WINCE_WM
if (!d->wm65)
#endif
painter->drawLine(rect.topLeft(), rect.bottomLeft());
break;
case QTabBar::TriangularWest:
case QTabBar::TriangularEast:
case QTabBar::TriangularSouth:
case QTabBar::TriangularNorth:
if (d->doubleControls)
qDrawPlainRect(painter, rect.adjusted(0,-2,0,0), option->palette.shadow().color(),2,&pal.light());
else
qDrawPlainRect(painter, rect, option->palette.shadow().color(),1,&pal.light());
break;
default:
break;
}
painter->restore();
}
break;
#endif //QT_NO_TABBAR
#ifndef QT_NO_ITEMVIEWS
case PE_PanelItemViewRow:
if (const QStyleOptionViewItemV4 *vopt = qstyleoption_cast<const QStyleOptionViewItemV4 *>(option)) {
QPalette::ColorGroup cg = vopt->state & QStyle::State_Enabled
? QPalette::Normal : QPalette::Disabled;
if (cg == QPalette::Normal && !(vopt->state & QStyle::State_Active))
cg = QPalette::Inactive;
if ((vopt->state & QStyle::State_Selected) && proxy()->styleHint(QStyle::SH_ItemView_ShowDecorationSelected, option, widget))
d->drawPanelItemViewSelected(painter, vopt);
else if (vopt->features & QStyleOptionViewItemV2::Alternate)
painter->fillRect(vopt->rect, vopt->palette.brush(cg, QPalette::AlternateBase));
else if (!(vopt->state & QStyle::State_Enabled))
painter->fillRect(vopt->rect, vopt->palette.brush(cg, QPalette::Base));
}
break;
case PE_PanelItemViewItem:
if (const QStyleOptionViewItemV4 *vopt = qstyleoption_cast<const QStyleOptionViewItemV4 *>(option)) {
QPalette::ColorGroup cg = vopt->state & QStyle::State_Enabled
? QPalette::Normal : QPalette::Disabled;
if (cg == QPalette::Normal && !(vopt->state & QStyle::State_Active))
cg = QPalette::Inactive;
if (vopt->showDecorationSelected && (vopt->state & QStyle::State_Selected)) {
d->drawPanelItemViewSelected(painter, vopt);
} else {
if (vopt->backgroundBrush.style() != Qt::NoBrush) {
QPointF oldBO = painter->brushOrigin();
painter->setBrushOrigin(vopt->rect.topLeft());
painter->fillRect(vopt->rect, vopt->backgroundBrush);
painter->setBrushOrigin(oldBO);
}
if (vopt->state & QStyle::State_Selected) {
QRect textRect = proxy()->subElementRect(QStyle::SE_ItemViewItemText, option, widget);
d->drawPanelItemViewSelected(painter, vopt, textRect);
}
}
}
break;
#endif //QT_NO_ITEMVIEWS
case PE_FrameWindow: {
QPalette popupPal = option->palette;
popupPal.setColor(QPalette::Light, option->palette.background().color());
popupPal.setColor(QPalette::Midlight, option->palette.light().color());
if (d->doubleControls)
qDrawPlainRect(painter, option->rect, popupPal.shadow().color(),2,0);
else
qDrawPlainRect(painter, option->rect, popupPal.shadow().color(),1,0);
break; }
case PE_FrameTabBarBase: {
break; }
case PE_Widget:
break;
case PE_IndicatorMenuCheckMark: {
int markW = option->rect.width() > 7 ? 7 : option->rect.width();
int markH = markW;
if (d->doubleControls)
markW*=2;
markH*=2;
int posX = option->rect.x() + (option->rect.width() - markW)/2 + 1;
int posY = option->rect.y() + (option->rect.height() - markH)/2;
QVector<QLineF> a;
a.reserve(markH);
int i, xx, yy;
xx = posX;
yy = 3 + posY;
for (i = 0; i < markW/2; ++i) {
a << QLineF(xx, yy, xx, yy + 2);
++xx;
++yy;
}
yy -= 2;
for (; i < markH; ++i) {
a << QLineF(xx, yy, xx, yy + 2);
++xx;
--yy;
}
if (!(option->state & State_Enabled) && !(option->state & State_On)) {
int pnt;
painter->setPen(option->palette.highlightedText().color());
QPoint offset(1, 1);
for (pnt = 0; pnt < a.size(); ++pnt)
a[pnt].translate(offset.x(), offset.y());
painter->drawLines(a);
for (pnt = 0; pnt < a.size(); ++pnt)
a[pnt].translate(offset.x(), offset.y());
}
painter->setPen(option->palette.text().color());
painter->drawLines(a);
break; }
case PE_IndicatorBranch: {
// Copied from the Windows style.
static const int decoration_size = d->doubleControls ? 18 : 9;
static const int ofsA = d->doubleControls ? 4 : 2;
static const int ofsB = d->doubleControls ? 8 : 4;
static const int ofsC = d->doubleControls ? 12 : 6;
static const int ofsD = d->doubleControls ? 1 : 0;
int mid_h = option->rect.x() + option->rect.width() / 2;
int mid_v = option->rect.y() + option->rect.height() / 2;
int bef_h = mid_h;
int bef_v = mid_v;
int aft_h = mid_h;
int aft_v = mid_v;
if (option->state & State_Children) {
int delta = decoration_size / 2;
bef_h -= delta;
bef_v -= delta;
aft_h += delta;
aft_v += delta;
QPen oldPen = painter->pen();
QPen crossPen = oldPen;
crossPen.setWidth(2);
painter->setPen(crossPen);
painter->drawLine(bef_h + ofsA + ofsD, bef_v + ofsB + ofsD, bef_h + ofsC + ofsD, bef_v + ofsB + ofsD);
if (!(option->state & State_Open))
painter->drawLine(bef_h + ofsB + ofsD, bef_v + ofsA + ofsD, bef_h + ofsB + ofsD, bef_v + ofsC + ofsD);
painter->setPen(option->palette.dark().color());
painter->drawRect(bef_h, bef_v, decoration_size - 1, decoration_size - 1);
if (d->doubleControls)
painter->drawRect(bef_h + 1, bef_v + 1, decoration_size - 3, decoration_size - 3);
painter->setPen(oldPen);
}
QBrush brush(option->palette.dark().color(), Qt::Dense4Pattern);
if (option->state & State_Item) {
if (option->direction == Qt::RightToLeft)
painter->fillRect(option->rect.left(), mid_v, bef_h - option->rect.left(), 1, brush);
else
painter->fillRect(aft_h, mid_v, option->rect.right() - aft_h + 1, 1, brush);
}
if (option->state & State_Sibling)
painter->fillRect(mid_h, aft_v, 1, option->rect.bottom() - aft_v + 1, brush);
if (option->state & (State_Open | State_Children | State_Item | State_Sibling))
painter->fillRect(mid_h, option->rect.y(), 1, bef_v - option->rect.y(), brush);
break; }
case PE_Frame:
qDrawPlainRect(painter, option->rect, option->palette.shadow().color(),
d->doubleControls ? 2 : 1, &option->palette.background());
break;
case PE_FrameLineEdit:
case PE_FrameMenu:
if (d->doubleControls)
qDrawPlainRect(painter, option->rect, option->palette.shadow().color(),2);
else
qDrawPlainRect(painter, option->rect, option->palette.shadow().color(),1);
break;
case PE_FrameStatusBar:
if (d->doubleControls)
qDrawPlainRect(painter, option->rect, option->palette.shadow().color(),2,0);
else
qDrawPlainRect(painter, option->rect, option->palette.shadow().color(),1,0);
break;
default:
QWindowsStyle::drawPrimitive(element, option, painter, widget);
break;
}
}
void QWindowsMobileStyle::drawControl(ControlElement element, const QStyleOption *option,
QPainter *painter, const QWidget *widget) const {
QWindowsMobileStylePrivate *d = const_cast<QWindowsMobileStylePrivate*>(d_func());
painter->setClipping(false);
switch (element) {
case CE_MenuBarEmptyArea:
painter->setClipping(true);
QWindowsStyle::drawControl(element, option, painter, widget);
break;
case CE_PushButtonBevel:
if (const QStyleOptionButton *button = qstyleoption_cast<const QStyleOptionButton *>(option)) {
QRect br = button->rect;
int dbi = proxy()->pixelMetric(PM_ButtonDefaultIndicator, button, widget);
if (button->features & QStyleOptionButton::AutoDefaultButton)
br.setCoords(br.left() + dbi, br.top() + dbi, br.right() - dbi, br.bottom() - dbi);
QStyleOptionButton tmpBtn = *button;
tmpBtn.rect = br;
proxy()->drawPrimitive(PE_PanelButtonCommand, &tmpBtn, painter, widget);
if (button->features & QStyleOptionButton::HasMenu) {
int mbi = proxy()->pixelMetric(PM_MenuButtonIndicator, button, widget);
QRect ir = button->rect;
QStyleOptionButton newButton = *button;
if (d->doubleControls)
newButton.rect = QRect(ir.right() - mbi, ir.height() - 30, mbi, ir.height() - 4);
else
newButton.rect = QRect(ir.right() - mbi, ir.height() - 20, mbi, ir.height() - 4);
proxy()->drawPrimitive(PE_IndicatorArrowDown, &newButton, painter, widget);
}
if (button->features & QStyleOptionButton::DefaultButton)
proxy()->drawPrimitive(PE_FrameDefaultButton, option, painter, widget);
}
break;
case CE_RadioButton:
case CE_CheckBox:
if (const QStyleOptionButton *button = qstyleoption_cast<const QStyleOptionButton *>(option)) {
bool isRadio = (element == CE_RadioButton);
QStyleOptionButton subopt = *button;
subopt.rect = proxy()->subElementRect(isRadio ? SE_RadioButtonIndicator
: SE_CheckBoxIndicator, button, widget);
proxy()->drawPrimitive(isRadio ? PE_IndicatorRadioButton : PE_IndicatorCheckBox,
&subopt, painter, widget);
subopt.rect = proxy()->subElementRect(isRadio ? SE_RadioButtonContents
: SE_CheckBoxContents, button, widget);
proxy()->drawControl(isRadio ? CE_RadioButtonLabel : CE_CheckBoxLabel, &subopt, painter, widget);
if (button->state & State_HasFocus) {
QStyleOptionFocusRect fropt;
fropt.QStyleOption::operator=(*button);
fropt.rect = proxy()->subElementRect(isRadio ? SE_RadioButtonFocusRect
: SE_CheckBoxFocusRect, button, widget);
proxy()->drawPrimitive(PE_FrameFocusRect, &fropt, painter, widget);
}
}
break;
case CE_RadioButtonLabel:
case CE_CheckBoxLabel:
if (const QStyleOptionButton *button = qstyleoption_cast<const QStyleOptionButton *>(option)) {
uint alignment = visualAlignment(button->direction, Qt::AlignLeft | Qt::AlignVCenter);
if (!styleHint(SH_UnderlineShortcut, button, widget))
alignment |= Qt::TextHideMnemonic;
QPixmap pix;
QRect textRect = button->rect;
if (!button->icon.isNull()) {
pix = button->icon.pixmap(button->iconSize, button->state & State_Enabled ? QIcon::Normal : QIcon::Disabled);
proxy()->drawItemPixmap(painter, button->rect, alignment, pix);
if (button->direction == Qt::RightToLeft)
textRect.setRight(textRect.right() - button->iconSize.width() - 4);
else
textRect.setLeft(textRect.left() + button->iconSize.width() + 4);
}
if (!button->text.isEmpty()){
if (button->state & State_Enabled)
proxy()->drawItemText(painter, textRect, alignment | Qt::TextShowMnemonic,
button->palette, false, button->text, QPalette::WindowText);
else
proxy()->drawItemText(painter, textRect, alignment | Qt::TextShowMnemonic,
button->palette, false, button->text, QPalette::Mid);
}
}
break;
#ifndef QT_NO_PROGRESSBAR
case CE_ProgressBarGroove:
if (d->doubleControls)
qDrawPlainRect(painter, option->rect, option->palette.shadow().color(), 2, &option->palette.brush(QPalette::Window));
else
qDrawPlainRect(painter, option->rect, option->palette.shadow().color(), 1, &option->palette.brush(QPalette::Window));
break;
#endif //QT_NO_PROGRESSBAR
#ifndef QT_NO_TABBAR
case CE_TabBarTab:
if (const QStyleOptionTab *tab = qstyleoption_cast<const QStyleOptionTab *>(option)) {
proxy()->drawControl(CE_TabBarTabShape, tab, painter, widget);
proxy()->drawControl(CE_TabBarTabLabel, tab, painter, widget);
}
break;
case CE_TabBarTabShape:
if (const QStyleOptionTab *tab = qstyleoption_cast<const QStyleOptionTab *>(option)) {
if (tab->shape == QTabBar::RoundedNorth || tab->shape == QTabBar::RoundedEast ||
tab->shape == QTabBar::RoundedSouth || tab->shape == QTabBar::RoundedWest) {
d->drawTabBarTab(painter, tab);
} else {
QCommonStyle::drawControl(element, option, painter, widget);
}
break; }
#endif // QT_NO_TABBAR
#ifndef QT_NO_TOOLBAR
case CE_ToolBar:
if (const QStyleOptionToolBar *toolBar = qstyleoption_cast<const QStyleOptionToolBar *>(option)) {
QRect rect = option->rect;
painter->save();
painter->setPen(option->palette.dark().color());
painter->fillRect(rect,option->palette.button());
if (d->doubleControls) {
QPen pen = painter->pen();
pen.setWidth(4);
painter->setPen(pen);
}
if (toolBar->toolBarArea == Qt::TopToolBarArea)
painter->drawLine(rect.bottomLeft(), rect.bottomRight());
else
painter->drawLine(rect.topLeft(), rect.topRight());
painter->restore();
break; }
#endif //QT_NO_TOOLBAR
case CE_Header:
if (const QStyleOptionHeader *header = qstyleoption_cast<const QStyleOptionHeader *>(option)) {
QRegion clipRegion = painter->clipRegion();
painter->setClipRect(option->rect);
proxy()->drawControl(CE_HeaderSection, header, painter, widget);
QStyleOptionHeader subopt = *header;
subopt.rect = proxy()->subElementRect(SE_HeaderLabel, header, widget);
if (header->state & State_Sunken)
subopt.palette.setColor(QPalette::ButtonText, header->palette.brightText().color());
subopt.state |= QStyle::State_On;
if (subopt.rect.isValid())
proxy()->drawControl(CE_HeaderLabel, &subopt, painter, widget);
if (header->sortIndicator != QStyleOptionHeader::None) {
subopt.rect = proxy()->subElementRect(SE_HeaderArrow, option, widget);
proxy()->drawPrimitive(PE_IndicatorHeaderArrow, &subopt, painter, widget);
}
painter->setClipRegion(clipRegion);
}
break;
case CE_HeaderSection:
if (const QStyleOptionHeader *header = qstyleoption_cast<const QStyleOptionHeader *>(option)) {
QBrush fill;
QColor color;
QRect rect = option->rect;
painter->setPen(option->palette.shadow().color());
int penSize = 1;
if (d->doubleControls) {
penSize = 2;
QPen pen = painter->pen();
pen.setWidth(2);
pen.setCapStyle(Qt::FlatCap);
painter->setPen(pen);
}
//fix Frame
if (header->position == QStyleOptionHeader::End
|| (header->position == QStyleOptionHeader::OnlyOneSection
&& !header->text.isEmpty()))
if (Qt::Horizontal == header->orientation )
rect.adjust(0, 0, penSize, 0);
else
rect.adjust(0, 0, 0, penSize);
if (option->state & State_Sunken) {
fill = option->palette.brush(QPalette::Shadow);
color = option->palette.light().color();
painter->drawLine(rect.bottomLeft(), rect.bottomRight());
painter->drawLine(rect.topRight(), rect.bottomRight());
rect.adjust(0, 0, -penSize, -penSize);
}
else {
fill = option->palette.brush(QPalette::Button);
color = option->palette.shadow().color();
if (Qt::Horizontal == header->orientation )
rect.adjust(-penSize, 0, 0, 0);
else
rect.adjust(0, -penSize, 0, 0);
}
if (Qt::Horizontal == header->orientation )
rect.adjust(0,-penSize,0,0);
else
rect.adjust(-penSize, 0, 0, 0);
if (option->state & State_Sunken) {
qDrawPlainRect(painter, rect, color, penSize, &fill);
} else {
//Corner
rect.adjust(-penSize, 0, 0, 0);
qDrawPlainRect(painter, rect, color, penSize, &fill);
}
//Hack to get rid of some double lines... StyleOptions need a clean flag for that
rect = option->rect;
#ifndef QT_NO_SCROLLAREA
if (const QAbstractScrollArea *abstractScrollArea = qobject_cast<const QAbstractScrollArea *> (widget) ) {
QRect rectScrollArea = abstractScrollArea->geometry();
if (Qt::Horizontal == header->orientation )
if ((rectScrollArea.right() - rect.right() ) > 1)
painter->drawLine(rect.topRight(), rect.bottomRight());
else ;
else
if ((rectScrollArea.bottom() - rect.bottom() ) > 1)
painter->drawLine(rect.bottomLeft(), rect.bottomRight());
}
#endif // QT_NO_SCROLLAREA
break;
}
#ifndef QT_NO_COMBOBOX
case CE_ComboBoxLabel:
// This is copied from qcommonstyle.cpp with the difference, that
// the editRect isn't adjusted when calling drawItemText.
if (const QStyleOptionComboBox *cb = qstyleoption_cast<const QStyleOptionComboBox *>(option)) {
QRect editRect = proxy()->subControlRect(CC_ComboBox, cb, SC_ComboBoxEditField, widget);
painter->save();
painter->setClipRect(editRect);
if (!cb->currentIcon.isNull()) {
QIcon::Mode mode = cb->state & State_Enabled ? QIcon::Normal
: QIcon::Disabled;
QPixmap pixmap = cb->currentIcon.pixmap(cb->iconSize, mode);
QRect iconRect(editRect);
iconRect.setWidth(cb->iconSize.width() + 4);
iconRect = alignedRect(cb->direction,
Qt::AlignLeft | Qt::AlignVCenter,
iconRect.size(), editRect);
if (cb->editable)
painter->fillRect(iconRect, option->palette.brush(QPalette::Base));
proxy()->drawItemPixmap(painter, iconRect, Qt::AlignCenter, pixmap);
if (cb->direction == Qt::RightToLeft)
editRect.translate(-4 - cb->iconSize.width(), 0);
else
editRect.translate(cb->iconSize.width() + 4, 0);
}
if (!cb->currentText.isEmpty() && !cb->editable) {
proxy()->drawItemText(painter, editRect,
visualAlignment(cb->direction, Qt::AlignLeft | Qt::AlignVCenter),
cb->palette, cb->state & State_Enabled, cb->currentText);
}
painter->restore();
}
break;
#endif // QT_NO_COMBOBOX
#ifndef QT_NO_DOCKWIDGET
case CE_DockWidgetTitle:
if (const QStyleOptionDockWidget *dwOpt = qstyleoption_cast<const QStyleOptionDockWidget *>(option)) {
const QStyleOptionDockWidgetV2 *v2
= qstyleoption_cast<const QStyleOptionDockWidgetV2*>(option);
bool verticalTitleBar = v2 == 0 ? false : v2->verticalTitleBar;
QRect rect = dwOpt->rect;
QRect r = rect;
if (verticalTitleBar) {
QSize s = r.size();
s.transpose();
r.setSize(s);
painter->save();
painter->translate(r.left(), r.top() + r.width());
painter->rotate(-90);
painter->translate(-r.left(), -r.top());
}
bool floating = false;
bool active = dwOpt->state & State_Active;
int menuOffset = 0; //used to center text when floated
QColor inactiveCaptionTextColor = option->palette.highlightedText().color();
if (dwOpt->movable) {
QColor left, right;
//Titlebar gradient
if (widget && widget->isWindow()) {
floating = true;
if (active) {
right = option->palette.highlight().color();
left = right.lighter(125);
} else {
left = option->palette.highlight().color().lighter(125);
right = QColor(0xff, 0xff, 0xff);
}
menuOffset = 2;
QBrush fillBrush(left);
if (left != right) {
QPoint p1(r.x(), r.top() + r.height()/2);
QPoint p2(rect.right(), r.top() + r.height()/2);
QLinearGradient lg(p1, p2);
lg.setColorAt(0, left);
lg.setColorAt(1, right);
fillBrush = lg;
}
painter->fillRect(r.adjusted(0, 0, 0, -3), fillBrush);
} else {
painter->fillRect(r.adjusted(0, 0, 0, -3), option->palette.button().color());
}
painter->setPen(dwOpt->palette.color(QPalette::Light));
if (!widget || !widget->isWindow()) {
painter->drawLine(r.topLeft(), r.topRight());
painter->setPen(dwOpt->palette.color(QPalette::Dark));
painter->drawLine(r.bottomLeft(), r.bottomRight()); }
}
if (!dwOpt->title.isEmpty()) {
QFont oldFont = painter->font();
QFont newFont = oldFont;
if (newFont.pointSize() > 2)
newFont.setPointSize(newFont.pointSize() - 2);
if (floating)
newFont.setBold(true);
painter->setFont(newFont);
QPalette palette = dwOpt->palette;
palette.setColor(QPalette::Window, inactiveCaptionTextColor);
QRect titleRect = proxy()->subElementRect(SE_DockWidgetTitleBarText, option, widget);
if (verticalTitleBar) {
titleRect = QRect(r.left() + rect.bottom()
- titleRect.bottom(),
r.top() + titleRect.left() - rect.left(),
titleRect.height(), titleRect.width());
}
proxy()->drawItemText(painter, titleRect,
Qt::AlignLeft | Qt::AlignVCenter | Qt::TextShowMnemonic, palette,
dwOpt->state & State_Enabled, dwOpt->title,
floating ? (active ? QPalette::BrightText : QPalette::Window) : QPalette::WindowText);
painter->setFont(oldFont);
}
if (verticalTitleBar)
painter->restore();
}
return;
#endif // QT_NO_DOCKWIDGET
case CE_PushButtonLabel:
if (const QStyleOptionButton *button = qstyleoption_cast<const QStyleOptionButton *>(option)) {
painter->save();
QRect ir = button->rect;
QPalette::ColorRole colorRole;
uint tf = Qt::AlignVCenter | Qt::TextShowMnemonic;
if (!styleHint(SH_UnderlineShortcut, button, widget))
tf |= Qt::TextHideMnemonic;
if (button->state & (State_On | State_Sunken))
colorRole = QPalette::Light;
else
colorRole = QPalette::ButtonText;
if (!button->icon.isNull()) {
QIcon::Mode mode = button->state & State_Enabled ? QIcon::Normal
: QIcon::Disabled;
if (mode == QIcon::Normal && button->state & State_HasFocus)
mode = QIcon::Active;
QIcon::State state = QIcon::Off;
if (button->state & State_On)
state = QIcon::On;
QPixmap pixmap = button->icon.pixmap(button->iconSize, mode, state);
int pixw = pixmap.width();
int pixh = pixmap.height();
//Center the icon if there is no text
QPoint point;
if (button->text.isEmpty()) {
point = QPoint(ir.x() + ir.width() / 2 - pixw / 2,
ir.y() + ir.height() / 2 - pixh / 2);
} else {
point = QPoint(ir.x() + 2, ir.y() + ir.height() / 2 - pixh / 2);
}
if (button->direction == Qt::RightToLeft)
point.rx() += pixw;
if ((button->state & (State_On | State_Sunken)) && button->direction == Qt::RightToLeft)
point.rx() -= proxy()->pixelMetric(PM_ButtonShiftHorizontal, option, widget) * 2;
painter->drawPixmap(visualPos(button->direction, button->rect, point), pixmap);
if (button->direction == Qt::RightToLeft)
ir.translate(-4, 0);
else
ir.translate(pixw + 4, 0);
ir.setWidth(ir.width() - (pixw + 4));
// left-align text if there is
if (!button->text.isEmpty())
tf |= Qt::AlignLeft;
} else {
tf |= Qt::AlignHCenter;
}
if (button->state & State_Enabled)
proxy()->drawItemText(painter, ir, tf, button->palette, true, button->text, colorRole);
else
proxy()->drawItemText(painter, ir, tf, button->palette, true, button->text, QPalette::Mid);
painter->restore();
}
break;
default:
QWindowsStyle::drawControl(element, option, painter, widget);
break;
}
}
void QWindowsMobileStyle::drawComplexControl(ComplexControl control, const QStyleOptionComplex *option,
QPainter *painter, const QWidget *widget) const {
painter->setClipping(false);
QWindowsMobileStylePrivate *d = const_cast<QWindowsMobileStylePrivate*>(d_func());
switch (control) {
#ifndef QT_NO_SLIDER
case CC_Slider:
if (const QStyleOptionSlider *slider = qstyleoption_cast<const QStyleOptionSlider *>(option)) {
int thickness = proxy()->pixelMetric(PM_SliderControlThickness, slider, widget);
int len = proxy()->pixelMetric(PM_SliderLength, slider, widget);
int ticks = slider->tickPosition;
QRect groove = proxy()->subControlRect(CC_Slider, slider, SC_SliderGroove, widget);
QRect handle = proxy()->subControlRect(CC_Slider, slider, SC_SliderHandle, widget);
if ((slider->subControls & SC_SliderGroove) && groove.isValid()) {
int mid = thickness / 2;
if (ticks & QSlider::TicksAbove)
mid += len / 8;
if (ticks & QSlider::TicksBelow)
mid -= len / 8;
painter->setPen(slider->palette.shadow().color());
if (slider->orientation == Qt::Horizontal) {
qDrawPlainRect(painter, groove.x(), groove.y() + mid - 2,
groove.width(), 4, option->palette.shadow().color(),1,0);
} else {
qDrawPlainRect(painter, groove.x()+mid-2, groove.y(),
4, groove.height(), option->palette.shadow().color(),1,0);
}
}
if (slider->subControls & SC_SliderTickmarks) {
QStyleOptionSlider tmpSlider = *slider;
tmpSlider.subControls = SC_SliderTickmarks;
QCommonStyle::drawComplexControl(control, &tmpSlider, painter, widget);
}
if (slider->subControls & SC_SliderHandle) {
const QColor c0 = slider->palette.shadow().color();
const QColor c1 = slider->palette.dark().color();
const QColor c3 = slider->palette.midlight().color();
const QColor c4 = slider->palette.dark().color();
QBrush handleBrush;
if (slider->state & State_Enabled) {
handleBrush = slider->palette.color(QPalette::Light);
} else {
handleBrush = QBrush(slider->palette.color(QPalette::Shadow),
Qt::Dense4Pattern);
}
int x = handle.x(), y = handle.y(),
wi = handle.width(), he = handle.height();
int x1 = x;
int x2 = x+wi-1;
int y1 = y;
int y2 = y+he-1;
Qt::Orientation orient = slider->orientation;
bool tickAbove = slider->tickPosition == QSlider::TicksAbove;
bool tickBelow = slider->tickPosition == QSlider::TicksBelow;
if (slider->state & State_HasFocus) {
QStyleOptionFocusRect fropt;
fropt.QStyleOption::operator=(*slider);
fropt.rect = proxy()->subElementRect(SE_SliderFocusRect, slider, widget);
proxy()->drawPrimitive(PE_FrameFocusRect, &fropt, painter, widget);
}
if ((tickAbove && tickBelow) || (!tickAbove && !tickBelow)) {
Qt::BGMode oldMode = painter->backgroundMode();
painter->setBackgroundMode(Qt::OpaqueMode);
qDrawPlainRect(painter, QRect(x, y, wi, he)
,slider->palette.shadow().color(),1,&handleBrush);
painter->setBackgroundMode(oldMode);
QBrush fill = QBrush(option->palette.light().color(), Qt::Dense4Pattern);
if (slider->state & State_Sunken)
painter->fillRect(QRectF(x1 + 2, y1 + 2, x2 - x1 - 3, y2 - y1 - 3),fill);
return;
}
QSliderDirection dir;
if (orient == Qt::Horizontal)
if (tickAbove)
dir = SliderUp;
else
dir = SliderDown;
else
if (tickAbove)
dir = SliderLeft;
else
dir = SliderRight;
QPolygon polygon;
int d = 0;
switch (dir) {
case SliderUp:
x2++;
y1 = y1 + wi / 2;
d = (wi + 1) / 2 - 1;
polygon.setPoints(5, x1, y1, x1, y2, x2, y2, x2, y1, x1 + d,y1 - d);
break;
case SliderDown:
x2++;
y2 = y2 - wi/2;
d = (wi + 1) / 2 - 1;
polygon.setPoints(5, x1, y1, x1, y2, x1 + d,y2 + d, x2, y2, x2, y1);
break;
case SliderLeft:
d = (he + 1) / 2 - 1;
x1 = x1 + he/2;
polygon.setPoints(5, x1, y1, x1 - d, y1 + d, x1,y2, x2, y2, x2, y1);
y1--;
break;
case SliderRight:
d = (he + 1) / 2 - 1;
x2 = x2 - he/2;
polygon.setPoints(5, x1, y1, x1, y2, x2,y2, x2 + d, y1 + d, x2, y1);
y1--;
break;
}
QBrush oldBrush = painter->brush();
painter->setPen(Qt::NoPen);
painter->setBrush(handleBrush);
Qt::BGMode oldMode = painter->backgroundMode();
painter->setBackgroundMode(Qt::OpaqueMode);
painter->drawRect(x1, y1, x2-x1+1, y2-y1+1);
painter->drawPolygon(polygon);
QBrush fill = QBrush(option->palette.button().color(), Qt::Dense4Pattern);
painter->setBrush(oldBrush);
painter->setBackgroundMode(oldMode);
if (slider->state & State_Sunken)
painter->fillRect(QRectF(x1, y1, x2 - x1 + 1, y2 - y1 + 1),fill);
if (dir != SliderUp) {
painter->setPen(c0);
painter->drawLine(x1, y1, x2, y1);
}
if (dir != SliderLeft) {
painter->setPen(c0);
painter->drawLine(x1, y1, x1, y2);
}
if (dir != SliderRight) {
painter->setPen(c0);
painter->drawLine(x2, y1, x2, y2);
}
if (dir != SliderDown) {
painter->setPen(c0);
painter->drawLine(x1, y2, x2, y2);
}
switch (dir) {
case SliderUp:
if (slider->state & State_Sunken)
painter->fillRect(QRectF(x1 + 3, y1 - d + 2, x2 - x1 - 4, y1),fill);
painter->setPen(c0);
painter->drawLine(x1, y1, x1 + d, y1 - d);
d = wi - d - 1;
painter->drawLine(x2, y1, x2 -d , y1 -d );
d--;
break;
case SliderDown:
if (slider->state & State_Sunken)
painter->fillRect(QRectF(x1+3, y2 - d, x2 - x1 -4,y2 - 8),fill);
painter->setPen(c0);
painter->drawLine(x1, y2, x1 + d, y2 + d);
d = wi - d - 1;
painter->drawLine(x2, y2, x2 - d, y2 + d);
d--;
break;
case SliderLeft:
if (slider->state & State_Sunken)
painter->fillRect(QRectF(x1 - d + 2, y1 + 2, x1, y2 - y1 - 3),fill);
painter->setPen(c0);
painter->drawLine(x1, y1, x1 - d, y1 + d);
d = he - d - 1;
painter->drawLine(x1, y2, x1 - d, y2 - d);
d--;
break;
case SliderRight:
if (slider->state & State_Sunken)
painter->fillRect(QRectF(x2 - d - 4, y1 + 2, x2 - 4, y2 - y1 - 3),fill);
painter->setPen(c0);
painter->drawLine(x2, y1, x2 + d, y1 + d);
painter->setPen(c0);
d = he - d - 1;
painter->drawLine(x2, y2, x2 + d, y2 - d);
d--;
break;
}
}
}
break;
#endif //QT_NO_SLIDER
#ifndef QT_NO_SCROLLBAR
case CC_ScrollBar:
painter->save();
painter->setPen(option->palette.shadow().color());
if (d->doubleControls) {
QPen pen = painter->pen();
pen.setWidth(2);
pen.setCapStyle(Qt::SquareCap);
painter->setPen(pen);
}
if (const QStyleOptionSlider *scrollbar = qstyleoption_cast<const QStyleOptionSlider *>(option)) {
d->drawScrollbarGroove(painter, scrollbar);
// Make a copy here and reset it for each primitive.
QStyleOptionSlider newScrollbar = *scrollbar;
State saveFlags = scrollbar->state;
//Check if the scrollbar is part of an abstractItemView and draw the frame according
bool drawCompleteFrame = true;
bool secondScrollBar = false;
if (widget)
if (QWidget *parent = widget->parentWidget()) {
if (QAbstractScrollArea *abstractScrollArea = qobject_cast<QAbstractScrollArea *>(parent->parentWidget())) {
drawCompleteFrame = (abstractScrollArea->frameStyle() == QFrame::NoFrame) || (abstractScrollArea->frameStyle() == QFrame::StyledPanel);
secondScrollBar = (abstractScrollArea->horizontalScrollBar()->isVisible()
&& abstractScrollArea->verticalScrollBar()->isVisible()) ;
}
#ifndef QT_NO_LISTVIEW
if (QListView *listView = qobject_cast<QListView *>(parent->parentWidget()))
drawCompleteFrame = false;
#endif
}
if (scrollbar->minimum == scrollbar->maximum)
saveFlags |= State_Enabled;
if (scrollbar->subControls & SC_ScrollBarSubLine) {
newScrollbar.state = saveFlags;
newScrollbar.rect = proxy()->subControlRect(control, &newScrollbar, SC_ScrollBarSubLine, widget);
if (newScrollbar.rect.isValid()) {
if (!(scrollbar->activeSubControls & SC_ScrollBarSubLine))
newScrollbar.state &= ~(State_Sunken | State_MouseOver);
d->drawScrollbarHandleUp(painter, &newScrollbar, drawCompleteFrame, secondScrollBar);
}
}
if (scrollbar->subControls & SC_ScrollBarAddLine) {
newScrollbar.rect = scrollbar->rect;
newScrollbar.state = saveFlags;
newScrollbar.rect = proxy()->subControlRect(control, &newScrollbar, SC_ScrollBarAddLine, widget);
if (newScrollbar.rect.isValid()) {
if (!(scrollbar->activeSubControls & SC_ScrollBarAddLine))
newScrollbar.state &= ~(State_Sunken | State_MouseOver);
d->drawScrollbarHandleDown(painter, &newScrollbar, drawCompleteFrame, secondScrollBar);
}
}
if (scrollbar->subControls & SC_ScrollBarSlider) {
newScrollbar.rect = scrollbar->rect;
newScrollbar.state = saveFlags;
newScrollbar.rect = proxy()->subControlRect(control, &newScrollbar, SC_ScrollBarSlider, widget);
if (newScrollbar.rect.isValid()) {
if (!(scrollbar->activeSubControls & SC_ScrollBarSlider))
newScrollbar.state &= ~(State_Sunken | State_MouseOver);
d->drawScrollbarGrip(painter, &newScrollbar, option, drawCompleteFrame);
}
}
}
painter->restore();
break;
#endif // QT_NO_SCROLLBAR
case CC_ToolButton:
if (const QStyleOptionToolButton *toolbutton
= qstyleoption_cast<const QStyleOptionToolButton *>(option)) {
QRect button, menuarea;
bool isTabWidget = false;
#ifndef QT_NO_TABWIDGET
if (widget)
if (QWidget *parent = widget->parentWidget())
isTabWidget = (qobject_cast<QTabWidget *>(parent->parentWidget()));
#endif //QT_NO_TABWIDGET
button = proxy()->subControlRect(control, toolbutton, SC_ToolButton, widget);
menuarea = proxy()->subControlRect(control, toolbutton, SC_ToolButtonMenu, widget);
State buttonFlags = toolbutton->state;
if (buttonFlags & State_AutoRaise) {
if (!(buttonFlags & State_MouseOver)) {
buttonFlags &= ~State_Raised;
}
}
State menuFlags = buttonFlags;
if (toolbutton->activeSubControls & SC_ToolButton)
buttonFlags |= State_Sunken;
if (toolbutton->activeSubControls & SC_ToolButtonMenu)
menuFlags |= State_On;
QStyleOption tool(0);
tool.palette = toolbutton->palette;
if (toolbutton->subControls & SC_ToolButton) {
tool.rect = button;
tool.state = buttonFlags;
proxy()->drawPrimitive(PE_PanelButtonTool, &tool, painter, widget);
}
if (toolbutton->subControls & SC_ToolButtonMenu) {
tool.rect = menuarea;
tool.state = buttonFlags & State_Enabled;
QStyleOption toolMenu(0);
toolMenu = *toolbutton;
toolMenu.state = menuFlags;
if (buttonFlags & State_Sunken)
proxy()->drawPrimitive(PE_PanelButtonTool, &toolMenu, painter, widget);
QStyleOption arrowOpt(0);
arrowOpt.rect = tool.rect;
arrowOpt.palette = tool.palette;
State flags = State_None;
if (menuFlags & State_Enabled)
flags |= State_Enabled;
if ((menuFlags & State_On) && !(buttonFlags & State_Sunken)) {
flags |= State_Sunken;
painter->fillRect(menuarea, option->palette.shadow());
}
arrowOpt.state = flags;
proxy()->drawPrimitive(PE_IndicatorArrowDown, &arrowOpt, painter, widget);
}
if (toolbutton->state & State_HasFocus) {
QStyleOptionFocusRect focusRect;
focusRect.QStyleOption::operator=(*toolbutton);
focusRect.rect.adjust(3, 3, -3, -3);
if (toolbutton->features & QStyleOptionToolButton::Menu)
focusRect.rect.adjust(0, 0, -proxy()->pixelMetric(QStyle::PM_MenuButtonIndicator,
toolbutton, widget), 0);
proxy()->drawPrimitive(PE_FrameFocusRect, &focusRect, painter, widget);
}
QStyleOptionToolButton label = *toolbutton;
if (isTabWidget)
label.state = toolbutton->state;
else
label.state = toolbutton->state & State_Enabled;
int fw = proxy()->pixelMetric(PM_DefaultFrameWidth, option, widget);
label.rect = button.adjusted(fw, fw, -fw, -fw);
proxy()->drawControl(CE_ToolButtonLabel, &label, painter, widget);
}
break;
#ifndef QT_NO_GROUPBOX
case CC_GroupBox:
if (const QStyleOptionGroupBox *groupBox = qstyleoption_cast<const QStyleOptionGroupBox *>(option)) {
// Draw frame
painter->save();
QFont font = painter->font();
font.setBold(true);
painter->setFont(font);
QStyleOptionGroupBox groupBoxFont = *groupBox;
groupBoxFont.fontMetrics = QFontMetrics(font);
QRect textRect = proxy()->subControlRect(CC_GroupBox, &groupBoxFont, SC_GroupBoxLabel, widget);
QRect checkBoxRect = proxy()->subControlRect(CC_GroupBox, option, SC_GroupBoxCheckBox, widget).adjusted(0,0,0,0);
if (groupBox->subControls & QStyle::SC_GroupBoxFrame) {
QStyleOptionFrameV2 frame;
frame.QStyleOption::operator=(*groupBox);
frame.features = groupBox->features;
frame.lineWidth = groupBox->lineWidth;
frame.midLineWidth = groupBox->midLineWidth;
frame.rect = proxy()->subControlRect(CC_GroupBox, option, SC_GroupBoxFrame, widget);
painter->save();
QRegion region(groupBox->rect);
if (!groupBox->text.isEmpty()) {
bool ltr = groupBox->direction == Qt::LeftToRight;
QRect finalRect = checkBoxRect.united(textRect);
if (groupBox->subControls & QStyle::SC_GroupBoxCheckBox)
finalRect.adjust(ltr ? -4 : 0, 0, ltr ? 0 : 4, 0);
region -= finalRect;
}
proxy()->drawPrimitive(PE_FrameGroupBox, &frame, painter, widget);
painter->restore();
}
// Draw checkbox
if (groupBox->subControls & SC_GroupBoxCheckBox) {
QStyleOptionButton box;
box.QStyleOption::operator=(*groupBox);
box.rect = checkBoxRect;
proxy()->drawPrimitive(PE_IndicatorCheckBox, &box, painter, widget);
}
// Draw title
if ((groupBox->subControls & QStyle::SC_GroupBoxLabel) && !groupBox->text.isEmpty()) {
QColor textColor = groupBox->textColor;
if (textColor.isValid())
painter->setPen(textColor);
else
painter->setPen(groupBox->palette.link().color());
painter->setPen(groupBox->palette.link().color());
int alignment = int(groupBox->textAlignment);
if (!styleHint(QStyle::SH_UnderlineShortcut, option, widget))
alignment |= Qt::TextHideMnemonic;
if (groupBox->state & State_Enabled)
proxy()->drawItemText(painter, textRect, Qt::TextShowMnemonic | Qt::AlignHCenter | alignment,
groupBox->palette, true, groupBox->text,
textColor.isValid() ? QPalette::NoRole : QPalette::Link);
else
proxy()->drawItemText(painter, textRect, Qt::TextShowMnemonic | Qt::AlignHCenter | alignment,
groupBox->palette, true, groupBox->text, QPalette::Mid);
if (groupBox->state & State_HasFocus) {
QStyleOptionFocusRect fropt;
fropt.QStyleOption::operator=(*groupBox);
fropt.rect = textRect;
proxy()->drawPrimitive(PE_FrameFocusRect, &fropt, painter, widget);
}
}
painter->restore();
}
break;
#endif //QT_NO_GROUPBOX
#ifndef QT_NO_COMBOBOX
case CC_ComboBox:
if (const QStyleOptionComboBox *cmb = qstyleoption_cast<const QStyleOptionComboBox *>(option)) {
QBrush editBrush = cmb->palette.brush(QPalette::Base);
if ((cmb->subControls & SC_ComboBoxFrame) && cmb->frame)
qDrawPlainRect(painter, option->rect, option->palette.shadow().color(), proxy()->pixelMetric(PM_ComboBoxFrameWidth, option, widget), &editBrush);
else
painter->fillRect(option->rect, editBrush);
State flags = State_None;
QRect ar = proxy()->subControlRect(CC_ComboBox, cmb, SC_ComboBoxArrow, widget);
if ((option->state & State_On)) {
painter->fillRect(ar.adjusted(0, 0, 1, 1),cmb->palette.brush(QPalette::Shadow));
}
if (d->doubleControls)
ar.adjust(5, 0, 5, 0);
else
ar.adjust(2, 0, -2, 0);
if (option->state & State_Enabled)
flags |= State_Enabled;
if (option->state & State_On)
flags |= State_Sunken;
QStyleOption arrowOpt(0);
arrowOpt.rect = ar;
arrowOpt.palette = cmb->palette;
arrowOpt.state = flags;
proxy()->drawPrimitive(PrimitiveElement(PE_IndicatorArrowDownBig), &arrowOpt, painter, widget);
if (cmb->subControls & SC_ComboBoxEditField) {
QRect re = proxy()->subControlRect(CC_ComboBox, cmb, SC_ComboBoxEditField, widget);
if (cmb->state & State_HasFocus && !cmb->editable)
painter->fillRect(re.x(), re.y(), re.width(), re.height(),
cmb->palette.brush(QPalette::Highlight));
if (cmb->state & State_HasFocus) {
painter->setPen(cmb->palette.highlightedText().color());
painter->setBackground(cmb->palette.highlight());
} else {
painter->setPen(cmb->palette.text().color());
painter->setBackground(cmb->palette.background());
}
if (cmb->state & State_HasFocus && !cmb->editable) {
QStyleOptionFocusRect focus;
focus.QStyleOption::operator=(*cmb);
focus.rect = proxy()->subElementRect(SE_ComboBoxFocusRect, cmb, widget);
focus.state |= State_FocusAtBorder;
focus.backgroundColor = cmb->palette.highlight().color();
if ((option->state & State_On))
proxy()->drawPrimitive(PE_FrameFocusRect, &focus, painter, widget);
}
}
}
break;
#endif // QT_NO_COMBOBOX
#ifndef QT_NO_SPINBOX
case CC_SpinBox:
if (const QStyleOptionSpinBox *spinBox = qstyleoption_cast<const QStyleOptionSpinBox *>(option)) {
QStyleOptionSpinBox copy = *spinBox;
//PrimitiveElement primitiveElement;
int primitiveElement;
if (spinBox->frame && (spinBox->subControls & SC_SpinBoxFrame)) {
QRect r = proxy()->subControlRect(CC_SpinBox, spinBox, SC_SpinBoxFrame, widget);
qDrawPlainRect(painter, r, option->palette.shadow().color(), proxy()->pixelMetric(PM_SpinBoxFrameWidth, option, widget),0);
}
QPalette shadePal(option->palette);
shadePal.setColor(QPalette::Button, option->palette.light().color());
shadePal.setColor(QPalette::Light, option->palette.base().color());
if (spinBox->subControls & SC_SpinBoxUp) {
copy.subControls = SC_SpinBoxUp;
QPalette pal2 = spinBox->palette;
if (!(spinBox->stepEnabled & QAbstractSpinBox::StepUpEnabled)) {
pal2.setCurrentColorGroup(QPalette::Disabled);
copy.state &= ~State_Enabled;
}
copy.palette = pal2;
if (spinBox->activeSubControls == SC_SpinBoxUp && (spinBox->state & State_Sunken)) {
copy.state |= State_On;
copy.state |= State_Sunken;
} else {
copy.state |= State_Raised;
copy.state &= ~State_Sunken;
}
primitiveElement = (spinBox->buttonSymbols == QAbstractSpinBox::PlusMinus ? PE_IndicatorArrowUpBig
: PE_IndicatorArrowUpBig);
copy.rect = proxy()->subControlRect(CC_SpinBox, spinBox, SC_SpinBoxUp, widget);
if (copy.state & (State_Sunken | State_On))
qDrawPlainRect(painter, copy.rect, option->palette.shadow().color(), proxy()->pixelMetric(PM_SpinBoxFrameWidth, option, widget), ©.palette.brush(QPalette::Shadow));
else
qDrawPlainRect(painter, copy.rect, option->palette.shadow().color(), proxy()->pixelMetric(PM_SpinBoxFrameWidth, option, widget), ©.palette.brush(QPalette::Base));
copy.rect.adjust(proxy()->pixelMetric(PM_SpinBoxFrameWidth, option, widget), 0, -pixelMetric(PM_SpinBoxFrameWidth, option, widget), 0);
proxy()->drawPrimitive(PrimitiveElement(primitiveElement), ©, painter, widget);
}
if (spinBox->subControls & SC_SpinBoxDown) {
copy.subControls = SC_SpinBoxDown;
copy.state = spinBox->state;
QPalette pal2 = spinBox->palette;
if (!(spinBox->stepEnabled & QAbstractSpinBox::StepDownEnabled)) {
pal2.setCurrentColorGroup(QPalette::Disabled);
copy.state &= ~State_Enabled;
}
copy.palette = pal2;
if (spinBox->activeSubControls == SC_SpinBoxDown && (spinBox->state & State_Sunken)) {
copy.state |= State_On;
copy.state |= State_Sunken;
} else {
copy.state |= State_Raised;
copy.state &= ~State_Sunken;
}
primitiveElement = (spinBox->buttonSymbols == QAbstractSpinBox::PlusMinus ? PE_IndicatorArrowDownBig
: PE_IndicatorArrowDownBig);
copy.rect = proxy()->subControlRect(CC_SpinBox, spinBox, SC_SpinBoxDown, widget);
qDrawPlainRect(painter, copy.rect, option->palette.shadow().color(), proxy()->pixelMetric(PM_SpinBoxFrameWidth, option, widget), ©.palette.brush(QPalette::Base));
if (copy.state & (State_Sunken | State_On))
qDrawPlainRect(painter, copy.rect, option->palette.shadow().color(), proxy()->pixelMetric(PM_SpinBoxFrameWidth, option, widget), ©.palette.brush(QPalette::Shadow));
else
qDrawPlainRect(painter, copy.rect, option->palette.shadow().color(), proxy()->pixelMetric(PM_SpinBoxFrameWidth, option, widget), ©.palette.brush(QPalette::Base));
copy.rect.adjust(3, 0, -4, 0);
if (primitiveElement == PE_IndicatorArrowUp || primitiveElement == PE_IndicatorArrowDown) {
int frameWidth = proxy()->pixelMetric(PM_SpinBoxFrameWidth, option, widget);
copy.rect = copy.rect.adjusted(frameWidth, frameWidth, -frameWidth, -frameWidth);
proxy()->drawPrimitive(PrimitiveElement(primitiveElement), ©, painter, widget);
}
else {
proxy()->drawPrimitive(PrimitiveElement(primitiveElement), ©, painter, widget);
}
if (spinBox->frame && (spinBox->subControls & SC_SpinBoxFrame)) {
QRect r = proxy()->subControlRect(CC_SpinBox, spinBox, SC_SpinBoxEditField, widget);
}
}
}
break;
#endif // QT_NO_SPINBOX
default:
QWindowsStyle::drawComplexControl(control, option, painter, widget);
break;
}
}
QSize QWindowsMobileStyle::sizeFromContents(ContentsType type, const QStyleOption *option,
const QSize &size, const QWidget *widget) const {
QSize newSize = QWindowsStyle::sizeFromContents(type, option, size, widget);
switch (type) {
case CT_PushButton:
if (const QStyleOptionButton *button = qstyleoption_cast<const QStyleOptionButton *>(option)) {
newSize = QCommonStyle::sizeFromContents(type, option, size, widget);
int w = newSize.width(),
h = newSize.height();
int defwidth = 0;
if (button->features & QStyleOptionButton::AutoDefaultButton)
defwidth = 2 * proxy()->pixelMetric(PM_ButtonDefaultIndicator, button, widget);
int minwidth = int(QStyleHelper::dpiScaled(55.0f));
int minheight = int(QStyleHelper::dpiScaled(19.0f));
if (w < minwidth + defwidth && button->icon.isNull())
w = minwidth + defwidth;
if (h < minheight + defwidth)
h = minheight + defwidth;
newSize = QSize(w + 4, h + 4);
}
break;
#ifndef QT_NO_GROUPBOX
case CT_GroupBox:
if (const QGroupBox *grb = static_cast<const QGroupBox *>(widget)) {
newSize = size + QSize(!grb->isFlat() ? 16 : 0, !grb->isFlat() ? 16 : 0);
}
break;
#endif // QT_NO_GROUPBOX
case CT_RadioButton:
case CT_CheckBox:
newSize = size;
if (const QStyleOptionButton *button = qstyleoption_cast<const QStyleOptionButton *>(option)) {
bool isRadio = (type == CT_RadioButton);
QRect irect = visualRect(button->direction, button->rect,
proxy()->subElementRect(isRadio ? SE_RadioButtonIndicator
: SE_CheckBoxIndicator, button, widget));
int h = proxy()->pixelMetric(isRadio ? PM_ExclusiveIndicatorHeight
: PM_IndicatorHeight, button, widget);
int margins = (!button->icon.isNull() && button->text.isEmpty()) ? 0 : 10;
if (d_func()->doubleControls)
margins *= 2;
newSize += QSize(irect.right() + margins, 1);
newSize.setHeight(qMax(newSize.height(), h));
}
break;
#ifndef QT_NO_COMBOBOX
case CT_ComboBox:
if (const QStyleOptionComboBox *comboBox = qstyleoption_cast<const QStyleOptionComboBox *>(option)) {
int fw = comboBox->frame ? proxy()->pixelMetric(PM_ComboBoxFrameWidth, option, widget) * 2 : 0;
newSize = QSize(newSize.width() + fw + 9, newSize.height() + fw); //Nine is a magic Number - See CommonStyle for real magic (23)
}
break;
#endif
#ifndef QT_NO_SPINBOX
case CT_SpinBox:
if (const QStyleOptionSpinBox *spinBox = qstyleoption_cast<const QStyleOptionSpinBox *>(option)) {
int fw = spinBox->frame ? proxy()->pixelMetric(PM_SpinBoxFrameWidth, option, widget) * 2 : 0;
newSize = QSize(newSize.width() + fw-5, newSize.height() + fw-6);
}
break;
#endif
#ifndef QT_NO_LINEEDIT
case CT_LineEdit:
newSize += QSize(0,1);
break;
#endif
case CT_ToolButton:
newSize = QSize(newSize.width() + 1, newSize.height());
break;
case CT_TabBarTab:
if (d_func()->doubleControls)
newSize = QSize(newSize.width(), 42);
else
newSize = QSize(newSize.width(), 21);
break;
case CT_HeaderSection:
newSize += QSize(4, 2);
break;
#ifndef QT_NO_ITEMVIEWS
#ifdef Q_WS_WINCE_WM
case CT_ItemViewItem:
if (d_func()->wm65)
if (d_func()->doubleControls)
newSize.setHeight(46);
else
newSize.setHeight(23);
break;
#endif //Q_WS_WINCE_WM
#endif //QT_NO_ITEMVIEWS
default:
break;
}
return newSize;
}
QRect QWindowsMobileStyle::subElementRect(SubElement element, const QStyleOption *option, const QWidget *widget) const {
QWindowsMobileStylePrivate *d = const_cast<QWindowsMobileStylePrivate*>(d_func());
QRect rect = QWindowsStyle::subElementRect(element, option, widget);
switch (element) {
#ifndef QT_NO_TABWIDGET
case SE_TabWidgetTabBar:
if (d->doubleControls)
rect.adjust(-2, 0, 2, 0);
else
rect.adjust(-2, 0, 2, 0);
break;
#endif //QT_NO_TABWIDGET
case SE_CheckBoxFocusRect:
rect.adjust(1,0,-2,-1);
break;
case SE_RadioButtonFocusRect:
rect.adjust(1,1,-2,-2);
break;
default:
break;
#ifndef QT_NO_SLIDER
case SE_SliderFocusRect:
if (const QStyleOptionSlider *slider = qstyleoption_cast<const QStyleOptionSlider *>(option)) {
rect = slider->rect;
}
break;
case SE_PushButtonFocusRect:
if (d->doubleControls)
rect.adjust(-1, -1, 0, 0);
break;
#endif // QT_NO_SLIDER
#ifndef QT_NO_ITEMVIEWS
case SE_ItemViewItemFocusRect:
#ifdef Q_WS_WINCE_WM
if (d->wm65)
rect = QRect();
#endif
break;
#endif //QT_NO_ITEMVIEWS
}
return rect;
}
QRect QWindowsMobileStyle::subControlRect(ComplexControl control, const QStyleOptionComplex *option,
SubControl subControl, const QWidget *widget) const {
QWindowsMobileStylePrivate *d = const_cast<QWindowsMobileStylePrivate*>(d_func());
QRect rect = QCommonStyle::subControlRect(control, option, subControl, widget);
switch (control) {
#ifndef QT_NO_SCROLLBAR
case CC_ScrollBar:
if (const QStyleOptionSlider *scrollbar = qstyleoption_cast<const QStyleOptionSlider *>(option)) {
int sliderButtonExtent = proxy()->pixelMetric(PM_ScrollBarExtent, scrollbar, widget);
float stretchFactor = 1.4f;
int sliderButtonExtentDir = int (sliderButtonExtent * stretchFactor);
#ifdef Q_WS_WINCE_WM
if (d->wm65)
{
sliderButtonExtent = d->imageScrollbarHandleUp.width();
sliderButtonExtentDir = d->imageScrollbarHandleUp.height();
}
#endif //Q_WS_WINCE_WM
int sliderlen;
int maxlen = ((scrollbar->orientation == Qt::Horizontal) ?
scrollbar->rect.width() : scrollbar->rect.height()) - (sliderButtonExtentDir * 2);
// calculate slider length
if (scrollbar->maximum != scrollbar->minimum) {
uint range = scrollbar->maximum - scrollbar->minimum;
sliderlen = (qint64(scrollbar->pageStep) * maxlen) / (range + scrollbar->pageStep);
int slidermin = proxy()->pixelMetric(PM_ScrollBarSliderMin, scrollbar, widget);
if (sliderlen < slidermin || range > INT_MAX / 2)
sliderlen = slidermin;
if (sliderlen > maxlen)
sliderlen = maxlen;
} else {
sliderlen = maxlen;
}
int sliderstart = sliderButtonExtentDir + sliderPositionFromValue(scrollbar->minimum,
scrollbar->maximum,
scrollbar->sliderPosition,
maxlen - sliderlen,
scrollbar->upsideDown);
if (d->smartphone) {
sliderstart -= sliderButtonExtentDir;
sliderlen += 2*sliderButtonExtent;
}
switch (subControl) {
case SC_ScrollBarSubLine: // top/left button
if (scrollbar->orientation == Qt::Horizontal) {
int buttonWidth = qMin(scrollbar->rect.width() / 2, sliderButtonExtentDir );
rect.setRect(0, 0, buttonWidth, sliderButtonExtent);
} else {
int buttonHeight = qMin(scrollbar->rect.height() / 2, sliderButtonExtentDir);
rect.setRect(0, 0, sliderButtonExtent, buttonHeight);
}
if (d->smartphone)
rect.setRect(0, 0, 0, 0);
break;
case SC_ScrollBarAddLine: // bottom/right button
if (scrollbar->orientation == Qt::Horizontal) {
int buttonWidth = qMin(scrollbar->rect.width()/2, sliderButtonExtentDir);
rect.setRect(scrollbar->rect.width() - buttonWidth, 0, buttonWidth, sliderButtonExtent);
} else {
int buttonHeight = qMin(scrollbar->rect.height()/2, sliderButtonExtentDir );
rect.setRect(0, scrollbar->rect.height() - buttonHeight, sliderButtonExtent, buttonHeight);
}
if (d->smartphone)
rect.setRect(0, 0, 0, 0);
break;
case SC_ScrollBarSubPage: // between top/left button and slider
if (scrollbar->orientation == Qt::Horizontal)
if (d->smartphone)
rect.setRect(0, 0, sliderstart, sliderButtonExtent);
else
rect.setRect(sliderButtonExtent, 0, sliderstart - sliderButtonExtent, sliderButtonExtent);
else
if (d->smartphone)
rect.setRect(0, 0, sliderButtonExtent, sliderstart);
else
rect.setRect(0, sliderButtonExtent, sliderButtonExtent, sliderstart - sliderButtonExtent);
break;
case SC_ScrollBarAddPage: // between bottom/right button and slider
if (scrollbar->orientation == Qt::Horizontal)
if (d->smartphone)
rect.setRect(sliderstart + sliderlen, 0,
maxlen - sliderstart - sliderlen + 2*sliderButtonExtent, sliderButtonExtent);
else
rect.setRect(sliderstart + sliderlen, 0,
maxlen - sliderstart - sliderlen + sliderButtonExtent, sliderButtonExtent);
else
if (d->smartphone)
rect.setRect(0, sliderstart + sliderlen, sliderButtonExtent,
maxlen - sliderstart - sliderlen + 2*sliderButtonExtent);
else
rect.setRect(0, sliderstart + sliderlen, sliderButtonExtent,
maxlen - sliderstart - sliderlen + sliderButtonExtent);
break;
case SC_ScrollBarGroove:
if (scrollbar->orientation == Qt::Horizontal)
rect.setRect(sliderButtonExtent, 0, scrollbar->rect.width() - sliderButtonExtent * 2,
scrollbar->rect.height());
else
rect.setRect(0, sliderButtonExtent, scrollbar->rect.width(),
scrollbar->rect.height() - sliderButtonExtent * 2);
break;
case SC_ScrollBarSlider:
if (scrollbar->orientation == Qt::Horizontal)
rect.setRect(sliderstart, 0, sliderlen, sliderButtonExtent);
else
rect.setRect(0, sliderstart, sliderButtonExtent, sliderlen);
break;
default:
break;
}
rect = visualRect(scrollbar->direction, scrollbar->rect, rect);
}
break;
#endif // QT_NO_SCROLLBAR
#ifndef QT_NO_TOOLBUTTON
case CC_ToolButton:
if (const QStyleOptionToolButton *toolButton = qstyleoption_cast<const QStyleOptionToolButton *>(option)) {
int mbi = proxy()->pixelMetric(PM_MenuButtonIndicator, toolButton, widget);
rect = toolButton->rect;
switch (subControl) {
case SC_ToolButton:
if ((toolButton->features
& (QStyleOptionToolButton::Menu | QStyleOptionToolButton::PopupDelay))
== QStyleOptionToolButton::Menu)
rect.adjust(0, 0, -mbi, 0);
break;
case SC_ToolButtonMenu:
if ((toolButton->features
& (QStyleOptionToolButton::Menu | QStyleOptionToolButton::PopupDelay))
== QStyleOptionToolButton::Menu)
rect.adjust(rect.width() - mbi, 1, 0, 1);
break;
default:
break;
}
rect = visualRect(toolButton->direction, toolButton->rect, rect);
}
break;
#endif // QT_NO_TOOLBUTTON
#ifndef QT_NO_SLIDER
case CC_Slider:
if (const QStyleOptionSlider *slider = qstyleoption_cast<const QStyleOptionSlider *>(option)) {
int tickOffset = proxy()->pixelMetric(PM_SliderTickmarkOffset, slider, widget);
int thickness = proxy()->pixelMetric(PM_SliderControlThickness, slider, widget);
switch (subControl) {
case SC_SliderHandle: {
int sliderPos = 0;
int len = proxy()->pixelMetric(PM_SliderLength, slider, widget);
bool horizontal = slider->orientation == Qt::Horizontal;
sliderPos = sliderPositionFromValue(slider->minimum, slider->maximum,
slider->sliderPosition,
(horizontal ? slider->rect.width()
: slider->rect.height()) - len,
slider->upsideDown);
if (horizontal)
rect.setRect(slider->rect.x() + sliderPos, slider->rect.y() + tickOffset, len, thickness);
else
rect.setRect(slider->rect.x() + tickOffset, slider->rect.y() + sliderPos, thickness, len);
break; }
default:
break;
}
rect = visualRect(slider->direction, slider->rect, rect);
}
break;
#endif //QT_NO_SLIDER
#ifndef QT_NO_COMBOBOX
case CC_ComboBox:
if (const QStyleOptionComboBox *comboBox = qstyleoption_cast<const QStyleOptionComboBox *>(option)) {
int x = comboBox->rect.x(),
y = comboBox->rect.y(),
wi = comboBox->rect.width(),
he = comboBox->rect.height();
int xpos = x;
int margin = comboBox->frame ? (d->doubleControls ? 2 : 1) : 0;
int bmarg = comboBox->frame ? (d->doubleControls ? 2 : 1) : 0;
if (subControl == SC_ComboBoxArrow)
xpos += wi - int((he - 2*bmarg)*0.9) - bmarg;
else
xpos += wi - (he - 2*bmarg) - bmarg;
switch (subControl) {
case SC_ComboBoxArrow:
rect.setRect(xpos, y + bmarg, he - 2*bmarg, he - 2*bmarg);
break;
case SC_ComboBoxEditField:
rect.setRect(x + margin, y + margin, wi - 2 * margin - int((he - 2*bmarg) * 0.84f), he - 2 * margin);
if (d->doubleControls) {
if (comboBox->editable)
rect.adjust(2, 0, 0, 0);
else
rect.adjust(4, 2, 0, -2);
} else if (!comboBox->editable) {
rect.adjust(2, 1, 0, -1);
}
break;
case SC_ComboBoxFrame:
rect = comboBox->rect;
break;
default:
break;
}
}
#endif //QT_NO_COMBOBOX
#ifndef QT_NO_SPINBOX
case CC_SpinBox:
if (const QStyleOptionSpinBox *spinBox = qstyleoption_cast<const QStyleOptionSpinBox *>(option)) {
QSize bs;
int fw = spinBox->frame ? proxy()->pixelMetric(PM_SpinBoxFrameWidth, spinBox, widget) : 0;
bs.setHeight(qMax(d->doubleControls ? 28 : 14, (spinBox->rect.height())));
// 1.6 -approximate golden mean
bs.setWidth(qMax(d->doubleControls ? 28 : 14, qMin((bs.height()*7/8), (spinBox->rect.width() / 8))));
bs = bs.expandedTo(QApplication::globalStrut());
int x, lx, rx;
x = spinBox->rect.width() - bs.width()*2;
lx = fw;
rx = x - fw;
switch (subControl) {
case SC_SpinBoxUp:
rect = QRect(x + proxy()->pixelMetric(PM_SpinBoxFrameWidth, option, widget), 0 , bs.width(), bs.height());
break;
case SC_SpinBoxDown:
rect = QRect(x + bs.width(), 0, bs.width(), bs.height());
break;
case SC_SpinBoxEditField:
if (spinBox->buttonSymbols == QAbstractSpinBox::NoButtons) {
rect = QRect(lx, fw, spinBox->rect.width() - 2*fw - 2, spinBox->rect.height() - 2*fw);
} else {
rect = QRect(lx, fw, rx-2, spinBox->rect.height() - 2*fw);
}
break;
case SC_SpinBoxFrame:
rect = spinBox->rect;
default:
break;
}
rect = visualRect(spinBox->direction, spinBox->rect, rect);
}
break;
#endif // Qt_NO_SPINBOX
#ifndef QT_NO_GROUPBOX
case CC_GroupBox: {
if (const QStyleOptionGroupBox *groupBox = qstyleoption_cast<const QStyleOptionGroupBox *>(option)) {
switch (subControl) {
case SC_GroupBoxFrame:
// FALL THROUGH
case SC_GroupBoxContents: {
int topMargin = 0;
int topHeight = 0;
int bottomMargin = 0;
int labelMargin = 2;
QRect frameRect = groupBox->rect;
int verticalAlignment = styleHint(SH_GroupBox_TextLabelVerticalAlignment, groupBox, widget);
if (groupBox->text.size()) {
topHeight = groupBox->fontMetrics.height();
if (verticalAlignment & Qt::AlignVCenter)
topMargin = topHeight+5;
else if (verticalAlignment & Qt::AlignTop)
topMargin = -topHeight+5;
}
if (subControl == SC_GroupBoxFrame) {
frameRect.setTop(topMargin);
frameRect.setBottom(frameRect.height() + bottomMargin);
rect = frameRect;
break;
}
int frameWidth = 0;
if (groupBox->text.size()) {
frameWidth = proxy()->pixelMetric(PM_DefaultFrameWidth, groupBox, widget);
rect = frameRect.adjusted(frameWidth, frameWidth + topHeight + labelMargin, -frameWidth, -frameWidth);
}
else {
rect = groupBox->rect;
}
break;
}
case SC_GroupBoxCheckBox:
// FALL THROUGH
case SC_GroupBoxLabel: {
QFontMetrics fontMetrics = groupBox->fontMetrics;
int h = fontMetrics.height();
int textWidth = fontMetrics.size(Qt::TextShowMnemonic, groupBox->text + QLatin1Char(' ')).width();
int margX = (groupBox->features & QStyleOptionFrameV2::Flat) ? 0 : 2;
int margY = (groupBox->features & QStyleOptionFrameV2::Flat) ? 0 : 2;
rect = groupBox->rect.adjusted(margX, margY, -margX, 0);
if (groupBox->text.size())
rect.setHeight(h);
else
rect.setHeight(0);
int indicatorWidth = proxy()->pixelMetric(PM_IndicatorWidth, option, widget);
int indicatorSpace = proxy()->pixelMetric(PM_CheckBoxLabelSpacing, option, widget) - 1;
bool hasCheckBox = groupBox->subControls & QStyle::SC_GroupBoxCheckBox;
int checkBoxSize = hasCheckBox ? (indicatorWidth + indicatorSpace) : 0;
// Adjusted rect for label + indicatorWidth + indicatorSpace
QRect totalRect = alignedRect(groupBox->direction, groupBox->textAlignment,
QSize(textWidth + checkBoxSize, h), rect);
// Adjust totalRect if checkbox is set
if (hasCheckBox) {
bool ltr = groupBox->direction == Qt::LeftToRight;
int left = 2;
// Adjust for check box
if (subControl == SC_GroupBoxCheckBox) {
int indicatorHeight = proxy()->pixelMetric(PM_IndicatorHeight, option, widget);
left = ltr ? totalRect.left() : (totalRect.right() - indicatorWidth);
int top = totalRect.top() + (fontMetrics.height() - indicatorHeight) / 2;
totalRect.setRect(left, top, indicatorWidth, indicatorHeight);
// Adjust for label
} else {
left = ltr ? (totalRect.left() + checkBoxSize - 2) : totalRect.left();
totalRect.setRect(left, totalRect.top(),
totalRect.width() - checkBoxSize, totalRect.height());
}
}
if ((subControl== SC_GroupBoxLabel))
totalRect.adjust(-2,0,6,0);
rect = totalRect;
break;
}
default:
break;
}
}
break;
}
#endif // QT_NO_GROUPBOX
default:
break;
}
return rect;
}
QPalette QWindowsMobileStyle::standardPalette() const {
QPalette palette (Qt::black,QColor(198, 195, 198), QColor(222, 223, 222 ),
QColor(132, 130, 132), QColor(198, 195, 198), Qt::black, Qt::white, Qt::white, QColor(198, 195, 198));
palette.setColor(QPalette::Window, QColor(206, 223, 239));
palette.setColor(QPalette::Link, QColor(8,77,123)); //Alternate TextColor for labels...
palette.setColor(QPalette::Base, Qt::white);
palette.setColor(QPalette::Button, QColor(206, 223, 239));
palette.setColor(QPalette::Highlight, QColor(49, 146, 214));
palette.setColor(QPalette::Light, Qt::white);
palette.setColor(QPalette::Text, Qt::black);
palette.setColor(QPalette::ButtonText, Qt::black);
palette.setColor(QPalette::Midlight, QColor(222, 223, 222 ));
palette.setColor(QPalette::Dark, QColor(132, 130, 132));
palette.setColor(QPalette::Mid, QColor(189, 190, 189));
palette.setColor(QPalette::Shadow, QColor(0, 0, 0));
palette.setColor(QPalette::BrightText, QColor(33, 162, 33)); //color for ItemView checked indicator (arrow)
return palette;
}
/*! \reimp */
void QWindowsMobileStyle::polish(QApplication *application) {
QWindowsStyle::polish(application);
}
/*! \reimp */
void QWindowsMobileStyle::polish(QWidget *widget) {
#ifndef QT_NO_TOOLBAR
if (QToolBar *toolBar = qobject_cast<QToolBar*>(widget)) {
QPalette pal = toolBar->palette();
pal.setColor(QPalette::Background, pal.button().color());
toolBar->setPalette(pal);
}
else
#endif //QT_NO_TOOLBAR
QWindowsStyle::polish(widget);
}
void QWindowsMobileStyle::unpolish(QWidget *widget)
{
QWindowsStyle::unpolish(widget);
}
void QWindowsMobileStyle::unpolish(QApplication *app)
{
QWindowsStyle::unpolish(app);
}
/*! \reimp */
void QWindowsMobileStyle::polish(QPalette &palette) {
QWindowsStyle::polish(palette);
}
int QWindowsMobileStyle::pixelMetric(PixelMetric pm, const QStyleOption *opt, const QWidget *widget) const {
QWindowsMobileStylePrivate *d = const_cast<QWindowsMobileStylePrivate*>(d_func());
int ret;
switch (pm) {
case PM_DefaultTopLevelMargin:
ret =0;
break;
case PM_DefaultLayoutSpacing:
d->doubleControls ? ret = 8 : ret = 4;
break;
case PM_HeaderMargin:
d->doubleControls ? ret = 2 : ret = 1;
break;
case PM_DefaultChildMargin:
d->doubleControls ? ret = 10 : ret = 5;
break;
case PM_ToolBarSeparatorExtent:
d->doubleControls ? ret = 6 : ret = 3;
break;
case PM_DefaultFrameWidth:
d->doubleControls ? ret = 2 : ret = 1;
break;
case PM_MenuVMargin:
ret = 1;
break;
case PM_MenuHMargin:
ret = 1;
break;
case PM_MenuButtonIndicator:
ret = d->doubleControls ? 24 : 14;
break;
case PM_ComboBoxFrameWidth:
d->doubleControls ? ret = 2 : ret = 1;
break;
case PM_SpinBoxFrameWidth:
d->doubleControls ? ret = 2 : ret = 1;
break;
case PM_ButtonDefaultIndicator:
case PM_ButtonShiftHorizontal:
case PM_ButtonShiftVertical:
d->doubleControls ? ret = 2 : ret = 1;
break;
#ifndef QT_NO_TABBAR
case PM_TabBarTabShiftHorizontal:
ret = 0;
break;
case PM_TabBarTabShiftVertical:
ret = 0;
break;
#endif
case PM_MaximumDragDistance:
ret = 60;
break;
case PM_TabBarTabVSpace:
ret = d->doubleControls ? 12 : 6;
break;
case PM_TabBarBaseHeight:
ret = 0;
break;
case PM_IndicatorWidth:
ret = d->doubleControls ? windowsMobileIndicatorSize * 2 : windowsMobileIndicatorSize;
break;
case PM_IndicatorHeight:
ret = d->doubleControls ? windowsMobileIndicatorSize * 2 : windowsMobileIndicatorSize;
break;
case PM_ExclusiveIndicatorWidth:
ret = d->doubleControls ? windowsMobileExclusiveIndicatorSize * 2 + 4: windowsMobileExclusiveIndicatorSize + 2;
break;
case PM_ExclusiveIndicatorHeight:
ret = d->doubleControls ? windowsMobileExclusiveIndicatorSize * 2 + 4: windowsMobileExclusiveIndicatorSize + 2;
break;
#ifndef QT_NO_SLIDER
case PM_SliderLength:
ret = d->doubleControls ? 16 : 8;
break;
case PM_FocusFrameHMargin:
ret = d->doubleControls ? 1 : 2;
break;
case PM_SliderThickness:
ret = d->doubleControls ? windowsMobileSliderThickness * 2: windowsMobileSliderThickness;
break;
case PM_TabBarScrollButtonWidth:
ret = d->doubleControls ? 14 * 2 : 18;
break;
case PM_CheckBoxLabelSpacing:
case PM_RadioButtonLabelSpacing:
ret = d->doubleControls ? 6 * 2 : 6;
break;
// Returns the number of pixels to use for the business part of the
// slider (i.e., the non-tickmark portion). The remaining space is shared
// equally between the tickmark regions.
case PM_SliderControlThickness:
if (const QStyleOptionSlider *sl = qstyleoption_cast<const QStyleOptionSlider *>(opt)) {
int space = (sl->orientation == Qt::Horizontal) ? sl->rect.height() : sl->rect.width();
int ticks = sl->tickPosition;
int n = 0;
if (ticks & QSlider::TicksAbove)
++n;
if (ticks & QSlider::TicksBelow)
++n;
if (!n) {
ret = space;
break;
}
int thick = 8;
if (ticks != QSlider::TicksBothSides && ticks != QSlider::NoTicks)
thick += proxy()->pixelMetric(PM_SliderLength, sl, widget) / 4;
space -= thick;
if (space > 0)
thick += (space * 2) / (n + 2);
ret = thick;
} else {
ret = 0;
}
break;
#endif // QT_NO_SLIDER
#ifndef QT_NO_MENU
case PM_SmallIconSize:
d->doubleControls ? ret = windowsMobileIconSize * 2 : ret = windowsMobileIconSize;
break;
case PM_ButtonMargin:
d->doubleControls ? ret = 8 : ret = 4;
break;
case PM_LargeIconSize:
d->doubleControls ? ret = 64 : ret = 32;
break;
case PM_IconViewIconSize:
ret = proxy()->pixelMetric(PM_LargeIconSize, opt, widget);
break;
case PM_ToolBarIconSize:
d->doubleControls ? ret = 2 * windowsMobileIconSize : ret = windowsMobileIconSize;
break;
case PM_DockWidgetTitleMargin:
ret = 2;
break;
#if defined(Q_WS_WIN)
#else
case PM_DockWidgetFrameWidth:
ret = 4;
break;
#endif // Q_WS_WIN
break;
#endif // QT_NO_MENU
case PM_TitleBarHeight:
d->doubleControls ? ret = 42 : ret = 21;
break;
case PM_ScrollBarSliderMin:
#ifdef Q_WS_WINCE_WM
if (d->wm65)
#else
if (false)
#endif
{
d->doubleControls ? ret = 68 : ret = 34;
} else {
d->doubleControls ? ret = 36 : ret = 18;
}
break;
case PM_ScrollBarExtent: {
if (d->smartphone)
ret = 9;
else
d->doubleControls ? ret = 25 : ret = 13;
#ifdef Q_WS_WINCE_WM
if (d->wm65)
#else
if (false)
#endif
{
d->doubleControls ? ret = 26 : ret = 13;
break;
}
#ifndef QT_NO_SCROLLAREA
//Check if the scrollbar is part of an abstractItemView and set size according
if (widget)
if (QWidget *parent = widget->parentWidget())
if (qobject_cast<QAbstractScrollArea *>(parent->parentWidget()))
if (d->smartphone)
ret = 8;
else
d->doubleControls ? ret = 24 : ret = 12;
#endif
}
break;
case PM_SplitterWidth:
ret = qMax(4, QApplication::globalStrut().width());
break;
#if defined(Q_WS_WIN)
case PM_MDIFrameWidth:
ret = 1;
break;
#endif
case PM_ToolBarExtensionExtent:
d->doubleControls ? ret = 32 : ret = 16;
break;
case PM_ToolBarItemMargin:
d->doubleControls ? ret = 2 : ret = 1;
break;
case PM_ToolBarItemSpacing:
d->doubleControls ? ret = 2 : ret = 1;
break;
case PM_ToolBarHandleExtent:
d->doubleControls ? ret = 16 : ret = 8;
break;
case PM_ButtonIconSize:
d->doubleControls ? ret = 32 : ret = 16;
break;
case PM_TextCursorWidth:
ret = 2;
break;
case PM_TabBar_ScrollButtonOverlap:
ret = 0;
break;
default:
ret = QWindowsStyle::pixelMetric(pm, opt, widget);
break;
}
return ret;
}
int QWindowsMobileStyle::styleHint(StyleHint hint, const QStyleOption *opt, const QWidget *widget,
QStyleHintReturn *returnData) const {
int ret;
switch (hint) {
case SH_Menu_MouseTracking:
case SH_ComboBox_ListMouseTracking:
case SH_EtchDisabledText:
ret = 0;
break;
case SH_DitherDisabledText:
ret = 0;
break;
case SH_ItemView_ShowDecorationSelected:
ret = 0;
break;
#ifndef QT_NO_TABWIDGET
case SH_TabWidget_DefaultTabPosition:
ret = QTabWidget::South;
break;
#endif
case SH_ToolBar_Movable:
ret = false;
break;
case SH_ScrollBar_ContextMenu:
ret = false;
break;
case SH_MenuBar_AltKeyNavigation:
ret = false;
break;
case SH_RequestSoftwareInputPanel:
ret = RSIP_OnMouseClick;
break;
default:
ret = QWindowsStyle::styleHint(hint, opt, widget, returnData);
break;
}
return ret;
}
QPixmap QWindowsMobileStyle::standardPixmap(StandardPixmap sp, const QStyleOption *option,
const QWidget *widget) const {
QWindowsMobileStylePrivate *d = const_cast<QWindowsMobileStylePrivate*>(d_func());
switch (sp) {
#ifndef QT_NO_IMAGEFORMAT_XPM
case SP_ToolBarHorizontalExtensionButton: {
QPixmap pixmap = QCommonStyle::standardPixmap(sp, option, widget);
if (d->doubleControls)
return pixmap.scaledToHeight(pixmap.height() * 2);
else
return pixmap;
}
case SP_TitleBarMaxButton:
case SP_TitleBarCloseButton:
case SP_TitleBarNormalButton:
case SP_TitleBarMinButton: {
QImage image;
switch (sp) {
case SP_TitleBarMaxButton:
image = d->imageMaximize;
break;
case SP_TitleBarCloseButton:
image = d->imageClose;
break;
case SP_TitleBarNormalButton:
image = d->imageNormalize;
break;
case SP_TitleBarMinButton:
image = d->imageMinimize;
break;
default:
break;
}
if (option) {
image.setColor(0, option->palette.shadow().color().rgba());
image.setColor(1, option->palette.highlight().color().rgba());
image.setColor(2, option->palette.highlight().color().lighter(150).rgba());
image.setColor(3, option->palette.highlightedText().color().rgba());
}
return QPixmap::fromImage(image);
}
#endif
default:
return QWindowsStyle::standardPixmap(sp, option, widget);
}
}
QPixmap QWindowsMobileStyle::generatedIconPixmap(QIcon::Mode iconMode, const QPixmap &pixmap,
const QStyleOption *option) const {
switch (iconMode) {
case QIcon::Selected: {
#ifdef Q_WS_WINCE_WM
if (d_func()->wm65)
return pixmap;
#endif //Q_WS_WINCE_WM
QImage img = pixmap.toImage().convertToFormat(QImage::Format_ARGB32);
int imgh = img.height();
int imgw = img.width();
for (int y = 0; y < imgh; y += 2) {
for (int x = 0; x < imgw; x += 2) {
QColor c = option->palette.highlight().color().rgb();
c.setAlpha( qAlpha(img.pixel(x, y)));
QRgb pixel = c.rgba();
img.setPixel(x, y, pixel);
}
}
return QPixmap::fromImage(img);
}
default:
break;
}
return QWindowsStyle::generatedIconPixmap(iconMode, pixmap, option);
}
bool QWindowsMobileStyle::doubleControls() const {
QWindowsMobileStylePrivate *d = const_cast<QWindowsMobileStylePrivate*>(d_func());
return d->doubleControls;
}
void QWindowsMobileStyle::setDoubleControls(bool doubleControls) {
QWindowsMobileStylePrivate *d = const_cast<QWindowsMobileStylePrivate*>(d_func());
d->doubleControls = doubleControls;
}
QT_END_NAMESPACE
#endif // QT_NO_STYLE_WINDOWSMOBILE
| Java |
/**
*/
package org.w3._2001.smil20.language;
import org.eclipse.emf.ecore.EAttribute;
import org.eclipse.emf.ecore.EClass;
import org.eclipse.emf.ecore.EPackage;
import org.eclipse.emf.ecore.EReference;
import org.w3._2001.smil20.Smil20Package;
/**
* <!-- begin-user-doc -->
* The <b>Package</b> for the model.
* It contains accessors for the meta objects to represent
* <ul>
* <li>each class,</li>
* <li>each feature of each class,</li>
* <li>each operation of each class,</li>
* <li>each enum,</li>
* <li>and each data type</li>
* </ul>
* <!-- end-user-doc -->
* <!-- begin-model-doc -->
*
* <div xmlns="http://www.w3.org/1999/xhtml">
* <h1>About the XML namespace</h1>
*
* <div class="bodytext">
* <p>
* This schema document describes the XML namespace, in a form
* suitable for import by other schema documents.
* </p>
* <p>
* See <a href="http://www.w3.org/XML/1998/namespace.html">
* http://www.w3.org/XML/1998/namespace.html</a> and
* <a href="http://www.w3.org/TR/REC-xml">
* http://www.w3.org/TR/REC-xml</a> for information
* about this namespace.
* </p>
* <p>
* Note that local names in this namespace are intended to be
* defined only by the World Wide Web Consortium or its subgroups.
* The names currently defined in this namespace are listed below.
* They should not be used with conflicting semantics by any Working
* Group, specification, or document instance.
* </p>
* <p>
* See further below in this document for more information about <a href="#usage">how to refer to this schema document from your own
* XSD schema documents</a> and about <a href="#nsversioning">the
* namespace-versioning policy governing this schema document</a>.
* </p>
* </div>
* </div>
*
*
* <div xmlns="http://www.w3.org/1999/xhtml">
*
* <h3>Father (in any context at all)</h3>
*
* <div class="bodytext">
* <p>
* denotes Jon Bosak, the chair of
* the original XML Working Group. This name is reserved by
* the following decision of the W3C XML Plenary and
* XML Coordination groups:
* </p>
* <blockquote>
* <p>
* In appreciation for his vision, leadership and
* dedication the W3C XML Plenary on this 10th day of
* February, 2000, reserves for Jon Bosak in perpetuity
* the XML name "xml:Father".
* </p>
* </blockquote>
* </div>
* </div>
*
*
* <div id="usage" xml:id="usage" xmlns="http://www.w3.org/1999/xhtml">
* <h2>
* <a name="usage">About this schema document</a>
* </h2>
*
* <div class="bodytext">
* <p>
* This schema defines attributes and an attribute group suitable
* for use by schemas wishing to allow <code>xml:base</code>,
* <code>xml:lang</code>, <code>xml:space</code> or
* <code>xml:id</code> attributes on elements they define.
* </p>
* <p>
* To enable this, such a schema must import this schema for
* the XML namespace, e.g. as follows:
* </p>
* <pre>
* <schema . . .>
* . . .
* <import namespace="http://www.w3.org/XML/1998/namespace"
* schemaLocation="http://www.w3.org/2001/xml.xsd"/>
* </pre>
* <p>
* or
* </p>
* <pre>
* <import namespace="http://www.w3.org/XML/1998/namespace"
* schemaLocation="http://www.w3.org/2009/01/xml.xsd"/>
* </pre>
* <p>
* Subsequently, qualified reference to any of the attributes or the
* group defined below will have the desired effect, e.g.
* </p>
* <pre>
* <type . . .>
* . . .
* <attributeGroup ref="xml:specialAttrs"/>
* </pre>
* <p>
* will define a type which will schema-validate an instance element
* with any of those attributes.
* </p>
* </div>
* </div>
*
*
* <div id="nsversioning" xml:id="nsversioning" xmlns="http://www.w3.org/1999/xhtml">
* <h2>
* <a name="nsversioning">Versioning policy for this schema document</a>
* </h2>
* <div class="bodytext">
* <p>
* In keeping with the XML Schema WG's standard versioning
* policy, this schema document will persist at
* <a href="http://www.w3.org/2009/01/xml.xsd">
* http://www.w3.org/2009/01/xml.xsd</a>.
* </p>
* <p>
* At the date of issue it can also be found at
* <a href="http://www.w3.org/2001/xml.xsd">
* http://www.w3.org/2001/xml.xsd</a>.
* </p>
* <p>
* The schema document at that URI may however change in the future,
* in order to remain compatible with the latest version of XML
* Schema itself, or with the XML namespace itself. In other words,
* if the XML Schema or XML namespaces change, the version of this
* document at <a href="http://www.w3.org/2001/xml.xsd">
* http://www.w3.org/2001/xml.xsd
* </a>
* will change accordingly; the version at
* <a href="http://www.w3.org/2009/01/xml.xsd">
* http://www.w3.org/2009/01/xml.xsd
* </a>
* will not change.
* </p>
* <p>
* Previous dated (and unchanging) versions of this schema
* document are at:
* </p>
* <ul>
* <li>
* <a href="http://www.w3.org/2009/01/xml.xsd">
* http://www.w3.org/2009/01/xml.xsd</a>
* </li>
* <li>
* <a href="http://www.w3.org/2007/08/xml.xsd">
* http://www.w3.org/2007/08/xml.xsd</a>
* </li>
* <li>
* <a href="http://www.w3.org/2004/10/xml.xsd">
* http://www.w3.org/2004/10/xml.xsd</a>
* </li>
* <li>
* <a href="http://www.w3.org/2001/03/xml.xsd">
* http://www.w3.org/2001/03/xml.xsd</a>
* </li>
* </ul>
* </div>
* </div>
*
* <!-- end-model-doc -->
* @see org.w3._2001.smil20.language.LanguageFactory
* @model kind="package"
* @generated
*/
public interface LanguagePackage extends EPackage {
/**
* The package name.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
String eNAME = "language";
/**
* The package namespace URI.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
String eNS_URI = "http://www.w3.org/2001/SMIL20/Language";
/**
* The package namespace name.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
String eNS_PREFIX = "language";
/**
* The singleton instance of the package.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
LanguagePackage eINSTANCE = org.w3._2001.smil20.language.impl.LanguagePackageImpl.init();
/**
* The meta object id for the '{@link org.w3._2001.smil20.language.impl.AnimateColorTypeImpl <em>Animate Color Type</em>}' class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @see org.w3._2001.smil20.language.impl.AnimateColorTypeImpl
* @see org.w3._2001.smil20.language.impl.LanguagePackageImpl#getAnimateColorType()
* @generated
*/
int ANIMATE_COLOR_TYPE = 0;
/**
* The feature id for the '<em><b>Accumulate</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int ANIMATE_COLOR_TYPE__ACCUMULATE = Smil20Package.ANIMATE_COLOR_PROTOTYPE__ACCUMULATE;
/**
* The feature id for the '<em><b>Additive</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int ANIMATE_COLOR_TYPE__ADDITIVE = Smil20Package.ANIMATE_COLOR_PROTOTYPE__ADDITIVE;
/**
* The feature id for the '<em><b>Attribute Name</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int ANIMATE_COLOR_TYPE__ATTRIBUTE_NAME = Smil20Package.ANIMATE_COLOR_PROTOTYPE__ATTRIBUTE_NAME;
/**
* The feature id for the '<em><b>Attribute Type</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int ANIMATE_COLOR_TYPE__ATTRIBUTE_TYPE = Smil20Package.ANIMATE_COLOR_PROTOTYPE__ATTRIBUTE_TYPE;
/**
* The feature id for the '<em><b>By</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int ANIMATE_COLOR_TYPE__BY = Smil20Package.ANIMATE_COLOR_PROTOTYPE__BY;
/**
* The feature id for the '<em><b>From</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int ANIMATE_COLOR_TYPE__FROM = Smil20Package.ANIMATE_COLOR_PROTOTYPE__FROM;
/**
* The feature id for the '<em><b>To</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int ANIMATE_COLOR_TYPE__TO = Smil20Package.ANIMATE_COLOR_PROTOTYPE__TO;
/**
* The feature id for the '<em><b>Values</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int ANIMATE_COLOR_TYPE__VALUES = Smil20Package.ANIMATE_COLOR_PROTOTYPE__VALUES;
/**
* The feature id for the '<em><b>Group</b></em>' attribute list.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int ANIMATE_COLOR_TYPE__GROUP = Smil20Package.ANIMATE_COLOR_PROTOTYPE_FEATURE_COUNT + 0;
/**
* The feature id for the '<em><b>Any</b></em>' attribute list.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int ANIMATE_COLOR_TYPE__ANY = Smil20Package.ANIMATE_COLOR_PROTOTYPE_FEATURE_COUNT + 1;
/**
* The feature id for the '<em><b>Alt</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int ANIMATE_COLOR_TYPE__ALT = Smil20Package.ANIMATE_COLOR_PROTOTYPE_FEATURE_COUNT + 2;
/**
* The feature id for the '<em><b>Begin</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int ANIMATE_COLOR_TYPE__BEGIN = Smil20Package.ANIMATE_COLOR_PROTOTYPE_FEATURE_COUNT + 3;
/**
* The feature id for the '<em><b>Calc Mode</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int ANIMATE_COLOR_TYPE__CALC_MODE = Smil20Package.ANIMATE_COLOR_PROTOTYPE_FEATURE_COUNT + 4;
/**
* The feature id for the '<em><b>Class</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int ANIMATE_COLOR_TYPE__CLASS = Smil20Package.ANIMATE_COLOR_PROTOTYPE_FEATURE_COUNT + 5;
/**
* The feature id for the '<em><b>Dur</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int ANIMATE_COLOR_TYPE__DUR = Smil20Package.ANIMATE_COLOR_PROTOTYPE_FEATURE_COUNT + 6;
/**
* The feature id for the '<em><b>End</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int ANIMATE_COLOR_TYPE__END = Smil20Package.ANIMATE_COLOR_PROTOTYPE_FEATURE_COUNT + 7;
/**
* The feature id for the '<em><b>Fill</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int ANIMATE_COLOR_TYPE__FILL = Smil20Package.ANIMATE_COLOR_PROTOTYPE_FEATURE_COUNT + 8;
/**
* The feature id for the '<em><b>Fill Default</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int ANIMATE_COLOR_TYPE__FILL_DEFAULT = Smil20Package.ANIMATE_COLOR_PROTOTYPE_FEATURE_COUNT + 9;
/**
* The feature id for the '<em><b>Id</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int ANIMATE_COLOR_TYPE__ID = Smil20Package.ANIMATE_COLOR_PROTOTYPE_FEATURE_COUNT + 10;
/**
* The feature id for the '<em><b>Lang</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int ANIMATE_COLOR_TYPE__LANG = Smil20Package.ANIMATE_COLOR_PROTOTYPE_FEATURE_COUNT + 11;
/**
* The feature id for the '<em><b>Longdesc</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int ANIMATE_COLOR_TYPE__LONGDESC = Smil20Package.ANIMATE_COLOR_PROTOTYPE_FEATURE_COUNT + 12;
/**
* The feature id for the '<em><b>Max</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int ANIMATE_COLOR_TYPE__MAX = Smil20Package.ANIMATE_COLOR_PROTOTYPE_FEATURE_COUNT + 13;
/**
* The feature id for the '<em><b>Min</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int ANIMATE_COLOR_TYPE__MIN = Smil20Package.ANIMATE_COLOR_PROTOTYPE_FEATURE_COUNT + 14;
/**
* The feature id for the '<em><b>Repeat</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int ANIMATE_COLOR_TYPE__REPEAT = Smil20Package.ANIMATE_COLOR_PROTOTYPE_FEATURE_COUNT + 15;
/**
* The feature id for the '<em><b>Repeat Count</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int ANIMATE_COLOR_TYPE__REPEAT_COUNT = Smil20Package.ANIMATE_COLOR_PROTOTYPE_FEATURE_COUNT + 16;
/**
* The feature id for the '<em><b>Repeat Dur</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int ANIMATE_COLOR_TYPE__REPEAT_DUR = Smil20Package.ANIMATE_COLOR_PROTOTYPE_FEATURE_COUNT + 17;
/**
* The feature id for the '<em><b>Restart</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int ANIMATE_COLOR_TYPE__RESTART = Smil20Package.ANIMATE_COLOR_PROTOTYPE_FEATURE_COUNT + 18;
/**
* The feature id for the '<em><b>Restart Default</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int ANIMATE_COLOR_TYPE__RESTART_DEFAULT = Smil20Package.ANIMATE_COLOR_PROTOTYPE_FEATURE_COUNT + 19;
/**
* The feature id for the '<em><b>Skip Content</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int ANIMATE_COLOR_TYPE__SKIP_CONTENT = Smil20Package.ANIMATE_COLOR_PROTOTYPE_FEATURE_COUNT + 20;
/**
* The feature id for the '<em><b>Sync Behavior</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int ANIMATE_COLOR_TYPE__SYNC_BEHAVIOR = Smil20Package.ANIMATE_COLOR_PROTOTYPE_FEATURE_COUNT + 21;
/**
* The feature id for the '<em><b>Sync Behavior Default</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int ANIMATE_COLOR_TYPE__SYNC_BEHAVIOR_DEFAULT = Smil20Package.ANIMATE_COLOR_PROTOTYPE_FEATURE_COUNT + 22;
/**
* The feature id for the '<em><b>Sync Tolerance</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int ANIMATE_COLOR_TYPE__SYNC_TOLERANCE = Smil20Package.ANIMATE_COLOR_PROTOTYPE_FEATURE_COUNT + 23;
/**
* The feature id for the '<em><b>Sync Tolerance Default</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int ANIMATE_COLOR_TYPE__SYNC_TOLERANCE_DEFAULT = Smil20Package.ANIMATE_COLOR_PROTOTYPE_FEATURE_COUNT + 24;
/**
* The feature id for the '<em><b>Target Element</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int ANIMATE_COLOR_TYPE__TARGET_ELEMENT = Smil20Package.ANIMATE_COLOR_PROTOTYPE_FEATURE_COUNT + 25;
/**
* The feature id for the '<em><b>Any Attribute</b></em>' attribute list.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int ANIMATE_COLOR_TYPE__ANY_ATTRIBUTE = Smil20Package.ANIMATE_COLOR_PROTOTYPE_FEATURE_COUNT + 26;
/**
* The number of structural features of the '<em>Animate Color Type</em>' class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int ANIMATE_COLOR_TYPE_FEATURE_COUNT = Smil20Package.ANIMATE_COLOR_PROTOTYPE_FEATURE_COUNT + 27;
/**
* The number of operations of the '<em>Animate Color Type</em>' class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int ANIMATE_COLOR_TYPE_OPERATION_COUNT = Smil20Package.ANIMATE_COLOR_PROTOTYPE_OPERATION_COUNT + 0;
/**
* The meta object id for the '{@link org.w3._2001.smil20.language.impl.AnimateMotionTypeImpl <em>Animate Motion Type</em>}' class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @see org.w3._2001.smil20.language.impl.AnimateMotionTypeImpl
* @see org.w3._2001.smil20.language.impl.LanguagePackageImpl#getAnimateMotionType()
* @generated
*/
int ANIMATE_MOTION_TYPE = 1;
/**
* The feature id for the '<em><b>Accumulate</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int ANIMATE_MOTION_TYPE__ACCUMULATE = Smil20Package.ANIMATE_MOTION_PROTOTYPE__ACCUMULATE;
/**
* The feature id for the '<em><b>Additive</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int ANIMATE_MOTION_TYPE__ADDITIVE = Smil20Package.ANIMATE_MOTION_PROTOTYPE__ADDITIVE;
/**
* The feature id for the '<em><b>By</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int ANIMATE_MOTION_TYPE__BY = Smil20Package.ANIMATE_MOTION_PROTOTYPE__BY;
/**
* The feature id for the '<em><b>From</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int ANIMATE_MOTION_TYPE__FROM = Smil20Package.ANIMATE_MOTION_PROTOTYPE__FROM;
/**
* The feature id for the '<em><b>Origin</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int ANIMATE_MOTION_TYPE__ORIGIN = Smil20Package.ANIMATE_MOTION_PROTOTYPE__ORIGIN;
/**
* The feature id for the '<em><b>To</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int ANIMATE_MOTION_TYPE__TO = Smil20Package.ANIMATE_MOTION_PROTOTYPE__TO;
/**
* The feature id for the '<em><b>Values</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int ANIMATE_MOTION_TYPE__VALUES = Smil20Package.ANIMATE_MOTION_PROTOTYPE__VALUES;
/**
* The feature id for the '<em><b>Group</b></em>' attribute list.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int ANIMATE_MOTION_TYPE__GROUP = Smil20Package.ANIMATE_MOTION_PROTOTYPE_FEATURE_COUNT + 0;
/**
* The feature id for the '<em><b>Any</b></em>' attribute list.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int ANIMATE_MOTION_TYPE__ANY = Smil20Package.ANIMATE_MOTION_PROTOTYPE_FEATURE_COUNT + 1;
/**
* The feature id for the '<em><b>Alt</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int ANIMATE_MOTION_TYPE__ALT = Smil20Package.ANIMATE_MOTION_PROTOTYPE_FEATURE_COUNT + 2;
/**
* The feature id for the '<em><b>Begin</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int ANIMATE_MOTION_TYPE__BEGIN = Smil20Package.ANIMATE_MOTION_PROTOTYPE_FEATURE_COUNT + 3;
/**
* The feature id for the '<em><b>Calc Mode</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int ANIMATE_MOTION_TYPE__CALC_MODE = Smil20Package.ANIMATE_MOTION_PROTOTYPE_FEATURE_COUNT + 4;
/**
* The feature id for the '<em><b>Class</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int ANIMATE_MOTION_TYPE__CLASS = Smil20Package.ANIMATE_MOTION_PROTOTYPE_FEATURE_COUNT + 5;
/**
* The feature id for the '<em><b>Dur</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int ANIMATE_MOTION_TYPE__DUR = Smil20Package.ANIMATE_MOTION_PROTOTYPE_FEATURE_COUNT + 6;
/**
* The feature id for the '<em><b>End</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int ANIMATE_MOTION_TYPE__END = Smil20Package.ANIMATE_MOTION_PROTOTYPE_FEATURE_COUNT + 7;
/**
* The feature id for the '<em><b>Fill</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int ANIMATE_MOTION_TYPE__FILL = Smil20Package.ANIMATE_MOTION_PROTOTYPE_FEATURE_COUNT + 8;
/**
* The feature id for the '<em><b>Fill Default</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int ANIMATE_MOTION_TYPE__FILL_DEFAULT = Smil20Package.ANIMATE_MOTION_PROTOTYPE_FEATURE_COUNT + 9;
/**
* The feature id for the '<em><b>Id</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int ANIMATE_MOTION_TYPE__ID = Smil20Package.ANIMATE_MOTION_PROTOTYPE_FEATURE_COUNT + 10;
/**
* The feature id for the '<em><b>Lang</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int ANIMATE_MOTION_TYPE__LANG = Smil20Package.ANIMATE_MOTION_PROTOTYPE_FEATURE_COUNT + 11;
/**
* The feature id for the '<em><b>Longdesc</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int ANIMATE_MOTION_TYPE__LONGDESC = Smil20Package.ANIMATE_MOTION_PROTOTYPE_FEATURE_COUNT + 12;
/**
* The feature id for the '<em><b>Max</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int ANIMATE_MOTION_TYPE__MAX = Smil20Package.ANIMATE_MOTION_PROTOTYPE_FEATURE_COUNT + 13;
/**
* The feature id for the '<em><b>Min</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int ANIMATE_MOTION_TYPE__MIN = Smil20Package.ANIMATE_MOTION_PROTOTYPE_FEATURE_COUNT + 14;
/**
* The feature id for the '<em><b>Repeat</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int ANIMATE_MOTION_TYPE__REPEAT = Smil20Package.ANIMATE_MOTION_PROTOTYPE_FEATURE_COUNT + 15;
/**
* The feature id for the '<em><b>Repeat Count</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int ANIMATE_MOTION_TYPE__REPEAT_COUNT = Smil20Package.ANIMATE_MOTION_PROTOTYPE_FEATURE_COUNT + 16;
/**
* The feature id for the '<em><b>Repeat Dur</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int ANIMATE_MOTION_TYPE__REPEAT_DUR = Smil20Package.ANIMATE_MOTION_PROTOTYPE_FEATURE_COUNT + 17;
/**
* The feature id for the '<em><b>Restart</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int ANIMATE_MOTION_TYPE__RESTART = Smil20Package.ANIMATE_MOTION_PROTOTYPE_FEATURE_COUNT + 18;
/**
* The feature id for the '<em><b>Restart Default</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int ANIMATE_MOTION_TYPE__RESTART_DEFAULT = Smil20Package.ANIMATE_MOTION_PROTOTYPE_FEATURE_COUNT + 19;
/**
* The feature id for the '<em><b>Skip Content</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int ANIMATE_MOTION_TYPE__SKIP_CONTENT = Smil20Package.ANIMATE_MOTION_PROTOTYPE_FEATURE_COUNT + 20;
/**
* The feature id for the '<em><b>Sync Behavior</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int ANIMATE_MOTION_TYPE__SYNC_BEHAVIOR = Smil20Package.ANIMATE_MOTION_PROTOTYPE_FEATURE_COUNT + 21;
/**
* The feature id for the '<em><b>Sync Behavior Default</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int ANIMATE_MOTION_TYPE__SYNC_BEHAVIOR_DEFAULT = Smil20Package.ANIMATE_MOTION_PROTOTYPE_FEATURE_COUNT + 22;
/**
* The feature id for the '<em><b>Sync Tolerance</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int ANIMATE_MOTION_TYPE__SYNC_TOLERANCE = Smil20Package.ANIMATE_MOTION_PROTOTYPE_FEATURE_COUNT + 23;
/**
* The feature id for the '<em><b>Sync Tolerance Default</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int ANIMATE_MOTION_TYPE__SYNC_TOLERANCE_DEFAULT = Smil20Package.ANIMATE_MOTION_PROTOTYPE_FEATURE_COUNT + 24;
/**
* The feature id for the '<em><b>Target Element</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int ANIMATE_MOTION_TYPE__TARGET_ELEMENT = Smil20Package.ANIMATE_MOTION_PROTOTYPE_FEATURE_COUNT + 25;
/**
* The feature id for the '<em><b>Any Attribute</b></em>' attribute list.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int ANIMATE_MOTION_TYPE__ANY_ATTRIBUTE = Smil20Package.ANIMATE_MOTION_PROTOTYPE_FEATURE_COUNT + 26;
/**
* The number of structural features of the '<em>Animate Motion Type</em>' class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int ANIMATE_MOTION_TYPE_FEATURE_COUNT = Smil20Package.ANIMATE_MOTION_PROTOTYPE_FEATURE_COUNT + 27;
/**
* The number of operations of the '<em>Animate Motion Type</em>' class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int ANIMATE_MOTION_TYPE_OPERATION_COUNT = Smil20Package.ANIMATE_MOTION_PROTOTYPE_OPERATION_COUNT + 0;
/**
* The meta object id for the '{@link org.w3._2001.smil20.language.impl.AnimateTypeImpl <em>Animate Type</em>}' class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @see org.w3._2001.smil20.language.impl.AnimateTypeImpl
* @see org.w3._2001.smil20.language.impl.LanguagePackageImpl#getAnimateType()
* @generated
*/
int ANIMATE_TYPE = 2;
/**
* The feature id for the '<em><b>Accumulate</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int ANIMATE_TYPE__ACCUMULATE = Smil20Package.ANIMATE_PROTOTYPE__ACCUMULATE;
/**
* The feature id for the '<em><b>Additive</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int ANIMATE_TYPE__ADDITIVE = Smil20Package.ANIMATE_PROTOTYPE__ADDITIVE;
/**
* The feature id for the '<em><b>Attribute Name</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int ANIMATE_TYPE__ATTRIBUTE_NAME = Smil20Package.ANIMATE_PROTOTYPE__ATTRIBUTE_NAME;
/**
* The feature id for the '<em><b>Attribute Type</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int ANIMATE_TYPE__ATTRIBUTE_TYPE = Smil20Package.ANIMATE_PROTOTYPE__ATTRIBUTE_TYPE;
/**
* The feature id for the '<em><b>By</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int ANIMATE_TYPE__BY = Smil20Package.ANIMATE_PROTOTYPE__BY;
/**
* The feature id for the '<em><b>From</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int ANIMATE_TYPE__FROM = Smil20Package.ANIMATE_PROTOTYPE__FROM;
/**
* The feature id for the '<em><b>To</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int ANIMATE_TYPE__TO = Smil20Package.ANIMATE_PROTOTYPE__TO;
/**
* The feature id for the '<em><b>Values</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int ANIMATE_TYPE__VALUES = Smil20Package.ANIMATE_PROTOTYPE__VALUES;
/**
* The feature id for the '<em><b>Group</b></em>' attribute list.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int ANIMATE_TYPE__GROUP = Smil20Package.ANIMATE_PROTOTYPE_FEATURE_COUNT + 0;
/**
* The feature id for the '<em><b>Any</b></em>' attribute list.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int ANIMATE_TYPE__ANY = Smil20Package.ANIMATE_PROTOTYPE_FEATURE_COUNT + 1;
/**
* The feature id for the '<em><b>Alt</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int ANIMATE_TYPE__ALT = Smil20Package.ANIMATE_PROTOTYPE_FEATURE_COUNT + 2;
/**
* The feature id for the '<em><b>Begin</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int ANIMATE_TYPE__BEGIN = Smil20Package.ANIMATE_PROTOTYPE_FEATURE_COUNT + 3;
/**
* The feature id for the '<em><b>Calc Mode</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int ANIMATE_TYPE__CALC_MODE = Smil20Package.ANIMATE_PROTOTYPE_FEATURE_COUNT + 4;
/**
* The feature id for the '<em><b>Class</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int ANIMATE_TYPE__CLASS = Smil20Package.ANIMATE_PROTOTYPE_FEATURE_COUNT + 5;
/**
* The feature id for the '<em><b>Dur</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int ANIMATE_TYPE__DUR = Smil20Package.ANIMATE_PROTOTYPE_FEATURE_COUNT + 6;
/**
* The feature id for the '<em><b>End</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int ANIMATE_TYPE__END = Smil20Package.ANIMATE_PROTOTYPE_FEATURE_COUNT + 7;
/**
* The feature id for the '<em><b>Fill</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int ANIMATE_TYPE__FILL = Smil20Package.ANIMATE_PROTOTYPE_FEATURE_COUNT + 8;
/**
* The feature id for the '<em><b>Fill Default</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int ANIMATE_TYPE__FILL_DEFAULT = Smil20Package.ANIMATE_PROTOTYPE_FEATURE_COUNT + 9;
/**
* The feature id for the '<em><b>Id</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int ANIMATE_TYPE__ID = Smil20Package.ANIMATE_PROTOTYPE_FEATURE_COUNT + 10;
/**
* The feature id for the '<em><b>Lang</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int ANIMATE_TYPE__LANG = Smil20Package.ANIMATE_PROTOTYPE_FEATURE_COUNT + 11;
/**
* The feature id for the '<em><b>Longdesc</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int ANIMATE_TYPE__LONGDESC = Smil20Package.ANIMATE_PROTOTYPE_FEATURE_COUNT + 12;
/**
* The feature id for the '<em><b>Max</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int ANIMATE_TYPE__MAX = Smil20Package.ANIMATE_PROTOTYPE_FEATURE_COUNT + 13;
/**
* The feature id for the '<em><b>Min</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int ANIMATE_TYPE__MIN = Smil20Package.ANIMATE_PROTOTYPE_FEATURE_COUNT + 14;
/**
* The feature id for the '<em><b>Repeat</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int ANIMATE_TYPE__REPEAT = Smil20Package.ANIMATE_PROTOTYPE_FEATURE_COUNT + 15;
/**
* The feature id for the '<em><b>Repeat Count</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int ANIMATE_TYPE__REPEAT_COUNT = Smil20Package.ANIMATE_PROTOTYPE_FEATURE_COUNT + 16;
/**
* The feature id for the '<em><b>Repeat Dur</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int ANIMATE_TYPE__REPEAT_DUR = Smil20Package.ANIMATE_PROTOTYPE_FEATURE_COUNT + 17;
/**
* The feature id for the '<em><b>Restart</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int ANIMATE_TYPE__RESTART = Smil20Package.ANIMATE_PROTOTYPE_FEATURE_COUNT + 18;
/**
* The feature id for the '<em><b>Restart Default</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int ANIMATE_TYPE__RESTART_DEFAULT = Smil20Package.ANIMATE_PROTOTYPE_FEATURE_COUNT + 19;
/**
* The feature id for the '<em><b>Skip Content</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int ANIMATE_TYPE__SKIP_CONTENT = Smil20Package.ANIMATE_PROTOTYPE_FEATURE_COUNT + 20;
/**
* The feature id for the '<em><b>Sync Behavior</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int ANIMATE_TYPE__SYNC_BEHAVIOR = Smil20Package.ANIMATE_PROTOTYPE_FEATURE_COUNT + 21;
/**
* The feature id for the '<em><b>Sync Behavior Default</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int ANIMATE_TYPE__SYNC_BEHAVIOR_DEFAULT = Smil20Package.ANIMATE_PROTOTYPE_FEATURE_COUNT + 22;
/**
* The feature id for the '<em><b>Sync Tolerance</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int ANIMATE_TYPE__SYNC_TOLERANCE = Smil20Package.ANIMATE_PROTOTYPE_FEATURE_COUNT + 23;
/**
* The feature id for the '<em><b>Sync Tolerance Default</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int ANIMATE_TYPE__SYNC_TOLERANCE_DEFAULT = Smil20Package.ANIMATE_PROTOTYPE_FEATURE_COUNT + 24;
/**
* The feature id for the '<em><b>Target Element</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int ANIMATE_TYPE__TARGET_ELEMENT = Smil20Package.ANIMATE_PROTOTYPE_FEATURE_COUNT + 25;
/**
* The feature id for the '<em><b>Any Attribute</b></em>' attribute list.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int ANIMATE_TYPE__ANY_ATTRIBUTE = Smil20Package.ANIMATE_PROTOTYPE_FEATURE_COUNT + 26;
/**
* The number of structural features of the '<em>Animate Type</em>' class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int ANIMATE_TYPE_FEATURE_COUNT = Smil20Package.ANIMATE_PROTOTYPE_FEATURE_COUNT + 27;
/**
* The number of operations of the '<em>Animate Type</em>' class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int ANIMATE_TYPE_OPERATION_COUNT = Smil20Package.ANIMATE_PROTOTYPE_OPERATION_COUNT + 0;
/**
* The meta object id for the '{@link org.w3._2001.smil20.language.impl.DocumentRootImpl <em>Document Root</em>}' class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @see org.w3._2001.smil20.language.impl.DocumentRootImpl
* @see org.w3._2001.smil20.language.impl.LanguagePackageImpl#getDocumentRoot()
* @generated
*/
int DOCUMENT_ROOT = 3;
/**
* The feature id for the '<em><b>Mixed</b></em>' attribute list.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int DOCUMENT_ROOT__MIXED = 0;
/**
* The feature id for the '<em><b>XMLNS Prefix Map</b></em>' map.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int DOCUMENT_ROOT__XMLNS_PREFIX_MAP = 1;
/**
* The feature id for the '<em><b>XSI Schema Location</b></em>' map.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int DOCUMENT_ROOT__XSI_SCHEMA_LOCATION = 2;
/**
* The feature id for the '<em><b>Animate</b></em>' containment reference.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int DOCUMENT_ROOT__ANIMATE = 3;
/**
* The feature id for the '<em><b>Animate Color</b></em>' containment reference.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int DOCUMENT_ROOT__ANIMATE_COLOR = 4;
/**
* The feature id for the '<em><b>Animate Motion</b></em>' containment reference.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int DOCUMENT_ROOT__ANIMATE_MOTION = 5;
/**
* The feature id for the '<em><b>Set</b></em>' containment reference.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int DOCUMENT_ROOT__SET = 6;
/**
* The number of structural features of the '<em>Document Root</em>' class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int DOCUMENT_ROOT_FEATURE_COUNT = 7;
/**
* The number of operations of the '<em>Document Root</em>' class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int DOCUMENT_ROOT_OPERATION_COUNT = 0;
/**
* The meta object id for the '{@link org.w3._2001.smil20.language.impl.SetTypeImpl <em>Set Type</em>}' class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @see org.w3._2001.smil20.language.impl.SetTypeImpl
* @see org.w3._2001.smil20.language.impl.LanguagePackageImpl#getSetType()
* @generated
*/
int SET_TYPE = 4;
/**
* The feature id for the '<em><b>Attribute Name</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int SET_TYPE__ATTRIBUTE_NAME = Smil20Package.SET_PROTOTYPE__ATTRIBUTE_NAME;
/**
* The feature id for the '<em><b>Attribute Type</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int SET_TYPE__ATTRIBUTE_TYPE = Smil20Package.SET_PROTOTYPE__ATTRIBUTE_TYPE;
/**
* The feature id for the '<em><b>To</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int SET_TYPE__TO = Smil20Package.SET_PROTOTYPE__TO;
/**
* The feature id for the '<em><b>Group</b></em>' attribute list.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int SET_TYPE__GROUP = Smil20Package.SET_PROTOTYPE_FEATURE_COUNT + 0;
/**
* The feature id for the '<em><b>Any</b></em>' attribute list.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int SET_TYPE__ANY = Smil20Package.SET_PROTOTYPE_FEATURE_COUNT + 1;
/**
* The feature id for the '<em><b>Alt</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int SET_TYPE__ALT = Smil20Package.SET_PROTOTYPE_FEATURE_COUNT + 2;
/**
* The feature id for the '<em><b>Begin</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int SET_TYPE__BEGIN = Smil20Package.SET_PROTOTYPE_FEATURE_COUNT + 3;
/**
* The feature id for the '<em><b>Class</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int SET_TYPE__CLASS = Smil20Package.SET_PROTOTYPE_FEATURE_COUNT + 4;
/**
* The feature id for the '<em><b>Dur</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int SET_TYPE__DUR = Smil20Package.SET_PROTOTYPE_FEATURE_COUNT + 5;
/**
* The feature id for the '<em><b>End</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int SET_TYPE__END = Smil20Package.SET_PROTOTYPE_FEATURE_COUNT + 6;
/**
* The feature id for the '<em><b>Fill</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int SET_TYPE__FILL = Smil20Package.SET_PROTOTYPE_FEATURE_COUNT + 7;
/**
* The feature id for the '<em><b>Fill Default</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int SET_TYPE__FILL_DEFAULT = Smil20Package.SET_PROTOTYPE_FEATURE_COUNT + 8;
/**
* The feature id for the '<em><b>Id</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int SET_TYPE__ID = Smil20Package.SET_PROTOTYPE_FEATURE_COUNT + 9;
/**
* The feature id for the '<em><b>Lang</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int SET_TYPE__LANG = Smil20Package.SET_PROTOTYPE_FEATURE_COUNT + 10;
/**
* The feature id for the '<em><b>Longdesc</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int SET_TYPE__LONGDESC = Smil20Package.SET_PROTOTYPE_FEATURE_COUNT + 11;
/**
* The feature id for the '<em><b>Max</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int SET_TYPE__MAX = Smil20Package.SET_PROTOTYPE_FEATURE_COUNT + 12;
/**
* The feature id for the '<em><b>Min</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int SET_TYPE__MIN = Smil20Package.SET_PROTOTYPE_FEATURE_COUNT + 13;
/**
* The feature id for the '<em><b>Repeat</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int SET_TYPE__REPEAT = Smil20Package.SET_PROTOTYPE_FEATURE_COUNT + 14;
/**
* The feature id for the '<em><b>Repeat Count</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int SET_TYPE__REPEAT_COUNT = Smil20Package.SET_PROTOTYPE_FEATURE_COUNT + 15;
/**
* The feature id for the '<em><b>Repeat Dur</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int SET_TYPE__REPEAT_DUR = Smil20Package.SET_PROTOTYPE_FEATURE_COUNT + 16;
/**
* The feature id for the '<em><b>Restart</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int SET_TYPE__RESTART = Smil20Package.SET_PROTOTYPE_FEATURE_COUNT + 17;
/**
* The feature id for the '<em><b>Restart Default</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int SET_TYPE__RESTART_DEFAULT = Smil20Package.SET_PROTOTYPE_FEATURE_COUNT + 18;
/**
* The feature id for the '<em><b>Skip Content</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int SET_TYPE__SKIP_CONTENT = Smil20Package.SET_PROTOTYPE_FEATURE_COUNT + 19;
/**
* The feature id for the '<em><b>Sync Behavior</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int SET_TYPE__SYNC_BEHAVIOR = Smil20Package.SET_PROTOTYPE_FEATURE_COUNT + 20;
/**
* The feature id for the '<em><b>Sync Behavior Default</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int SET_TYPE__SYNC_BEHAVIOR_DEFAULT = Smil20Package.SET_PROTOTYPE_FEATURE_COUNT + 21;
/**
* The feature id for the '<em><b>Sync Tolerance</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int SET_TYPE__SYNC_TOLERANCE = Smil20Package.SET_PROTOTYPE_FEATURE_COUNT + 22;
/**
* The feature id for the '<em><b>Sync Tolerance Default</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int SET_TYPE__SYNC_TOLERANCE_DEFAULT = Smil20Package.SET_PROTOTYPE_FEATURE_COUNT + 23;
/**
* The feature id for the '<em><b>Target Element</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int SET_TYPE__TARGET_ELEMENT = Smil20Package.SET_PROTOTYPE_FEATURE_COUNT + 24;
/**
* The feature id for the '<em><b>Any Attribute</b></em>' attribute list.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int SET_TYPE__ANY_ATTRIBUTE = Smil20Package.SET_PROTOTYPE_FEATURE_COUNT + 25;
/**
* The number of structural features of the '<em>Set Type</em>' class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int SET_TYPE_FEATURE_COUNT = Smil20Package.SET_PROTOTYPE_FEATURE_COUNT + 26;
/**
* The number of operations of the '<em>Set Type</em>' class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int SET_TYPE_OPERATION_COUNT = Smil20Package.SET_PROTOTYPE_OPERATION_COUNT + 0;
/**
* Returns the meta object for class '{@link org.w3._2001.smil20.language.AnimateColorType <em>Animate Color Type</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for class '<em>Animate Color Type</em>'.
* @see org.w3._2001.smil20.language.AnimateColorType
* @generated
*/
EClass getAnimateColorType();
/**
* Returns the meta object for the attribute list '{@link org.w3._2001.smil20.language.AnimateColorType#getGroup <em>Group</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the attribute list '<em>Group</em>'.
* @see org.w3._2001.smil20.language.AnimateColorType#getGroup()
* @see #getAnimateColorType()
* @generated
*/
EAttribute getAnimateColorType_Group();
/**
* Returns the meta object for the attribute list '{@link org.w3._2001.smil20.language.AnimateColorType#getAny <em>Any</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the attribute list '<em>Any</em>'.
* @see org.w3._2001.smil20.language.AnimateColorType#getAny()
* @see #getAnimateColorType()
* @generated
*/
EAttribute getAnimateColorType_Any();
/**
* Returns the meta object for the attribute '{@link org.w3._2001.smil20.language.AnimateColorType#getAlt <em>Alt</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the attribute '<em>Alt</em>'.
* @see org.w3._2001.smil20.language.AnimateColorType#getAlt()
* @see #getAnimateColorType()
* @generated
*/
EAttribute getAnimateColorType_Alt();
/**
* Returns the meta object for the attribute '{@link org.w3._2001.smil20.language.AnimateColorType#getBegin <em>Begin</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the attribute '<em>Begin</em>'.
* @see org.w3._2001.smil20.language.AnimateColorType#getBegin()
* @see #getAnimateColorType()
* @generated
*/
EAttribute getAnimateColorType_Begin();
/**
* Returns the meta object for the attribute '{@link org.w3._2001.smil20.language.AnimateColorType#getCalcMode <em>Calc Mode</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the attribute '<em>Calc Mode</em>'.
* @see org.w3._2001.smil20.language.AnimateColorType#getCalcMode()
* @see #getAnimateColorType()
* @generated
*/
EAttribute getAnimateColorType_CalcMode();
/**
* Returns the meta object for the attribute '{@link org.w3._2001.smil20.language.AnimateColorType#getClass_ <em>Class</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the attribute '<em>Class</em>'.
* @see org.w3._2001.smil20.language.AnimateColorType#getClass_()
* @see #getAnimateColorType()
* @generated
*/
EAttribute getAnimateColorType_Class();
/**
* Returns the meta object for the attribute '{@link org.w3._2001.smil20.language.AnimateColorType#getDur <em>Dur</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the attribute '<em>Dur</em>'.
* @see org.w3._2001.smil20.language.AnimateColorType#getDur()
* @see #getAnimateColorType()
* @generated
*/
EAttribute getAnimateColorType_Dur();
/**
* Returns the meta object for the attribute '{@link org.w3._2001.smil20.language.AnimateColorType#getEnd <em>End</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the attribute '<em>End</em>'.
* @see org.w3._2001.smil20.language.AnimateColorType#getEnd()
* @see #getAnimateColorType()
* @generated
*/
EAttribute getAnimateColorType_End();
/**
* Returns the meta object for the attribute '{@link org.w3._2001.smil20.language.AnimateColorType#getFill <em>Fill</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the attribute '<em>Fill</em>'.
* @see org.w3._2001.smil20.language.AnimateColorType#getFill()
* @see #getAnimateColorType()
* @generated
*/
EAttribute getAnimateColorType_Fill();
/**
* Returns the meta object for the attribute '{@link org.w3._2001.smil20.language.AnimateColorType#getFillDefault <em>Fill Default</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the attribute '<em>Fill Default</em>'.
* @see org.w3._2001.smil20.language.AnimateColorType#getFillDefault()
* @see #getAnimateColorType()
* @generated
*/
EAttribute getAnimateColorType_FillDefault();
/**
* Returns the meta object for the attribute '{@link org.w3._2001.smil20.language.AnimateColorType#getId <em>Id</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the attribute '<em>Id</em>'.
* @see org.w3._2001.smil20.language.AnimateColorType#getId()
* @see #getAnimateColorType()
* @generated
*/
EAttribute getAnimateColorType_Id();
/**
* Returns the meta object for the attribute '{@link org.w3._2001.smil20.language.AnimateColorType#getLang <em>Lang</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the attribute '<em>Lang</em>'.
* @see org.w3._2001.smil20.language.AnimateColorType#getLang()
* @see #getAnimateColorType()
* @generated
*/
EAttribute getAnimateColorType_Lang();
/**
* Returns the meta object for the attribute '{@link org.w3._2001.smil20.language.AnimateColorType#getLongdesc <em>Longdesc</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the attribute '<em>Longdesc</em>'.
* @see org.w3._2001.smil20.language.AnimateColorType#getLongdesc()
* @see #getAnimateColorType()
* @generated
*/
EAttribute getAnimateColorType_Longdesc();
/**
* Returns the meta object for the attribute '{@link org.w3._2001.smil20.language.AnimateColorType#getMax <em>Max</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the attribute '<em>Max</em>'.
* @see org.w3._2001.smil20.language.AnimateColorType#getMax()
* @see #getAnimateColorType()
* @generated
*/
EAttribute getAnimateColorType_Max();
/**
* Returns the meta object for the attribute '{@link org.w3._2001.smil20.language.AnimateColorType#getMin <em>Min</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the attribute '<em>Min</em>'.
* @see org.w3._2001.smil20.language.AnimateColorType#getMin()
* @see #getAnimateColorType()
* @generated
*/
EAttribute getAnimateColorType_Min();
/**
* Returns the meta object for the attribute '{@link org.w3._2001.smil20.language.AnimateColorType#getRepeat <em>Repeat</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the attribute '<em>Repeat</em>'.
* @see org.w3._2001.smil20.language.AnimateColorType#getRepeat()
* @see #getAnimateColorType()
* @generated
*/
EAttribute getAnimateColorType_Repeat();
/**
* Returns the meta object for the attribute '{@link org.w3._2001.smil20.language.AnimateColorType#getRepeatCount <em>Repeat Count</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the attribute '<em>Repeat Count</em>'.
* @see org.w3._2001.smil20.language.AnimateColorType#getRepeatCount()
* @see #getAnimateColorType()
* @generated
*/
EAttribute getAnimateColorType_RepeatCount();
/**
* Returns the meta object for the attribute '{@link org.w3._2001.smil20.language.AnimateColorType#getRepeatDur <em>Repeat Dur</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the attribute '<em>Repeat Dur</em>'.
* @see org.w3._2001.smil20.language.AnimateColorType#getRepeatDur()
* @see #getAnimateColorType()
* @generated
*/
EAttribute getAnimateColorType_RepeatDur();
/**
* Returns the meta object for the attribute '{@link org.w3._2001.smil20.language.AnimateColorType#getRestart <em>Restart</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the attribute '<em>Restart</em>'.
* @see org.w3._2001.smil20.language.AnimateColorType#getRestart()
* @see #getAnimateColorType()
* @generated
*/
EAttribute getAnimateColorType_Restart();
/**
* Returns the meta object for the attribute '{@link org.w3._2001.smil20.language.AnimateColorType#getRestartDefault <em>Restart Default</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the attribute '<em>Restart Default</em>'.
* @see org.w3._2001.smil20.language.AnimateColorType#getRestartDefault()
* @see #getAnimateColorType()
* @generated
*/
EAttribute getAnimateColorType_RestartDefault();
/**
* Returns the meta object for the attribute '{@link org.w3._2001.smil20.language.AnimateColorType#isSkipContent <em>Skip Content</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the attribute '<em>Skip Content</em>'.
* @see org.w3._2001.smil20.language.AnimateColorType#isSkipContent()
* @see #getAnimateColorType()
* @generated
*/
EAttribute getAnimateColorType_SkipContent();
/**
* Returns the meta object for the attribute '{@link org.w3._2001.smil20.language.AnimateColorType#getSyncBehavior <em>Sync Behavior</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the attribute '<em>Sync Behavior</em>'.
* @see org.w3._2001.smil20.language.AnimateColorType#getSyncBehavior()
* @see #getAnimateColorType()
* @generated
*/
EAttribute getAnimateColorType_SyncBehavior();
/**
* Returns the meta object for the attribute '{@link org.w3._2001.smil20.language.AnimateColorType#getSyncBehaviorDefault <em>Sync Behavior Default</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the attribute '<em>Sync Behavior Default</em>'.
* @see org.w3._2001.smil20.language.AnimateColorType#getSyncBehaviorDefault()
* @see #getAnimateColorType()
* @generated
*/
EAttribute getAnimateColorType_SyncBehaviorDefault();
/**
* Returns the meta object for the attribute '{@link org.w3._2001.smil20.language.AnimateColorType#getSyncTolerance <em>Sync Tolerance</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the attribute '<em>Sync Tolerance</em>'.
* @see org.w3._2001.smil20.language.AnimateColorType#getSyncTolerance()
* @see #getAnimateColorType()
* @generated
*/
EAttribute getAnimateColorType_SyncTolerance();
/**
* Returns the meta object for the attribute '{@link org.w3._2001.smil20.language.AnimateColorType#getSyncToleranceDefault <em>Sync Tolerance Default</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the attribute '<em>Sync Tolerance Default</em>'.
* @see org.w3._2001.smil20.language.AnimateColorType#getSyncToleranceDefault()
* @see #getAnimateColorType()
* @generated
*/
EAttribute getAnimateColorType_SyncToleranceDefault();
/**
* Returns the meta object for the attribute '{@link org.w3._2001.smil20.language.AnimateColorType#getTargetElement <em>Target Element</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the attribute '<em>Target Element</em>'.
* @see org.w3._2001.smil20.language.AnimateColorType#getTargetElement()
* @see #getAnimateColorType()
* @generated
*/
EAttribute getAnimateColorType_TargetElement();
/**
* Returns the meta object for the attribute list '{@link org.w3._2001.smil20.language.AnimateColorType#getAnyAttribute <em>Any Attribute</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the attribute list '<em>Any Attribute</em>'.
* @see org.w3._2001.smil20.language.AnimateColorType#getAnyAttribute()
* @see #getAnimateColorType()
* @generated
*/
EAttribute getAnimateColorType_AnyAttribute();
/**
* Returns the meta object for class '{@link org.w3._2001.smil20.language.AnimateMotionType <em>Animate Motion Type</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for class '<em>Animate Motion Type</em>'.
* @see org.w3._2001.smil20.language.AnimateMotionType
* @generated
*/
EClass getAnimateMotionType();
/**
* Returns the meta object for the attribute list '{@link org.w3._2001.smil20.language.AnimateMotionType#getGroup <em>Group</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the attribute list '<em>Group</em>'.
* @see org.w3._2001.smil20.language.AnimateMotionType#getGroup()
* @see #getAnimateMotionType()
* @generated
*/
EAttribute getAnimateMotionType_Group();
/**
* Returns the meta object for the attribute list '{@link org.w3._2001.smil20.language.AnimateMotionType#getAny <em>Any</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the attribute list '<em>Any</em>'.
* @see org.w3._2001.smil20.language.AnimateMotionType#getAny()
* @see #getAnimateMotionType()
* @generated
*/
EAttribute getAnimateMotionType_Any();
/**
* Returns the meta object for the attribute '{@link org.w3._2001.smil20.language.AnimateMotionType#getAlt <em>Alt</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the attribute '<em>Alt</em>'.
* @see org.w3._2001.smil20.language.AnimateMotionType#getAlt()
* @see #getAnimateMotionType()
* @generated
*/
EAttribute getAnimateMotionType_Alt();
/**
* Returns the meta object for the attribute '{@link org.w3._2001.smil20.language.AnimateMotionType#getBegin <em>Begin</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the attribute '<em>Begin</em>'.
* @see org.w3._2001.smil20.language.AnimateMotionType#getBegin()
* @see #getAnimateMotionType()
* @generated
*/
EAttribute getAnimateMotionType_Begin();
/**
* Returns the meta object for the attribute '{@link org.w3._2001.smil20.language.AnimateMotionType#getCalcMode <em>Calc Mode</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the attribute '<em>Calc Mode</em>'.
* @see org.w3._2001.smil20.language.AnimateMotionType#getCalcMode()
* @see #getAnimateMotionType()
* @generated
*/
EAttribute getAnimateMotionType_CalcMode();
/**
* Returns the meta object for the attribute '{@link org.w3._2001.smil20.language.AnimateMotionType#getClass_ <em>Class</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the attribute '<em>Class</em>'.
* @see org.w3._2001.smil20.language.AnimateMotionType#getClass_()
* @see #getAnimateMotionType()
* @generated
*/
EAttribute getAnimateMotionType_Class();
/**
* Returns the meta object for the attribute '{@link org.w3._2001.smil20.language.AnimateMotionType#getDur <em>Dur</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the attribute '<em>Dur</em>'.
* @see org.w3._2001.smil20.language.AnimateMotionType#getDur()
* @see #getAnimateMotionType()
* @generated
*/
EAttribute getAnimateMotionType_Dur();
/**
* Returns the meta object for the attribute '{@link org.w3._2001.smil20.language.AnimateMotionType#getEnd <em>End</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the attribute '<em>End</em>'.
* @see org.w3._2001.smil20.language.AnimateMotionType#getEnd()
* @see #getAnimateMotionType()
* @generated
*/
EAttribute getAnimateMotionType_End();
/**
* Returns the meta object for the attribute '{@link org.w3._2001.smil20.language.AnimateMotionType#getFill <em>Fill</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the attribute '<em>Fill</em>'.
* @see org.w3._2001.smil20.language.AnimateMotionType#getFill()
* @see #getAnimateMotionType()
* @generated
*/
EAttribute getAnimateMotionType_Fill();
/**
* Returns the meta object for the attribute '{@link org.w3._2001.smil20.language.AnimateMotionType#getFillDefault <em>Fill Default</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the attribute '<em>Fill Default</em>'.
* @see org.w3._2001.smil20.language.AnimateMotionType#getFillDefault()
* @see #getAnimateMotionType()
* @generated
*/
EAttribute getAnimateMotionType_FillDefault();
/**
* Returns the meta object for the attribute '{@link org.w3._2001.smil20.language.AnimateMotionType#getId <em>Id</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the attribute '<em>Id</em>'.
* @see org.w3._2001.smil20.language.AnimateMotionType#getId()
* @see #getAnimateMotionType()
* @generated
*/
EAttribute getAnimateMotionType_Id();
/**
* Returns the meta object for the attribute '{@link org.w3._2001.smil20.language.AnimateMotionType#getLang <em>Lang</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the attribute '<em>Lang</em>'.
* @see org.w3._2001.smil20.language.AnimateMotionType#getLang()
* @see #getAnimateMotionType()
* @generated
*/
EAttribute getAnimateMotionType_Lang();
/**
* Returns the meta object for the attribute '{@link org.w3._2001.smil20.language.AnimateMotionType#getLongdesc <em>Longdesc</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the attribute '<em>Longdesc</em>'.
* @see org.w3._2001.smil20.language.AnimateMotionType#getLongdesc()
* @see #getAnimateMotionType()
* @generated
*/
EAttribute getAnimateMotionType_Longdesc();
/**
* Returns the meta object for the attribute '{@link org.w3._2001.smil20.language.AnimateMotionType#getMax <em>Max</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the attribute '<em>Max</em>'.
* @see org.w3._2001.smil20.language.AnimateMotionType#getMax()
* @see #getAnimateMotionType()
* @generated
*/
EAttribute getAnimateMotionType_Max();
/**
* Returns the meta object for the attribute '{@link org.w3._2001.smil20.language.AnimateMotionType#getMin <em>Min</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the attribute '<em>Min</em>'.
* @see org.w3._2001.smil20.language.AnimateMotionType#getMin()
* @see #getAnimateMotionType()
* @generated
*/
EAttribute getAnimateMotionType_Min();
/**
* Returns the meta object for the attribute '{@link org.w3._2001.smil20.language.AnimateMotionType#getRepeat <em>Repeat</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the attribute '<em>Repeat</em>'.
* @see org.w3._2001.smil20.language.AnimateMotionType#getRepeat()
* @see #getAnimateMotionType()
* @generated
*/
EAttribute getAnimateMotionType_Repeat();
/**
* Returns the meta object for the attribute '{@link org.w3._2001.smil20.language.AnimateMotionType#getRepeatCount <em>Repeat Count</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the attribute '<em>Repeat Count</em>'.
* @see org.w3._2001.smil20.language.AnimateMotionType#getRepeatCount()
* @see #getAnimateMotionType()
* @generated
*/
EAttribute getAnimateMotionType_RepeatCount();
/**
* Returns the meta object for the attribute '{@link org.w3._2001.smil20.language.AnimateMotionType#getRepeatDur <em>Repeat Dur</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the attribute '<em>Repeat Dur</em>'.
* @see org.w3._2001.smil20.language.AnimateMotionType#getRepeatDur()
* @see #getAnimateMotionType()
* @generated
*/
EAttribute getAnimateMotionType_RepeatDur();
/**
* Returns the meta object for the attribute '{@link org.w3._2001.smil20.language.AnimateMotionType#getRestart <em>Restart</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the attribute '<em>Restart</em>'.
* @see org.w3._2001.smil20.language.AnimateMotionType#getRestart()
* @see #getAnimateMotionType()
* @generated
*/
EAttribute getAnimateMotionType_Restart();
/**
* Returns the meta object for the attribute '{@link org.w3._2001.smil20.language.AnimateMotionType#getRestartDefault <em>Restart Default</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the attribute '<em>Restart Default</em>'.
* @see org.w3._2001.smil20.language.AnimateMotionType#getRestartDefault()
* @see #getAnimateMotionType()
* @generated
*/
EAttribute getAnimateMotionType_RestartDefault();
/**
* Returns the meta object for the attribute '{@link org.w3._2001.smil20.language.AnimateMotionType#isSkipContent <em>Skip Content</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the attribute '<em>Skip Content</em>'.
* @see org.w3._2001.smil20.language.AnimateMotionType#isSkipContent()
* @see #getAnimateMotionType()
* @generated
*/
EAttribute getAnimateMotionType_SkipContent();
/**
* Returns the meta object for the attribute '{@link org.w3._2001.smil20.language.AnimateMotionType#getSyncBehavior <em>Sync Behavior</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the attribute '<em>Sync Behavior</em>'.
* @see org.w3._2001.smil20.language.AnimateMotionType#getSyncBehavior()
* @see #getAnimateMotionType()
* @generated
*/
EAttribute getAnimateMotionType_SyncBehavior();
/**
* Returns the meta object for the attribute '{@link org.w3._2001.smil20.language.AnimateMotionType#getSyncBehaviorDefault <em>Sync Behavior Default</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the attribute '<em>Sync Behavior Default</em>'.
* @see org.w3._2001.smil20.language.AnimateMotionType#getSyncBehaviorDefault()
* @see #getAnimateMotionType()
* @generated
*/
EAttribute getAnimateMotionType_SyncBehaviorDefault();
/**
* Returns the meta object for the attribute '{@link org.w3._2001.smil20.language.AnimateMotionType#getSyncTolerance <em>Sync Tolerance</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the attribute '<em>Sync Tolerance</em>'.
* @see org.w3._2001.smil20.language.AnimateMotionType#getSyncTolerance()
* @see #getAnimateMotionType()
* @generated
*/
EAttribute getAnimateMotionType_SyncTolerance();
/**
* Returns the meta object for the attribute '{@link org.w3._2001.smil20.language.AnimateMotionType#getSyncToleranceDefault <em>Sync Tolerance Default</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the attribute '<em>Sync Tolerance Default</em>'.
* @see org.w3._2001.smil20.language.AnimateMotionType#getSyncToleranceDefault()
* @see #getAnimateMotionType()
* @generated
*/
EAttribute getAnimateMotionType_SyncToleranceDefault();
/**
* Returns the meta object for the attribute '{@link org.w3._2001.smil20.language.AnimateMotionType#getTargetElement <em>Target Element</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the attribute '<em>Target Element</em>'.
* @see org.w3._2001.smil20.language.AnimateMotionType#getTargetElement()
* @see #getAnimateMotionType()
* @generated
*/
EAttribute getAnimateMotionType_TargetElement();
/**
* Returns the meta object for the attribute list '{@link org.w3._2001.smil20.language.AnimateMotionType#getAnyAttribute <em>Any Attribute</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the attribute list '<em>Any Attribute</em>'.
* @see org.w3._2001.smil20.language.AnimateMotionType#getAnyAttribute()
* @see #getAnimateMotionType()
* @generated
*/
EAttribute getAnimateMotionType_AnyAttribute();
/**
* Returns the meta object for class '{@link org.w3._2001.smil20.language.AnimateType <em>Animate Type</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for class '<em>Animate Type</em>'.
* @see org.w3._2001.smil20.language.AnimateType
* @generated
*/
EClass getAnimateType();
/**
* Returns the meta object for the attribute list '{@link org.w3._2001.smil20.language.AnimateType#getGroup <em>Group</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the attribute list '<em>Group</em>'.
* @see org.w3._2001.smil20.language.AnimateType#getGroup()
* @see #getAnimateType()
* @generated
*/
EAttribute getAnimateType_Group();
/**
* Returns the meta object for the attribute list '{@link org.w3._2001.smil20.language.AnimateType#getAny <em>Any</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the attribute list '<em>Any</em>'.
* @see org.w3._2001.smil20.language.AnimateType#getAny()
* @see #getAnimateType()
* @generated
*/
EAttribute getAnimateType_Any();
/**
* Returns the meta object for the attribute '{@link org.w3._2001.smil20.language.AnimateType#getAlt <em>Alt</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the attribute '<em>Alt</em>'.
* @see org.w3._2001.smil20.language.AnimateType#getAlt()
* @see #getAnimateType()
* @generated
*/
EAttribute getAnimateType_Alt();
/**
* Returns the meta object for the attribute '{@link org.w3._2001.smil20.language.AnimateType#getBegin <em>Begin</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the attribute '<em>Begin</em>'.
* @see org.w3._2001.smil20.language.AnimateType#getBegin()
* @see #getAnimateType()
* @generated
*/
EAttribute getAnimateType_Begin();
/**
* Returns the meta object for the attribute '{@link org.w3._2001.smil20.language.AnimateType#getCalcMode <em>Calc Mode</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the attribute '<em>Calc Mode</em>'.
* @see org.w3._2001.smil20.language.AnimateType#getCalcMode()
* @see #getAnimateType()
* @generated
*/
EAttribute getAnimateType_CalcMode();
/**
* Returns the meta object for the attribute '{@link org.w3._2001.smil20.language.AnimateType#getClass_ <em>Class</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the attribute '<em>Class</em>'.
* @see org.w3._2001.smil20.language.AnimateType#getClass_()
* @see #getAnimateType()
* @generated
*/
EAttribute getAnimateType_Class();
/**
* Returns the meta object for the attribute '{@link org.w3._2001.smil20.language.AnimateType#getDur <em>Dur</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the attribute '<em>Dur</em>'.
* @see org.w3._2001.smil20.language.AnimateType#getDur()
* @see #getAnimateType()
* @generated
*/
EAttribute getAnimateType_Dur();
/**
* Returns the meta object for the attribute '{@link org.w3._2001.smil20.language.AnimateType#getEnd <em>End</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the attribute '<em>End</em>'.
* @see org.w3._2001.smil20.language.AnimateType#getEnd()
* @see #getAnimateType()
* @generated
*/
EAttribute getAnimateType_End();
/**
* Returns the meta object for the attribute '{@link org.w3._2001.smil20.language.AnimateType#getFill <em>Fill</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the attribute '<em>Fill</em>'.
* @see org.w3._2001.smil20.language.AnimateType#getFill()
* @see #getAnimateType()
* @generated
*/
EAttribute getAnimateType_Fill();
/**
* Returns the meta object for the attribute '{@link org.w3._2001.smil20.language.AnimateType#getFillDefault <em>Fill Default</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the attribute '<em>Fill Default</em>'.
* @see org.w3._2001.smil20.language.AnimateType#getFillDefault()
* @see #getAnimateType()
* @generated
*/
EAttribute getAnimateType_FillDefault();
/**
* Returns the meta object for the attribute '{@link org.w3._2001.smil20.language.AnimateType#getId <em>Id</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the attribute '<em>Id</em>'.
* @see org.w3._2001.smil20.language.AnimateType#getId()
* @see #getAnimateType()
* @generated
*/
EAttribute getAnimateType_Id();
/**
* Returns the meta object for the attribute '{@link org.w3._2001.smil20.language.AnimateType#getLang <em>Lang</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the attribute '<em>Lang</em>'.
* @see org.w3._2001.smil20.language.AnimateType#getLang()
* @see #getAnimateType()
* @generated
*/
EAttribute getAnimateType_Lang();
/**
* Returns the meta object for the attribute '{@link org.w3._2001.smil20.language.AnimateType#getLongdesc <em>Longdesc</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the attribute '<em>Longdesc</em>'.
* @see org.w3._2001.smil20.language.AnimateType#getLongdesc()
* @see #getAnimateType()
* @generated
*/
EAttribute getAnimateType_Longdesc();
/**
* Returns the meta object for the attribute '{@link org.w3._2001.smil20.language.AnimateType#getMax <em>Max</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the attribute '<em>Max</em>'.
* @see org.w3._2001.smil20.language.AnimateType#getMax()
* @see #getAnimateType()
* @generated
*/
EAttribute getAnimateType_Max();
/**
* Returns the meta object for the attribute '{@link org.w3._2001.smil20.language.AnimateType#getMin <em>Min</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the attribute '<em>Min</em>'.
* @see org.w3._2001.smil20.language.AnimateType#getMin()
* @see #getAnimateType()
* @generated
*/
EAttribute getAnimateType_Min();
/**
* Returns the meta object for the attribute '{@link org.w3._2001.smil20.language.AnimateType#getRepeat <em>Repeat</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the attribute '<em>Repeat</em>'.
* @see org.w3._2001.smil20.language.AnimateType#getRepeat()
* @see #getAnimateType()
* @generated
*/
EAttribute getAnimateType_Repeat();
/**
* Returns the meta object for the attribute '{@link org.w3._2001.smil20.language.AnimateType#getRepeatCount <em>Repeat Count</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the attribute '<em>Repeat Count</em>'.
* @see org.w3._2001.smil20.language.AnimateType#getRepeatCount()
* @see #getAnimateType()
* @generated
*/
EAttribute getAnimateType_RepeatCount();
/**
* Returns the meta object for the attribute '{@link org.w3._2001.smil20.language.AnimateType#getRepeatDur <em>Repeat Dur</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the attribute '<em>Repeat Dur</em>'.
* @see org.w3._2001.smil20.language.AnimateType#getRepeatDur()
* @see #getAnimateType()
* @generated
*/
EAttribute getAnimateType_RepeatDur();
/**
* Returns the meta object for the attribute '{@link org.w3._2001.smil20.language.AnimateType#getRestart <em>Restart</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the attribute '<em>Restart</em>'.
* @see org.w3._2001.smil20.language.AnimateType#getRestart()
* @see #getAnimateType()
* @generated
*/
EAttribute getAnimateType_Restart();
/**
* Returns the meta object for the attribute '{@link org.w3._2001.smil20.language.AnimateType#getRestartDefault <em>Restart Default</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the attribute '<em>Restart Default</em>'.
* @see org.w3._2001.smil20.language.AnimateType#getRestartDefault()
* @see #getAnimateType()
* @generated
*/
EAttribute getAnimateType_RestartDefault();
/**
* Returns the meta object for the attribute '{@link org.w3._2001.smil20.language.AnimateType#isSkipContent <em>Skip Content</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the attribute '<em>Skip Content</em>'.
* @see org.w3._2001.smil20.language.AnimateType#isSkipContent()
* @see #getAnimateType()
* @generated
*/
EAttribute getAnimateType_SkipContent();
/**
* Returns the meta object for the attribute '{@link org.w3._2001.smil20.language.AnimateType#getSyncBehavior <em>Sync Behavior</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the attribute '<em>Sync Behavior</em>'.
* @see org.w3._2001.smil20.language.AnimateType#getSyncBehavior()
* @see #getAnimateType()
* @generated
*/
EAttribute getAnimateType_SyncBehavior();
/**
* Returns the meta object for the attribute '{@link org.w3._2001.smil20.language.AnimateType#getSyncBehaviorDefault <em>Sync Behavior Default</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the attribute '<em>Sync Behavior Default</em>'.
* @see org.w3._2001.smil20.language.AnimateType#getSyncBehaviorDefault()
* @see #getAnimateType()
* @generated
*/
EAttribute getAnimateType_SyncBehaviorDefault();
/**
* Returns the meta object for the attribute '{@link org.w3._2001.smil20.language.AnimateType#getSyncTolerance <em>Sync Tolerance</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the attribute '<em>Sync Tolerance</em>'.
* @see org.w3._2001.smil20.language.AnimateType#getSyncTolerance()
* @see #getAnimateType()
* @generated
*/
EAttribute getAnimateType_SyncTolerance();
/**
* Returns the meta object for the attribute '{@link org.w3._2001.smil20.language.AnimateType#getSyncToleranceDefault <em>Sync Tolerance Default</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the attribute '<em>Sync Tolerance Default</em>'.
* @see org.w3._2001.smil20.language.AnimateType#getSyncToleranceDefault()
* @see #getAnimateType()
* @generated
*/
EAttribute getAnimateType_SyncToleranceDefault();
/**
* Returns the meta object for the attribute '{@link org.w3._2001.smil20.language.AnimateType#getTargetElement <em>Target Element</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the attribute '<em>Target Element</em>'.
* @see org.w3._2001.smil20.language.AnimateType#getTargetElement()
* @see #getAnimateType()
* @generated
*/
EAttribute getAnimateType_TargetElement();
/**
* Returns the meta object for the attribute list '{@link org.w3._2001.smil20.language.AnimateType#getAnyAttribute <em>Any Attribute</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the attribute list '<em>Any Attribute</em>'.
* @see org.w3._2001.smil20.language.AnimateType#getAnyAttribute()
* @see #getAnimateType()
* @generated
*/
EAttribute getAnimateType_AnyAttribute();
/**
* Returns the meta object for class '{@link org.w3._2001.smil20.language.DocumentRoot <em>Document Root</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for class '<em>Document Root</em>'.
* @see org.w3._2001.smil20.language.DocumentRoot
* @generated
*/
EClass getDocumentRoot();
/**
* Returns the meta object for the attribute list '{@link org.w3._2001.smil20.language.DocumentRoot#getMixed <em>Mixed</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the attribute list '<em>Mixed</em>'.
* @see org.w3._2001.smil20.language.DocumentRoot#getMixed()
* @see #getDocumentRoot()
* @generated
*/
EAttribute getDocumentRoot_Mixed();
/**
* Returns the meta object for the map '{@link org.w3._2001.smil20.language.DocumentRoot#getXMLNSPrefixMap <em>XMLNS Prefix Map</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the map '<em>XMLNS Prefix Map</em>'.
* @see org.w3._2001.smil20.language.DocumentRoot#getXMLNSPrefixMap()
* @see #getDocumentRoot()
* @generated
*/
EReference getDocumentRoot_XMLNSPrefixMap();
/**
* Returns the meta object for the map '{@link org.w3._2001.smil20.language.DocumentRoot#getXSISchemaLocation <em>XSI Schema Location</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the map '<em>XSI Schema Location</em>'.
* @see org.w3._2001.smil20.language.DocumentRoot#getXSISchemaLocation()
* @see #getDocumentRoot()
* @generated
*/
EReference getDocumentRoot_XSISchemaLocation();
/**
* Returns the meta object for the containment reference '{@link org.w3._2001.smil20.language.DocumentRoot#getAnimate <em>Animate</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the containment reference '<em>Animate</em>'.
* @see org.w3._2001.smil20.language.DocumentRoot#getAnimate()
* @see #getDocumentRoot()
* @generated
*/
EReference getDocumentRoot_Animate();
/**
* Returns the meta object for the containment reference '{@link org.w3._2001.smil20.language.DocumentRoot#getAnimateColor <em>Animate Color</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the containment reference '<em>Animate Color</em>'.
* @see org.w3._2001.smil20.language.DocumentRoot#getAnimateColor()
* @see #getDocumentRoot()
* @generated
*/
EReference getDocumentRoot_AnimateColor();
/**
* Returns the meta object for the containment reference '{@link org.w3._2001.smil20.language.DocumentRoot#getAnimateMotion <em>Animate Motion</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the containment reference '<em>Animate Motion</em>'.
* @see org.w3._2001.smil20.language.DocumentRoot#getAnimateMotion()
* @see #getDocumentRoot()
* @generated
*/
EReference getDocumentRoot_AnimateMotion();
/**
* Returns the meta object for the containment reference '{@link org.w3._2001.smil20.language.DocumentRoot#getSet <em>Set</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the containment reference '<em>Set</em>'.
* @see org.w3._2001.smil20.language.DocumentRoot#getSet()
* @see #getDocumentRoot()
* @generated
*/
EReference getDocumentRoot_Set();
/**
* Returns the meta object for class '{@link org.w3._2001.smil20.language.SetType <em>Set Type</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for class '<em>Set Type</em>'.
* @see org.w3._2001.smil20.language.SetType
* @generated
*/
EClass getSetType();
/**
* Returns the meta object for the attribute list '{@link org.w3._2001.smil20.language.SetType#getGroup <em>Group</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the attribute list '<em>Group</em>'.
* @see org.w3._2001.smil20.language.SetType#getGroup()
* @see #getSetType()
* @generated
*/
EAttribute getSetType_Group();
/**
* Returns the meta object for the attribute list '{@link org.w3._2001.smil20.language.SetType#getAny <em>Any</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the attribute list '<em>Any</em>'.
* @see org.w3._2001.smil20.language.SetType#getAny()
* @see #getSetType()
* @generated
*/
EAttribute getSetType_Any();
/**
* Returns the meta object for the attribute '{@link org.w3._2001.smil20.language.SetType#getAlt <em>Alt</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the attribute '<em>Alt</em>'.
* @see org.w3._2001.smil20.language.SetType#getAlt()
* @see #getSetType()
* @generated
*/
EAttribute getSetType_Alt();
/**
* Returns the meta object for the attribute '{@link org.w3._2001.smil20.language.SetType#getBegin <em>Begin</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the attribute '<em>Begin</em>'.
* @see org.w3._2001.smil20.language.SetType#getBegin()
* @see #getSetType()
* @generated
*/
EAttribute getSetType_Begin();
/**
* Returns the meta object for the attribute '{@link org.w3._2001.smil20.language.SetType#getClass_ <em>Class</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the attribute '<em>Class</em>'.
* @see org.w3._2001.smil20.language.SetType#getClass_()
* @see #getSetType()
* @generated
*/
EAttribute getSetType_Class();
/**
* Returns the meta object for the attribute '{@link org.w3._2001.smil20.language.SetType#getDur <em>Dur</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the attribute '<em>Dur</em>'.
* @see org.w3._2001.smil20.language.SetType#getDur()
* @see #getSetType()
* @generated
*/
EAttribute getSetType_Dur();
/**
* Returns the meta object for the attribute '{@link org.w3._2001.smil20.language.SetType#getEnd <em>End</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the attribute '<em>End</em>'.
* @see org.w3._2001.smil20.language.SetType#getEnd()
* @see #getSetType()
* @generated
*/
EAttribute getSetType_End();
/**
* Returns the meta object for the attribute '{@link org.w3._2001.smil20.language.SetType#getFill <em>Fill</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the attribute '<em>Fill</em>'.
* @see org.w3._2001.smil20.language.SetType#getFill()
* @see #getSetType()
* @generated
*/
EAttribute getSetType_Fill();
/**
* Returns the meta object for the attribute '{@link org.w3._2001.smil20.language.SetType#getFillDefault <em>Fill Default</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the attribute '<em>Fill Default</em>'.
* @see org.w3._2001.smil20.language.SetType#getFillDefault()
* @see #getSetType()
* @generated
*/
EAttribute getSetType_FillDefault();
/**
* Returns the meta object for the attribute '{@link org.w3._2001.smil20.language.SetType#getId <em>Id</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the attribute '<em>Id</em>'.
* @see org.w3._2001.smil20.language.SetType#getId()
* @see #getSetType()
* @generated
*/
EAttribute getSetType_Id();
/**
* Returns the meta object for the attribute '{@link org.w3._2001.smil20.language.SetType#getLang <em>Lang</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the attribute '<em>Lang</em>'.
* @see org.w3._2001.smil20.language.SetType#getLang()
* @see #getSetType()
* @generated
*/
EAttribute getSetType_Lang();
/**
* Returns the meta object for the attribute '{@link org.w3._2001.smil20.language.SetType#getLongdesc <em>Longdesc</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the attribute '<em>Longdesc</em>'.
* @see org.w3._2001.smil20.language.SetType#getLongdesc()
* @see #getSetType()
* @generated
*/
EAttribute getSetType_Longdesc();
/**
* Returns the meta object for the attribute '{@link org.w3._2001.smil20.language.SetType#getMax <em>Max</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the attribute '<em>Max</em>'.
* @see org.w3._2001.smil20.language.SetType#getMax()
* @see #getSetType()
* @generated
*/
EAttribute getSetType_Max();
/**
* Returns the meta object for the attribute '{@link org.w3._2001.smil20.language.SetType#getMin <em>Min</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the attribute '<em>Min</em>'.
* @see org.w3._2001.smil20.language.SetType#getMin()
* @see #getSetType()
* @generated
*/
EAttribute getSetType_Min();
/**
* Returns the meta object for the attribute '{@link org.w3._2001.smil20.language.SetType#getRepeat <em>Repeat</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the attribute '<em>Repeat</em>'.
* @see org.w3._2001.smil20.language.SetType#getRepeat()
* @see #getSetType()
* @generated
*/
EAttribute getSetType_Repeat();
/**
* Returns the meta object for the attribute '{@link org.w3._2001.smil20.language.SetType#getRepeatCount <em>Repeat Count</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the attribute '<em>Repeat Count</em>'.
* @see org.w3._2001.smil20.language.SetType#getRepeatCount()
* @see #getSetType()
* @generated
*/
EAttribute getSetType_RepeatCount();
/**
* Returns the meta object for the attribute '{@link org.w3._2001.smil20.language.SetType#getRepeatDur <em>Repeat Dur</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the attribute '<em>Repeat Dur</em>'.
* @see org.w3._2001.smil20.language.SetType#getRepeatDur()
* @see #getSetType()
* @generated
*/
EAttribute getSetType_RepeatDur();
/**
* Returns the meta object for the attribute '{@link org.w3._2001.smil20.language.SetType#getRestart <em>Restart</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the attribute '<em>Restart</em>'.
* @see org.w3._2001.smil20.language.SetType#getRestart()
* @see #getSetType()
* @generated
*/
EAttribute getSetType_Restart();
/**
* Returns the meta object for the attribute '{@link org.w3._2001.smil20.language.SetType#getRestartDefault <em>Restart Default</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the attribute '<em>Restart Default</em>'.
* @see org.w3._2001.smil20.language.SetType#getRestartDefault()
* @see #getSetType()
* @generated
*/
EAttribute getSetType_RestartDefault();
/**
* Returns the meta object for the attribute '{@link org.w3._2001.smil20.language.SetType#isSkipContent <em>Skip Content</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the attribute '<em>Skip Content</em>'.
* @see org.w3._2001.smil20.language.SetType#isSkipContent()
* @see #getSetType()
* @generated
*/
EAttribute getSetType_SkipContent();
/**
* Returns the meta object for the attribute '{@link org.w3._2001.smil20.language.SetType#getSyncBehavior <em>Sync Behavior</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the attribute '<em>Sync Behavior</em>'.
* @see org.w3._2001.smil20.language.SetType#getSyncBehavior()
* @see #getSetType()
* @generated
*/
EAttribute getSetType_SyncBehavior();
/**
* Returns the meta object for the attribute '{@link org.w3._2001.smil20.language.SetType#getSyncBehaviorDefault <em>Sync Behavior Default</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the attribute '<em>Sync Behavior Default</em>'.
* @see org.w3._2001.smil20.language.SetType#getSyncBehaviorDefault()
* @see #getSetType()
* @generated
*/
EAttribute getSetType_SyncBehaviorDefault();
/**
* Returns the meta object for the attribute '{@link org.w3._2001.smil20.language.SetType#getSyncTolerance <em>Sync Tolerance</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the attribute '<em>Sync Tolerance</em>'.
* @see org.w3._2001.smil20.language.SetType#getSyncTolerance()
* @see #getSetType()
* @generated
*/
EAttribute getSetType_SyncTolerance();
/**
* Returns the meta object for the attribute '{@link org.w3._2001.smil20.language.SetType#getSyncToleranceDefault <em>Sync Tolerance Default</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the attribute '<em>Sync Tolerance Default</em>'.
* @see org.w3._2001.smil20.language.SetType#getSyncToleranceDefault()
* @see #getSetType()
* @generated
*/
EAttribute getSetType_SyncToleranceDefault();
/**
* Returns the meta object for the attribute '{@link org.w3._2001.smil20.language.SetType#getTargetElement <em>Target Element</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the attribute '<em>Target Element</em>'.
* @see org.w3._2001.smil20.language.SetType#getTargetElement()
* @see #getSetType()
* @generated
*/
EAttribute getSetType_TargetElement();
/**
* Returns the meta object for the attribute list '{@link org.w3._2001.smil20.language.SetType#getAnyAttribute <em>Any Attribute</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the attribute list '<em>Any Attribute</em>'.
* @see org.w3._2001.smil20.language.SetType#getAnyAttribute()
* @see #getSetType()
* @generated
*/
EAttribute getSetType_AnyAttribute();
/**
* Returns the factory that creates the instances of the model.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the factory that creates the instances of the model.
* @generated
*/
LanguageFactory getLanguageFactory();
/**
* <!-- begin-user-doc -->
* Defines literals for the meta objects that represent
* <ul>
* <li>each class,</li>
* <li>each feature of each class,</li>
* <li>each operation of each class,</li>
* <li>each enum,</li>
* <li>and each data type</li>
* </ul>
* <!-- end-user-doc -->
* @generated
*/
interface Literals {
/**
* The meta object literal for the '{@link org.w3._2001.smil20.language.impl.AnimateColorTypeImpl <em>Animate Color Type</em>}' class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @see org.w3._2001.smil20.language.impl.AnimateColorTypeImpl
* @see org.w3._2001.smil20.language.impl.LanguagePackageImpl#getAnimateColorType()
* @generated
*/
EClass ANIMATE_COLOR_TYPE = eINSTANCE.getAnimateColorType();
/**
* The meta object literal for the '<em><b>Group</b></em>' attribute list feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EAttribute ANIMATE_COLOR_TYPE__GROUP = eINSTANCE.getAnimateColorType_Group();
/**
* The meta object literal for the '<em><b>Any</b></em>' attribute list feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EAttribute ANIMATE_COLOR_TYPE__ANY = eINSTANCE.getAnimateColorType_Any();
/**
* The meta object literal for the '<em><b>Alt</b></em>' attribute feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EAttribute ANIMATE_COLOR_TYPE__ALT = eINSTANCE.getAnimateColorType_Alt();
/**
* The meta object literal for the '<em><b>Begin</b></em>' attribute feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EAttribute ANIMATE_COLOR_TYPE__BEGIN = eINSTANCE.getAnimateColorType_Begin();
/**
* The meta object literal for the '<em><b>Calc Mode</b></em>' attribute feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EAttribute ANIMATE_COLOR_TYPE__CALC_MODE = eINSTANCE.getAnimateColorType_CalcMode();
/**
* The meta object literal for the '<em><b>Class</b></em>' attribute feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EAttribute ANIMATE_COLOR_TYPE__CLASS = eINSTANCE.getAnimateColorType_Class();
/**
* The meta object literal for the '<em><b>Dur</b></em>' attribute feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EAttribute ANIMATE_COLOR_TYPE__DUR = eINSTANCE.getAnimateColorType_Dur();
/**
* The meta object literal for the '<em><b>End</b></em>' attribute feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EAttribute ANIMATE_COLOR_TYPE__END = eINSTANCE.getAnimateColorType_End();
/**
* The meta object literal for the '<em><b>Fill</b></em>' attribute feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EAttribute ANIMATE_COLOR_TYPE__FILL = eINSTANCE.getAnimateColorType_Fill();
/**
* The meta object literal for the '<em><b>Fill Default</b></em>' attribute feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EAttribute ANIMATE_COLOR_TYPE__FILL_DEFAULT = eINSTANCE.getAnimateColorType_FillDefault();
/**
* The meta object literal for the '<em><b>Id</b></em>' attribute feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EAttribute ANIMATE_COLOR_TYPE__ID = eINSTANCE.getAnimateColorType_Id();
/**
* The meta object literal for the '<em><b>Lang</b></em>' attribute feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EAttribute ANIMATE_COLOR_TYPE__LANG = eINSTANCE.getAnimateColorType_Lang();
/**
* The meta object literal for the '<em><b>Longdesc</b></em>' attribute feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EAttribute ANIMATE_COLOR_TYPE__LONGDESC = eINSTANCE.getAnimateColorType_Longdesc();
/**
* The meta object literal for the '<em><b>Max</b></em>' attribute feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EAttribute ANIMATE_COLOR_TYPE__MAX = eINSTANCE.getAnimateColorType_Max();
/**
* The meta object literal for the '<em><b>Min</b></em>' attribute feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EAttribute ANIMATE_COLOR_TYPE__MIN = eINSTANCE.getAnimateColorType_Min();
/**
* The meta object literal for the '<em><b>Repeat</b></em>' attribute feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EAttribute ANIMATE_COLOR_TYPE__REPEAT = eINSTANCE.getAnimateColorType_Repeat();
/**
* The meta object literal for the '<em><b>Repeat Count</b></em>' attribute feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EAttribute ANIMATE_COLOR_TYPE__REPEAT_COUNT = eINSTANCE.getAnimateColorType_RepeatCount();
/**
* The meta object literal for the '<em><b>Repeat Dur</b></em>' attribute feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EAttribute ANIMATE_COLOR_TYPE__REPEAT_DUR = eINSTANCE.getAnimateColorType_RepeatDur();
/**
* The meta object literal for the '<em><b>Restart</b></em>' attribute feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EAttribute ANIMATE_COLOR_TYPE__RESTART = eINSTANCE.getAnimateColorType_Restart();
/**
* The meta object literal for the '<em><b>Restart Default</b></em>' attribute feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EAttribute ANIMATE_COLOR_TYPE__RESTART_DEFAULT = eINSTANCE.getAnimateColorType_RestartDefault();
/**
* The meta object literal for the '<em><b>Skip Content</b></em>' attribute feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EAttribute ANIMATE_COLOR_TYPE__SKIP_CONTENT = eINSTANCE.getAnimateColorType_SkipContent();
/**
* The meta object literal for the '<em><b>Sync Behavior</b></em>' attribute feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EAttribute ANIMATE_COLOR_TYPE__SYNC_BEHAVIOR = eINSTANCE.getAnimateColorType_SyncBehavior();
/**
* The meta object literal for the '<em><b>Sync Behavior Default</b></em>' attribute feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EAttribute ANIMATE_COLOR_TYPE__SYNC_BEHAVIOR_DEFAULT = eINSTANCE.getAnimateColorType_SyncBehaviorDefault();
/**
* The meta object literal for the '<em><b>Sync Tolerance</b></em>' attribute feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EAttribute ANIMATE_COLOR_TYPE__SYNC_TOLERANCE = eINSTANCE.getAnimateColorType_SyncTolerance();
/**
* The meta object literal for the '<em><b>Sync Tolerance Default</b></em>' attribute feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EAttribute ANIMATE_COLOR_TYPE__SYNC_TOLERANCE_DEFAULT = eINSTANCE.getAnimateColorType_SyncToleranceDefault();
/**
* The meta object literal for the '<em><b>Target Element</b></em>' attribute feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EAttribute ANIMATE_COLOR_TYPE__TARGET_ELEMENT = eINSTANCE.getAnimateColorType_TargetElement();
/**
* The meta object literal for the '<em><b>Any Attribute</b></em>' attribute list feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EAttribute ANIMATE_COLOR_TYPE__ANY_ATTRIBUTE = eINSTANCE.getAnimateColorType_AnyAttribute();
/**
* The meta object literal for the '{@link org.w3._2001.smil20.language.impl.AnimateMotionTypeImpl <em>Animate Motion Type</em>}' class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @see org.w3._2001.smil20.language.impl.AnimateMotionTypeImpl
* @see org.w3._2001.smil20.language.impl.LanguagePackageImpl#getAnimateMotionType()
* @generated
*/
EClass ANIMATE_MOTION_TYPE = eINSTANCE.getAnimateMotionType();
/**
* The meta object literal for the '<em><b>Group</b></em>' attribute list feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EAttribute ANIMATE_MOTION_TYPE__GROUP = eINSTANCE.getAnimateMotionType_Group();
/**
* The meta object literal for the '<em><b>Any</b></em>' attribute list feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EAttribute ANIMATE_MOTION_TYPE__ANY = eINSTANCE.getAnimateMotionType_Any();
/**
* The meta object literal for the '<em><b>Alt</b></em>' attribute feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EAttribute ANIMATE_MOTION_TYPE__ALT = eINSTANCE.getAnimateMotionType_Alt();
/**
* The meta object literal for the '<em><b>Begin</b></em>' attribute feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EAttribute ANIMATE_MOTION_TYPE__BEGIN = eINSTANCE.getAnimateMotionType_Begin();
/**
* The meta object literal for the '<em><b>Calc Mode</b></em>' attribute feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EAttribute ANIMATE_MOTION_TYPE__CALC_MODE = eINSTANCE.getAnimateMotionType_CalcMode();
/**
* The meta object literal for the '<em><b>Class</b></em>' attribute feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EAttribute ANIMATE_MOTION_TYPE__CLASS = eINSTANCE.getAnimateMotionType_Class();
/**
* The meta object literal for the '<em><b>Dur</b></em>' attribute feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EAttribute ANIMATE_MOTION_TYPE__DUR = eINSTANCE.getAnimateMotionType_Dur();
/**
* The meta object literal for the '<em><b>End</b></em>' attribute feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EAttribute ANIMATE_MOTION_TYPE__END = eINSTANCE.getAnimateMotionType_End();
/**
* The meta object literal for the '<em><b>Fill</b></em>' attribute feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EAttribute ANIMATE_MOTION_TYPE__FILL = eINSTANCE.getAnimateMotionType_Fill();
/**
* The meta object literal for the '<em><b>Fill Default</b></em>' attribute feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EAttribute ANIMATE_MOTION_TYPE__FILL_DEFAULT = eINSTANCE.getAnimateMotionType_FillDefault();
/**
* The meta object literal for the '<em><b>Id</b></em>' attribute feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EAttribute ANIMATE_MOTION_TYPE__ID = eINSTANCE.getAnimateMotionType_Id();
/**
* The meta object literal for the '<em><b>Lang</b></em>' attribute feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EAttribute ANIMATE_MOTION_TYPE__LANG = eINSTANCE.getAnimateMotionType_Lang();
/**
* The meta object literal for the '<em><b>Longdesc</b></em>' attribute feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EAttribute ANIMATE_MOTION_TYPE__LONGDESC = eINSTANCE.getAnimateMotionType_Longdesc();
/**
* The meta object literal for the '<em><b>Max</b></em>' attribute feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EAttribute ANIMATE_MOTION_TYPE__MAX = eINSTANCE.getAnimateMotionType_Max();
/**
* The meta object literal for the '<em><b>Min</b></em>' attribute feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EAttribute ANIMATE_MOTION_TYPE__MIN = eINSTANCE.getAnimateMotionType_Min();
/**
* The meta object literal for the '<em><b>Repeat</b></em>' attribute feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EAttribute ANIMATE_MOTION_TYPE__REPEAT = eINSTANCE.getAnimateMotionType_Repeat();
/**
* The meta object literal for the '<em><b>Repeat Count</b></em>' attribute feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EAttribute ANIMATE_MOTION_TYPE__REPEAT_COUNT = eINSTANCE.getAnimateMotionType_RepeatCount();
/**
* The meta object literal for the '<em><b>Repeat Dur</b></em>' attribute feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EAttribute ANIMATE_MOTION_TYPE__REPEAT_DUR = eINSTANCE.getAnimateMotionType_RepeatDur();
/**
* The meta object literal for the '<em><b>Restart</b></em>' attribute feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EAttribute ANIMATE_MOTION_TYPE__RESTART = eINSTANCE.getAnimateMotionType_Restart();
/**
* The meta object literal for the '<em><b>Restart Default</b></em>' attribute feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EAttribute ANIMATE_MOTION_TYPE__RESTART_DEFAULT = eINSTANCE.getAnimateMotionType_RestartDefault();
/**
* The meta object literal for the '<em><b>Skip Content</b></em>' attribute feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EAttribute ANIMATE_MOTION_TYPE__SKIP_CONTENT = eINSTANCE.getAnimateMotionType_SkipContent();
/**
* The meta object literal for the '<em><b>Sync Behavior</b></em>' attribute feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EAttribute ANIMATE_MOTION_TYPE__SYNC_BEHAVIOR = eINSTANCE.getAnimateMotionType_SyncBehavior();
/**
* The meta object literal for the '<em><b>Sync Behavior Default</b></em>' attribute feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EAttribute ANIMATE_MOTION_TYPE__SYNC_BEHAVIOR_DEFAULT = eINSTANCE.getAnimateMotionType_SyncBehaviorDefault();
/**
* The meta object literal for the '<em><b>Sync Tolerance</b></em>' attribute feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EAttribute ANIMATE_MOTION_TYPE__SYNC_TOLERANCE = eINSTANCE.getAnimateMotionType_SyncTolerance();
/**
* The meta object literal for the '<em><b>Sync Tolerance Default</b></em>' attribute feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EAttribute ANIMATE_MOTION_TYPE__SYNC_TOLERANCE_DEFAULT = eINSTANCE.getAnimateMotionType_SyncToleranceDefault();
/**
* The meta object literal for the '<em><b>Target Element</b></em>' attribute feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EAttribute ANIMATE_MOTION_TYPE__TARGET_ELEMENT = eINSTANCE.getAnimateMotionType_TargetElement();
/**
* The meta object literal for the '<em><b>Any Attribute</b></em>' attribute list feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EAttribute ANIMATE_MOTION_TYPE__ANY_ATTRIBUTE = eINSTANCE.getAnimateMotionType_AnyAttribute();
/**
* The meta object literal for the '{@link org.w3._2001.smil20.language.impl.AnimateTypeImpl <em>Animate Type</em>}' class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @see org.w3._2001.smil20.language.impl.AnimateTypeImpl
* @see org.w3._2001.smil20.language.impl.LanguagePackageImpl#getAnimateType()
* @generated
*/
EClass ANIMATE_TYPE = eINSTANCE.getAnimateType();
/**
* The meta object literal for the '<em><b>Group</b></em>' attribute list feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EAttribute ANIMATE_TYPE__GROUP = eINSTANCE.getAnimateType_Group();
/**
* The meta object literal for the '<em><b>Any</b></em>' attribute list feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EAttribute ANIMATE_TYPE__ANY = eINSTANCE.getAnimateType_Any();
/**
* The meta object literal for the '<em><b>Alt</b></em>' attribute feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EAttribute ANIMATE_TYPE__ALT = eINSTANCE.getAnimateType_Alt();
/**
* The meta object literal for the '<em><b>Begin</b></em>' attribute feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EAttribute ANIMATE_TYPE__BEGIN = eINSTANCE.getAnimateType_Begin();
/**
* The meta object literal for the '<em><b>Calc Mode</b></em>' attribute feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EAttribute ANIMATE_TYPE__CALC_MODE = eINSTANCE.getAnimateType_CalcMode();
/**
* The meta object literal for the '<em><b>Class</b></em>' attribute feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EAttribute ANIMATE_TYPE__CLASS = eINSTANCE.getAnimateType_Class();
/**
* The meta object literal for the '<em><b>Dur</b></em>' attribute feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EAttribute ANIMATE_TYPE__DUR = eINSTANCE.getAnimateType_Dur();
/**
* The meta object literal for the '<em><b>End</b></em>' attribute feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EAttribute ANIMATE_TYPE__END = eINSTANCE.getAnimateType_End();
/**
* The meta object literal for the '<em><b>Fill</b></em>' attribute feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EAttribute ANIMATE_TYPE__FILL = eINSTANCE.getAnimateType_Fill();
/**
* The meta object literal for the '<em><b>Fill Default</b></em>' attribute feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EAttribute ANIMATE_TYPE__FILL_DEFAULT = eINSTANCE.getAnimateType_FillDefault();
/**
* The meta object literal for the '<em><b>Id</b></em>' attribute feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EAttribute ANIMATE_TYPE__ID = eINSTANCE.getAnimateType_Id();
/**
* The meta object literal for the '<em><b>Lang</b></em>' attribute feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EAttribute ANIMATE_TYPE__LANG = eINSTANCE.getAnimateType_Lang();
/**
* The meta object literal for the '<em><b>Longdesc</b></em>' attribute feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EAttribute ANIMATE_TYPE__LONGDESC = eINSTANCE.getAnimateType_Longdesc();
/**
* The meta object literal for the '<em><b>Max</b></em>' attribute feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EAttribute ANIMATE_TYPE__MAX = eINSTANCE.getAnimateType_Max();
/**
* The meta object literal for the '<em><b>Min</b></em>' attribute feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EAttribute ANIMATE_TYPE__MIN = eINSTANCE.getAnimateType_Min();
/**
* The meta object literal for the '<em><b>Repeat</b></em>' attribute feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EAttribute ANIMATE_TYPE__REPEAT = eINSTANCE.getAnimateType_Repeat();
/**
* The meta object literal for the '<em><b>Repeat Count</b></em>' attribute feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EAttribute ANIMATE_TYPE__REPEAT_COUNT = eINSTANCE.getAnimateType_RepeatCount();
/**
* The meta object literal for the '<em><b>Repeat Dur</b></em>' attribute feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EAttribute ANIMATE_TYPE__REPEAT_DUR = eINSTANCE.getAnimateType_RepeatDur();
/**
* The meta object literal for the '<em><b>Restart</b></em>' attribute feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EAttribute ANIMATE_TYPE__RESTART = eINSTANCE.getAnimateType_Restart();
/**
* The meta object literal for the '<em><b>Restart Default</b></em>' attribute feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EAttribute ANIMATE_TYPE__RESTART_DEFAULT = eINSTANCE.getAnimateType_RestartDefault();
/**
* The meta object literal for the '<em><b>Skip Content</b></em>' attribute feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EAttribute ANIMATE_TYPE__SKIP_CONTENT = eINSTANCE.getAnimateType_SkipContent();
/**
* The meta object literal for the '<em><b>Sync Behavior</b></em>' attribute feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EAttribute ANIMATE_TYPE__SYNC_BEHAVIOR = eINSTANCE.getAnimateType_SyncBehavior();
/**
* The meta object literal for the '<em><b>Sync Behavior Default</b></em>' attribute feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EAttribute ANIMATE_TYPE__SYNC_BEHAVIOR_DEFAULT = eINSTANCE.getAnimateType_SyncBehaviorDefault();
/**
* The meta object literal for the '<em><b>Sync Tolerance</b></em>' attribute feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EAttribute ANIMATE_TYPE__SYNC_TOLERANCE = eINSTANCE.getAnimateType_SyncTolerance();
/**
* The meta object literal for the '<em><b>Sync Tolerance Default</b></em>' attribute feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EAttribute ANIMATE_TYPE__SYNC_TOLERANCE_DEFAULT = eINSTANCE.getAnimateType_SyncToleranceDefault();
/**
* The meta object literal for the '<em><b>Target Element</b></em>' attribute feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EAttribute ANIMATE_TYPE__TARGET_ELEMENT = eINSTANCE.getAnimateType_TargetElement();
/**
* The meta object literal for the '<em><b>Any Attribute</b></em>' attribute list feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EAttribute ANIMATE_TYPE__ANY_ATTRIBUTE = eINSTANCE.getAnimateType_AnyAttribute();
/**
* The meta object literal for the '{@link org.w3._2001.smil20.language.impl.DocumentRootImpl <em>Document Root</em>}' class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @see org.w3._2001.smil20.language.impl.DocumentRootImpl
* @see org.w3._2001.smil20.language.impl.LanguagePackageImpl#getDocumentRoot()
* @generated
*/
EClass DOCUMENT_ROOT = eINSTANCE.getDocumentRoot();
/**
* The meta object literal for the '<em><b>Mixed</b></em>' attribute list feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EAttribute DOCUMENT_ROOT__MIXED = eINSTANCE.getDocumentRoot_Mixed();
/**
* The meta object literal for the '<em><b>XMLNS Prefix Map</b></em>' map feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EReference DOCUMENT_ROOT__XMLNS_PREFIX_MAP = eINSTANCE.getDocumentRoot_XMLNSPrefixMap();
/**
* The meta object literal for the '<em><b>XSI Schema Location</b></em>' map feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EReference DOCUMENT_ROOT__XSI_SCHEMA_LOCATION = eINSTANCE.getDocumentRoot_XSISchemaLocation();
/**
* The meta object literal for the '<em><b>Animate</b></em>' containment reference feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EReference DOCUMENT_ROOT__ANIMATE = eINSTANCE.getDocumentRoot_Animate();
/**
* The meta object literal for the '<em><b>Animate Color</b></em>' containment reference feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EReference DOCUMENT_ROOT__ANIMATE_COLOR = eINSTANCE.getDocumentRoot_AnimateColor();
/**
* The meta object literal for the '<em><b>Animate Motion</b></em>' containment reference feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EReference DOCUMENT_ROOT__ANIMATE_MOTION = eINSTANCE.getDocumentRoot_AnimateMotion();
/**
* The meta object literal for the '<em><b>Set</b></em>' containment reference feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EReference DOCUMENT_ROOT__SET = eINSTANCE.getDocumentRoot_Set();
/**
* The meta object literal for the '{@link org.w3._2001.smil20.language.impl.SetTypeImpl <em>Set Type</em>}' class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @see org.w3._2001.smil20.language.impl.SetTypeImpl
* @see org.w3._2001.smil20.language.impl.LanguagePackageImpl#getSetType()
* @generated
*/
EClass SET_TYPE = eINSTANCE.getSetType();
/**
* The meta object literal for the '<em><b>Group</b></em>' attribute list feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EAttribute SET_TYPE__GROUP = eINSTANCE.getSetType_Group();
/**
* The meta object literal for the '<em><b>Any</b></em>' attribute list feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EAttribute SET_TYPE__ANY = eINSTANCE.getSetType_Any();
/**
* The meta object literal for the '<em><b>Alt</b></em>' attribute feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EAttribute SET_TYPE__ALT = eINSTANCE.getSetType_Alt();
/**
* The meta object literal for the '<em><b>Begin</b></em>' attribute feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EAttribute SET_TYPE__BEGIN = eINSTANCE.getSetType_Begin();
/**
* The meta object literal for the '<em><b>Class</b></em>' attribute feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EAttribute SET_TYPE__CLASS = eINSTANCE.getSetType_Class();
/**
* The meta object literal for the '<em><b>Dur</b></em>' attribute feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EAttribute SET_TYPE__DUR = eINSTANCE.getSetType_Dur();
/**
* The meta object literal for the '<em><b>End</b></em>' attribute feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EAttribute SET_TYPE__END = eINSTANCE.getSetType_End();
/**
* The meta object literal for the '<em><b>Fill</b></em>' attribute feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EAttribute SET_TYPE__FILL = eINSTANCE.getSetType_Fill();
/**
* The meta object literal for the '<em><b>Fill Default</b></em>' attribute feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EAttribute SET_TYPE__FILL_DEFAULT = eINSTANCE.getSetType_FillDefault();
/**
* The meta object literal for the '<em><b>Id</b></em>' attribute feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EAttribute SET_TYPE__ID = eINSTANCE.getSetType_Id();
/**
* The meta object literal for the '<em><b>Lang</b></em>' attribute feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EAttribute SET_TYPE__LANG = eINSTANCE.getSetType_Lang();
/**
* The meta object literal for the '<em><b>Longdesc</b></em>' attribute feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EAttribute SET_TYPE__LONGDESC = eINSTANCE.getSetType_Longdesc();
/**
* The meta object literal for the '<em><b>Max</b></em>' attribute feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EAttribute SET_TYPE__MAX = eINSTANCE.getSetType_Max();
/**
* The meta object literal for the '<em><b>Min</b></em>' attribute feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EAttribute SET_TYPE__MIN = eINSTANCE.getSetType_Min();
/**
* The meta object literal for the '<em><b>Repeat</b></em>' attribute feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EAttribute SET_TYPE__REPEAT = eINSTANCE.getSetType_Repeat();
/**
* The meta object literal for the '<em><b>Repeat Count</b></em>' attribute feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EAttribute SET_TYPE__REPEAT_COUNT = eINSTANCE.getSetType_RepeatCount();
/**
* The meta object literal for the '<em><b>Repeat Dur</b></em>' attribute feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EAttribute SET_TYPE__REPEAT_DUR = eINSTANCE.getSetType_RepeatDur();
/**
* The meta object literal for the '<em><b>Restart</b></em>' attribute feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EAttribute SET_TYPE__RESTART = eINSTANCE.getSetType_Restart();
/**
* The meta object literal for the '<em><b>Restart Default</b></em>' attribute feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EAttribute SET_TYPE__RESTART_DEFAULT = eINSTANCE.getSetType_RestartDefault();
/**
* The meta object literal for the '<em><b>Skip Content</b></em>' attribute feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EAttribute SET_TYPE__SKIP_CONTENT = eINSTANCE.getSetType_SkipContent();
/**
* The meta object literal for the '<em><b>Sync Behavior</b></em>' attribute feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EAttribute SET_TYPE__SYNC_BEHAVIOR = eINSTANCE.getSetType_SyncBehavior();
/**
* The meta object literal for the '<em><b>Sync Behavior Default</b></em>' attribute feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EAttribute SET_TYPE__SYNC_BEHAVIOR_DEFAULT = eINSTANCE.getSetType_SyncBehaviorDefault();
/**
* The meta object literal for the '<em><b>Sync Tolerance</b></em>' attribute feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EAttribute SET_TYPE__SYNC_TOLERANCE = eINSTANCE.getSetType_SyncTolerance();
/**
* The meta object literal for the '<em><b>Sync Tolerance Default</b></em>' attribute feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EAttribute SET_TYPE__SYNC_TOLERANCE_DEFAULT = eINSTANCE.getSetType_SyncToleranceDefault();
/**
* The meta object literal for the '<em><b>Target Element</b></em>' attribute feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EAttribute SET_TYPE__TARGET_ELEMENT = eINSTANCE.getSetType_TargetElement();
/**
* The meta object literal for the '<em><b>Any Attribute</b></em>' attribute list feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EAttribute SET_TYPE__ANY_ATTRIBUTE = eINSTANCE.getSetType_AnyAttribute();
}
} //LanguagePackage
| Java |
/* Copyright (c) 2008, 2009 The Board of Trustees of The Leland Stanford
* Junior University
*
* We are making the OpenFlow specification and associated documentation
* (Software) available for public use and benefit with the expectation
* that others will use, modify and enhance the Software and contribute
* those enhancements back to the community. However, since we would
* like to make the Software available for broadest use, with as few
* restrictions as possible permission is hereby granted, free of
* charge, to any person obtaining a copy of this Software to deal in
* the Software under the copyrights without restriction, including
* without limitation the rights to use, copy, modify, merge, publish,
* distribute, sublicense, and/or sell copies of the Software, and to
* permit persons to whom the Software is furnished to do so, subject to
* the following conditions:
*
* The above copyright notice and this permission notice shall be
* included in all copies or substantial portions of the Software.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
* NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS
* BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN
* ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
* CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
* SOFTWARE.
*
* The name and trademarks of copyright holder(s) may NOT be used in
* advertising or publicity pertaining to the Software or any
* derivatives without specific, written prior permission.
*/
/* The original Stanford code has been modified during the implementation of
* the OpenFlow 1.3 userspace switch.
*
*/
#include "datapath.h"
#include <assert.h>
#include <errno.h>
#include <inttypes.h>
#include <stdlib.h>
#include <string.h>
#include <unistd.h>
#include "csum.h"
#include "dp_buffers.h"
#include "dp_control.h"
#include "ofp.h"
#include "ofpbuf.h"
#include "group_table.h"
#include "meter_table.h"
#include "oflib/ofl.h"
#include "oflib-exp/ofl-exp.h"
#include "oflib-exp/ofl-exp-nicira.h"
#include "oflib/ofl-messages.h"
#include "oflib/ofl-log.h"
#include "openflow/openflow.h"
#include "openflow/nicira-ext.h"
#include "openflow/private-ext.h"
#include "openflow/openflow-ext.h"
#include "pipeline.h"
#include "poll-loop.h"
#include "rconn.h"
#include "stp.h"
#include "vconn.h"
#define LOG_MODULE VLM_dp
static struct vlog_rate_limit rl = VLOG_RATE_LIMIT_INIT(60, 60);
static struct remote *remote_create(struct datapath *dp, struct rconn *rconn, struct rconn *rconn_aux);
static void remote_run(struct datapath *, struct remote *);
static void remote_rconn_run(struct datapath *, struct remote *, uint8_t);
static void remote_wait(struct remote *);
static void remote_destroy(struct remote *);
#define MFR_DESC "Stanford University, Ericsson Research and CPqD Research"
#define HW_DESC "OpenFlow 1.3 Reference Userspace Switch"
#define SW_DESC __DATE__" "__TIME__
#define DP_DESC "OpenFlow 1.3 Reference Userspace Switch Datapath"
#define SERIAL_NUM "1"
#define MAIN_CONNECTION 0
#define PTIN_CONNECTION 1
/* Callbacks for processing experimenter messages in OFLib. */
static struct ofl_exp_msg dp_exp_msg =
{.pack = ofl_exp_msg_pack,
.unpack = ofl_exp_msg_unpack,
.free = ofl_exp_msg_free,
.to_string = ofl_exp_msg_to_string};
static struct ofl_exp dp_exp =
{.act = NULL,
.inst = NULL,
.match = NULL,
.stats = NULL,
.msg = &dp_exp_msg};
/* Generates and returns a random datapath id. */
static uint64_t
gen_datapath_id(void) {
uint8_t ea[ETH_ADDR_LEN];
eth_addr_random(ea);
return eth_addr_to_uint64(ea);
}
struct datapath *
dp_new(void) {
struct datapath *dp;
dp = xmalloc(sizeof(struct datapath));
dp->mfr_desc = strncpy(xmalloc(DESC_STR_LEN), MFR_DESC, DESC_STR_LEN);
dp->mfr_desc[DESC_STR_LEN-1] = 0x00;
dp->hw_desc = strncpy(xmalloc(DESC_STR_LEN), HW_DESC, DESC_STR_LEN);
dp->hw_desc[DESC_STR_LEN-1] = 0x00;
dp->sw_desc = strncpy(xmalloc(DESC_STR_LEN), SW_DESC, DESC_STR_LEN);
dp->sw_desc[DESC_STR_LEN-1] = 0x00;
dp->dp_desc = strncpy(xmalloc(DESC_STR_LEN), DP_DESC, DESC_STR_LEN);
dp->dp_desc[DESC_STR_LEN-1] = 0x00;
dp->serial_num = strncpy(xmalloc(SERIAL_NUM_LEN), SERIAL_NUM, SERIAL_NUM_LEN);
dp->serial_num[SERIAL_NUM_LEN-1] = 0x00;
dp->id = gen_datapath_id();
dp->generation_id = -1;
dp->last_timeout = time_now();
list_init(&dp->remotes);
dp->listeners = NULL;
dp->n_listeners = 0;
dp->listeners_aux = NULL;
dp->n_listeners_aux = 0;
memset(dp->ports, 0x00, sizeof (dp->ports));
dp->local_port = NULL;
dp->buffers = dp_buffers_create(dp);
dp->pipeline = pipeline_create(dp);
dp->groups = group_table_create(dp);
dp->meters = meter_table_create(dp);
list_init(&dp->port_list);
dp->ports_num = 0;
dp->max_queues = NETDEV_MAX_QUEUES;
dp->exp = &dp_exp;
dp->config.flags = OFPC_FRAG_NORMAL;
dp->config.miss_send_len = OFP_DEFAULT_MISS_SEND_LEN;
if(strlen(dp->dp_desc) == 0) {
/* just use "$HOSTNAME pid=$$" */
char hostnametmp[DESC_STR_LEN];
gethostname(hostnametmp,sizeof hostnametmp);
snprintf(dp->dp_desc, sizeof dp->dp_desc,"%s pid=%u",hostnametmp, getpid());
}
/* FIXME: Should not depend on udatapath_as_lib */
#if defined(OF_HW_PLAT) && (defined(UDATAPATH_AS_LIB) || defined(USE_NETDEV))
dp_hw_drv_init(dp);
#endif
return dp;
}
void
dp_add_pvconn(struct datapath *dp, struct pvconn *pvconn, struct pvconn *pvconn_aux) {
dp->listeners = xrealloc(dp->listeners,
sizeof *dp->listeners * (dp->n_listeners + 1));
dp->listeners[dp->n_listeners++] = pvconn;
dp->listeners_aux = xrealloc(dp->listeners_aux,
sizeof *dp->listeners_aux * (dp->n_listeners_aux + 1));
dp->listeners_aux[dp->n_listeners_aux++] = pvconn_aux;
}
void
dp_run(struct datapath *dp) {
time_t now = time_now();
struct remote *r, *rn;
size_t i;
if (now != dp->last_timeout) {
dp->last_timeout = now;
meter_table_add_tokens(dp->meters);
pipeline_timeout(dp->pipeline);
}
poll_timer_wait(1000);
dp_ports_run(dp);
/* Talk to remotes. */
LIST_FOR_EACH_SAFE (r, rn, struct remote, node, &dp->remotes) {
remote_run(dp, r);
}
for (i = 0; i < dp->n_listeners; ) {
struct pvconn *pvconn = dp->listeners[i];
struct vconn *new_vconn;
int retval = pvconn_accept(pvconn, OFP_VERSION, &new_vconn);
if (!retval) {
struct rconn * rconn_aux = NULL;
if (dp->n_listeners_aux && dp->listeners_aux[i] != NULL) {
struct pvconn *pvconn_aux = dp->listeners_aux[i];
struct vconn *new_vconn_aux;
int retval_aux = pvconn_accept(pvconn_aux, OFP_VERSION, &new_vconn_aux);
if (!retval_aux)
rconn_aux = rconn_new_from_vconn("passive_aux", new_vconn_aux);
}
remote_create(dp, rconn_new_from_vconn("passive", new_vconn), rconn_aux);
}
else if (retval != EAGAIN) {
VLOG_WARN_RL(LOG_MODULE, &rl, "accept failed (%s)", strerror(retval));
dp->listeners[i] = dp->listeners[--dp->n_listeners];
if (dp->n_listeners_aux) {
dp->listeners_aux[i] = dp->listeners_aux[--dp->n_listeners_aux];
}
continue;
}
i++;
}
}
static void
remote_run(struct datapath *dp, struct remote *r)
{
remote_rconn_run(dp, r, MAIN_CONNECTION);
if (!rconn_is_alive(r->rconn)) {
remote_destroy(r);
return;
}
if (r->rconn_aux == NULL || !rconn_is_alive(r->rconn_aux))
return;
remote_rconn_run(dp, r, PTIN_CONNECTION);
}
static void
remote_rconn_run(struct datapath *dp, struct remote *r, uint8_t conn_id) {
struct rconn *rconn;
ofl_err error;
size_t i;
if (conn_id == MAIN_CONNECTION)
rconn = r->rconn;
else if (conn_id == PTIN_CONNECTION)
rconn = r->rconn_aux;
rconn_run(rconn);
/* Do some remote processing, but cap it at a reasonable amount so that
* other processing doesn't starve. */
for (i = 0; i < 50; i++) {
if (!r->cb_dump) {
struct ofpbuf *buffer;
buffer = rconn_recv(rconn);
if (buffer == NULL) {
break;
} else {
struct ofl_msg_header *msg;
struct sender sender = {.remote = r, .conn_id = conn_id};
error = ofl_msg_unpack(buffer->data, buffer->size, &msg, &(sender.xid), dp->exp);
if (!error) {
error = handle_control_msg(dp, msg, &sender);
if (error) {
ofl_msg_free(msg, dp->exp);
}
}
if (error) {
struct ofl_msg_error err =
{{.type = OFPT_ERROR},
.type = ofl_error_type(error),
.code = ofl_error_code(error),
.data_length = buffer->size,
.data = buffer->data};
dp_send_message(dp, (struct ofl_msg_header *)&err, &sender);
}
ofpbuf_delete(buffer);
}
} else {
if (r->n_txq < TXQ_LIMIT) {
int error = r->cb_dump(dp, r->cb_aux);
if (error <= 0) {
if (error) {
VLOG_WARN_RL(LOG_MODULE, &rl, "Callback error: %s.",
strerror(-error));
}
r->cb_done(r->cb_aux);
r->cb_dump = NULL;
}
} else {
break;
}
}
}
}
static void
remote_wait(struct remote *r)
{
rconn_run_wait(r->rconn);
rconn_recv_wait(r->rconn);
if (r->rconn_aux) {
rconn_run_wait(r->rconn_aux);
rconn_recv_wait(r->rconn_aux);
}
}
static void
remote_destroy(struct remote *r)
{
if (r) {
if (r->cb_dump && r->cb_done) {
r->cb_done(r->cb_aux);
}
list_remove(&r->node);
if (r->rconn_aux != NULL) {
rconn_destroy(r->rconn_aux);
}
rconn_destroy(r->rconn);
free(r);
}
}
static struct remote *
remote_create(struct datapath *dp, struct rconn *rconn, struct rconn *rconn_aux)
{
size_t i;
struct remote *remote = xmalloc(sizeof *remote);
list_push_back(&dp->remotes, &remote->node);
remote->rconn = rconn;
remote->rconn_aux = rconn_aux;
remote->cb_dump = NULL;
remote->n_txq = 0;
remote->role = OFPCR_ROLE_EQUAL;
/* Set the remote configuration to receive any asynchronous message*/
for(i = 0; i < 2; i++){
memset(&remote->config.packet_in_mask[i], 0x7, sizeof(uint32_t));
memset(&remote->config.port_status_mask[i], 0x7, sizeof(uint32_t));
memset(&remote->config.flow_removed_mask[i], 0x1f, sizeof(uint32_t));
}
return remote;
}
void
dp_wait(struct datapath *dp)
{
struct sw_port *p;
struct remote *r;
size_t i;
LIST_FOR_EACH (p, struct sw_port, node, &dp->port_list) {
if (IS_HW_PORT(p)) {
continue;
}
netdev_recv_wait(p->netdev);
}
LIST_FOR_EACH (r, struct remote, node, &dp->remotes) {
remote_wait(r);
}
for (i = 0; i < dp->n_listeners; i++) {
pvconn_wait(dp->listeners[i]);
}
}
void
dp_set_dpid(struct datapath *dp, uint64_t dpid) {
dp->id = dpid;
}
void
dp_set_mfr_desc(struct datapath *dp, char *mfr_desc) {
strncpy(dp->mfr_desc, mfr_desc, DESC_STR_LEN);
dp->mfr_desc[DESC_STR_LEN-1] = 0x00;
}
void
dp_set_hw_desc(struct datapath *dp, char *hw_desc) {
strncpy(dp->hw_desc, hw_desc, DESC_STR_LEN);
dp->hw_desc[DESC_STR_LEN-1] = 0x00;
}
void
dp_set_sw_desc(struct datapath *dp, char *sw_desc) {
strncpy(dp->sw_desc, sw_desc, DESC_STR_LEN);
dp->sw_desc[DESC_STR_LEN-1] = 0x00;
}
void
dp_set_dp_desc(struct datapath *dp, char *dp_desc) {
strncpy(dp->dp_desc, dp_desc, DESC_STR_LEN);
dp->dp_desc[DESC_STR_LEN-1] = 0x00;
}
void
dp_set_serial_num(struct datapath *dp, char *serial_num) {
strncpy(dp->serial_num, serial_num, SERIAL_NUM_LEN);
dp->serial_num[SERIAL_NUM_LEN-1] = 0x00;
}
void
dp_set_max_queues(struct datapath *dp, uint32_t max_queues) {
dp->max_queues = max_queues;
}
static int
send_openflow_buffer_to_remote(struct ofpbuf *buffer, struct remote *remote) {
struct rconn* rconn = remote->rconn;
int retval;
if (buffer->conn_id == PTIN_CONNECTION &&
remote->rconn != NULL &&
remote->rconn_aux != NULL &&
rconn_is_connected(remote->rconn) &&
rconn_is_connected(remote->rconn_aux)) {
rconn = remote->rconn_aux;
}
retval = rconn_send_with_limit(rconn, buffer, &remote->n_txq,
TXQ_LIMIT);
if (retval) {
VLOG_WARN_RL(LOG_MODULE, &rl, "send to %s failed: %s",
rconn_get_name(rconn), strerror(retval));
}
return retval;
}
static int
send_openflow_buffer(struct datapath *dp, struct ofpbuf *buffer,
const struct sender *sender) {
update_openflow_length(buffer);
if (sender) {
/* Send back to the sender. */
return send_openflow_buffer_to_remote(buffer, sender->remote);
} else {
/* Broadcast to all remotes. */
struct remote *r, *prev = NULL;
uint8_t msg_type;
/* Get the type of the message */
memcpy(&msg_type,((char* ) buffer->data) + 1, sizeof(uint8_t));
LIST_FOR_EACH (r, struct remote, node, &dp->remotes) {
/* do not send to remotes with slave role apart from port status */
if (r->role == OFPCR_ROLE_EQUAL || r->role == OFPCR_ROLE_MASTER){
/*Check if the message is enabled in the asynchronous configuration*/
switch(msg_type){
case (OFPT_PACKET_IN):{
struct ofp_packet_in *p = (struct ofp_packet_in*)buffer->data;
/* Do not send message if the reason is not enabled */
if((p->reason == OFPR_NO_MATCH) && !(r->config.packet_in_mask[0] & 0x1))
continue;
if((p->reason == OFPR_ACTION) && !(r->config.packet_in_mask[0] & 0x2))
continue;
if((p->reason == OFPR_INVALID_TTL) && !(r->config.packet_in_mask[0] & 0x4))
continue;
break;
}
case (OFPT_PORT_STATUS):{
struct ofp_port_status *p = (struct ofp_port_status*)buffer->data;
if((p->reason == OFPPR_ADD) && !(r->config.port_status_mask[0] & 0x1))
continue;
if((p->reason == OFPPR_DELETE) && !(r->config.port_status_mask[0] & 0x2))
continue;
if((p->reason == OFPPR_MODIFY) && !(r->config.packet_in_mask[0] & 0x4))
continue;
}
case (OFPT_FLOW_REMOVED):{
struct ofp_flow_removed *p= (struct ofp_flow_removed *)buffer->data;
if((p->reason == OFPRR_IDLE_TIMEOUT) && !(r->config.port_status_mask[0] & 0x1))
continue;
if((p->reason == OFPRR_HARD_TIMEOUT) && !(r->config.port_status_mask[0] & 0x2))
continue;
if((p->reason == OFPRR_DELETE) && !(r->config.packet_in_mask[0] & 0x4))
continue;
if((p->reason == OFPRR_GROUP_DELETE) && !(r->config.packet_in_mask[0] & 0x8))
continue;
if((p->reason == OFPRR_METER_DELETE) && !(r->config.packet_in_mask[0] & 0x10))
continue;
}
}
}
else {
/* In this implementation we assume that a controller with role slave
can is able to receive only port stats messages */
if (r->role == OFPCR_ROLE_SLAVE && msg_type != OFPT_PORT_STATUS) {
continue;
}
else {
struct ofp_port_status *p = (struct ofp_port_status*)buffer->data;
if((p->reason == OFPPR_ADD) && !(r->config.port_status_mask[1] & 0x1))
continue;
if((p->reason == OFPPR_DELETE) && !(r->config.port_status_mask[1] & 0x2))
continue;
if((p->reason == OFPPR_MODIFY) && !(r->config.packet_in_mask[1] & 0x4))
continue;
}
}
if (prev) {
send_openflow_buffer_to_remote(ofpbuf_clone(buffer), prev);
}
prev = r;
}
if (prev) {
send_openflow_buffer_to_remote(buffer, prev);
} else {
ofpbuf_delete(buffer);
}
return 0;
}
}
int
dp_send_message(struct datapath *dp, struct ofl_msg_header *msg,
const struct sender *sender) {
struct ofpbuf *ofpbuf;
uint8_t *buf;
size_t buf_size;
int error;
if (VLOG_IS_DBG_ENABLED(LOG_MODULE)) {
char *msg_str = ofl_msg_to_string(msg, dp->exp);
VLOG_DBG_RL(LOG_MODULE, &rl, "sending: %.400s", msg_str);
free(msg_str);
}
error = ofl_msg_pack(msg, sender == NULL ? 0 : sender->xid, &buf, &buf_size, dp->exp);
if (error) {
VLOG_WARN_RL(LOG_MODULE, &rl, "There was an error packing the message!");
return error;
}
ofpbuf = ofpbuf_new(0);
ofpbuf_use(ofpbuf, buf, buf_size);
ofpbuf_put_uninit(ofpbuf, buf_size);
/* Choose the connection to send the packet to.
1) By default, we send it to the main connection
2) If there's an associated sender, send the response to the same
connection the request came from
3) If it's a packet in, use the auxiliary connection
*/
ofpbuf->conn_id = MAIN_CONNECTION;
if (sender != NULL)
ofpbuf->conn_id = sender->conn_id;
if (msg->type == OFPT_PACKET_IN)
ofpbuf->conn_id = PTIN_CONNECTION;
error = send_openflow_buffer(dp, ofpbuf, sender);
if (error) {
VLOG_WARN_RL(LOG_MODULE, &rl, "There was an error sending the message!");
/* TODO Zoltan: is delete needed? */
ofpbuf_delete(ofpbuf);
return error;
}
return 0;
}
ofl_err
dp_handle_set_desc(struct datapath *dp, struct ofl_exp_openflow_msg_set_dp_desc *msg,
const struct sender *sender UNUSED) {
dp_set_dp_desc(dp, msg->dp_desc);
ofl_msg_free((struct ofl_msg_header *)msg, dp->exp);
return 0;
}
static ofl_err
dp_check_generation_id(struct datapath *dp, uint64_t new_gen_id){
if(dp->generation_id >= 0 && ((uint64_t)(new_gen_id - dp->generation_id) < 0) )
return ofl_error(OFPET_ROLE_REQUEST_FAILED, OFPRRFC_STALE);
else dp->generation_id = new_gen_id;
return 0;
}
ofl_err
dp_handle_role_request(struct datapath *dp, struct ofl_msg_role_request *msg,
const struct sender *sender) {
uint32_t role = msg->role;
uint64_t generation_id = msg->generation_id;
switch (msg->role) {
case OFPCR_ROLE_NOCHANGE:{
role = sender->remote->role;
generation_id = dp->generation_id;
break;
}
case OFPCR_ROLE_EQUAL: {
sender->remote->role = OFPCR_ROLE_EQUAL;
break;
}
case OFPCR_ROLE_MASTER: {
struct remote *r;
int error = dp_check_generation_id(dp,msg->generation_id);
if (error) {
VLOG_WARN_RL(LOG_MODULE, &rl, "Role message generation id is smaller than the current id!");
return error;
}
/* Old master(s) must be changed to slave(s) */
LIST_FOR_EACH (r, struct remote, node, &dp->remotes) {
if (r->role == OFPCR_ROLE_MASTER) {
r->role = OFPCR_ROLE_SLAVE;
}
}
sender->remote->role = OFPCR_ROLE_MASTER;
break;
}
case OFPCR_ROLE_SLAVE: {
int error = dp_check_generation_id(dp,msg->generation_id);
if (error) {
VLOG_WARN_RL(LOG_MODULE, &rl, "Role message generation id is smaller than the current id!");
return error;
}
sender->remote->role = OFPCR_ROLE_SLAVE;
break;
}
default: {
VLOG_WARN_RL(LOG_MODULE, &rl, "Role request with unknown role (%u).", msg->role);
return ofl_error(OFPET_ROLE_REQUEST_FAILED, OFPRRFC_BAD_ROLE);
}
}
{
struct ofl_msg_role_request reply =
{{.type = OFPT_ROLE_REPLY},
.role = role,
.generation_id = generation_id};
dp_send_message(dp, (struct ofl_msg_header *)&reply, sender);
}
return 0;
}
ofl_err
dp_handle_async_request(struct datapath *dp, struct ofl_msg_async_config *msg,
const struct sender *sender) {
uint16_t async_type = msg->header.type;
switch(async_type){
case (OFPT_GET_ASYNC_REQUEST):{
struct ofl_msg_async_config reply =
{{.type = OFPT_GET_ASYNC_REPLY},
.config = &sender->remote->config};
dp_send_message(dp, (struct ofl_msg_header *)&reply, sender);
ofl_msg_free((struct ofl_msg_header*)msg, dp->exp);
break;
}
case (OFPT_SET_ASYNC):{
memcpy(&sender->remote->config, msg->config, sizeof(struct ofl_async_config));
break;
}
}
return 0;
}
| Java |
/*!
* This program is free software; you can redistribute it and/or modify it under the
* terms of the GNU Lesser General Public License, version 2.1 as published by the Free Software
* Foundation.
*
* You should have received a copy of the GNU Lesser General Public License along with this
* program; if not, you can obtain a copy at http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html
* or from the Free Software Foundation, Inc.,
* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
*
* This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY;
* without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
* See the GNU Lesser General Public License for more details.
*
* Copyright (c) 2002-2017 Hitachi Vantara.. All rights reserved.
*/
package org.pentaho.reporting.engine.classic.core.layout.output;
import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
import org.pentaho.reporting.engine.classic.core.event.ReportProgressEvent;
import org.pentaho.reporting.engine.classic.core.event.ReportProgressListener;
import org.pentaho.reporting.libraries.base.util.MemoryUsageMessage;
import org.pentaho.reporting.libraries.formatting.FastMessageFormat;
public class PerformanceProgressLogger implements ReportProgressListener {
private static final Log logger = LogFactory.getLog( PerformanceProgressLogger.class );
private static final int ROW_PROGRESS = 5000;
private int lastPage;
private int lastRow;
private int lastStage;
private int lastActivity;
private long startTime;
private int rowCount;
private boolean logPageProgress;
private boolean logLevelProgress;
private boolean logRowProgress;
public PerformanceProgressLogger() {
this( true, true, true );
}
public PerformanceProgressLogger( final boolean logLevelProgress, final boolean logPageProgress,
final boolean logRowProgress ) {
this.logLevelProgress = logLevelProgress;
this.logPageProgress = logPageProgress;
this.logRowProgress = logRowProgress;
}
/**
* Receives a notification that the report processing has started.
*
* @param event
* the start event.
*/
public void reportProcessingStarted( final ReportProgressEvent event ) {
if ( logger.isInfoEnabled() == false ) {
return;
}
rowCount = -1;
startTime = System.currentTimeMillis();
logger.info( new MemoryUsageMessage( "[" + Thread.currentThread().getName() + "] Report Processing started. " ) );
}
/**
* Receives a notification that the report processing made some progress.
*
* @param event
* the update event.
*/
public void reportProcessingUpdate( final ReportProgressEvent event ) {
if ( logger.isInfoEnabled() == false ) {
return;
}
rowCount = event.getMaximumRow();
boolean print = false;
if ( lastStage != event.getLevel() || lastActivity != event.getActivity() ) {
lastStage = event.getLevel();
lastActivity = event.getActivity();
lastRow = 0;
if ( logLevelProgress ) {
print = true;
}
}
if ( lastPage != event.getPage() ) {
lastPage = event.getPage();
if ( logPageProgress ) {
print = true;
}
}
final int modRow = ( event.getRow() - lastRow );
if ( modRow > ROW_PROGRESS ) {
lastRow = ( event.getRow() / ROW_PROGRESS ) * ROW_PROGRESS;
if ( logRowProgress ) {
print = true;
}
}
if ( print ) {
logger.info( new MemoryUsageMessage( "[" + Thread.currentThread().getName() + "] Activity: "
+ event.getActivity() + " Level: " + +lastStage + " Processing page: " + lastPage + " Row: " + lastRow
+ " Time: " + ( System.currentTimeMillis() - startTime ) + "ms " ) );
}
}
/**
* Receives a notification that the report processing was finished.
*
* @param event
* the finish event.
*/
public void reportProcessingFinished( final ReportProgressEvent event ) {
if ( logger.isInfoEnabled() == false ) {
return;
}
final FastMessageFormat messageFormat =
new FastMessageFormat( "[{0}] Report Processing Finished: {1}ms - {2,number,0.000} rows/sec - " );
final long processTime = System.currentTimeMillis() - startTime;
final double rowsPerSecond = rowCount * 1000.0f / ( processTime );
logger.info( new MemoryUsageMessage( messageFormat.format( new Object[] { Thread.currentThread().getName(),
new Long( processTime ), new Double( rowsPerSecond ) } ) ) );
}
}
| Java |
/**********************************************************************
* $Id$
*
* GEOS - Geometry Engine Open Source
* http://geos.refractions.net
*
* Copyright (C) 2001-2002 Vivid Solutions Inc.
*
* This is free software; you can redistribute and/or modify it under
* the terms of the GNU Lesser General Public Licence as published
* by the Free Software Foundation.
* See the COPYING file for more information.
*
**********************************************************************
* $Log$
* Revision 1.3 2004/03/17 02:00:33 ybychkov
* "Algorithm" upgraded to JTS 1.4
*
* Revision 1.2 2003/11/07 01:23:43 pramsey
* Add standard CVS headers licence notices and copyrights to all cpp and h
* files.
*
*
**********************************************************************/
/*////////////////////////////////////////////////////////////////////////////
* Project:
* Memory_and_Exception_Trace
*
* ///////////////////////////////////////////////////////////////////////////
* File:
* Stackwalker.h
*
* Remarks:
*
*
* Note:
*
*
* Author:
* Jochen Kalmbach
*
*////////////////////////////////////////////////////////////////////////////
#ifndef __STACKWALKER_H__
#define __STACKWALKER_H__
// Only valid in the following environment: Intel platform, MS VC++ 5/6/7
#ifndef _X86_
#error Only INTEL envirnoments are supported!
#endif
// Only MS VC++ 5 to 7
#if (_MSC_VER < 1100) || (_MSC_VER > 1300)
//#warning Only MS VC++ 5/6/7 supported. Check if the '_CrtMemBlockHeader' has not changed with this compiler!
#endif
typedef enum eAllocCheckOutput
{
ACOutput_Simple,
ACOutput_Advanced,
ACOutput_XML
};
// Make extern "C", so it will also work with normal C-Programs
#ifdef __cplusplus
extern "C" {
#endif
extern int InitAllocCheckWN(eAllocCheckOutput eOutput, LPCTSTR pszFilename, ULONG ulShowStackAtAlloc = 0);
extern int InitAllocCheck(eAllocCheckOutput eOutput = ACOutput_Simple, BOOL bSetUnhandledExeptionFilter = TRUE, ULONG ulShowStackAtAlloc = 0); // will create the filename by itself
extern ULONG DeInitAllocCheck();
extern DWORD StackwalkFilter( EXCEPTION_POINTERS *ep, DWORD status, LPCTSTR pszLogFile);
#ifdef __cplusplus
}
#endif
#endif // __STACKWALKER_H__
| Java |
/******************************************************************************
JPtrArray-JString16.h
Copyright © 1997 by John Lindal. All rights reserved.
******************************************************************************/
#ifndef _H_JPtrArray_JString16
#define _H_JPtrArray_JString16
#if !defined _J_UNIX && !defined ACE_LACKS_PRAGMA_ONCE
#pragma once
#endif
#include <JPtrArray.h>
#ifdef _TODO
#include <JString16PtrMap.h>
#endif
#include <JString16.h>
istream& operator>>(istream&, JPtrArray<JString16>&);
ostream& operator<<(ostream&, const JPtrArray<JString16>&);
#ifdef _TODO
istream& operator>>(istream&, JString16PtrMap<JString16>&);
ostream& operator<<(ostream&, const JString16PtrMap<JString16>&);
#endif
JBoolean JSameStrings(const JPtrArray<JString16>&, const JPtrArray<JString16>&,
const JBoolean caseSensitive);
JOrderedSetT::CompareResult
JCompareStringsCaseSensitive(JString16* const &, JString16* const &);
JOrderedSetT::CompareResult
JCompareStringsCaseInsensitive(JString16* const &, JString16* const &);
#endif
| Java |
/* -*- OpenSAF -*-
*
* (C) Copyright 2010 The OpenSAF Foundation
*
* This program is distributed in the hope that it will be useful, but
* WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
* or FITNESS FOR A PARTICULAR PURPOSE. This file and program are licensed
* under the GNU Lesser General Public License Version 2.1, February 1999.
* The complete license can be accessed from the following location:
* http://opensource.org/licenses/lgpl-license.php
* See the Copying file included with the OpenSAF distribution for full
* licensing terms.
*
* Author(s): Wind River Systems
*
*/
#include <ncssysf_tsk.h>
#include <logtrace.h>
#include <daemon.h>
#include "cpd.h"
static int __init_cpd(void)
{
NCS_LIB_REQ_INFO lib_create;
/* Init LIB_CREATE request for Server */
memset(&lib_create, 0, sizeof(lib_create));
lib_create.i_op = NCS_LIB_REQ_CREATE;
lib_create.info.create.argc = 0;
lib_create.info.create.argv = NULL;
if (ncs_agents_startup() != NCSCC_RC_SUCCESS)
return m_LEAP_DBG_SINK(NCSCC_RC_FAILURE);
/* Init CPD */
m_NCS_DBG_PRINTF("\nCPSV:CPD:ON");
if (cpd_lib_req(&lib_create) != NCSCC_RC_SUCCESS) {
fprintf(stderr, "cpd_lib_req FAILED\n");
return m_LEAP_DBG_SINK(NCSCC_RC_FAILURE);
}
return (NCSCC_RC_SUCCESS);
}
int main(int argc, char *argv[])
{
daemonize(argc, argv);
if (__init_cpd() != NCSCC_RC_SUCCESS) {
syslog(LOG_ERR, "__init_dts() failed");
exit(EXIT_FAILURE);
}
while (1) {
m_NCS_TASK_SLEEP(0xfffffff0);
}
exit(1);
}
| Java |
/* Copyright (C) 2006-2008 Jeff Epler <jepler@unpythonic.net>
* Copyright (C) 2012-2014 Michael Haberler <license@mah.priv.at>
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
*/
/*
* TODO: on setuid and capabilites(7)
*
* right now this program runs as setuid root
* it might be possible to drop the wholesale root privs by using
* capabilites(7). in particular:
*
* CAP_SYS_RAWIO open /dev/mem and /dev/kmem & Perform I/O port operations
* CAP_SYS_NICE set real-time scheduling policies, set CPU affinity
* CAP_SYS_MODULE Load and unload kernel modules
*
* NB: Capabilities are a per-thread attribute,
* so this might need to be done on a per-thread basis
* see also CAP_SETPCAP, CAP_INHERITABLE and 'inheritable set'
*
* see also:
* http://stackoverflow.com/questions/13183327/drop-root-uid-while-retaining-cap-sys-nice
* http://stackoverflow.com/questions/12141420/losing-capabilities-after-setuid
*/
#include "config.h"
#include <sys/types.h>
#include <unistd.h>
#include <errno.h>
#include <uuid/uuid.h>
#include <dlfcn.h>
#include <signal.h>
#include <sys/signalfd.h>
#include <string>
#include <map>
#include <vector>
#include <algorithm>
#include <sys/resource.h>
#include <linux/capability.h>
#include <sys/io.h>
#include <stdlib.h>
#include <stdio.h>
#include <getopt.h>
#include <errno.h>
#include <malloc.h>
#include <assert.h>
#include <syslog_async.h>
#include <limits.h>
#include <sys/prctl.h>
#include <inifile.h>
#include <czmq.h>
#include <google/protobuf/text_format.h>
#include <machinetalk/generated/message.pb.h>
using namespace google::protobuf;
typedef ::google::protobuf::RepeatedPtrField< ::std::string> pbstringarray_t;
#include "rtapi.h"
#include "rtapi_global.h"
#include "rtapi_compat.h"
#include "hal.h"
#include "hal_priv.h"
#include "rtapi/shmdrv/shmdrv.h"
#include "mk-backtrace.h"
#include "setup_signals.h"
#include "mk-zeroconf.hh"
#include "select_interface.h"
#define BACKGROUND_TIMER 1000
using namespace std;
/* Pre-allocation size. Must be enough for the whole application life to avoid
* pagefaults by new memory requested from the system. */
#define PRE_ALLOC_SIZE (30 * 1024 * 1024)
template<class T> T DLSYM(void *handle, const string &name) {
return (T)(dlsym(handle, name.c_str()));
}
template<class T> T DLSYM(void *handle, const char *name) {
return (T)(dlsym(handle, name));
}
static std::map<string, void*> modules;
static std::vector<string> loading_order;
static void remove_module(std::string name);
static struct rusage rusage;
static unsigned long minflt, majflt;
static int instance_id;
flavor_ptr flavor;
static int use_drivers = 0;
static int foreground;
static int debug;
static int signal_fd;
static bool interrupted;
int shmdrv_loaded;
long page_size;
static const char *progname;
static const char *z_uri;
static int z_port;
static pb::Container command, reply;
static uuid_t process_uuid;
static char process_uuid_str[40];
static register_context_t *rtapi_publisher;
static const char *service_uuid;
#ifdef NOTYET
static int remote = 0; // announce and bind a TCP socket
static const char *ipaddr = "127.0.0.1";
static const char *z_uri_dsn;
#endif
static const char *interfaces;
static const char *inifile;
static FILE *inifp;
#ifdef NOTYET
static AvahiCzmqPoll *av_loop;
#endif
// the following two variables, despite extern, are in fact private to rtapi_app
// in the sense that they are not visible in the RT space (the namespace
// of dlopen'd modules); these are supposed to be 'ships in the night'
// relative to any symbols exported by rtapi_app.
//
// global_data is set in attach_global_segment() which was already
// created by rtapi_msgd
// rtapi_switch is set once rtapi.so has been loaded by calling the
// rtapi_get_handle() method in rtapi.so.
// Once set, rtapi methods in rtapi.so can be called normally through
// the rtapi_switch redirection (see rtapi.h).
// NB: do _not_ call any rtapi_* methods before these variables are set
// except for rtapi_msg* and friends (those do not go through the rtapi_switch).
rtapi_switch_t *rtapi_switch;
global_data_t *global_data;
static int init_actions(int instance);
static void exit_actions(int instance);
static int harden_rt(void);
static void rtapi_app_msg_handler(msg_level_t level, const char *fmt, va_list ap);
static void stderr_rtapi_msg_handler(msg_level_t level, const char *fmt, va_list ap);
static int do_one_item(char item_type_char, const string ¶m_name,
const string ¶m_value, void *vitem, int idx=0)
{
char *endp;
switch(item_type_char) {
case 'l': {
long *litem = *(long**) vitem;
litem[idx] = strtol(param_value.c_str(), &endp, 0);
if(*endp) {
rtapi_print_msg(RTAPI_MSG_ERR,
"`%s' invalid for parameter `%s'",
param_value.c_str(), param_name.c_str());
return -1;
}
return 0;
}
case 'i': {
int *iitem = *(int**) vitem;
iitem[idx] = strtol(param_value.c_str(), &endp, 0);
if(*endp) {
rtapi_print_msg(RTAPI_MSG_ERR,
"`%s' invalid for parameter `%s'",
param_value.c_str(), param_name.c_str());
return -1;
}
return 0;
}
case 's': {
char **sitem = *(char***) vitem;
sitem[idx] = strdup(param_value.c_str());
return 0;
}
default:
rtapi_print_msg(RTAPI_MSG_ERR,
"%s: Invalid type character `%c'\n",
param_name.c_str(), item_type_char);
return -1;
}
return 0;
}
void remove_quotes(string &s)
{
s.erase(remove_copy(s.begin(), s.end(), s.begin(), '"'), s.end());
}
static int do_comp_args(void *module, pbstringarray_t args)
{
for(int i = 0; i < args.size(); i++) {
string s(args.Get(i));
remove_quotes(s);
size_t idx = s.find('=');
if(idx == string::npos) {
rtapi_print_msg(RTAPI_MSG_ERR, "Invalid parameter `%s'\n",
s.c_str());
return -1;
}
string param_name(s, 0, idx);
string param_value(s, idx+1);
void *item=DLSYM<void*>(module, "rtapi_info_address_" + param_name);
if(!item) {
rtapi_print_msg(RTAPI_MSG_ERR,
"Unknown parameter `%s'\n", s.c_str());
return -1;
}
char **item_type=DLSYM<char**>(module, "rtapi_info_type_" + param_name);
if(!item_type || !*item_type) {
rtapi_print_msg(RTAPI_MSG_ERR,
"Unknown parameter `%s' (type information missing)\n",
s.c_str());
return -1;
}
string item_type_string = *item_type;
if(item_type_string.size() > 1) {
int a, b;
char item_type_char;
int r = sscanf(item_type_string.c_str(), "%d-%d%c",
&a, &b, &item_type_char);
if(r != 3) {
rtapi_print_msg(RTAPI_MSG_ERR,
"Unknown parameter `%s'"
" (corrupt array type information): %s\n",
s.c_str(), item_type_string.c_str());
return -1;
}
size_t idx = 0;
int i = 0;
while(idx != string::npos) {
if(i == b) {
rtapi_print_msg(RTAPI_MSG_ERR,
"%s: can only take %d arguments\n",
s.c_str(), b);
return -1;
}
size_t idx1 = param_value.find(",", idx);
string substr(param_value, idx, idx1 - idx);
int result = do_one_item(item_type_char, s, substr, item, i);
if(result != 0) return result;
i++;
idx = idx1 == string::npos ? idx1 : idx1 + 1;
}
} else {
char item_type_char = item_type_string[0];
int result = do_one_item(item_type_char, s, param_value, item);
if(result != 0) return result;
}
}
return 0;
}
static void pbconcat(string &s, const pbstringarray_t &args)
{
for (int i = 0; i < args.size(); i++) {
s += args.Get(i);
if (i < args.size()-1)
s += " ";
}
}
static inline bool kernel_threads(flavor_ptr f) {
assert(f);
return (f->flags & FLAVOR_KERNEL_BUILD) != 0;
}
static int do_load_cmd(int instance, string name, pbstringarray_t args)
{
void *w = modules[name];
char module_name[PATH_MAX];
void *module;
int retval;
if (w == NULL) {
if (kernel_threads(flavor)) {
string cmdargs;
pbconcat(cmdargs, args);
retval = run_module_helper("insert %s %s", name.c_str(), cmdargs.c_str());
if (retval) {
rtapi_print_msg(RTAPI_MSG_ERR, "couldnt insmod %s - see dmesg\n",
name.c_str());
} else {
modules[name] = (void *) -1; // so 'if (modules[name])' works
loading_order.push_back(name);
}
return retval;
} else {
strncpy(module_name, (name + flavor->mod_ext).c_str(),
PATH_MAX);
module = modules[name] = dlopen(module_name, RTLD_GLOBAL |RTLD_NOW);
if (!module) {
rtapi_print_msg(RTAPI_MSG_ERR, "%s: dlopen: %s\n",
name.c_str(), dlerror());
return -1;
}
// retrieve the address of rtapi_switch_struct
// so rtapi functions can be called and members
// accessed
if (rtapi_switch == NULL) {
rtapi_get_handle_t rtapi_get_handle;
dlerror();
rtapi_get_handle = (rtapi_get_handle_t) dlsym(module,
"rtapi_get_handle");
if (rtapi_get_handle != NULL) {
rtapi_switch = rtapi_get_handle();
assert(rtapi_switch != NULL);
}
}
/// XXX handle arguments
int (*start)(void) = DLSYM<int(*)(void)>(module, "rtapi_app_main");
if(!start) {
rtapi_print_msg(RTAPI_MSG_ERR, "%s: dlsym: %s\n",
name.c_str(), dlerror());
return -1;
}
int result;
result = do_comp_args(module, args);
if(result < 0) { dlclose(module); return -1; }
// need to call rtapi_app_main with as root
// RT thread creation and hardening requires this
if ((result = start()) < 0) {
rtapi_print_msg(RTAPI_MSG_ERR, "rtapi_app_main(%s): %d %s\n",
name.c_str(), result, strerror(-result));
modules.erase(modules.find(name));
return result;
}
loading_order.push_back(name);
rtapi_print_msg(RTAPI_MSG_DBG, "%s: loaded from %s\n",
name.c_str(), module_name);
return 0;
}
} else {
rtapi_print_msg(RTAPI_MSG_ERR, "%s: already loaded\n", name.c_str());
return -1;
}
}
static int do_unload_cmd(int instance, string name)
{
void *w = modules[name];
int retval = 0;
if (w == NULL) {
rtapi_print_msg(RTAPI_MSG_ERR, "unload: '%s' not loaded\n",
name.c_str());
return -1;
} else {
if (kernel_threads(flavor)) {
retval = run_module_helper("remove %s", name.c_str());
if (retval) {
rtapi_print_msg(RTAPI_MSG_ERR, "couldnt rmmod %s - see dmesg\n",
name.c_str());
return retval;
} else {
modules.erase(modules.find(name));
remove_module(name);
}
} else {
int (*stop)(void) = DLSYM<int(*)(void)>(w, "rtapi_app_exit");
if (stop)
stop();
modules.erase(modules.find(name));
remove_module(name);
dlclose(w);
}
}
rtapi_print_msg(RTAPI_MSG_DBG, " '%s' unloaded\n", name.c_str());
return retval;
}
// shut down the stack in reverse loading order
static void exit_actions(int instance)
{
size_t index = loading_order.size() - 1;
for(std::vector<std::string>::reverse_iterator rit = loading_order.rbegin();
rit != loading_order.rend(); ++rit, --index) {
do_unload_cmd(instance, *rit);
}
}
static int init_actions(int instance)
{
int retval;
char modules[PATH_MAX];
get_rtapi_config(modules,"MODULES",PATH_MAX);
if (kernel_threads(flavor)) {
// kthreads cant possibly run without shmdrv, so bail
// also, cannot load it here because rtapi_msgd already needs this
// so it'd be too late here
if (!is_module_loaded("shmdrv")) {
rtapi_print_msg(RTAPI_MSG_ERR, "shmdrv not loaded");
return -1;
}
// leftovers or running session?
if (is_module_loaded("rtapi")) {
rtapi_print_msg(RTAPI_MSG_ERR, "rtapi already loaded");
return -1;
}
if (is_module_loaded("hal_lib")) {
rtapi_print_msg(RTAPI_MSG_ERR, "hal_lib already loaded");
return -1;
}
char *m = strtok(modules, "\t ");
while (m != NULL) {
char cmdline[PATH_MAX];
if (!strcmp(m, "rtapi")) {
snprintf(cmdline, sizeof(cmdline),
"insert %s rtapi_instance=%d", m, instance_id);
} else {
snprintf(cmdline, sizeof(cmdline), "insert %s", m);
}
rtapi_print_msg(RTAPI_MSG_DBG, "running '%s'", cmdline);
retval = run_module_helper(cmdline);
if (retval) {
rtapi_print_msg(RTAPI_MSG_ERR,
"linuxcnc_module_helper '%s' failed - see dmesg\n",
cmdline);
return retval;
} else
rtapi_print_msg(RTAPI_MSG_DBG, "'%s' loaded\n", m);
m = strtok(NULL, "\t ");
}
}
retval = do_load_cmd(instance, "rtapi", pbstringarray_t());
if (retval)
return retval;
return do_load_cmd(instance, "hal_lib", pbstringarray_t());
}
static int attach_global_segment()
{
int retval = 0;
int globalkey = OS_KEY(GLOBAL_KEY, instance_id);
int size = 0;
int tries = 10; // 5 sec deadline for msgd/globaldata to come up
shm_common_init();
do {
retval = shm_common_new(globalkey, &size,
instance_id, (void **) &global_data, 0);
if (retval < 0) {
tries--;
if (tries == 0) {
syslog_async(LOG_ERR,
"rtapi_app:%d: ERROR: cannot attach global segment key=0x%x %s\n",
instance_id, globalkey, strerror(-retval));
return retval;
}
struct timespec ts = {0, 500 * 1000 * 1000}; //ms
nanosleep(&ts, NULL);
}
} while (retval < 0);
if (size != sizeof(global_data_t)) {
syslog_async(LOG_ERR,
"rtapi_app:%d global segment size mismatch: expect %zu got %d\n",
instance_id, sizeof(global_data_t), size);
return -EINVAL;
}
tries = 10;
while (global_data->magic != GLOBAL_READY) {
tries--;
if (tries == 0) {
syslog_async(LOG_ERR,
"rtapi_app:%d: ERROR: global segment magic not changing to ready: magic=0x%x\n",
instance_id, global_data->magic);
return -EINVAL;
}
struct timespec ts = {0, 500 * 1000 * 1000}; //ms
nanosleep(&ts, NULL);
}
return retval;
}
// handle commands from zmq socket
static int rtapi_request(zloop_t *loop, zmq_pollitem_t *poller, void *arg)
{
zmsg_t *r = zmsg_recv(poller->socket);
char *origin = zmsg_popstr (r);
zframe_t *request_frame = zmsg_pop (r);
static bool force_exit = false;
pb::Container pbreq, pbreply;
if (!pbreq.ParseFromArray(zframe_data(request_frame),
zframe_size(request_frame))) {
rtapi_print_msg(RTAPI_MSG_ERR, "cant decode request from %s (size %zu)",
origin ? origin : "NULL",
zframe_size(request_frame));
zmsg_destroy(&r);
return 0;
}
if (debug) {
string buffer;
if (TextFormat::PrintToString(pbreq, &buffer)) {
fprintf(stderr, "request: %s\n",buffer.c_str());
}
}
pbreply.set_type(pb::MT_RTAPI_APP_REPLY);
switch (pbreq.type()) {
case pb::MT_RTAPI_APP_PING:
char buffer[LINELEN];
snprintf(buffer, sizeof(buffer),
"pid=%d flavor=%s gcc=%s git=%s",
getpid(),flavor->name, __VERSION__, GIT_VERSION);
pbreply.add_note(buffer);
pbreply.set_retcode(0);
break;
case pb::MT_RTAPI_APP_EXIT:
assert(pbreq.has_rtapicmd());
exit_actions(pbreq.rtapicmd().instance());
force_exit = true;
pbreply.set_retcode(0);
break;
case pb::MT_RTAPI_APP_LOADRT:
assert(pbreq.has_rtapicmd());
assert(pbreq.rtapicmd().has_modname());
assert(pbreq.rtapicmd().has_instance());
pbreply.set_retcode(do_load_cmd(pbreq.rtapicmd().instance(),
pbreq.rtapicmd().modname(),
pbreq.rtapicmd().argv()));
break;
case pb::MT_RTAPI_APP_UNLOADRT:
assert(pbreq.rtapicmd().has_modname());
assert(pbreq.rtapicmd().has_instance());
pbreply.set_retcode(do_unload_cmd(pbreq.rtapicmd().instance(),
pbreq.rtapicmd().modname()));
break;
case pb::MT_RTAPI_APP_LOG:
assert(pbreq.has_rtapicmd());
if (pbreq.rtapicmd().has_rt_msglevel()) {
global_data->rt_msg_level = pbreq.rtapicmd().rt_msglevel();
}
if (pbreq.rtapicmd().has_user_msglevel()) {
global_data->user_msg_level = pbreq.rtapicmd().user_msglevel();
}
pbreply.set_retcode(0);
break;
#if DEPRECATED
case pb::MT_RTAPI_APP_NEWINST:
pbreply.set_retcode(0);
break;
#endif
case pb::MT_RTAPI_APP_NEWTHREAD:
assert(pbreq.has_rtapicmd());
assert(pbreq.rtapicmd().has_threadname());
assert(pbreq.rtapicmd().has_threadperiod());
assert(pbreq.rtapicmd().has_cpu());
assert(pbreq.rtapicmd().has_use_fp());
assert(pbreq.rtapicmd().has_instance());
if (kernel_threads(flavor)) {
int retval = procfs_threadcmd("newthread %s %d %d %d",
pbreq.rtapicmd().threadname().c_str(),
pbreq.rtapicmd().threadperiod(),
pbreq.rtapicmd().use_fp(),
pbreq.rtapicmd().cpu());
pbreply.set_retcode(retval < 0 ? retval:0);
} else {
void *w = modules["hal_lib"];
if (w == NULL) {
pbreply.add_note("hal_lib not loaded");
pbreply.set_retcode(-1);
break;
}
int (*create_thread)(const char *, unsigned long,int, int) =
DLSYM<int(*)(const char *, unsigned long,int, int)>(w,
"hal_create_thread");
if (create_thread == NULL) {
pbreply.add_note("symbol 'hal_create_thread' not found in hal_lib");
pbreply.set_retcode(-1);
break;
}
int retval = create_thread(pbreq.rtapicmd().threadname().c_str(),
pbreq.rtapicmd().threadperiod(),
pbreq.rtapicmd().use_fp(),
pbreq.rtapicmd().cpu());
pbreply.set_retcode(retval);
}
break;
case pb::MT_RTAPI_APP_DELTHREAD:
assert(pbreq.has_rtapicmd());
assert(pbreq.rtapicmd().has_threadname());
assert(pbreq.rtapicmd().has_instance());
if (kernel_threads(flavor)) {
int retval = procfs_threadcmd("delthread %s",
pbreq.rtapicmd().threadname().c_str());
pbreply.set_retcode(retval < 0 ? retval:0);
} else {
void *w = modules["hal_lib"];
if (w == NULL) {
pbreply.add_note("hal_lib not loaded");
pbreply.set_retcode(-1);
break;
}
int (*delete_thread)(const char *) =
DLSYM<int(*)(const char *)>(w,"hal_thread_delete");
if (delete_thread == NULL) {
pbreply.add_note("symbol 'hal_thread_delete' not found in hal_lib");
pbreply.set_retcode(-1);
break;
}
int retval = delete_thread(pbreq.rtapicmd().threadname().c_str());
pbreply.set_retcode(retval);
}
break;
default:
rtapi_print_msg(RTAPI_MSG_ERR,
"unkown command type %d)",
(int) pbreq.type());
zmsg_destroy(&r);
return 0;
}
// TODO: extract + attach error message
size_t reply_size = pbreply.ByteSize();
zframe_t *reply = zframe_new (NULL, reply_size);
if (!pbreply.SerializeWithCachedSizesToArray(zframe_data (reply))) {
zframe_destroy(&reply);
rtapi_print_msg(RTAPI_MSG_ERR,
"cant serialize to %s (type %d size %zu)",
origin ? origin : "NULL",
pbreply.type(),
reply_size);
} else {
if (debug) {
string buffer;
if (TextFormat::PrintToString(pbreply, &buffer)) {
fprintf(stderr, "reply: %s\n",buffer.c_str());
}
}
assert(zstr_sendm (poller->socket, origin) == 0);
if (zframe_send (&reply, poller->socket, 0)) {
rtapi_print_msg(RTAPI_MSG_ERR,
"cant serialize to %s (type %d size %zu)",
origin ? origin : "NULL",
pbreply.type(),
zframe_size(reply));
}
}
free(origin);
zmsg_destroy(&r);
if (force_exit) // terminate the zloop
return -1;
return 0;
}
static void btprint(const char *prefix, const char *fmt, ...)
{
va_list args;
va_start(args, fmt);
rtapi_msg_handler_t print = rtapi_get_msg_handler();
print(RTAPI_MSG_ERR, fmt, args);
va_end(args);
}
// handle signals delivered via sigaction - not all signals
// can be dealt with through signalfd(2)
// log, try to do something sane, and dump core
static void sigaction_handler(int sig, siginfo_t *si, void *uctx)
{
switch (sig) {
case SIGXCPU:
// should not happen - must be handled in RTAPI if enabled
rtapi_print_msg(RTAPI_MSG_ERR, "rtapi_app: BUG: SIGXCPU should be handled in RTAPI");
// NB: fall through
default:
rtapi_print_msg(RTAPI_MSG_ERR,
"signal %d - '%s' received, dumping core (current dir=%s)",
sig, strsignal(sig), get_current_dir_name());
backtrace("", "rtapi_app", btprint, 3);
if (global_data)
global_data->rtapi_app_pid = 0;
closelog_async(); // let syslog_async drain
sleep(1);
// reset handler for current signal to default
signal(sig, SIG_DFL);
// and re-raise so we get a proper core dump and stacktrace
kill(getpid(), sig);
sleep(1);
break;
}
// not reached
}
// handle signals delivered synchronously in the event loop
// by polling signal_fd
// log, start shutdown and flag end of the event loop
static int s_handle_signal(zloop_t *loop, zmq_pollitem_t *poller, void *arg)
{
struct signalfd_siginfo fdsi;
ssize_t s;
s = read(signal_fd, &fdsi, sizeof(struct signalfd_siginfo));
if (s != sizeof(struct signalfd_siginfo)) {
rtapi_print_msg(RTAPI_MSG_ERR,
"BUG: read(signal_fd): %s", strerror(errno));
return 0;
}
switch (fdsi.ssi_signo) {
// see machinetalk/lib/setup_signals for handled signals
case SIGINT:
case SIGQUIT:
case SIGKILL:
case SIGTERM:
rtapi_print_msg(RTAPI_MSG_INFO,
"signal %d - '%s' received, exiting",
fdsi.ssi_signo, strsignal(fdsi.ssi_signo));
exit_actions(instance_id);
interrupted = true; // make mainloop exit
if (global_data)
global_data->rtapi_app_pid = 0;
return -1;
default:
// this should be handled either above or in sigaction_handler
rtapi_print_msg(RTAPI_MSG_ERR, "BUG: unhandled signal %d - '%s' received\n",
fdsi.ssi_signo, strsignal(fdsi.ssi_signo));
}
return 0;
}
static int
s_handle_timer(zloop_t *loop, int timer_id, void *args)
{
if (global_data->rtapi_msgd_pid == 0) {
// cant log this via rtapi_print, since msgd is gone
syslog_async(LOG_ERR,"rtapi_msgd went away, exiting\n");
exit_actions(instance_id);
if (global_data)
global_data->rtapi_app_pid = 0;
exit(EXIT_FAILURE);
}
return 0;
}
static int mainloop(size_t argc, char **argv)
{
int retval;
unsigned i;
static char proctitle[20];
// set new process name
snprintf(proctitle, sizeof(proctitle), "rtapi:%d",instance_id);
size_t argv0_len = strlen(argv[0]);
size_t procname_len = strlen(proctitle);
size_t max_procname_len = (argv0_len > procname_len) ?
(procname_len) : (argv0_len);
strncpy(argv[0], proctitle, max_procname_len);
memset(&argv[0][max_procname_len], '\0', argv0_len - max_procname_len);
for (i = 1; i < argc; i++)
memset(argv[i], '\0', strlen(argv[i]));
backtrace_init(proctitle);
// set this thread's name so it can be identified in ps/top as
// rtapi:<instance>
if (prctl(PR_SET_NAME, argv[0]) < 0) {
syslog_async(LOG_ERR, "rtapi_app: prctl(PR_SETNAME,%s) failed: %s\n",
argv[0], strerror(errno));
}
// attach global segment which rtapi_msgd already prepared
if ((retval = attach_global_segment()) != 0) {
syslog_async(LOG_ERR, "%s: FATAL - failed to attach to global segment\n",
argv[0]);
exit(retval);
}
// make sure rtapi_msgd's pid is valid and msgd is running,
// in case we caught a leftover shmseg
// otherwise log messages would vanish
if ((global_data->rtapi_msgd_pid == 0) ||
kill(global_data->rtapi_msgd_pid, 0) != 0) {
syslog_async(LOG_ERR,"%s: rtapi_msgd pid invalid: %d, exiting\n",
argv[0], global_data->rtapi_msgd_pid);
exit(EXIT_FAILURE);
}
// from here on it is safe to use rtapi_print() and friends as
// the error ring is now set up and msgd is logging it
rtapi_set_logtag("rtapi_app");
rtapi_set_msg_level(global_data->rt_msg_level);
// obtain handle on flavor descriptor as detected by rtapi_msgd
flavor = flavor_byid(global_data->rtapi_thread_flavor);
if (flavor == NULL) {
rtapi_print_msg(RTAPI_MSG_ERR,
"FATAL - invalid flavor id: %d\n",
global_data->rtapi_thread_flavor);
global_data->rtapi_app_pid = 0;
exit(EXIT_FAILURE);
}
// make sure we're setuid root when we need to
if (use_drivers || (flavor->flags & FLAVOR_DOES_IO)) {
if (geteuid() != 0) {
rtapi_print_msg(RTAPI_MSG_ERR,
"rtapi_app:%d need to"
" 'sudo make setuid' to access I/O?\n",
instance_id);
global_data->rtapi_app_pid = 0;
exit(EXIT_FAILURE);
}
}
// assorted RT incantations - memory locking, prefaulting etc
if ((retval = harden_rt())) {
rtapi_print_msg(RTAPI_MSG_ERR,
"rtapi_app:%d failed to setup "
"realtime environment - 'sudo make setuid' missing?\n",
instance_id);
global_data->rtapi_app_pid = 0;
exit(retval);
}
// load rtapi and hal_lib
if (init_actions(instance_id)) {
rtapi_print_msg(RTAPI_MSG_ERR,
"init_actions() failed\n");
global_data->rtapi_app_pid = 0;
exit(1);
}
// block all signal delivery through signal handler
// since we're using signalfd()
// do this here so child threads inherit the sigmask
signal_fd = setup_signals(sigaction_handler, SIGINT, SIGQUIT, SIGKILL, SIGTERM, -1);
assert(signal_fd > -1);
// suppress default handling of signals in zctx_new()
// since we're using signalfd()
zsys_handler_set(NULL);
zctx_t *z_context = zctx_new ();
void *z_command = zsocket_new (z_context, ZMQ_ROUTER);
{
char z_ident[30];
snprintf(z_ident, sizeof(z_ident), "rtapi_app%d", getpid());
zsocket_set_identity(z_command, z_ident);
zsocket_set_linger(z_command, 1000); // wait for last reply to drain
}
#ifdef NOTYET
// determine interface to bind to if remote option set
if ((remote || z_uri) && interfaces) {
char ifname[LINELEN], ip[LINELEN];
// rtapi_print_msg(RTAPI_MSG_INFO, "rtapi_app: ifpref='%s'\n",interfaces);
if (parse_interface_prefs(interfaces, ifname, ip, NULL) == 0) {
rtapi_print_msg(RTAPI_MSG_INFO, "rtapi_app: using preferred interface %s/%s\n",
ifname, ip);
ipaddr = strdup(ip);
} else {
rtapi_print_msg(RTAPI_MSG_ERR, "rtapi_app: INTERFACES='%s'"
" - cant determine preferred interface, using %s/%s\n",
interfaces, ifname, ipaddr);
}
if (z_uri == NULL) { // not given on command line - finalize the URI
char uri[LINELEN];
snprintf(uri, sizeof(uri), "tcp://%s:*" , ipaddr);
z_uri = strdup(uri);
}
if ((z_port = zsocket_bind(z_command, z_uri)) == -1) {
rtapi_print_msg(RTAPI_MSG_ERR, "cannot bind '%s' - %s\n",
z_uri, strerror(errno));
global_data->rtapi_app_pid = 0;
exit(EXIT_FAILURE);
} else {
z_uri_dsn = zsocket_last_endpoint(z_command);
rtapi_print_msg(RTAPI_MSG_DBG, "rtapi_app: command RPC socket on '%s'\n",
z_uri_dsn);
}
}
#endif
{ // always bind the IPC socket
char uri[LINELEN];
snprintf(uri, sizeof(uri), ZMQIPC_FORMAT,
RUNDIR, instance_id, "rtapi", service_uuid);
mode_t prev = umask(S_IROTH | S_IWOTH | S_IXOTH);
if ((z_port = zsocket_bind(z_command, uri )) < 0) {
rtapi_print_msg(RTAPI_MSG_ERR, "cannot bind IPC socket '%s' - %s\n",
uri, strerror(errno));
global_data->rtapi_app_pid = 0;
exit(EXIT_FAILURE);
}
rtapi_print_msg(RTAPI_MSG_ERR,"accepting commands at %s\n",uri);
umask(prev);
}
zloop_t *z_loop = zloop_new();
assert(z_loop);
zloop_set_verbose(z_loop, debug);
zmq_pollitem_t signal_poller = { 0, signal_fd, ZMQ_POLLIN };
zloop_poller (z_loop, &signal_poller, s_handle_signal, NULL);
zmq_pollitem_t command_poller = { z_command, 0, ZMQ_POLLIN };
zloop_poller(z_loop, &command_poller, rtapi_request, NULL);
zloop_timer (z_loop, BACKGROUND_TIMER, 0, s_handle_timer, NULL);
#ifdef NOTYET
// no remote rtapi service yet
if (remote) {
if (!(av_loop = avahi_czmq_poll_new(z_loop))) {
rtapi_print_msg(RTAPI_MSG_ERR, "rtapi_app:%d: zeroconf: Failed to create avahi event loop object.",
instance_id);
return -1;
} else {
char name[255];
snprintf(name, sizeof(name), "RTAPI service on %s pid %d", ipaddr, getpid());
rtapi_publisher = zeroconf_service_announce(name,
MACHINEKIT_DNSSD_SERVICE_TYPE,
RTAPI_DNSSD_SUBTYPE,
z_port,
(char *)z_uri_dsn,
service_uuid,
process_uuid_str,
"rtapi", NULL,
av_loop);
if (rtapi_publisher == NULL) {
rtapi_print_msg(RTAPI_MSG_ERR, "rtapi_app:%d: failed to start zeroconf publisher",
instance_id);
return -1;
}
}
}
#endif
// report success
rtapi_print_msg(RTAPI_MSG_INFO, "rtapi_app:%d ready flavor=%s gcc=%s git=%s",
instance_id, flavor->name, __VERSION__, GIT_VERSION);
// the RT stack is now set up and good for use
global_data->rtapi_app_pid = getpid();
// main loop
do {
retval = zloop_start(z_loop);
} while (!(retval || interrupted));
rtapi_print_msg(RTAPI_MSG_INFO,
"exiting mainloop (%s)\n",
interrupted ? "interrupted": "by remote command");
// stop the service announcement
zeroconf_service_withdraw(rtapi_publisher);
// shutdown zmq context
zctx_destroy(&z_context);
// exiting, so deregister our pid, which will make rtapi_msgd exit too
global_data->rtapi_app_pid = 0;
return 0;
}
static int configure_memory(void)
{
unsigned int i, pagesize;
char *buf;
if (global_data->rtapi_thread_flavor != RTAPI_POSIX_ID) {
// Realtime tweak requires privs
/* Lock all memory. This includes all current allocations (BSS/data)
* and future allocations. */
if (mlockall(MCL_CURRENT | MCL_FUTURE)) {
rtapi_print_msg(RTAPI_MSG_WARN,
"mlockall() failed: %d '%s'\n",
errno,strerror(errno));
rtapi_print_msg(RTAPI_MSG_WARN,
"For more information, see "
"http://wiki.linuxcnc.org/cgi-bin/emcinfo.pl?LockedMemory\n");
return 1;
}
}
/* Turn off malloc trimming.*/
if (!mallopt(M_TRIM_THRESHOLD, -1)) {
rtapi_print_msg(RTAPI_MSG_WARN,
"mallopt(M_TRIM_THRESHOLD, -1) failed\n");
return 1;
}
/* Turn off mmap usage. */
if (!mallopt(M_MMAP_MAX, 0)) {
rtapi_print_msg(RTAPI_MSG_WARN,
"mallopt(M_MMAP_MAX, -1) failed\n");
return 1;
}
buf = static_cast<char *>(malloc(PRE_ALLOC_SIZE));
if (buf == NULL) {
rtapi_print_msg(RTAPI_MSG_WARN, "malloc(PRE_ALLOC_SIZE) failed\n");
return 1;
}
pagesize = sysconf(_SC_PAGESIZE);
/* Touch each page in this piece of memory to get it mapped into RAM */
for (i = 0; i < PRE_ALLOC_SIZE; i += pagesize) {
/* Each write to this buffer will generate a pagefault.
* Once the pagefault is handled a page will be locked in
* memory and never given back to the system. */
buf[i] = 0;
}
/* buffer will now be released. As Glibc is configured such that it
* never gives back memory to the kernel, the memory allocated above is
* locked for this process. All malloc() and new() calls come from
* the memory pool reserved and locked above. Issuing free() and
* delete() does NOT make this locking undone. So, with this locking
* mechanism we can build C++ applications that will never run into
* a major/minor pagefault, even with swapping enabled. */
free(buf);
return 0;
}
static void
exit_handler(void)
{
struct rusage rusage;
getrusage(RUSAGE_SELF, &rusage);
if ((rusage.ru_majflt - majflt) > 0) {
// RTAPI already shut down here
rtapi_print_msg(RTAPI_MSG_WARN,
"rtapi_app_main %d: %ld page faults, %ld page reclaims\n",
getpid(), rusage.ru_majflt - majflt,
rusage.ru_minflt - minflt);
}
}
static int harden_rt()
{
// enable core dumps
struct rlimit core_limit;
core_limit.rlim_cur = RLIM_INFINITY;
core_limit.rlim_max = RLIM_INFINITY;
if (setrlimit(RLIMIT_CORE, &core_limit) < 0)
rtapi_print_msg(RTAPI_MSG_WARN,
"setrlimit: %s - core dumps may be truncated or non-existant\n",
strerror(errno));
// even when setuid root
// note this may not be enough
// echo 1 >
// might be needed to have setuid programs dump core
if (prctl(PR_SET_DUMPABLE, 1) < 0)
rtapi_print_msg(RTAPI_MSG_WARN,
"prctl(PR_SET_DUMPABLE) failed: no core dumps will be created - %d - %s\n",
errno, strerror(errno));
FILE *fd;
if ((fd = fopen("/proc/sys/fs/suid_dumpable","r")) != NULL) {
int flag;
if ((fscanf(fd, "%d", &flag) == 1) && (flag == 0)) {
rtapi_print_msg(RTAPI_MSG_WARN,
"rtapi:%d: cannot create core dumps - /proc/sys/fs/suid_dumpable contains 0",
instance_id);
rtapi_print_msg(RTAPI_MSG_WARN,
"you might have to run 'echo 1 > /proc/sys/fs/suid_dumpable'"
" as root to enable rtapi_app core dumps");
}
fclose(fd);
}
configure_memory();
if (getrusage(RUSAGE_SELF, &rusage)) {
rtapi_print_msg(RTAPI_MSG_WARN,
"getrusage(RUSAGE_SELF) failed: %d '%s'\n",
errno,strerror(errno));
} else {
minflt = rusage.ru_minflt;
majflt = rusage.ru_majflt;
if (atexit(exit_handler)) {
rtapi_print_msg(RTAPI_MSG_WARN,
"atexit() failed: %d '%s'\n",
errno,strerror(errno));
}
}
if (flavor->id == RTAPI_XENOMAI_ID) {
int retval = user_in_xenomai_group();
switch (retval) {
case 1:
// {
// gid_t xg = xenomai_gid();
// do_setuid();
// if (setegid(xg))
// rtapi_print_msg(RTAPI_MSG_ERR,
// "setegid(%d): %s", xg, strerror(errno));
// undo_setuid();
// rtapi_print_msg(RTAPI_MSG_ERR,
// "xg=%d egid now %d", xg, getegid());
// }
break;
case 0:
rtapi_print_msg(RTAPI_MSG_ERR,
"this user is not member of group xenomai");
rtapi_print_msg(RTAPI_MSG_ERR,
"please 'sudo adduser <username> xenomai',"
" logout and login again");
return -1;
default:
rtapi_print_msg(RTAPI_MSG_ERR,
"cannot determine if this user is a member of group xenomai: %s",
strerror(-retval));
return -1;
}
}
#if defined(__x86_64__) || defined(__i386__)
// this is a bit of a shotgun approach and should be made more selective
// however, due to serial invocations of rtapi_app during setup it is not
// guaranteed the process executing e.g. hal_parport's rtapi_app_main is
// the same process which starts the RT threads, causing hal_parport
// thread functions to fail on inb/outb
if (use_drivers || (flavor->flags & FLAVOR_DOES_IO)) {
if (iopl(3) < 0) {
rtapi_print_msg(RTAPI_MSG_ERR,
"cannot gain I/O privileges - "
"forgot 'sudo make setuid'?\n");
return -EPERM;
}
}
#endif
return 0;
}
static void usage(int argc, char **argv)
{
printf("Usage: %s [options]\n", argv[0]);
}
static struct option long_options[] = {
{"help", no_argument, 0, 'h'},
{"foreground", no_argument, 0, 'F'},
{"instance", required_argument, 0, 'I'},
{"ini", required_argument, 0, 'i'}, // default: getenv(INI_FILE_NAME)
{"drivers", required_argument, 0, 'D'},
{"uri", required_argument, 0, 'U'},
{"debug", no_argument, 0, 'd'},
{"svcuuid", required_argument, 0, 'R'},
{"interfaces", required_argument, 0, 'n'},
{0, 0, 0, 0}
};
int main(int argc, char **argv)
{
int c;
progname = argv[0];
inifile = getenv("MACHINEKIT_INI");
uuid_generate_time(process_uuid);
uuid_unparse(process_uuid, process_uuid_str);
rtapi_set_msg_handler(rtapi_app_msg_handler);
openlog_async(argv[0], LOG_NDELAY, LOG_LOCAL1);
setlogmask_async(LOG_UPTO(LOG_DEBUG));
// max out async syslog buffers for slow system in debug mode
tunelog_async(99,1000);
while (1) {
int option_index = 0;
int curind = optind;
c = getopt_long (argc, argv, "hH:m:I:f:r:U:NFdR:n:i:",
long_options, &option_index);
if (c == -1)
break;
switch (c) {
case 'd':
debug++;
break;
case 'D':
use_drivers = 1;
break;
case 'F':
foreground = 1;
rtapi_set_msg_handler(stderr_rtapi_msg_handler);
break;
case 'i':
inifile = strdup(optarg);
break;
case 'I':
instance_id = atoi(optarg);
break;
case 'f':
if ((flavor = flavor_byname(optarg)) == NULL) {
fprintf(stderr, "no such flavor: '%s' -- valid flavors are:\n",
optarg);
flavor_ptr f = flavors;
while (f->name) {
fprintf(stderr, "\t%s\n", f->name);
f++;
}
exit(1);
}
break;
case 'U':
z_uri = optarg;
break;
case 'n':
interfaces = strdup(optarg);
break;
case 'R':
service_uuid = strdup(optarg);
break;
case '?':
if (optopt) fprintf(stderr, "bad short opt '%c'\n", optopt);
else fprintf(stderr, "bad long opt \"%s\"\n", argv[curind]);
//usage(argc, argv);
exit(1);
break;
default:
usage(argc, argv);
exit(0);
}
}
if (inifile && ((inifp = fopen(inifile,"r")) == NULL)) {
fprintf(stderr,"rtapi_app: cant open inifile '%s'\n", inifile);
}
// must have a MKUUID one way or the other
if (service_uuid == NULL) {
const char *s;
if ((s = iniFind(inifp, "MKUUID", "MACHINEKIT"))) {
service_uuid = strdup(s);
}
}
if (service_uuid == NULL) {
fprintf(stderr, "rtapi: no service UUID (-R <uuid> or environment MKUUID) present\n");
exit(-1);
}
#ifdef NOTYET
iniFindInt(inifp, "REMOTE", "MACHINEKIT", &remote);
if (remote && (interfaces == NULL)) {
const char *s;
if ((s = iniFind(inifp, "INTERFACES", "MACHINEKIT"))) {
interfaces = strdup(s);
}
}
#endif
// the actual checking for setuid happens in harden_rt() (if needed)
if (getuid() != 0) {
pid_t pid1;
pid_t pid2;
int status;
if ((pid1 = fork())) {
waitpid(pid1, &status, 0);
exit(status);
} else if (!pid1) {
if ((pid2 = fork())) {
exit(0);
} else if (!pid2) {
setsid(); // Detach from the parent session
} else {
exit(1);
}
} else {
exit(1);
}
} else {
// dont run as root XXX
}
exit(mainloop(argc, argv));
}
// normally rtapi_app will log through the message ringbuffer in the
// global data segment. This isnt available initially, and during shutdown,
// so switch to direct syslog during these time windows so we dont
// loose log messages, even if they cant go through the ringbuffer
static void rtapi_app_msg_handler(msg_level_t level, const char *fmt,
va_list ap)
{
// during startup the global segment might not be
// available yet, so use stderr until then
if (global_data) {
vs_ring_write(level, fmt, ap);
} else {
vsyslog_async(rtapi2syslog(level), fmt, ap);
}
}
// use this handler if -F/--foreground was given
static void stderr_rtapi_msg_handler(msg_level_t level,
const char *fmt, va_list ap)
{
vfprintf(stderr, fmt, ap);
}
static void remove_module(std::string name)
{
std::vector<string>::iterator invalid;
invalid = remove( loading_order.begin(), loading_order.end(), name );
}
| Java |
<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<title></title>
<!-- <script src="http://use.edgefonts.net/source-sans-pro;source-code-pro.js"></script> -->
<link href='http://fonts.googleapis.com/css?family=Source+Sans+Pro:300,400,700,300italic,400italic,700italic|Source+Code+Pro:300,400,700' rel='stylesheet' type='text/css'>
<link rel="stylesheet" href="../assets/css/bootstrap.css">
<link rel="stylesheet" href="../assets/css/jquery.bonsai.css">
<link rel="stylesheet" href="../assets/css/main.css">
<link rel="stylesheet" href="../assets/css/icons.css">
<script type="text/javascript" src="../assets/js/jquery-2.1.0.min.js"></script>
<script type="text/javascript" src="../assets/js/bootstrap.js"></script>
<script type="text/javascript" src="../assets/js/jquery.bonsai.js"></script>
<!-- <script type="text/javascript" src="../assets/js/main.js"></script> -->
</head>
<body>
<div>
<!-- Name Title -->
<h1>(unnamed)</h1>
<!-- Type and Stereotype -->
<section style="margin-top: .5em;">
<span class="alert alert-info">
<span class="node-icon _icon-UMLGeneralization"></span>
UMLGeneralization
</span>
</section>
<!-- Path -->
<section style="margin-top: 10px">
<span class="label label-info"><a href='cf9c8b720f3815adeccaf3ef6e48c6c4.html'><span class='node-icon _icon-Project'></span>Untitled</a></span>
<span>::</span>
<span class="label label-info"><a href='6550300e57d7fc770bd2e9afbcdb3ecb.html'><span class='node-icon _icon-UMLModel'></span>JavaReverse</a></span>
<span>::</span>
<span class="label label-info"><a href='7ff2d96ca3eb7f62f48c1a30b3c7c990.html'><span class='node-icon _icon-UMLPackage'></span>net</a></span>
<span>::</span>
<span class="label label-info"><a href='7adc4be4f2e4859086f068fc27512d85.html'><span class='node-icon _icon-UMLPackage'></span>gleamynode</a></span>
<span>::</span>
<span class="label label-info"><a href='bb15307bdbbaf31bfef4f71be74150ae.html'><span class='node-icon _icon-UMLPackage'></span>netty</a></span>
<span>::</span>
<span class="label label-info"><a href='392fd228dddcffe2ef252f5663cf31a7.html'><span class='node-icon _icon-UMLPackage'></span>channel</a></span>
<span>::</span>
<span class="label label-info"><a href='6c70ca2d44dbb8586b8590225d3474f2.html'><span class='node-icon _icon-UMLClass'></span>DefaultChannelStateEvent</a></span>
<span>::</span>
<span class="label label-info"><a href='d06fea664dd4592ab2eb97007a947c6e.html'><span class='node-icon _icon-UMLGeneralization'></span>(DefaultChannelStateEvent→DefaultChannelEvent)</a></span>
</section>
<!-- Diagram -->
<!-- Description -->
<section>
<h3>Description</h3>
<div>
<span class="label label-info">none</span>
</div>
</section>
<!-- Specification -->
<!-- Directed Relationship -->
<section class="element-list">
<table width="100%">
<tr>
<td width="50%">
<h3>Source</h3>
<ul class="nav nav-list">
<li><a href='6c70ca2d44dbb8586b8590225d3474f2.html'><span class='node-icon _icon-UMLClass'></span>DefaultChannelStateEvent</a></a></li>
</ul>
</td>
<td width="50%">
<h3>Target</h3>
<ul class="nav nav-list">
<li><a href='aecb7e7ef54674250158ee8a116dc3e6.html'><span class='node-icon _icon-UMLClass'></span>DefaultChannelEvent</a></a></li>
</ul>
</td>
</tr>
</table>
</section>
<!-- Undirected Relationship -->
<!-- Classifier -->
<!-- Interface -->
<!-- Component -->
<!-- Node -->
<!-- Actor -->
<!-- Use Case -->
<!-- Template Parameters -->
<!-- Literals -->
<!-- Attributes -->
<!-- Operations -->
<!-- Receptions -->
<!-- Extension Points -->
<!-- Parameters -->
<!-- Diagrams -->
<!-- Behavior -->
<!-- Action -->
<!-- Interaction -->
<!-- CombinedFragment -->
<!-- Activity -->
<!-- State Machine -->
<!-- State Machine -->
<!-- State -->
<!-- Vertex -->
<!-- Transition -->
<!-- Properties -->
<section>
<h3>Properties</h3>
<table class="table table-striped table-bordered">
<tr>
<th width="50%">Name</th>
<th width="50%">Value</th>
</tr>
<tr>
<td>name</td>
<td></td>
</tr>
<tr>
<td>source</td>
<td><a href='6c70ca2d44dbb8586b8590225d3474f2.html'><span class='node-icon _icon-UMLClass'></span>DefaultChannelStateEvent</a></td>
</tr>
<tr>
<td>target</td>
<td><a href='aecb7e7ef54674250158ee8a116dc3e6.html'><span class='node-icon _icon-UMLClass'></span>DefaultChannelEvent</a></td>
</tr>
<tr>
<td>stereotype</td>
<td><span class='label label-info'>null</span></td>
</tr>
<tr>
<td>visibility</td>
<td>public</td>
</tr>
<tr>
<td>discriminator</td>
<td></td>
</tr>
</table>
</section>
<!-- Tags -->
<!-- Constraints, Dependencies, Dependants -->
<!-- Relationships -->
<!-- Owned Elements -->
</div>
</body>
</html>
| Java |
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>Deprecated X font backend</title>
<meta name="generator" content="DocBook XSL Stylesheets V1.75.2">
<link rel="home" href="index.html" title="Pango Reference Manual">
<link rel="up" href="rendering.html" title="Rendering with Pango">
<link rel="prev" href="pango-ATSUI-Fonts.html" title="ATSUI Fonts">
<link rel="next" href="lowlevel.html" title="Low Level Functionality">
<meta name="generator" content="GTK-Doc V1.11 (XML mode)">
<link rel="stylesheet" href="style.css" type="text/css">
<link rel="chapter" href="pango.html" title="Basic Pango Interfaces">
<link rel="chapter" href="rendering.html" title="Rendering with Pango">
<link rel="chapter" href="lowlevel.html" title="Low Level Functionality">
<link rel="chapter" href="tools.html" title="Pango Tools">
<link rel="chapter" href="pango-hierarchy.html" title="Object Hierarchy">
<link rel="index" href="index-all.html" title="Index">
<link rel="index" href="index-deprecated.html" title="Index of deprecated symbols">
<link rel="index" href="index-1.2.html" title="Index of new symbols in 1.2">
<link rel="index" href="index-1.4.html" title="Index of new symbols in 1.4">
<link rel="index" href="index-1.6.html" title="Index of new symbols in 1.6">
<link rel="index" href="index-1.8.html" title="Index of new symbols in 1.8">
<link rel="index" href="index-1.10.html" title="Index of new symbols in 1.10">
<link rel="index" href="index-1.12.html" title="Index of new symbols in 1.12">
<link rel="index" href="index-1.14.html" title="Index of new symbols in 1.14">
<link rel="index" href="index-1.16.html" title="Index of new symbols in 1.16">
<link rel="index" href="index-1.18.html" title="Index of new symbols in 1.18">
<link rel="index" href="index-1.20.html" title="Index of new symbols in 1.20">
<link rel="index" href="index-1.22.html" title="Index of new symbols in 1.22">
<link rel="index" href="index-1.24.html" title="Index of new symbols in 1.24">
<link rel="index" href="index-1.26.html" title="Index of new symbols in 1.26">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table class="navigation" id="top" width="100%" summary="Navigation header" cellpadding="2" cellspacing="2">
<tr valign="middle">
<td><a accesskey="p" href="pango-ATSUI-Fonts.html"><img src="left.png" width="24" height="24" border="0" alt="Prev"></a></td>
<td><a accesskey="u" href="rendering.html"><img src="up.png" width="24" height="24" border="0" alt="Up"></a></td>
<td><a accesskey="h" href="index.html"><img src="home.png" width="24" height="24" border="0" alt="Home"></a></td>
<th width="100%" align="center">Pango Reference Manual</th>
<td><a accesskey="n" href="lowlevel.html"><img src="right.png" width="24" height="24" border="0" alt="Next"></a></td>
</tr>
<tr><td colspan="5" class="shortcuts">
<a href="#pango-X-Fonts-and-Rendering.synopsis" class="shortcut">Top</a>
|
<a href="#pango-X-Fonts-and-Rendering.description" class="shortcut">Description</a>
</td></tr>
</table>
<div class="refentry" title="Deprecated X font backend">
<a name="pango-X-Fonts-and-Rendering"></a><div class="titlepage"></div>
<div class="refnamediv"><table width="100%"><tr>
<td valign="top">
<h2><span class="refentrytitle"><a name="pango-X-Fonts-and-Rendering.top_of_page"></a>Deprecated X font backend</span></h2>
<p>Deprecated X font backend — Font handling and rendering with the deprecated X font backend</p>
</td>
<td valign="top" align="right"></td>
</tr></table></div>
<div class="refsynopsisdiv" title="Synopsis">
<a name="pango-X-Fonts-and-Rendering.synopsis"></a><h2>Synopsis</h2>
<pre class="synopsis">
#define <a class="link" href="pango-X-Fonts-and-Rendering.html#PANGO-RENDER-TYPE-X--CAPS" title="PANGO_RENDER_TYPE_X">PANGO_RENDER_TYPE_X</a>
<a class="link" href="pango-Text-Processing.html#PangoContext">PangoContext</a> * <a class="link" href="pango-X-Fonts-and-Rendering.html#pango-x-get-context" title="pango_x_get_context ()">pango_x_get_context</a> (Display *display);
void <a class="link" href="pango-X-Fonts-and-Rendering.html#pango-x-context-set-funcs" title="pango_x_context_set_funcs ()">pango_x_context_set_funcs</a> (<a class="link" href="pango-Text-Processing.html#PangoContext">PangoContext</a> *context,
<a class="link" href="pango-X-Fonts-and-Rendering.html#PangoGetGCFunc" title="PangoGetGCFunc ()">PangoGetGCFunc</a> get_gc_func,
<a class="link" href="pango-X-Fonts-and-Rendering.html#PangoFreeGCFunc" title="PangoFreeGCFunc ()">PangoFreeGCFunc</a> free_gc_func);
GC (<a class="link" href="pango-X-Fonts-and-Rendering.html#PangoGetGCFunc" title="PangoGetGCFunc ()">*PangoGetGCFunc</a>) (<a class="link" href="pango-Text-Processing.html#PangoContext">PangoContext</a> *context,
<a class="link" href="pango-Text-Attributes.html#PangoColor" title="PangoColor">PangoColor</a> *color,
GC base_gc);
void (<a class="link" href="pango-X-Fonts-and-Rendering.html#PangoFreeGCFunc" title="PangoFreeGCFunc ()">*PangoFreeGCFunc</a>) (<a class="link" href="pango-Text-Processing.html#PangoContext">PangoContext</a> *context,
GC gc);
void <a class="link" href="pango-X-Fonts-and-Rendering.html#pango-x-render" title="pango_x_render ()">pango_x_render</a> (Display *display,
Drawable d,
GC gc,
<a class="link" href="pango-Fonts.html#PangoFont">PangoFont</a> *font,
<a class="link" href="pango-Glyph-Storage.html#PangoGlyphString" title="PangoGlyphString">PangoGlyphString</a> *glyphs,
<a
href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gint"
>gint</a> x,
<a
href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gint"
>gint</a> y);
void <a class="link" href="pango-X-Fonts-and-Rendering.html#pango-x-render-layout-line" title="pango_x_render_layout_line ()">pango_x_render_layout_line</a> (Display *display,
Drawable drawable,
GC gc,
<a class="link" href="pango-Layout-Objects.html#PangoLayoutLine" title="PangoLayoutLine">PangoLayoutLine</a> *line,
int x,
int y);
void <a class="link" href="pango-X-Fonts-and-Rendering.html#pango-x-render-layout" title="pango_x_render_layout ()">pango_x_render_layout</a> (Display *display,
Drawable drawable,
GC gc,
<a class="link" href="pango-Layout-Objects.html#PangoLayout">PangoLayout</a> *layout,
int x,
int y);
typedef <a class="link" href="pango-X-Fonts-and-Rendering.html#PangoXSubfont" title="PangoXSubfont">PangoXSubfont</a>;
#define <a class="link" href="pango-X-Fonts-and-Rendering.html#PANGO-X-MAKE-GLYPH--CAPS" title="PANGO_X_MAKE_GLYPH()">PANGO_X_MAKE_GLYPH</a> (subfont,index_)
#define <a class="link" href="pango-X-Fonts-and-Rendering.html#PANGO-X-GLYPH-SUBFONT--CAPS" title="PANGO_X_GLYPH_SUBFONT()">PANGO_X_GLYPH_SUBFONT</a> (glyph)
#define <a class="link" href="pango-X-Fonts-and-Rendering.html#PANGO-X-GLYPH-INDEX--CAPS" title="PANGO_X_GLYPH_INDEX()">PANGO_X_GLYPH_INDEX</a> (glyph)
<a class="link" href="pango-Fonts.html#PangoFont">PangoFont</a> * <a class="link" href="pango-X-Fonts-and-Rendering.html#pango-x-load-font" title="pango_x_load_font ()">pango_x_load_font</a> (Display *display,
const <a
href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gchar"
>gchar</a> *spec);
<a class="link" href="pango-Glyph-Storage.html#PangoGlyph" title="PangoGlyph">PangoGlyph</a> <a class="link" href="pango-X-Fonts-and-Rendering.html#pango-x-get-unknown-glyph" title="pango_x_get_unknown_glyph ()">pango_x_get_unknown_glyph</a> (<a class="link" href="pango-Fonts.html#PangoFont">PangoFont</a> *font);
<a
href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gboolean"
>gboolean</a> <a class="link" href="pango-X-Fonts-and-Rendering.html#pango-x-has-glyph" title="pango_x_has_glyph ()">pango_x_has_glyph</a> (<a class="link" href="pango-Fonts.html#PangoFont">PangoFont</a> *font,
<a class="link" href="pango-Glyph-Storage.html#PangoGlyph" title="PangoGlyph">PangoGlyph</a> glyph);
int <a class="link" href="pango-X-Fonts-and-Rendering.html#pango-x-list-subfonts" title="pango_x_list_subfonts ()">pango_x_list_subfonts</a> (<a class="link" href="pango-Fonts.html#PangoFont">PangoFont</a> *font,
char **charsets,
int n_charsets,
<a class="link" href="pango-X-Fonts-and-Rendering.html#PangoXSubfont" title="PangoXSubfont">PangoXSubfont</a> **subfont_ids,
int **subfont_charsets);
<a class="link" href="pango-Fonts.html#PangoFontMap">PangoFontMap</a> * <a class="link" href="pango-X-Fonts-and-Rendering.html#pango-x-font-map-for-display" title="pango_x_font_map_for_display ()">pango_x_font_map_for_display</a> (Display *display);
void <a class="link" href="pango-X-Fonts-and-Rendering.html#pango-x-shutdown-display" title="pango_x_shutdown_display ()">pango_x_shutdown_display</a> (Display *display);
<a class="link" href="pango-X-Fonts-and-Rendering.html#PangoXFontCache" title="PangoXFontCache">PangoXFontCache</a> * <a class="link" href="pango-X-Fonts-and-Rendering.html#pango-x-font-map-get-font-cache" title="pango_x_font_map_get_font_cache ()">pango_x_font_map_get_font_cache</a> (<a class="link" href="pango-Fonts.html#PangoFontMap">PangoFontMap</a> *font_map);
char * <a class="link" href="pango-X-Fonts-and-Rendering.html#pango-x-font-subfont-xlfd" title="pango_x_font_subfont_xlfd ()">pango_x_font_subfont_xlfd</a> (<a class="link" href="pango-Fonts.html#PangoFont">PangoFont</a> *font,
<a class="link" href="pango-X-Fonts-and-Rendering.html#PangoXSubfont" title="PangoXSubfont">PangoXSubfont</a> subfont_id);
<a
href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gboolean"
>gboolean</a> <a class="link" href="pango-X-Fonts-and-Rendering.html#pango-x-find-first-subfont" title="pango_x_find_first_subfont ()">pango_x_find_first_subfont</a> (<a class="link" href="pango-Fonts.html#PangoFont">PangoFont</a> *font,
char **charsets,
int n_charsets,
<a class="link" href="pango-X-Fonts-and-Rendering.html#PangoXSubfont" title="PangoXSubfont">PangoXSubfont</a> *rfont);
<a class="link" href="pango-Glyph-Storage.html#PangoGlyph" title="PangoGlyph">PangoGlyph</a> <a class="link" href="pango-X-Fonts-and-Rendering.html#pango-x-font-get-unknown-glyph" title="pango_x_font_get_unknown_glyph ()">pango_x_font_get_unknown_glyph</a> (<a class="link" href="pango-Fonts.html#PangoFont">PangoFont</a> *font,
<a
href="http://library.gnome.org/devel/glib/unstable/glib-Unicode-Manipulation.html#gunichar"
>gunichar</a> wc);
<a
href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gboolean"
>gboolean</a> <a class="link" href="pango-X-Fonts-and-Rendering.html#pango-x-apply-ligatures" title="pango_x_apply_ligatures ()">pango_x_apply_ligatures</a> (<a class="link" href="pango-Fonts.html#PangoFont">PangoFont</a> *font,
<a class="link" href="pango-X-Fonts-and-Rendering.html#PangoXSubfont" title="PangoXSubfont">PangoXSubfont</a> subfont,
<a
href="http://library.gnome.org/devel/glib/unstable/glib-Unicode-Manipulation.html#gunichar"
>gunichar</a> **glyphs,
int *n_glyphs,
int **clusters);
void <a class="link" href="pango-X-Fonts-and-Rendering.html#pango-x-fallback-shape" title="pango_x_fallback_shape ()">pango_x_fallback_shape</a> (<a class="link" href="pango-Fonts.html#PangoFont">PangoFont</a> *font,
<a class="link" href="pango-Glyph-Storage.html#PangoGlyphString" title="PangoGlyphString">PangoGlyphString</a> *glyphs,
const char *text,
int n_chars);
<a class="link" href="pango-X-Fonts-and-Rendering.html#PangoXFontCache" title="PangoXFontCache">PangoXFontCache</a>;
<a class="link" href="pango-X-Fonts-and-Rendering.html#PangoXFontCache" title="PangoXFontCache">PangoXFontCache</a> * <a class="link" href="pango-X-Fonts-and-Rendering.html#pango-x-font-cache-new" title="pango_x_font_cache_new ()">pango_x_font_cache_new</a> (Display *display);
void <a class="link" href="pango-X-Fonts-and-Rendering.html#pango-x-font-cache-free" title="pango_x_font_cache_free ()">pango_x_font_cache_free</a> (<a class="link" href="pango-X-Fonts-and-Rendering.html#PangoXFontCache" title="PangoXFontCache">PangoXFontCache</a> *cache);
XFontStruct * <a class="link" href="pango-X-Fonts-and-Rendering.html#pango-x-font-cache-load" title="pango_x_font_cache_load ()">pango_x_font_cache_load</a> (<a class="link" href="pango-X-Fonts-and-Rendering.html#PangoXFontCache" title="PangoXFontCache">PangoXFontCache</a> *cache,
const char *xlfd);
void <a class="link" href="pango-X-Fonts-and-Rendering.html#pango-x-font-cache-unload" title="pango_x_font_cache_unload ()">pango_x_font_cache_unload</a> (<a class="link" href="pango-X-Fonts-and-Rendering.html#PangoXFontCache" title="PangoXFontCache">PangoXFontCache</a> *cache,
XFontStruct *fs);
</pre>
</div>
<div class="refsect1" title="Description">
<a name="pango-X-Fonts-and-Rendering.description"></a><h2>Description</h2>
<p>
The functions and macros in this section are for use with the old
X font backend which used server-side bitmap fonts. This font backend
is no longer supported, and attempts to use it will produce
unpredictable results. Use the <a class="link" href="pango-Xft-Fonts-and-Rendering.html" title="Xft Fonts and Rendering">Xft</a>
or <a class="link" href="pango-Cairo-Rendering.html" title="Cairo Rendering">Cairo</a> backend instead.
</p>
</div>
<div class="refsect1" title="Details">
<a name="pango-X-Fonts-and-Rendering.details"></a><h2>Details</h2>
<div class="refsect2" title="PANGO_RENDER_TYPE_X">
<a name="PANGO-RENDER-TYPE-X--CAPS"></a><h3>PANGO_RENDER_TYPE_X</h3>
<pre class="programlisting">#define PANGO_RENDER_TYPE_X "PangoRenderX"
</pre>
<div class="warning" title="Warning" style="margin-left: 0.5in; margin-right: 0.5in;">
<h3 class="title">Warning</h3>
<p><code class="literal">PANGO_RENDER_TYPE_X</code> is deprecated and should not be used in newly-written code.</p>
</div>
<p>
A string constant identifying the X renderer. The associated quark (see
<a
href="http://library.gnome.org/devel/glib/unstable/glib-Quarks.html#g-quark-from-string"
><code class="function">g_quark_from_string()</code></a>) is used to identify the renderer in <a class="link" href="pango-Modules.html#pango-find-map" title="pango_find_map ()"><code class="function">pango_find_map()</code></a>.
</p>
</div>
<hr>
<div class="refsect2" title="pango_x_get_context ()">
<a name="pango-x-get-context"></a><h3>pango_x_get_context ()</h3>
<pre class="programlisting"><a class="link" href="pango-Text-Processing.html#PangoContext">PangoContext</a> * pango_x_get_context (Display *display);</pre>
<div class="warning" title="Warning" style="margin-left: 0.5in; margin-right: 0.5in;">
<h3 class="title">Warning</h3>
<p><code class="literal">pango_x_get_context</code> has been deprecated since version 1.22 and should not be used in newly-written code. Use <a class="link" href="pango-X-Fonts-and-Rendering.html#pango-x-font-map-for-display" title="pango_x_font_map_for_display ()"><code class="function">pango_x_font_map_for_display()</code></a> followed by
<a class="link" href="pango-Fonts.html#pango-font-map-create-context" title="pango_font_map_create_context ()"><code class="function">pango_font_map_create_context()</code></a> instead.</p>
</div>
<p>
Retrieves a <a class="link" href="pango-Text-Processing.html#PangoContext"><span class="type">PangoContext</span></a> appropriate for rendering with X fonts on the
given display.</p>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><em class="parameter"><code>display</code></em> :</span></p></td>
<td> an X display (As returned by <code class="function">XOpenDisplay()</code>.)
</td>
</tr>
<tr>
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
<td> the new <a class="link" href="pango-Text-Processing.html#PangoContext"><span class="type">PangoContext</span></a>.
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" title="pango_x_context_set_funcs ()">
<a name="pango-x-context-set-funcs"></a><h3>pango_x_context_set_funcs ()</h3>
<pre class="programlisting">void pango_x_context_set_funcs (<a class="link" href="pango-Text-Processing.html#PangoContext">PangoContext</a> *context,
<a class="link" href="pango-X-Fonts-and-Rendering.html#PangoGetGCFunc" title="PangoGetGCFunc ()">PangoGetGCFunc</a> get_gc_func,
<a class="link" href="pango-X-Fonts-and-Rendering.html#PangoFreeGCFunc" title="PangoFreeGCFunc ()">PangoFreeGCFunc</a> free_gc_func);</pre>
<div class="warning" title="Warning" style="margin-left: 0.5in; margin-right: 0.5in;">
<h3 class="title">Warning</h3>
<p><code class="literal">pango_x_context_set_funcs</code> is deprecated and should not be used in newly-written code.</p>
</div>
<p>
Sets the functions that will be used to get GC's in various colors when
rendering layouts with this context.</p>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><em class="parameter"><code>context</code></em> :</span></p></td>
<td> a <a class="link" href="pango-Text-Processing.html#PangoContext"><span class="type">PangoContext</span></a>.
</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>get_gc_func</code></em> :</span></p></td>
<td> function called to create a new GC for a given color.
</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>free_gc_func</code></em> :</span></p></td>
<td> function called to free a GC created with <em class="parameter"><code>get_gc_func</code></em>.
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" title="PangoGetGCFunc ()">
<a name="PangoGetGCFunc"></a><h3>PangoGetGCFunc ()</h3>
<pre class="programlisting">GC (*PangoGetGCFunc) (<a class="link" href="pango-Text-Processing.html#PangoContext">PangoContext</a> *context,
<a class="link" href="pango-Text-Attributes.html#PangoColor" title="PangoColor">PangoColor</a> *color,
GC base_gc);</pre>
<div class="warning" title="Warning" style="margin-left: 0.5in; margin-right: 0.5in;">
<h3 class="title">Warning</h3>
<p><code class="literal">PangoGetGCFunc</code> is deprecated and should not be used in newly-written code.</p>
</div>
<p>
Specifies the type of the function used to create a new GC for a given
color.
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><em class="parameter"><code>context</code></em> :</span></p></td>
<td>a <a class="link" href="pango-Text-Processing.html#PangoContext"><span class="type">PangoContext</span></a>.
</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>color</code></em> :</span></p></td>
<td>the color to create a new GC for.
</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>base_gc</code></em> :</span></p></td>
<td>the GC to base the new GC on.
</td>
</tr>
<tr>
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
<td>the new GC.
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" title="PangoFreeGCFunc ()">
<a name="PangoFreeGCFunc"></a><h3>PangoFreeGCFunc ()</h3>
<pre class="programlisting">void (*PangoFreeGCFunc) (<a class="link" href="pango-Text-Processing.html#PangoContext">PangoContext</a> *context,
GC gc);</pre>
<div class="warning" title="Warning" style="margin-left: 0.5in; margin-right: 0.5in;">
<h3 class="title">Warning</h3>
<p><code class="literal">PangoFreeGCFunc</code> is deprecated and should not be used in newly-written code.</p>
</div>
<p>
Specifies the type of the function used to free a GC created with
the corresponding <a class="link" href="pango-X-Fonts-and-Rendering.html#PangoGetGCFunc" title="PangoGetGCFunc ()"><span class="type">PangoGetGCFunc</span></a> function.
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><em class="parameter"><code>context</code></em> :</span></p></td>
<td>a <a class="link" href="pango-Text-Processing.html#PangoContext"><span class="type">PangoContext</span></a>.
</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>gc</code></em> :</span></p></td>
<td>the GC to free.
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" title="pango_x_render ()">
<a name="pango-x-render"></a><h3>pango_x_render ()</h3>
<pre class="programlisting">void pango_x_render (Display *display,
Drawable d,
GC gc,
<a class="link" href="pango-Fonts.html#PangoFont">PangoFont</a> *font,
<a class="link" href="pango-Glyph-Storage.html#PangoGlyphString" title="PangoGlyphString">PangoGlyphString</a> *glyphs,
<a
href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gint"
>gint</a> x,
<a
href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gint"
>gint</a> y);</pre>
<div class="warning" title="Warning" style="margin-left: 0.5in; margin-right: 0.5in;">
<h3 class="title">Warning</h3>
<p><code class="literal">pango_x_render</code> is deprecated and should not be used in newly-written code.</p>
</div>
<p>
Renders a <a class="link" href="pango-Glyph-Storage.html#PangoGlyphString" title="PangoGlyphString"><span class="type">PangoGlyphString</span></a> onto an X drawable.</p>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><em class="parameter"><code>display</code></em> :</span></p></td>
<td> the X display.
</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>d</code></em> :</span></p></td>
<td> the drawable on which to draw string.
</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>gc</code></em> :</span></p></td>
<td> the graphics context.
</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>font</code></em> :</span></p></td>
<td> the font in which to draw the string.
</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>glyphs</code></em> :</span></p></td>
<td> the glyph string to draw.
</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>x</code></em> :</span></p></td>
<td> the x position of start of string (in pixels).
</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>y</code></em> :</span></p></td>
<td> the y position of baseline (in pixels).
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" title="pango_x_render_layout_line ()">
<a name="pango-x-render-layout-line"></a><h3>pango_x_render_layout_line ()</h3>
<pre class="programlisting">void pango_x_render_layout_line (Display *display,
Drawable drawable,
GC gc,
<a class="link" href="pango-Layout-Objects.html#PangoLayoutLine" title="PangoLayoutLine">PangoLayoutLine</a> *line,
int x,
int y);</pre>
<div class="warning" title="Warning" style="margin-left: 0.5in; margin-right: 0.5in;">
<h3 class="title">Warning</h3>
<p><code class="literal">pango_x_render_layout_line</code> is deprecated and should not be used in newly-written code.</p>
</div>
<p>
Renders a <a class="link" href="pango-Layout-Objects.html#PangoLayoutLine" title="PangoLayoutLine"><span class="type">PangoLayoutLine</span></a> onto an X drawable.</p>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><em class="parameter"><code>display</code></em> :</span></p></td>
<td> the X display.
</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>drawable</code></em> :</span></p></td>
<td> the drawable on which to draw.
</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>gc</code></em> :</span></p></td>
<td> GC to use for uncolored drawing.
</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>line</code></em> :</span></p></td>
<td> a <a class="link" href="pango-Layout-Objects.html#PangoLayoutLine" title="PangoLayoutLine"><span class="type">PangoLayoutLine</span></a>.
</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>x</code></em> :</span></p></td>
<td> the x position of start of string (in pixels).
</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>y</code></em> :</span></p></td>
<td> the y position of baseline (in pixels).
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" title="pango_x_render_layout ()">
<a name="pango-x-render-layout"></a><h3>pango_x_render_layout ()</h3>
<pre class="programlisting">void pango_x_render_layout (Display *display,
Drawable drawable,
GC gc,
<a class="link" href="pango-Layout-Objects.html#PangoLayout">PangoLayout</a> *layout,
int x,
int y);</pre>
<div class="warning" title="Warning" style="margin-left: 0.5in; margin-right: 0.5in;">
<h3 class="title">Warning</h3>
<p><code class="literal">pango_x_render_layout</code> is deprecated and should not be used in newly-written code.</p>
</div>
<p>
Renders a <a class="link" href="pango-Layout-Objects.html#PangoLayout"><span class="type">PangoLayout</span></a> onto an X drawable.</p>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><em class="parameter"><code>display</code></em> :</span></p></td>
<td> the X display.
</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>drawable</code></em> :</span></p></td>
<td> the drawable on which to draw.
</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>gc</code></em> :</span></p></td>
<td> GC to use for uncolored drawing.
</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>layout</code></em> :</span></p></td>
<td> a <a class="link" href="pango-Layout-Objects.html#PangoLayout"><span class="type">PangoLayout</span></a>.
</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>x</code></em> :</span></p></td>
<td> the x position of the left of the layout (in pixels).
</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>y</code></em> :</span></p></td>
<td> the y position of the top of the layout (in pixels).
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" title="PangoXSubfont">
<a name="PangoXSubfont"></a><h3>PangoXSubfont</h3>
<pre class="programlisting">typedef guint16 PangoXSubfont;
</pre>
<div class="warning" title="Warning" style="margin-left: 0.5in; margin-right: 0.5in;">
<h3 class="title">Warning</h3>
<p><code class="literal">PangoXSubfont</code> is deprecated and should not be used in newly-written code.</p>
</div>
<p>
The <span class="type">PangoXSubFont</span> type is an integer ID that identifies one
particular X font within the fonts referenced in a <a class="link" href="pango-Fonts.html#PangoFont"><span class="type">PangoFont</span></a>.
</p>
</div>
<hr>
<div class="refsect2" title="PANGO_X_MAKE_GLYPH()">
<a name="PANGO-X-MAKE-GLYPH--CAPS"></a><h3>PANGO_X_MAKE_GLYPH()</h3>
<pre class="programlisting">#define PANGO_X_MAKE_GLYPH(subfont,index_) ((subfont)<<16 | (index_))
</pre>
<div class="warning" title="Warning" style="margin-left: 0.5in; margin-right: 0.5in;">
<h3 class="title">Warning</h3>
<p><code class="literal">PANGO_X_MAKE_GLYPH</code> is deprecated and should not be used in newly-written code.</p>
</div>
<p>
Make a glyph index from a <span class="type">PangoXSubFont</span> index and a index
of a character with the corresponding X font.
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><em class="parameter"><code>subfont</code></em> :</span></p></td>
<td>a <a class="link" href="pango-X-Fonts-and-Rendering.html#PangoXSubfont" title="PangoXSubfont"><span class="type">PangoXSubfont</span></a> index
</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>index_</code></em> :</span></p></td>
<td>the index of a character within an X font.
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" title="PANGO_X_GLYPH_SUBFONT()">
<a name="PANGO-X-GLYPH-SUBFONT--CAPS"></a><h3>PANGO_X_GLYPH_SUBFONT()</h3>
<pre class="programlisting">#define PANGO_X_GLYPH_SUBFONT(glyph) ((glyph)>>16)
</pre>
<div class="warning" title="Warning" style="margin-left: 0.5in; margin-right: 0.5in;">
<h3 class="title">Warning</h3>
<p><code class="literal">PANGO_X_GLYPH_SUBFONT</code> is deprecated and should not be used in newly-written code.</p>
</div>
<p>
Extract the subfont index from a glyph index.
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody><tr>
<td><p><span class="term"><em class="parameter"><code>glyph</code></em> :</span></p></td>
<td>a <span class="type">PangoGlyphIndex</span>
</td>
</tr></tbody>
</table></div>
</div>
<hr>
<div class="refsect2" title="PANGO_X_GLYPH_INDEX()">
<a name="PANGO-X-GLYPH-INDEX--CAPS"></a><h3>PANGO_X_GLYPH_INDEX()</h3>
<pre class="programlisting">#define PANGO_X_GLYPH_INDEX(glyph) ((glyph) & 0xffff)
</pre>
<div class="warning" title="Warning" style="margin-left: 0.5in; margin-right: 0.5in;">
<h3 class="title">Warning</h3>
<p><code class="literal">PANGO_X_GLYPH_INDEX</code> is deprecated and should not be used in newly-written code.</p>
</div>
<p>
Extract the character index within the X font from a
glyph index.
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody><tr>
<td><p><span class="term"><em class="parameter"><code>glyph</code></em> :</span></p></td>
<td>a <span class="type">PangoGlyphIndex</span>
</td>
</tr></tbody>
</table></div>
</div>
<hr>
<div class="refsect2" title="pango_x_load_font ()">
<a name="pango-x-load-font"></a><h3>pango_x_load_font ()</h3>
<pre class="programlisting"><a class="link" href="pango-Fonts.html#PangoFont">PangoFont</a> * pango_x_load_font (Display *display,
const <a
href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gchar"
>gchar</a> *spec);</pre>
<div class="warning" title="Warning" style="margin-left: 0.5in; margin-right: 0.5in;">
<h3 class="title">Warning</h3>
<p><code class="literal">pango_x_load_font</code> is deprecated and should not be used in newly-written code.</p>
</div>
<p>
Loads up a logical font based on a "fontset" style text
specification. This is not remotely useful (Pango API's generally
work in terms of <a class="link" href="pango-Fonts.html#PangoFontDescription" title="PangoFontDescription"><span class="type">PangoFontDescription</span></a>) and the result may not
work correctly in all circumstances. Use of this function should
be avoided.</p>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><em class="parameter"><code>display</code></em> :</span></p></td>
<td> the X display.
</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>spec</code></em> :</span></p></td>
<td> a comma-separated list of XLFD's.
</td>
</tr>
<tr>
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
<td> a new <a class="link" href="pango-Fonts.html#PangoFont"><span class="type">PangoFont</span></a>.
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" title="pango_x_get_unknown_glyph ()">
<a name="pango-x-get-unknown-glyph"></a><h3>pango_x_get_unknown_glyph ()</h3>
<pre class="programlisting"><a class="link" href="pango-Glyph-Storage.html#PangoGlyph" title="PangoGlyph">PangoGlyph</a> pango_x_get_unknown_glyph (<a class="link" href="pango-Fonts.html#PangoFont">PangoFont</a> *font);</pre>
<div class="warning" title="Warning" style="margin-left: 0.5in; margin-right: 0.5in;">
<h3 class="title">Warning</h3>
<p><code class="literal">pango_x_get_unknown_glyph</code> is deprecated and should not be used in newly-written code.</p>
</div>
<p>
Returns the index of a glyph suitable for drawing unknown characters;
you should generally use <a class="link" href="pango-Glyph-Storage.html#PANGO-GET-UNKNOWN-GLYPH--CAPS" title="PANGO_GET_UNKNOWN_GLYPH()"><code class="function">PANGO_GET_UNKNOWN_GLYPH()</code></a> instead,
since that may return a glyph that provides a better representation
of a particular char. (E.g., by showing hex digits, or a glyph
representative of a certain Unicode range.)</p>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><em class="parameter"><code>font</code></em> :</span></p></td>
<td> a <a class="link" href="pango-Fonts.html#PangoFont"><span class="type">PangoFont</span></a>.
</td>
</tr>
<tr>
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
<td> a glyph index into <em class="parameter"><code>font</code></em>.
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" title="pango_x_has_glyph ()">
<a name="pango-x-has-glyph"></a><h3>pango_x_has_glyph ()</h3>
<pre class="programlisting"><a
href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gboolean"
>gboolean</a> pango_x_has_glyph (<a class="link" href="pango-Fonts.html#PangoFont">PangoFont</a> *font,
<a class="link" href="pango-Glyph-Storage.html#PangoGlyph" title="PangoGlyph">PangoGlyph</a> glyph);</pre>
<div class="warning" title="Warning" style="margin-left: 0.5in; margin-right: 0.5in;">
<h3 class="title">Warning</h3>
<p><code class="literal">pango_x_has_glyph</code> is deprecated and should not be used in newly-written code.</p>
</div>
<p>
Checks if the given glyph is present in a X font.</p>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><em class="parameter"><code>font</code></em> :</span></p></td>
<td> a <a class="link" href="pango-Fonts.html#PangoFont"><span class="type">PangoFont</span></a> which must be from the X backend.
</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>glyph</code></em> :</span></p></td>
<td> the index of a glyph in the font. (Formed
using the <a class="link" href="pango-X-Fonts-and-Rendering.html#PANGO-X-MAKE-GLYPH--CAPS" title="PANGO_X_MAKE_GLYPH()"><span class="type">PANGO_X_MAKE_GLYPH</span></a> macro)
</td>
</tr>
<tr>
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
<td> <code class="literal">TRUE</code> if the glyph is present.
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" title="pango_x_list_subfonts ()">
<a name="pango-x-list-subfonts"></a><h3>pango_x_list_subfonts ()</h3>
<pre class="programlisting">int pango_x_list_subfonts (<a class="link" href="pango-Fonts.html#PangoFont">PangoFont</a> *font,
char **charsets,
int n_charsets,
<a class="link" href="pango-X-Fonts-and-Rendering.html#PangoXSubfont" title="PangoXSubfont">PangoXSubfont</a> **subfont_ids,
int **subfont_charsets);</pre>
<div class="warning" title="Warning" style="margin-left: 0.5in; margin-right: 0.5in;">
<h3 class="title">Warning</h3>
<p><code class="literal">pango_x_list_subfonts</code> is deprecated and should not be used in newly-written code.</p>
</div>
<p>
Lists the subfonts of a given font. The result is ordered first by charset,
and then within each charset, by the order of fonts in the font specification.</p>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><em class="parameter"><code>font</code></em> :</span></p></td>
<td> a <a class="link" href="pango-Fonts.html#PangoFont"><span class="type">PangoFont</span></a>.
</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>charsets</code></em> :</span></p></td>
<td> the charsets to list subfonts for.
</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>n_charsets</code></em> :</span></p></td>
<td> the number of charsets in <em class="parameter"><code>charsets</code></em>.
</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>subfont_ids</code></em> :</span></p></td>
<td> location to store a pointer to an array of subfont IDs for each found subfont;
the result must be freed using <a
href="http://library.gnome.org/devel/glib/unstable/glib-Memory-Allocation.html#g-free"
><code class="function">g_free()</code></a>.
</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>subfont_charsets</code></em> :</span></p></td>
<td> location to store a pointer to an array of subfont IDs for each found subfont;
the result must be freed using <a
href="http://library.gnome.org/devel/glib/unstable/glib-Memory-Allocation.html#g-free"
><code class="function">g_free()</code></a>.
</td>
</tr>
<tr>
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
<td> length of the arrays stored in <em class="parameter"><code>subfont_ids</code></em> and
<em class="parameter"><code>subfont_charsets</code></em>.
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" title="pango_x_font_map_for_display ()">
<a name="pango-x-font-map-for-display"></a><h3>pango_x_font_map_for_display ()</h3>
<pre class="programlisting"><a class="link" href="pango-Fonts.html#PangoFontMap">PangoFontMap</a> * pango_x_font_map_for_display (Display *display);</pre>
<div class="warning" title="Warning" style="margin-left: 0.5in; margin-right: 0.5in;">
<h3 class="title">Warning</h3>
<p><code class="literal">pango_x_font_map_for_display</code> is deprecated and should not be used in newly-written code.</p>
</div>
<p>
Returns a <span class="type">PangoXFontMap</span> for <em class="parameter"><code>display</code></em>. Font maps are cached and should
not be freed. If the font map for a display is no longer needed, it can
be released with <a class="link" href="pango-X-Fonts-and-Rendering.html#pango-x-shutdown-display" title="pango_x_shutdown_display ()"><code class="function">pango_x_shutdown_display()</code></a>.</p>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><em class="parameter"><code>display</code></em> :</span></p></td>
<td> an X <span class="type">Display</span>.
</td>
</tr>
<tr>
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
<td> a <span class="type">PangoXFontMap</span> for <em class="parameter"><code>display</code></em>.
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" title="pango_x_shutdown_display ()">
<a name="pango-x-shutdown-display"></a><h3>pango_x_shutdown_display ()</h3>
<pre class="programlisting">void pango_x_shutdown_display (Display *display);</pre>
<div class="warning" title="Warning" style="margin-left: 0.5in; margin-right: 0.5in;">
<h3 class="title">Warning</h3>
<p><code class="literal">pango_x_shutdown_display</code> is deprecated and should not be used in newly-written code.</p>
</div>
<p>
Free cached resources for the given X display structure.</p>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody><tr>
<td><p><span class="term"><em class="parameter"><code>display</code></em> :</span></p></td>
<td> an X <span class="type">Display</span>
</td>
</tr></tbody>
</table></div>
</div>
<hr>
<div class="refsect2" title="pango_x_font_map_get_font_cache ()">
<a name="pango-x-font-map-get-font-cache"></a><h3>pango_x_font_map_get_font_cache ()</h3>
<pre class="programlisting"><a class="link" href="pango-X-Fonts-and-Rendering.html#PangoXFontCache" title="PangoXFontCache">PangoXFontCache</a> * pango_x_font_map_get_font_cache (<a class="link" href="pango-Fonts.html#PangoFontMap">PangoFontMap</a> *font_map);</pre>
<div class="warning" title="Warning" style="margin-left: 0.5in; margin-right: 0.5in;">
<h3 class="title">Warning</h3>
<p><code class="literal">pango_x_font_map_get_font_cache</code> is deprecated and should not be used in newly-written code.</p>
</div>
<p>
Obtains the font cache associated with the given font map.</p>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><em class="parameter"><code>font_map</code></em> :</span></p></td>
<td> a <span class="type">PangoXFontMap</span>.
</td>
</tr>
<tr>
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
<td> the <a class="link" href="pango-X-Fonts-and-Rendering.html#PangoXFontCache" title="PangoXFontCache"><span class="type">PangoXFontCache</span></a> of <em class="parameter"><code>font_map</code></em>.
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" title="pango_x_font_subfont_xlfd ()">
<a name="pango-x-font-subfont-xlfd"></a><h3>pango_x_font_subfont_xlfd ()</h3>
<pre class="programlisting">char * pango_x_font_subfont_xlfd (<a class="link" href="pango-Fonts.html#PangoFont">PangoFont</a> *font,
<a class="link" href="pango-X-Fonts-and-Rendering.html#PangoXSubfont" title="PangoXSubfont">PangoXSubfont</a> subfont_id);</pre>
<div class="warning" title="Warning" style="margin-left: 0.5in; margin-right: 0.5in;">
<h3 class="title">Warning</h3>
<p><code class="literal">pango_x_font_subfont_xlfd</code> is deprecated and should not be used in newly-written code.</p>
</div>
<p>
Determines the X Logical Font Description for the specified
subfont.</p>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><em class="parameter"><code>font</code></em> :</span></p></td>
<td> a <a class="link" href="pango-Fonts.html#PangoFont"><span class="type">PangoFont</span></a> which must be from the X backend.
</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>subfont_id</code></em> :</span></p></td>
<td> the id of a subfont within the font.
</td>
</tr>
<tr>
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
<td> A newly-allocated string containing the XLFD for the
subfont. This string must be freed with <a
href="http://library.gnome.org/devel/glib/unstable/glib-Memory-Allocation.html#g-free"
><code class="function">g_free()</code></a>.
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" title="pango_x_find_first_subfont ()">
<a name="pango-x-find-first-subfont"></a><h3>pango_x_find_first_subfont ()</h3>
<pre class="programlisting"><a
href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gboolean"
>gboolean</a> pango_x_find_first_subfont (<a class="link" href="pango-Fonts.html#PangoFont">PangoFont</a> *font,
char **charsets,
int n_charsets,
<a class="link" href="pango-X-Fonts-and-Rendering.html#PangoXSubfont" title="PangoXSubfont">PangoXSubfont</a> *rfont);</pre>
<div class="warning" title="Warning" style="margin-left: 0.5in; margin-right: 0.5in;">
<h3 class="title">Warning</h3>
<p><code class="literal">pango_x_find_first_subfont</code> is deprecated and should not be used in newly-written code.</p>
</div>
<p>
Looks for subfonts with the <em class="parameter"><code>charset</code></em> charset,
in <em class="parameter"><code>font</code></em>, and puts the first one in *<em class="parameter"><code>rfont</code></em>.</p>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><em class="parameter"><code>font</code></em> :</span></p></td>
<td> A <a class="link" href="pango-Fonts.html#PangoFont"><span class="type">PangoFont</span></a>.
</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>charsets</code></em> :</span></p></td>
<td> An array of charsets.
</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>n_charsets</code></em> :</span></p></td>
<td> The number of charsets in <em class="parameter"><code>charsets</code></em>.
</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>rfont</code></em> :</span></p></td>
<td> A pointer to a <a class="link" href="pango-X-Fonts-and-Rendering.html#PangoXSubfont" title="PangoXSubfont"><span class="type">PangoXSubfont</span></a>.
</td>
</tr>
<tr>
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
<td> <code class="literal">TRUE</code> if *<em class="parameter"><code>rfont</code></em> now contains a font.
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" title="pango_x_font_get_unknown_glyph ()">
<a name="pango-x-font-get-unknown-glyph"></a><h3>pango_x_font_get_unknown_glyph ()</h3>
<pre class="programlisting"><a class="link" href="pango-Glyph-Storage.html#PangoGlyph" title="PangoGlyph">PangoGlyph</a> pango_x_font_get_unknown_glyph (<a class="link" href="pango-Fonts.html#PangoFont">PangoFont</a> *font,
<a
href="http://library.gnome.org/devel/glib/unstable/glib-Unicode-Manipulation.html#gunichar"
>gunichar</a> wc);</pre>
<div class="warning" title="Warning" style="margin-left: 0.5in; margin-right: 0.5in;">
<h3 class="title">Warning</h3>
<p><code class="literal">pango_x_font_get_unknown_glyph</code> is deprecated and should not be used in newly-written code.</p>
</div>
<p>
Returns the index of a glyph suitable for drawing <em class="parameter"><code>wc</code></em> as an
unknown character.
</p>
<p>
Use <a class="link" href="pango-Glyph-Storage.html#PANGO-GET-UNKNOWN-GLYPH--CAPS" title="PANGO_GET_UNKNOWN_GLYPH()"><code class="function">PANGO_GET_UNKNOWN_GLYPH()</code></a> instead.</p>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><em class="parameter"><code>font</code></em> :</span></p></td>
<td> a <a class="link" href="pango-Fonts.html#PangoFont"><span class="type">PangoFont</span></a>.
</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>wc</code></em> :</span></p></td>
<td> the Unicode character for which a glyph is needed.
</td>
</tr>
<tr>
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
<td> a glyph index into <em class="parameter"><code>font</code></em>.
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" title="pango_x_apply_ligatures ()">
<a name="pango-x-apply-ligatures"></a><h3>pango_x_apply_ligatures ()</h3>
<pre class="programlisting"><a
href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gboolean"
>gboolean</a> pango_x_apply_ligatures (<a class="link" href="pango-Fonts.html#PangoFont">PangoFont</a> *font,
<a class="link" href="pango-X-Fonts-and-Rendering.html#PangoXSubfont" title="PangoXSubfont">PangoXSubfont</a> subfont,
<a
href="http://library.gnome.org/devel/glib/unstable/glib-Unicode-Manipulation.html#gunichar"
>gunichar</a> **glyphs,
int *n_glyphs,
int **clusters);</pre>
<div class="warning" title="Warning" style="margin-left: 0.5in; margin-right: 0.5in;">
<h3 class="title">Warning</h3>
<p><code class="literal">pango_x_apply_ligatures</code> is deprecated and should not be used in newly-written code.</p>
</div>
<p>
Previously did subfont-specific ligation. Now a no-op.</p>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><em class="parameter"><code>font</code></em> :</span></p></td>
<td> unused
</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>subfont</code></em> :</span></p></td>
<td> unused
</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>glyphs</code></em> :</span></p></td>
<td> unused
</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>n_glyphs</code></em> :</span></p></td>
<td> unused
</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>clusters</code></em> :</span></p></td>
<td> unused
</td>
</tr>
<tr>
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
<td> <code class="literal">FALSE</code>, always.
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" title="pango_x_fallback_shape ()">
<a name="pango-x-fallback-shape"></a><h3>pango_x_fallback_shape ()</h3>
<pre class="programlisting">void pango_x_fallback_shape (<a class="link" href="pango-Fonts.html#PangoFont">PangoFont</a> *font,
<a class="link" href="pango-Glyph-Storage.html#PangoGlyphString" title="PangoGlyphString">PangoGlyphString</a> *glyphs,
const char *text,
int n_chars);</pre>
<div class="warning" title="Warning" style="margin-left: 0.5in; margin-right: 0.5in;">
<h3 class="title">Warning</h3>
<p><code class="literal">pango_x_fallback_shape</code> is deprecated and should not be used in newly-written code.</p>
</div>
<p>
This is a simple fallback shaper, that can be used
if no subfont that supports a given script is found.
For every character in <em class="parameter"><code>text</code></em>, it puts the unknown glyph.</p>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><em class="parameter"><code>font</code></em> :</span></p></td>
<td> A <a class="link" href="pango-Fonts.html#PangoFont"><span class="type">PangoFont</span></a>.
</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>glyphs</code></em> :</span></p></td>
<td> A pointer to a <a class="link" href="pango-Glyph-Storage.html#PangoGlyphString" title="PangoGlyphString"><span class="type">PangoGlyphString</span></a>.
</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>text</code></em> :</span></p></td>
<td> UTF-8 string.
</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>n_chars</code></em> :</span></p></td>
<td> Number of UTF-8 seqs in <em class="parameter"><code>text</code></em>.
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" title="PangoXFontCache">
<a name="PangoXFontCache"></a><h3>PangoXFontCache</h3>
<pre class="programlisting">typedef struct _PangoXFontCache PangoXFontCache;</pre>
<div class="warning" title="Warning" style="margin-left: 0.5in; margin-right: 0.5in;">
<h3 class="title">Warning</h3>
<p><code class="literal">PangoXFontCache</code> is deprecated and should not be used in newly-written code.</p>
</div>
<p>
A <a class="link" href="pango-X-Fonts-and-Rendering.html#PangoXFontCache" title="PangoXFontCache"><span class="type">PangoXFontCache</span></a> caches
<span class="type">XFontStructs</span> for a single display by their XLFD name.
</p>
</div>
<hr>
<div class="refsect2" title="pango_x_font_cache_new ()">
<a name="pango-x-font-cache-new"></a><h3>pango_x_font_cache_new ()</h3>
<pre class="programlisting"><a class="link" href="pango-X-Fonts-and-Rendering.html#PangoXFontCache" title="PangoXFontCache">PangoXFontCache</a> * pango_x_font_cache_new (Display *display);</pre>
<div class="warning" title="Warning" style="margin-left: 0.5in; margin-right: 0.5in;">
<h3 class="title">Warning</h3>
<p><code class="literal">pango_x_font_cache_new</code> is deprecated and should not be used in newly-written code.</p>
</div>
<p>
Creates a font cache for the specified display.</p>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><em class="parameter"><code>display</code></em> :</span></p></td>
<td> an X display.
</td>
</tr>
<tr>
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
<td> The newly allocated <a class="link" href="pango-X-Fonts-and-Rendering.html#PangoXFontCache" title="PangoXFontCache"><span class="type">PangoXFontCache</span></a>, which should be
freed with <a class="link" href="pango-X-Fonts-and-Rendering.html#pango-x-font-cache-free" title="pango_x_font_cache_free ()"><code class="function">pango_x_font_cache_free()</code></a>.
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" title="pango_x_font_cache_free ()">
<a name="pango-x-font-cache-free"></a><h3>pango_x_font_cache_free ()</h3>
<pre class="programlisting">void pango_x_font_cache_free (<a class="link" href="pango-X-Fonts-and-Rendering.html#PangoXFontCache" title="PangoXFontCache">PangoXFontCache</a> *cache);</pre>
<div class="warning" title="Warning" style="margin-left: 0.5in; margin-right: 0.5in;">
<h3 class="title">Warning</h3>
<p><code class="literal">pango_x_font_cache_free</code> is deprecated and should not be used in newly-written code.</p>
</div>
<p>
Frees a <a class="link" href="pango-X-Fonts-and-Rendering.html#PangoXFontCache" title="PangoXFontCache"><span class="type">PangoXFontCache</span></a> and all associated memory. All fonts loaded
through this font cache will be freed along with the cache.</p>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody><tr>
<td><p><span class="term"><em class="parameter"><code>cache</code></em> :</span></p></td>
<td> a <a class="link" href="pango-X-Fonts-and-Rendering.html#PangoXFontCache" title="PangoXFontCache"><span class="type">PangoXFontCache</span></a>
</td>
</tr></tbody>
</table></div>
</div>
<hr>
<div class="refsect2" title="pango_x_font_cache_load ()">
<a name="pango-x-font-cache-load"></a><h3>pango_x_font_cache_load ()</h3>
<pre class="programlisting">XFontStruct * pango_x_font_cache_load (<a class="link" href="pango-X-Fonts-and-Rendering.html#PangoXFontCache" title="PangoXFontCache">PangoXFontCache</a> *cache,
const char *xlfd);</pre>
<div class="warning" title="Warning" style="margin-left: 0.5in; margin-right: 0.5in;">
<h3 class="title">Warning</h3>
<p><code class="literal">pango_x_font_cache_load</code> is deprecated and should not be used in newly-written code.</p>
</div>
<p>
Loads a <span class="type">XFontStruct</span> from a X Logical Font Description. The
result may be newly loaded, or it may have been previously
stored.</p>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><em class="parameter"><code>cache</code></em> :</span></p></td>
<td> a <a class="link" href="pango-X-Fonts-and-Rendering.html#PangoXFontCache" title="PangoXFontCache"><span class="type">PangoXFontCache</span></a>
</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>xlfd</code></em> :</span></p></td>
<td> the X Logical Font Description to load.
</td>
</tr>
<tr>
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
<td> The font structure, or <code class="literal">NULL</code> if the font could
not be loaded. In order to free this structure, you must call
<a class="link" href="pango-X-Fonts-and-Rendering.html#pango-x-font-cache-unload" title="pango_x_font_cache_unload ()"><code class="function">pango_x_font_cache_unload()</code></a>.
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" title="pango_x_font_cache_unload ()">
<a name="pango-x-font-cache-unload"></a><h3>pango_x_font_cache_unload ()</h3>
<pre class="programlisting">void pango_x_font_cache_unload (<a class="link" href="pango-X-Fonts-and-Rendering.html#PangoXFontCache" title="PangoXFontCache">PangoXFontCache</a> *cache,
XFontStruct *fs);</pre>
<div class="warning" title="Warning" style="margin-left: 0.5in; margin-right: 0.5in;">
<h3 class="title">Warning</h3>
<p><code class="literal">pango_x_font_cache_unload</code> is deprecated and should not be used in newly-written code.</p>
</div>
<p>
Frees a font structure previously loaded with <a class="link" href="pango-X-Fonts-and-Rendering.html#pango-x-font-cache-load" title="pango_x_font_cache_load ()"><code class="function">pango_x_font_cache_load()</code></a>.</p>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><em class="parameter"><code>cache</code></em> :</span></p></td>
<td> a <a class="link" href="pango-X-Fonts-and-Rendering.html#PangoXFontCache" title="PangoXFontCache"><span class="type">PangoXFontCache</span></a>
</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>fs</code></em> :</span></p></td>
<td> the font structure to unload
</td>
</tr>
</tbody>
</table></div>
</div>
</div>
</div>
<div class="footer">
<hr>
Generated by GTK-Doc V1.11</div>
</body>
</html>
| Java |
#include "attr-path.hh"
#include "util.hh"
namespace nix {
// !!! Shouldn't we return a pointer to a Value?
void findAlongAttrPath(EvalState & state, const string & attrPath,
Bindings & autoArgs, Expr * e, Value & v)
{
Strings tokens = tokenizeString(attrPath, ".");
Error attrError =
Error(format("attribute selection path `%1%' does not match expression") % attrPath);
string curPath;
state.mkThunk_(v, e);
foreach (Strings::iterator, i, tokens) {
if (!curPath.empty()) curPath += ".";
curPath += *i;
/* Is *i an index (integer) or a normal attribute name? */
enum { apAttr, apIndex } apType = apAttr;
string attr = *i;
int attrIndex = -1;
if (string2Int(attr, attrIndex)) apType = apIndex;
/* Evaluate the expression. */
Value vTmp;
state.autoCallFunction(autoArgs, v, vTmp);
v = vTmp;
state.forceValue(v);
/* It should evaluate to either an attribute set or an
expression, according to what is specified in the
attrPath. */
if (apType == apAttr) {
if (v.type != tAttrs)
throw TypeError(
format("the expression selected by the selection path `%1%' should be an attribute set but is %2%")
% curPath % showType(v));
Bindings::iterator a = v.attrs->find(state.symbols.create(attr));
if (a == v.attrs->end())
throw Error(format("attribute `%1%' in selection path `%2%' not found") % attr % curPath);
v = *a->value;
}
else if (apType == apIndex) {
if (v.type != tList)
throw TypeError(
format("the expression selected by the selection path `%1%' should be a list but is %2%")
% curPath % showType(v));
if (attrIndex >= v.list.length)
throw Error(format("list index %1% in selection path `%2%' is out of range") % attrIndex % curPath);
v = *v.list.elems[attrIndex];
}
}
}
}
| Java |
/*
* $Id$
*
Copyright (c) 2001 Stephane Conversy, Jean-Daniel Fekete and Ecole des
Mines de Nantes.
All rights reserved.
This software is proprietary information of Stephane Conversy,
Jean-Daniel Fekete and Ecole des Mines de Nantes. You shall use it
only in accordance with the terms of the license agreement you
accepted when downloading this software. The license is available in
the file license.txt and at the following URL:
http://www.emn.fr/info/image/Themes/Indigo/licence.html
*/
#include <w3c/svg/GetSVGDocument.hpp>
#include <w3c/svg/SVGColor.hpp>
#include <w3c/svg/SVGPaint.hpp>
#include <w3c/svg/SVGAngle.hpp>
#include <w3c/svg/SVGPoint.hpp>
#include <w3c/dom/DOMException.hpp>
namespace svg {
SVGDocument*
GetSVGDocument::getSVGDocument ( )
{
throw dom::DOMException(dom::DOMException::NOT_SUPPORTED_ERR);
return 0;
}
void
SVGColor::setRGBColor ( const DOMString& rgbColor )
{
throw dom::DOMException(dom::DOMException::NOT_SUPPORTED_ERR);
}
void
SVGColor::setRGBColorICCColor ( const DOMString& rgbColor, const DOMString& iccColor )
{
throw dom::DOMException(dom::DOMException::NOT_SUPPORTED_ERR);
}
void
SVGPaint::setUri ( const DOMString& uri )
{
throw dom::DOMException(dom::DOMException::NOT_SUPPORTED_ERR);
}
void
SVGPaint::setPaint ( unsigned short paintType, const DOMString& uri, const DOMString& rgbColor, const DOMString& iccColor )
{
throw dom::DOMException(dom::DOMException::NOT_SUPPORTED_ERR);
}
void
SVGAngle::newValueSpecifiedUnits ( unsigned short unitType, float valueInSpecifiedUnits )
{
throw dom::DOMException(dom::DOMException::NOT_SUPPORTED_ERR);
}
void
SVGAngle::convertToSpecifiedUnits ( unsigned short unitType )
{
throw dom::DOMException(dom::DOMException::NOT_SUPPORTED_ERR);
}
SVGPoint*
SVGPoint::matrixTransform ( const SVGMatrix& matrix )
{
throw dom::DOMException(dom::DOMException::NOT_SUPPORTED_ERR);
}
}
| Java |
/***************************************************************************
**
** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies).
** All rights reserved.
** Contact: Karoliina T. Salminen <karoliina.t.salminen@nokia.com>
**
** This file is part of duicontrolpanel.
**
**
** This library is free software; you can redistribute it and/or
** modify it under the terms of the GNU Lesser General Public
** License version 2.1 as published by the Free Software Foundation
** and appearing in the file LICENSE.LGPL included in the packaging
** of this file.
**
****************************************************************************/
#include <QObject>
#include <QGraphicsSceneMouseEvent>
#include <QSignalSpy>
#include <dcpwidget.h>
#include <dcpwidget_p.h>
#include "ut_dcpwidget.h"
void Ut_DcpWidget::init()
{
m_subject = new DcpWidget();
}
void Ut_DcpWidget::cleanup()
{
delete m_subject;
m_subject = 0;
}
void Ut_DcpWidget::initTestCase()
{
}
void Ut_DcpWidget::cleanupTestCase()
{
}
void Ut_DcpWidget::testCreation()
{
QVERIFY(m_subject);
}
void Ut_DcpWidget::testWidgetId()
{
QCOMPARE(m_subject->d_ptr->m_WidgetId, -1);
QVERIFY(m_subject->setWidgetId(1));
QCOMPARE(m_subject->d_ptr->m_WidgetId, 1);
QCOMPARE(m_subject->getWidgetId(), 1);
QVERIFY(!m_subject->setWidgetId(10)); // already set
}
void Ut_DcpWidget::testBack()
{
QVERIFY(m_subject->back()); // default behaviour
}
void Ut_DcpWidget::testPagePans()
{
QVERIFY(m_subject->pagePans()); // default behaviour
}
void Ut_DcpWidget::testProgressIndicator()
{
// default value:
QVERIFY(!m_subject->isProgressIndicatorVisible());
QSignalSpy spy (m_subject, SIGNAL(inProgress(bool)));
// show it:
m_subject->setProgressIndicatorVisible(true);
QVERIFY(m_subject->isProgressIndicatorVisible());
QCOMPARE(spy.count(), 1);
QVERIFY(spy.takeFirst().at(0).toBool());
// hide it:
m_subject->setProgressIndicatorVisible(false);
QVERIFY(!m_subject->isProgressIndicatorVisible());
QCOMPARE(spy.count(), 1);
QVERIFY(!spy.takeFirst().at(0).toBool());
}
QTEST_APPLESS_MAIN(Ut_DcpWidget)
| Java |
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<!-- NewPage -->
<html lang="it">
<head>
<!-- Generated by javadoc (version 1.7.0_03) on Tue Dec 09 10:54:57 CET 2014 -->
<title>Deprecated List (JADE 4.3.3 Sniffer Reference)</title>
<meta name="date" content="2014-12-09">
<link rel="stylesheet" type="text/css" href="stylesheet.css" title="Style">
</head>
<body>
<script type="text/javascript"><!--
if (location.href.indexOf('is-external=true') == -1) {
parent.document.title="Deprecated List (JADE 4.3.3 Sniffer Reference)";
}
//-->
</script>
<noscript>
<div>JavaScript is disabled on your browser.</div>
</noscript>
<!-- ========= START OF TOP NAVBAR ======= -->
<div class="topNav"><a name="navbar_top">
<!-- -->
</a><a href="#skip-navbar_top" title="Skip navigation links"></a><a name="navbar_top_firstrow">
<!-- -->
</a>
<ul class="navList" title="Navigation">
<li><a href="jade/tools/sniffer/package-summary.html">Package</a></li>
<li>Class</li>
<li><a href="jade/tools/sniffer/package-tree.html">Tree</a></li>
<li class="navBarCell1Rev">Deprecated</li>
<li><a href="index-all.html">Index</a></li>
<li><a href="help-doc.html">Help</a></li>
</ul>
</div>
<div class="subNav">
<ul class="navList">
<li>Prev</li>
<li>Next</li>
</ul>
<ul class="navList">
<li><a href="index.html?deprecated-list.html" target="_top">Frames</a></li>
<li><a href="deprecated-list.html" target="_top">No Frames</a></li>
</ul>
<ul class="navList" id="allclasses_navbar_top">
<li><a href="allclasses-noframe.html">All Classes</a></li>
</ul>
<div>
<script type="text/javascript"><!--
allClassesLink = document.getElementById("allclasses_navbar_top");
if(window==top) {
allClassesLink.style.display = "block";
}
else {
allClassesLink.style.display = "none";
}
//-->
</script>
</div>
<a name="skip-navbar_top">
<!-- -->
</a></div>
<!-- ========= END OF TOP NAVBAR ========= -->
<div class="header">
<h1 title="Deprecated API" class="title">Deprecated API</h1>
<h2 title="Contents">Contents</h2>
</div>
<!-- ======= START OF BOTTOM NAVBAR ====== -->
<div class="bottomNav"><a name="navbar_bottom">
<!-- -->
</a><a href="#skip-navbar_bottom" title="Skip navigation links"></a><a name="navbar_bottom_firstrow">
<!-- -->
</a>
<ul class="navList" title="Navigation">
<li><a href="jade/tools/sniffer/package-summary.html">Package</a></li>
<li>Class</li>
<li><a href="jade/tools/sniffer/package-tree.html">Tree</a></li>
<li class="navBarCell1Rev">Deprecated</li>
<li><a href="index-all.html">Index</a></li>
<li><a href="help-doc.html">Help</a></li>
</ul>
</div>
<div class="subNav">
<ul class="navList">
<li>Prev</li>
<li>Next</li>
</ul>
<ul class="navList">
<li><a href="index.html?deprecated-list.html" target="_top">Frames</a></li>
<li><a href="deprecated-list.html" target="_top">No Frames</a></li>
</ul>
<ul class="navList" id="allclasses_navbar_bottom">
<li><a href="allclasses-noframe.html">All Classes</a></li>
</ul>
<div>
<script type="text/javascript"><!--
allClassesLink = document.getElementById("allclasses_navbar_bottom");
if(window==top) {
allClassesLink.style.display = "block";
}
else {
allClassesLink.style.display = "none";
}
//-->
</script>
</div>
<a name="skip-navbar_bottom">
<!-- -->
</a></div>
<!-- ======== END OF BOTTOM NAVBAR ======= -->
</body>
</html>
| Java |
/***************************************************************************
**
** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies).
** All rights reserved.
** Contact: Nokia Corporation (directui@nokia.com)
**
** This file is part of libmeegotouch.
**
** If you have questions regarding the use of this file, please contact
** Nokia at directui@nokia.com.
**
** This library is free software; you can redistribute it and/or
** modify it under the terms of the GNU Lesser General Public
** License version 2.1 as published by the Free Software Foundation
** and appearing in the file LICENSE.LGPL included in the packaging
** of this file.
**
****************************************************************************/
#include <QObject>
#include <MApplication>
#include <MButton>
#include <QAction>
#include <QSignalSpy>
#include <mbasicsheetheader.h>
#include <mbasicsheetheaderview.h>
#include <mbasicsheetheaderview_p.h>
#include "ut_mbasicsheetheaderview.h"
Ut_MBasicSheetHeaderView::Ut_MBasicSheetHeaderView():
subject(0),
controller(0),
app(0)
{
}
void Ut_MBasicSheetHeaderView::initTestCase()
{
static int argc = 1;
static char *app_name[1] = { (char *) "./ut_mbasicsheetheaderview" };
app = new MApplication(argc, app_name);
}
void Ut_MBasicSheetHeaderView::cleanupTestCase()
{
delete app;
}
void Ut_MBasicSheetHeaderView::init()
{
controller = new MBasicSheetHeader();
subject = new MBasicSheetHeaderView(controller);
controller->setView(subject);
}
void Ut_MBasicSheetHeaderView::cleanup()
{
delete controller;
controller = 0;
}
void Ut_MBasicSheetHeaderView::testClickingPositiveButtonTriggersPositiveAction()
{
QAction *action = new QAction(controller);
controller->setPositiveAction(action);
testClickingButtonTriggersAction(subject->d_func()->positiveButton, action);
}
void Ut_MBasicSheetHeaderView::testClickingNegativeButtonTriggersNegativeAction()
{
QAction *action = new QAction(controller);
controller->setNegativeAction(action);
testClickingButtonTriggersAction(subject->d_func()->negativeButton, action);
}
void Ut_MBasicSheetHeaderView::testDisablingPositiveActionDisablesPositiveButton()
{
QAction *action = new QAction(controller);
controller->setPositiveAction(action);
testDisablingActionDisablesButton(action, subject->d_func()->positiveButton);
}
void Ut_MBasicSheetHeaderView::testDisablingNegativeActionDisablesNegativeButton()
{
QAction *action = new QAction(controller);
controller->setNegativeAction(action);
testDisablingActionDisablesButton(action, subject->d_func()->negativeButton);
}
void Ut_MBasicSheetHeaderView::testPositiveButtonTextUsesActionText()
{
QAction *action = new QAction("foo", controller);
controller->setPositiveAction(action);
QCOMPARE(subject->d_func()->positiveButton->text(), action->text());
}
void Ut_MBasicSheetHeaderView::testNegativeButtonTextUsesActionText()
{
QAction *action = new QAction("foo", controller);
controller->setNegativeAction(action);
QCOMPARE(subject->d_func()->negativeButton->text(), action->text());
}
/////
// Helpers
void Ut_MBasicSheetHeaderView::testClickingButtonTriggersAction(
MButton *button, QAction *action)
{
QSignalSpy spyActionTriggered(action, SIGNAL(triggered(bool)));
QVERIFY(button != 0);
QCOMPARE(spyActionTriggered.count(), 0);
button->click();
QCOMPARE(spyActionTriggered.count(), 1);
}
void Ut_MBasicSheetHeaderView::testDisablingActionDisablesButton(
QAction *action, MButton *button)
{
QVERIFY(button != 0);
QCOMPARE(button->isEnabled(), action->isEnabled());
action->setEnabled(false);
QCOMPARE(button->isEnabled(), action->isEnabled());
}
QTEST_APPLESS_MAIN(Ut_MBasicSheetHeaderView)
| Java |
// Copyright Benoit Blanchon 2014-2015
// MIT License
//
// Arduino JSON library
// https://github.com/bblanchon/ArduinoJson
#pragma once
#include "../Arduino/Print.hpp"
namespace ArduinoJson {
namespace Internals {
class Encoding {
public:
// Optimized for code size on a 8-bit AVR
static char escapeChar(char c) {
const char *p = _escapeTable;
while (p[0] && p[1] != c) {
p += 2;
}
return p[0];
}
// Optimized for code size on a 8-bit AVR
static char unescapeChar(char c) {
const char *p = _escapeTable + 4;
for (;;) {
if (p[0] == '\0') return c;
if (p[0] == c) return p[1];
p += 2;
}
}
private:
static const char _escapeTable[];
};
}
}
| Java |
//
// (c) Copyright 2017 DESY,ESS
// 2021 Eugen Wintersberger <eugen.wintersberger@gmail.com>
//
// This file is part of h5cpp.
//
// This library is free software; you can redistribute it and/or modify it
// under the terms of the GNU Lesser General Public License as published
// by the Free Software Foundation; either version 2.1 of the License, or
// (at your option) any later version.
//
// This library is distributed in the hope that it will be useful, but
// WITHOUT ANY WARRANTY; without even the implied warranty ofMERCHANTABILITY
// or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public
// License for more details.
//
// You should have received a copy of the GNU Lesser General Public License
// along with this library; if not, write to the
// Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor
// Boston, MA 02110-1301 USA
// ===========================================================================
//
// Author: Eugen Wintersberger <eugen.wintersberger@gmail.com>
// Created on: Oct 24, 2017
//
#include <catch2/catch.hpp>
#include <h5cpp/hdf5.hpp>
using namespace hdf5;
SCENARIO("testing bool IO") {
auto f = file::create("DatasetBoolIO.h5", file::AccessFlags::Truncate);
auto r = f.root();
auto type = hdf5::datatype::create<bool>();
hdf5::dataspace::Scalar space;
GIVEN("a dataset of type bool") {
auto d = node::Dataset(r, Path("data"), type, space);
THEN("we can write a boolean value to it") {
bool write = true;
REQUIRE_NOTHROW(d.write(write));
AND_THEN("we can read the value back") {
bool read = false;
REQUIRE_NOTHROW(d.read(read));
REQUIRE(read);
}
}
}
}
| Java |
#include <hildon/hildon.h>
#include <exempi/xmp.h>
#include <json-glib/json-glib.h>
#include <libintl.h>
#include <sharing-tag.h>
#include <locale.h>
#include <math.h>
#include <string.h>
#include <gst/gst.h>
#include "places.h"
#define SCHEMA_IPTC "http://iptc.org/std/Iptc4xmpCore/1.0/xmlns/"
#define SCHEMA_EXIF "http://ns.adobe.com/exif/1.0/"
#define SCHEMA_TIFF "http://ns.adobe.com/tiff/1.0/"
struct _FacebookSelectPlace
{
const gchar *file;
GSList *places;
gboolean thread_active;
gint orientation;
gint selected;
gboolean is_video;
};
typedef struct _FacebookSelectPlace FacebookSelectPlace;
struct _FacebookSearchData
{
gchar *location;
gdouble latitude;
gdouble longitude;
};
typedef struct _FacebookSearchData FacebookSearchData;
/*
* Seems like Nokia use dd,mm.mm format to encode GPS coordinates, at least on
* N900 and N950.
*/
static inline gdouble
convert2deg_dm(const gchar *d, const gchar *m, const gchar *mm)
{
return
(gdouble)atoi(d) +
((gdouble)atoi(m)) / 60.0 +
((gdouble)atoi(mm)) / (60.0 * pow(10, strlen(mm)));
}
static gdouble
deg2dec(const gchar *s, gboolean *ok)
{
gchar **v = g_strsplit_set(s, ",.", 3);
gdouble rv = 0;
if(v[0] && v[1] && v[2])
{
gchar *ref = &v[2][strlen(v[2]) - 1];
switch (*ref)
{
case 'E':
case 'N':
*ref = '\0';
rv = convert2deg_dm(v[0], v[1], v[2]);
*ok = TRUE;
break;
case 'S':
case 'W':
*ref = '\0';
rv = 0.0 - convert2deg_dm(v[0], v[1], v[2]);
*ok = TRUE;
break;
default:
*ok = FALSE;
}
}
else
*ok = FALSE;
g_strfreev(v);
return rv;
}
static int
select_place_thread(FacebookSelectPlace *select)
{
GtkWidget *selector, *dialog, *image = NULL, *picker, *align;
GdkPixbuf *pixbuf, *newpixbuf;
gint i;
gchar *s;
gdk_threads_enter();
selector = hildon_touch_selector_new_text();
hildon_touch_selector_set_column_selection_mode(
HILDON_TOUCH_SELECTOR(selector),
HILDON_TOUCH_SELECTOR_SELECTION_MODE_SINGLE);
for (i = 0; i < g_slist_length(select->places); i ++)
{
hildon_touch_selector_append_text(HILDON_TOUCH_SELECTOR(selector),
g_slist_nth_data(select->places, i));
}
s = g_strdup_printf("%s Facebook %s",
dgettext("osso-connectivity-ui", "conn_bd_dialog_ok"),
dgettext("gtk20","Location"));
dialog = gtk_dialog_new_with_buttons(s, NULL,
GTK_DIALOG_NO_SEPARATOR |
GTK_DIALOG_DESTROY_WITH_PARENT |
GTK_DIALOG_MODAL,
dgettext("hildon-libs", "wdgt_bd_done"),
GTK_RESPONSE_OK,
NULL);
g_free(s);
picker = hildon_picker_button_new(HILDON_SIZE_FINGER_HEIGHT,
HILDON_BUTTON_ARRANGEMENT_VERTICAL);
hildon_picker_button_set_selector(HILDON_PICKER_BUTTON(picker),
HILDON_TOUCH_SELECTOR(selector));
hildon_button_set_title(HILDON_BUTTON(picker),
dgettext("gtk20","Location"));
hildon_picker_button_set_active(HILDON_PICKER_BUTTON(picker), 0);
hildon_button_set_alignment(HILDON_BUTTON(picker), 0.0, 0.5, 1.0, 0.0);
align = gtk_alignment_new(0, 0, 0, 0);
gtk_alignment_set_padding(GTK_ALIGNMENT(align), 8, 8, 8, 8);
if (!select->is_video)
{
pixbuf =
gdk_pixbuf_new_from_file_at_scale(select->file, 128, 128, TRUE, NULL);
if (pixbuf)
{
/*
* FIXME - we may need to flip as well, unfortunately I have no images
* to test with, so better leave it that way.
*/
newpixbuf =
gdk_pixbuf_rotate_simple(pixbuf,
360 - (select->orientation % 4 - 1) * 90);
g_object_unref(pixbuf);
pixbuf = newpixbuf;
}
}
else
{
pixbuf = gtk_icon_theme_load_icon(gtk_icon_theme_get_default (),
"video-x-generic", 128,
GTK_ICON_LOOKUP_FORCE_SIZE, NULL);
}
if (pixbuf)
{
image = gtk_image_new_from_pixbuf(pixbuf);
g_object_unref(pixbuf);
}
if (image)
gtk_container_add(GTK_CONTAINER(align), image);
gtk_box_pack_start(GTK_BOX(GTK_DIALOG(dialog)->vbox), align, TRUE, TRUE, 0);
gtk_box_pack_start(GTK_BOX(GTK_DIALOG(dialog)->vbox), picker, TRUE, TRUE, 0);
gtk_widget_show_all(dialog);
if (gtk_dialog_run(GTK_DIALOG(dialog)) == GTK_RESPONSE_OK)
{
select->selected =
hildon_picker_button_get_active(HILDON_PICKER_BUTTON(picker));
}
gtk_widget_destroy (GTK_WIDGET(dialog));
gdk_threads_leave();
select->thread_active = FALSE;
return FALSE;
}
static gint
select_place_id(const gchar *file, GSList *places, gint orientation,
gboolean is_video)
{
FacebookSelectPlace select;
DEBUG_LOG(__func__);
select.thread_active = TRUE;
select.file = file;
select.selected = -1;
select.places = places;
select.orientation = orientation;
select.is_video = is_video;
g_thread_create_full((GThreadFunc)select_place_thread, &select, 0, FALSE,
FALSE, G_THREAD_PRIORITY_NORMAL, NULL);
while (select.thread_active)
{
while (g_main_context_pending(NULL))
g_main_context_iteration(NULL, TRUE);
}
return select.selected;
}
static gchar *
get_place_id(facebook_graph_request *request, const gchar *access_token,
const gchar *path, ConIcConnection *con,
const FacebookSearchData *data, gboolean is_video,
gint orientation)
{
gchar *rv = NULL;
DEBUG_LOG(__func__);
if (data->location && data->latitude != NAN && data->longitude != NAN)
{
GString *url;
int http_result;
GArray *response = g_array_new(1, 1, 1);
facebook_graph_request_reset(request);
g_hash_table_insert(request->query_params, "q",
g_strdup(data->location));
g_hash_table_insert(request->query_params, "type",
g_strdup("place"));
{
locale_t loc = newlocale(LC_NUMERIC_MASK, "C", (locale_t)0);
locale_t old = uselocale(loc);
g_hash_table_insert(request->query_params, "center",
g_strdup_printf("%f,%f",
data->latitude,
data->longitude));
uselocale(old);
freelocale(loc);
}
g_hash_table_insert(request->query_params, "distance",
g_strdup("50000"));
g_hash_table_insert(request->query_params, "fields",
g_strdup("id,name"));
g_hash_table_insert(request->query_params, "limit",
g_strdup("128")); /* why not? */
g_hash_table_insert(request->query_params, "access_token",
g_strdup(access_token));
url = g_string_new("https://graph.facebook.com/search");
http_result = network_utils_get(url, response, NULL,
request->query_params, con, NULL);
g_string_free(url, FALSE);
if (http_result == 200)
{
JsonParser *parser = json_parser_new();
if (json_parser_load_from_data(parser, response->data,
response->len, NULL))
{
JsonNode *root = json_parser_get_root(parser);
JsonObject *object;
if (root && JSON_NODE_HOLDS_OBJECT(root) &&
(object = json_node_get_object(root)) &&
json_object_has_member(object, "data"))
{
JsonArray *data = json_object_get_array_member(object, "data");
guint len = json_array_get_length(data);
gint i;
GSList *l = NULL;
for (i = 0; i < len; i ++)
{
object = json_array_get_object_element(data, i);
if (object)
l = g_slist_append(
l,
(gpointer)json_object_get_string_member(object,
"name"));
}
i = select_place_id(path, l, orientation, is_video);
g_slist_free(l);
if (i >= 0)
{
rv = (gchar *)json_object_get_string_member(
json_array_get_object_element(data, i), "id");
}
if (rv)
rv = g_strdup(rv);
}
g_object_unref(parser);
}
}
g_array_free(response, TRUE);
}
return rv;
}
static gchar *
get_photo_place_id(const SharingEntryMedia *entry,
facebook_graph_request *request, const gchar *access_token,
const gchar *path, ConIcConnection *con)
{
XmpPtr xmp;
XmpFilePtr fp;
FacebookSearchData data = {NULL, NAN, NAN};
guint orientation = 1;
gchar *rv;
gboolean ok;
DEBUG_LOG(__func__);
xmp_init();
if (!(xmp = xmp_new_empty()))
return NULL;
if (!(fp = xmp_files_open_new(path, (XmpOpenFileOptions)(XMP_OPEN_READ |
XMP_OPEN_ONLYXMP))))
{
xmp_free(xmp);
return NULL;
}
if (xmp_files_get_xmp(fp, xmp))
{
XmpStringPtr value = xmp_string_new();
if (xmp_get_property(xmp, SCHEMA_IPTC, "Iptc4xmpCore:location", value,
NULL) ||
xmp_get_property(xmp, SCHEMA_IPTC, "Iptc4xmpCore:Location", value,
NULL))
data.location = g_strdup(xmp_string_cstr(value));
if (xmp_get_property(xmp, SCHEMA_EXIF, "exif:GPSLatitude", value, NULL))
{
data.latitude = deg2dec(g_strdup(xmp_string_cstr(value)), &ok);
if (!ok)
goto error;
}
if (xmp_get_property(xmp, SCHEMA_EXIF, "exif:GPSLongitude", value, NULL))
{
data.longitude = deg2dec(g_strdup(xmp_string_cstr(value)), &ok);
if (!ok)
goto error;
}
if (xmp_get_property(xmp, SCHEMA_TIFF, "tiff:Orientation", value, NULL))
orientation = atoi(xmp_string_cstr(value));
error:
xmp_string_free(value);
}
rv =
get_place_id(request, access_token, path, con, &data, FALSE, orientation);
g_free(data.location);
xmp_free(xmp);
xmp_terminate();
return rv;
}
static void
sharing_tag_f(gpointer data, gpointer user_data)
{
const SharingTag *tag = (const SharingTag *)data;
switch (sharing_tag_get_type(tag))
{
case SHARING_TAG_GEO_SUBURB:
((FacebookSearchData *)user_data)->location =
(gchar *)sharing_tag_get_word(tag);
break;
default:
break;
}
}
static void
read_one_tag(const GstTagList *list, const gchar *tag, gpointer user_data)
{
FacebookSearchData *data = user_data;
int n = gst_tag_list_get_tag_size(list, tag);
if (!g_strcmp0(tag, "geo-location-latitude") && n == 1)
data->latitude = g_value_get_double(
gst_tag_list_get_value_index(list, tag, 0));
if (!g_strcmp0(tag, "geo-location-longitude") && n == 1)
data->longitude = g_value_get_double(
gst_tag_list_get_value_index(list, tag, 1));
}
static void
on_new_pad(GstElement *dec, GstPad *pad, GstElement *fakesink)
{
GstPad *sinkpad;
sinkpad = gst_element_get_static_pad (fakesink, "sink");
if (!gst_pad_is_linked (sinkpad))
gst_pad_link(pad, sinkpad);
gst_object_unref (sinkpad);
}
static void
gst_get_gps_coord(const gchar *path, FacebookSearchData *data)
{
GstElement *pipe, *dec, *sink;
GstMessage *msg;
gchar *uri = g_strdup_printf("file://%s", path);
gst_init(NULL, NULL);
pipe = gst_pipeline_new("pipeline");
dec = gst_element_factory_make("uridecodebin", NULL);
g_object_set(dec, "uri", uri, NULL);
g_free(uri);
gst_bin_add(GST_BIN (pipe), dec);
sink = gst_element_factory_make("fakesink", NULL);
gst_bin_add(GST_BIN (pipe), sink);
g_signal_connect(dec, "pad-added", G_CALLBACK (on_new_pad), sink);
gst_element_set_state(pipe, GST_STATE_PAUSED);
while (TRUE)
{
GstTagList *tags = NULL;
msg = gst_bus_timed_pop_filtered(GST_ELEMENT_BUS (pipe),
GST_CLOCK_TIME_NONE,
GST_MESSAGE_ASYNC_DONE |
GST_MESSAGE_TAG | GST_MESSAGE_ERROR);
if (GST_MESSAGE_TYPE(msg) != GST_MESSAGE_TAG)
{
gst_message_unref(msg);
break;
}
gst_message_parse_tag(msg, &tags);
gst_tag_list_foreach(tags, read_one_tag, data);
gst_tag_list_free(tags);
gst_message_unref(msg);
};
gst_element_set_state(pipe, GST_STATE_NULL);
gst_object_unref(pipe);
}
static gchar *
get_video_place_id(const SharingEntryMedia *entry,
facebook_graph_request *request, const gchar *access_token,
const gchar *path, ConIcConnection *con)
{
FacebookSearchData data ={NULL, NAN, NAN};
gchar *rv = NULL;
GSList *tags = (GSList *)sharing_entry_media_get_tags(entry);
/* Try to get suburb */
g_slist_foreach(tags, sharing_tag_f, &data);
if (!data.location)
return NULL;
gst_get_gps_coord(path, &data);
if (!data.latitude == 0.0 || data.longitude == 0.0)
return NULL;
rv = get_place_id(request, access_token, path, con, &data, TRUE, 0);
return rv;
}
gchar *
fb_sharing_plugin_get_place_id(const SharingEntryMedia *media,
facebook_graph_request *request,
const gchar *access_token, const gchar *path,
ConIcConnection *con, gboolean is_video)
{
if (!is_video)
return
get_photo_place_id(media, request, access_token, path, con);
else
return
get_video_place_id(media, request, access_token, path, con);
}
| Java |
/**********************************************************************
* $Id: WKBReader.cpp 2022 2007-09-14 15:25:29Z csavage $
*
* GEOS - Geometry Engine Open Source
* http://geos.refractions.net
*
* Copyright (C) 2005-2006 Refractions Research Inc.
*
* This is free software; you can redistribute and/or modify it under
* the terms of the GNU Lesser General Public Licence as published
* by the Free Software Foundation.
* See the COPYING file for more information.
*
**********************************************************************/
#include <geos/io/WKBReader.h>
#include <geos/io/WKBConstants.h>
#include <geos/io/ByteOrderValues.h>
#include <geos/io/ParseException.h>
#include <geos/geom/GeometryFactory.h>
#include <geos/geom/Coordinate.h>
#include <geos/geom/Point.h>
#include <geos/geom/LinearRing.h>
#include <geos/geom/LineString.h>
#include <geos/geom/Polygon.h>
#include <geos/geom/MultiPoint.h>
#include <geos/geom/MultiLineString.h>
#include <geos/geom/MultiPolygon.h>
#include <geos/geom/CoordinateSequenceFactory.h>
#include <geos/geom/CoordinateSequence.h>
#include <geos/geom/PrecisionModel.h>
#include <iomanip>
#include <ostream>
#include <sstream>
#include <string>
//#define DEBUG_WKB_READER 1
using namespace std;
using namespace geos::geom;
namespace geos {
namespace io { // geos.io
string WKBReader::BAD_GEOM_TYPE_MSG = "bad geometry type encountered in ";
WKBReader::WKBReader()
:
factory(*(GeometryFactory::getDefaultInstance()))
{}
ostream &
WKBReader::printHEX(istream &is, ostream &os)
{
static const char hex[] = "0123456789ABCDEF";
long pos = is.tellg(); // take note of input stream get pointer
is.seekg(0, ios::beg); // rewind input stream
char each=0;
while(is.read(&each, 1))
{
const unsigned char c=each;
int low = (c & 0x0F);
int high = (c >> 4);
os << hex[high] << hex[low];
}
is.clear(); // clear input stream eof flag
is.seekg(pos); // reset input stream position
return os;
}
Geometry *
WKBReader::readHEX(istream &is)
{
// setup input/output stream
stringstream os(ios_base::binary|ios_base::in|ios_base::out);
unsigned char high, low, result_high, result_low, value;
while(!is.eof())//readsome(&str[0], 2))
{
// get the high part of the byte
is >> high;
// geth the low part of the byte
is >> low;
switch (high)
{
case '0' :
result_high = 0;
break;
case '1' :
result_high = 1;
break;
case '2' :
result_high = 2;
break;
case '3' :
result_high = 3;
break;
case '4' :
result_high = 4;
break;
case '5' :
result_high = 5;
break;
case '6' :
result_high = 6;
break;
case '7' :
result_high = 7;
break;
case '8' :
result_high = 8;
break;
case '9' :
result_high = 9;
break;
case 'A' :
result_high = 10;
break;
case 'B' :
result_high = 11;
break;
case 'C' :
result_high = 12;
break;
case 'D' :
result_high = 13;
break;
case 'E' :
result_high = 14;
break;
case 'F' :
result_high = 15;
break;
default:
throw ParseException("Invalid HEX char");
}
switch (low)
{
case '0' :
result_low = 0;
break;
case '1' :
result_low = 1;
break;
case '2' :
result_low = 2;
break;
case '3' :
result_low = 3;
break;
case '4' :
result_low = 4;
break;
case '5' :
result_low = 5;
break;
case '6' :
result_low = 6;
break;
case '7' :
result_low = 7;
break;
case '8' :
result_low = 8;
break;
case '9' :
result_low = 9;
break;
case 'A' :
result_low = 10;
break;
case 'B' :
result_low = 11;
break;
case 'C' :
result_low = 12;
break;
case 'D' :
result_low = 13;
break;
case 'E' :
result_low = 14;
break;
case 'F' :
result_low = 15;
break;
default:
throw ParseException("Invalid HEX char");
}
value = (result_high<<4) + result_low;
#if DEBUG_HEX_READER
cout<<"HEX "<<high<<low<<" -> DEC "<<(int)value<<endl;
#endif
// write the value to the output stream
os << value;
}
// now call read to convert the geometry
return this->read(os);
}
Geometry *
WKBReader::read(istream &is)
{
dis.setInStream(&is); // will default to machine endian
return readGeometry();
}
Geometry *
WKBReader::readGeometry()
{
// determine byte order
unsigned char byteOrder = dis.readByte();
#if DEBUG_WKB_READER
cout<<"WKB byteOrder: "<<(int)byteOrder<<endl;
#endif
// default is machine endian
if (byteOrder == WKBConstants::wkbNDR)
dis.setOrder(ByteOrderValues::ENDIAN_LITTLE);
else if (byteOrder == WKBConstants::wkbXDR)
dis.setOrder(ByteOrderValues::ENDIAN_BIG);
int typeInt = dis.readInt();
int geometryType = typeInt & 0xff;
#if DEBUG_WKB_READER
cout<<"WKB geometryType: "<<geometryType<<endl;
#endif
bool hasZ = ((typeInt & 0x80000000) != 0);
if (hasZ) inputDimension = 3;
else inputDimension = 2; // doesn't handle M currently
#if DEBUG_WKB_READER
cout<<"WKB hasZ: "<<hasZ<<endl;
#endif
#if DEBUG_WKB_READER
cout<<"WKB dimensions: "<<inputDimension<<endl;
#endif
bool hasSRID = ((typeInt & 0x20000000) != 0);
#if DEBUG_WKB_READER
cout<<"WKB hasSRID: "<<hasZ<<endl;
#endif
int SRID = 0;
if (hasSRID) SRID = dis.readInt(); // read SRID
// allocate space for ordValues
if ( ordValues.size() < inputDimension )
ordValues.resize(inputDimension);
Geometry *result;
switch (geometryType) {
case WKBConstants::wkbPoint :
result = readPoint();
break;
case WKBConstants::wkbLineString :
result = readLineString();
break;
case WKBConstants::wkbPolygon :
result = readPolygon();
break;
case WKBConstants::wkbMultiPoint :
result = readMultiPoint();
break;
case WKBConstants::wkbMultiLineString :
result = readMultiLineString();
break;
case WKBConstants::wkbMultiPolygon :
result = readMultiPolygon();
break;
case WKBConstants::wkbGeometryCollection :
result = readGeometryCollection();
break;
default:
stringstream err;
err << "Unknown WKB type " << geometryType;
throw ParseException(err.str());
}
result->setSRID(SRID);
return result;
}
Point *
WKBReader::readPoint()
{
readCoordinate();
return factory.createPoint(Coordinate(ordValues[0], ordValues[1]));
}
LineString *
WKBReader::readLineString()
{
int size = dis.readInt();
#if DEBUG_WKB_READER
cout<<"WKB npoints: "<<size<<endl;
#endif
CoordinateSequence *pts = readCoordinateSequence(size);
return factory.createLineString(pts);
}
LinearRing *
WKBReader::readLinearRing()
{
int size = dis.readInt();
#if DEBUG_WKB_READER
cout<<"WKB npoints: "<<size<<endl;
#endif
CoordinateSequence *pts = readCoordinateSequence(size);
return factory.createLinearRing(pts);
}
Polygon *
WKBReader::readPolygon()
{
int numRings = dis.readInt();
#if DEBUG_WKB_READER
cout<<"WKB numRings: "<<numRings<<endl;
#endif
LinearRing *shell = NULL;
if( numRings > 0 )
shell = readLinearRing();
vector<Geometry *>*holes=NULL;
if ( numRings > 1 )
{
try {
holes = new vector<Geometry *>(numRings-1);
for (int i=0; i<numRings-1; i++)
(*holes)[i] = (Geometry *)readLinearRing();
} catch (...) {
for (unsigned int i=0; i<holes->size(); i++)
delete (*holes)[i];
delete holes;
delete shell;
throw;
}
}
return factory.createPolygon(shell, holes);
}
MultiPoint *
WKBReader::readMultiPoint()
{
int numGeoms = dis.readInt();
vector<Geometry *> *geoms = new vector<Geometry *>(numGeoms);
try {
for (int i=0; i<numGeoms; i++)
{
Geometry *g = readGeometry();
if (!dynamic_cast<Point *>(g))
{
stringstream err;
err << BAD_GEOM_TYPE_MSG << " MultiPoint";
throw ParseException(err.str());
}
(*geoms)[i] = g;
}
} catch (...) {
for (unsigned int i=0; i<geoms->size(); i++)
delete (*geoms)[i];
delete geoms;
throw;
}
return factory.createMultiPoint(geoms);
}
MultiLineString *
WKBReader::readMultiLineString()
{
int numGeoms = dis.readInt();
vector<Geometry *> *geoms = new vector<Geometry *>(numGeoms);
try {
for (int i=0; i<numGeoms; i++)
{
Geometry *g = readGeometry();
if (!dynamic_cast<LineString *>(g))
{
stringstream err;
err << BAD_GEOM_TYPE_MSG << " LineString";
throw ParseException(err.str());
}
(*geoms)[i] = g;
}
} catch (...) {
for (unsigned int i=0; i<geoms->size(); i++)
delete (*geoms)[i];
delete geoms;
throw;
}
return factory.createMultiLineString(geoms);
}
MultiPolygon *
WKBReader::readMultiPolygon()
{
int numGeoms = dis.readInt();
vector<Geometry *> *geoms = new vector<Geometry *>(numGeoms);
try {
for (int i=0; i<numGeoms; i++)
{
Geometry *g = readGeometry();
if (!dynamic_cast<Polygon *>(g))
{
stringstream err;
err << BAD_GEOM_TYPE_MSG << " Polygon";
throw ParseException(err.str());
}
(*geoms)[i] = g;
}
} catch (...) {
for (unsigned int i=0; i<geoms->size(); i++)
delete (*geoms)[i];
delete geoms;
throw;
}
return factory.createMultiPolygon(geoms);
}
GeometryCollection *
WKBReader::readGeometryCollection()
{
int numGeoms = dis.readInt();
vector<Geometry *> *geoms = new vector<Geometry *>(numGeoms);
try {
for (int i=0; i<numGeoms; i++)
(*geoms)[i] = (readGeometry());
} catch (...) {
for (unsigned int i=0; i<geoms->size(); i++)
delete (*geoms)[i];
delete geoms;
throw;
}
return factory.createGeometryCollection(geoms);
}
CoordinateSequence *
WKBReader::readCoordinateSequence(int size)
{
CoordinateSequence *seq = factory.getCoordinateSequenceFactory()->create(size, inputDimension);
unsigned int targetDim = seq->getDimension();
if ( targetDim > inputDimension )
targetDim = inputDimension;
for (int i=0; i<size; i++) {
readCoordinate();
for (unsigned int j=0; j<targetDim; j++) {
seq->setOrdinate(i, j, ordValues[j]);
}
}
return seq;
}
void
WKBReader::readCoordinate()
{
const PrecisionModel &pm = *factory.getPrecisionModel();
for (unsigned int i=0; i<inputDimension; ++i)
{
if ( i <= 1 ) ordValues[i] = pm.makePrecise(dis.readDouble());
else ordValues[i] = dis.readDouble();
}
#if DEBUG_WKB_READER
cout<<"WKB coordinate: "<<ordValues[0]<<","<<ordValues[1]<<endl;
#endif
}
} // namespace geos.io
} // namespace geos
| Java |
package fr.toss.FF7Weapons;
import net.minecraft.entity.SharedMonsterAttributes;
import net.minecraft.entity.ai.attributes.AttributeModifier;
import net.minecraft.item.Item;
import com.google.common.collect.Multimap;
public class Druidmace extends FF7weapon
{
private float field_150934_a;
private final Item.ToolMaterial field_150933_b;
public Druidmace(Item.ToolMaterial p_i45356_1_)
{
super();
this.field_150933_b = p_i45356_1_;
setUnlocalizedName("Druid_mace");
this.field_150934_a = 26F + p_i45356_1_.getDamageVsEntity();
}
public float func_150931_i()
{
return this.field_150933_b.getDamageVsEntity();
}
public String getToolMaterialName()
{
return this.field_150933_b.toString();
}
public Multimap getItemAttributeModifiers()
{
Multimap multimap = super.getItemAttributeModifiers();
multimap.put(SharedMonsterAttributes.attackDamage.getAttributeUnlocalizedName(), new AttributeModifier(field_111210_e, "Weapon modifier", (double)this.field_150934_a, 0));
return multimap;
}
}
| Java |
/*
* Jitsi, the OpenSource Java VoIP and Instant Messaging client.
*
* Distributable under LGPL license.
* See terms of license at gnu.org.
*/
package net.java.sip.communicator.impl.protocol.sip;
import gov.nist.core.*;
import gov.nist.javax.sip.*;
import gov.nist.javax.sip.message.*;
import java.io.*;
import java.net.*;
import java.util.*;
import javax.sip.*;
import net.java.sip.communicator.util.*;
import org.jitsi.service.packetlogging.*;
/**
* This class passes log calls from JAIN-SIP to log4j, so that it is possible
* to change the log level for the JAIN-SIP stack in logging.properties
*
* @author Sebastien Mazy
*/
public class SipLogger
implements StackLogger,
ServerLogger
{
/**
* All messages will be passed to this logger.
*/
private static final Logger logger
= Logger.getLogger(SipLogger.class);
/**
* SipStack to use.
*/
private SipStack sipStack;
/*
* Implementation of StackLogger
*/
/**
* logs a stack trace. This helps to look at the stack frame.
*/
public void logStackTrace()
{
if (logger.isTraceEnabled())
logger.trace("JAIN-SIP stack trace", new Throwable());
}
/**
* logs a stack trace. This helps to look at the stack frame.
*
* @param traceLevel currently unused.
*/
public void logStackTrace(int traceLevel)
{
if (logger.isTraceEnabled())
logger.trace("JAIN-SIP stack trace", new Throwable());
}
/**
* Get the line count in the log stream.
*
* @return line count
*/
public int getLineCount()
{
return 0;
}
/**
* Log an exception.
*
* @param ex the exception that we are to log.
*/
public void logException(Throwable ex)
{
logger.warn("Exception in the JAIN-SIP stack: " + ex.getMessage());
if (logger.isInfoEnabled())
logger.info("JAIN-SIP exception stack trace is", ex);
}
/**
* Log a message into the log file.
*
* @param message
* message to log into the log file.
*/
public void logDebug(String message)
{
if (logger.isDebugEnabled())
logger.debug("Debug output from the JAIN-SIP stack: " + message);
}
/**
* Log an error message.
*
* @param message --
* error message to log.
*/
public void logFatalError(String message)
{
if (logger.isTraceEnabled())
logger.trace("Fatal error from the JAIN-SIP stack: " + message);
}
/**
* Log an error message.
*
* @param message error message to log.
*/
public void logError(String message)
{
logger.error("Error from the JAIN-SIP stack: " + message);
}
/**
* Determines whether logging is enabled.
*
* @return flag to indicate if logging is enabled.
*/
public boolean isLoggingEnabled()
{
return true;
}
/**
* Return true/false if logging is enabled at a given level.
*
* @param logLevel the level that we'd like to check loggability for.
*
* @return always <tt>true</tt> regardless of <tt>logLevel</tt>'s value.
*/
public boolean isLoggingEnabled(int logLevel)
{
// always enable trace messages so we can receive packets
// and log them to packet logging service
if (logLevel == TRACE_DEBUG)
return logger.isDebugEnabled();
if (logLevel == TRACE_MESSAGES) // same as TRACE_INFO
return true;
if (logLevel == TRACE_NONE)
return false;
return true;
}
/**
* Logs an exception and an error message error message.
*
* @param message that message that we'd like to log.
* @param ex the exception that we'd like to log.
*/
public void logError(String message, Exception ex)
{
logger.error("Error from the JAIN-SIP stack: " + message, ex);
}
/**
* Log a warning message.
*
* @param string the warning that we'd like to log
*/
public void logWarning(String string)
{
logger.warn("Warning from the JAIN-SIP stack" + string);
}
/**
* Log an info message.
*
* @param string the message that we'd like to log.
*/
public void logInfo(String string)
{
if (logger.isInfoEnabled())
logger.info("Info from the JAIN-SIP stack: " + string);
}
/**
* Disable logging altogether.
*
*/
public void disableLogging() {}
/**
* Enable logging (globally).
*/
public void enableLogging() {}
/**
* Logs the build time stamp of the jain-sip reference implementation.
*
* @param buildTimeStamp the build time stamp of the jain-sip reference
* implementation.
*/
public void setBuildTimeStamp(String buildTimeStamp)
{
if (logger.isTraceEnabled())
logger.trace("JAIN-SIP RI build " + buildTimeStamp);
}
/**
* Dummy implementation for {@link ServerLogger#setStackProperties(
* Properties)}
*/
public void setStackProperties(Properties stackProperties) {}
/**
* Dummy implementation for {@link ServerLogger#closeLogFile()}
*/
public void closeLogFile() {}
/**
* Logs the specified message and details.
*
* @param message the message to log
* @param from the message sender
* @param to the message addressee
* @param sender determines whether we are the origin of this message.
* @param time the date this message was received at.
*/
public void logMessage(SIPMessage message, String from, String to,
boolean sender, long time)
{
logMessage(message, from, to, null, sender, time);
}
/**
* Logs the specified message and details.
*
* @param message the message to log
* @param from the message sender
* @param to the message addressee
* @param status message status
* @param sender determines whether we are the origin of this message.
* @param time the date this message was received at.
*/
public void logMessage(SIPMessage message, String from, String to,
String status, boolean sender, long time)
{
try
{
logPacket(message, sender);
}
catch(Throwable e)
{
logger.error("Error logging packet", e);
}
}
/**
* Logs the specified message and details to the packet logging service
* if enabled.
*
* @param message the message to log
* @param sender determines whether we are the origin of this message.
*/
private void logPacket(SIPMessage message, boolean sender)
{
try
{
PacketLoggingService packetLogging = SipActivator.getPacketLogging();
if( packetLogging == null
|| !packetLogging.isLoggingEnabled(
PacketLoggingService.ProtocolName.SIP)
/* Via not present in CRLF packet on TCP - causes NPE */
|| message.getTopmostVia() == null )
return;
String transport = message.getTopmostVia().getTransport();
boolean isTransportUDP = transport.equalsIgnoreCase("UDP");
byte[] srcAddr;
int srcPort;
byte[] dstAddr;
int dstPort;
// if addresses are not set use empty byte array with length
// equals to the other address or just empty
// byte array with length 4 (ipv4 0.0.0.0)
if(sender)
{
if(!isTransportUDP)
{
InetSocketAddress localAddress =
getLocalAddressForDestination(
message.getRemoteAddress(),
message.getRemotePort(),
message.getLocalAddress(),
transport);
if (localAddress != null)
{
srcPort = localAddress.getPort();
srcAddr = localAddress.getAddress().getAddress();
}
else
{
logger.warn("Could not obtain source address for "
+ " packet. Writing source as 0.0.0.0:0");
srcPort = 0;
srcAddr = new byte[] { 0, 0, 0, 0 };
}
}
else
{
srcPort = message.getLocalPort();
if(message.getLocalAddress() != null)
srcAddr = message.getLocalAddress().getAddress();
else if(message.getRemoteAddress() != null)
srcAddr = new byte[
message.getRemoteAddress().getAddress().length];
else
srcAddr = new byte[4];
}
dstPort = message.getRemotePort();
if(message.getRemoteAddress() != null)
dstAddr = message.getRemoteAddress().getAddress();
else
dstAddr = new byte[srcAddr.length];
}
else
{
if(!isTransportUDP)
{
InetSocketAddress dstAddress =
getLocalAddressForDestination(
message.getRemoteAddress(),
message.getRemotePort(),
message.getLocalAddress(),
transport);
dstPort = dstAddress.getPort();
dstAddr = dstAddress.getAddress().getAddress();
}
else
{
dstPort = message.getLocalPort();
if(message.getLocalAddress() != null)
dstAddr = message.getLocalAddress().getAddress();
else if(message.getRemoteAddress() != null)
dstAddr = new byte[
message.getRemoteAddress().getAddress().length];
else
dstAddr = new byte[4];
}
srcPort = message.getRemotePort();
if(message.getRemoteAddress() != null)
srcAddr = message.getRemoteAddress().getAddress();
else
srcAddr = new byte[dstAddr.length];
}
byte[] msg = null;
if(message instanceof SIPRequest)
{
SIPRequest req = (SIPRequest)message;
if(req.getMethod().equals(SIPRequest.MESSAGE)
&& message.getContentTypeHeader() != null
&& message.getContentTypeHeader()
.getContentType().equalsIgnoreCase("text"))
{
int len = req.getContentLength().getContentLength();
if(len > 0)
{
SIPRequest newReq = (SIPRequest)req.clone();
byte[] newContent = new byte[len];
Arrays.fill(newContent, (byte)'.');
newReq.setMessageContent(newContent);
msg = newReq.toString().getBytes("UTF-8");
}
}
}
if(msg == null)
{
msg = message.toString().getBytes("UTF-8");
}
packetLogging.logPacket(
PacketLoggingService.ProtocolName.SIP,
srcAddr, srcPort,
dstAddr, dstPort,
isTransportUDP ? PacketLoggingService.TransportName.UDP :
PacketLoggingService.TransportName.TCP,
sender, msg);
}
catch(Throwable e)
{
logger.error("Cannot obtain message body", e);
}
}
/**
* Logs the specified message and details.
*
* @param message the message to log
* @param from the message sender
* @param to the message addressee
* @param status message status
* @param sender determines whether we are the origin of this message.
*/
public void logMessage(SIPMessage message, String from, String to,
String status, boolean sender)
{
if (!logger.isInfoEnabled())
return;
String msgHeader;
if(sender)
msgHeader = "JAIN-SIP sent a message from=\"";
else
msgHeader = "JAIN-SIP received a message from=\"";
if (logger.isInfoEnabled())
logger.info(msgHeader + from + "\" to=\"" + to + "\" (status: "
+ status + "):\n" + message);
}
/**
* Prints the specified <tt>exception</tt> as a warning.
*
* @param exception the <tt>Exception</tt> we are passed from jain-sip.
*/
public void logException(Exception exception)
{
logger.warn("the following exception occured in JAIN-SIP: "
+ exception, exception);
}
/**
* A dummy implementation.
*
* @param sipStack ignored;
*/
public void setSipStack(SipStack sipStack)
{
this.sipStack = sipStack;
}
/**
* Returns a logger name.
*
* @return a logger name.
*/
public String getLoggerName()
{
return "SIP Communicator JAIN SIP logger.";
}
/**
* Logs the specified trace with a debuf level.
*
* @param message the trace to log.
*/
public void logTrace(String message)
{
if (logger.isDebugEnabled())
logger.debug(message);
}
/**
* Returns a local address to use with the specified TCP destination.
* The method forces the JAIN-SIP stack to create
* s and binds (if necessary)
* and return a socket connected to the specified destination address and
* port and then return its local address.
*
* @param dst the destination address that the socket would need to connect
* to.
* @param dstPort the port number that the connection would be established
* with.
* @param localAddress the address that we would like to bind on
* (null for the "any" address).
* @param transport the transport that will be used TCP ot TLS
*
* @return the SocketAddress that this handler would use when connecting to
* the specified destination address and port.
*
* @throws IOException if we fail binding the local socket
*/
public java.net.InetSocketAddress getLocalAddressForDestination(
java.net.InetAddress dst,
int dstPort,
java.net.InetAddress localAddress,
String transport)
throws IOException
{
if(ListeningPoint.TLS.equalsIgnoreCase(transport))
return (java.net.InetSocketAddress)(((SipStackImpl)this.sipStack)
.getLocalAddressForTlsDst(dst, dstPort, localAddress));
else
return (java.net.InetSocketAddress)(((SipStackImpl)this.sipStack)
.getLocalAddressForTcpDst(dst, dstPort, localAddress, 0));
}
}
| Java |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.