QgsMarkerLineSymbolLayerV2Widget::QgsMarkerLineSymbolLayerV2Widget( const QgsVectorLayer* vl, QWidget* parent ) : QgsSymbolLayerV2Widget( parent, vl ) { mLayer = NULL; setupUi( this ); connect( spinInterval, SIGNAL( valueChanged( double ) ), this, SLOT( setInterval( double ) ) ); connect( chkRotateMarker, SIGNAL( clicked() ), this, SLOT( setRotate() ) ); connect( spinOffset, SIGNAL( valueChanged( double ) ), this, SLOT( setOffset() ) ); connect( radInterval, SIGNAL( clicked() ), this, SLOT( setPlacement() ) ); connect( radVertex, SIGNAL( clicked() ), this, SLOT( setPlacement() ) ); connect( radVertexLast, SIGNAL( clicked() ), this, SLOT( setPlacement() ) ); connect( radVertexFirst, SIGNAL( clicked() ), this, SLOT( setPlacement() ) ); connect( radCentralPoint, SIGNAL( clicked() ), this, SLOT( setPlacement() ) ); }
StaffText::StaffText(SubStyle ss, Score* s) : Text(ss, s) { setFlags(ElementFlag::MOVABLE | ElementFlag::SELECTABLE | ElementFlag::ON_STAFF); setPlacement(Placement::ABOVE); // default setSwingParameters(MScore::division / 2, 60); }
void Ottava::setOttavaType(OttavaType val) { setEndHook(true); _ottavaType = val; Spatium hook(score()->styleS(ST_ottavaHook)); SymId id; if (_numbersOnly) id = ottavaDefault[int(val)].numbersOnlyId; else id = ottavaDefault[int(val)].id; if (beginSymbolStyle == PropertyStyle::STYLED) setBeginSymbol(id); if (continueSymbolStyle == PropertyStyle::STYLED) setContinueSymbol(id); setBeginSymbolOffset(ottavaDefault[int(val)].offset); setContinueSymbolOffset(ottavaDefault[int(val)].offset); setEndHookHeight(hook * ottavaDefault[int(val)].hookDirection); setPlacement(ottavaDefault[int(val)].place); _pitchShift = ottavaDefault[int(val)].shift; foreach(SpannerSegment* s, spannerSegments()) { OttavaSegment* os = static_cast<OttavaSegment*>(s); os->clearText(); }
void QgsMarkerLineSymbolLayerV2Widget::setSymbolLayer( QgsSymbolLayerV2* layer ) { if ( layer->layerType() != "MarkerLine" ) return; // layer type is correct, we can do the cast mLayer = static_cast<QgsMarkerLineSymbolLayerV2*>( layer ); // set values spinInterval->setValue( mLayer->interval() ); chkRotateMarker->setChecked( mLayer->rotateMarker() ); spinOffset->setValue( mLayer->offset() ); if ( mLayer->placement() == QgsMarkerLineSymbolLayerV2::Interval ) radInterval->setChecked( true ); else if ( mLayer->placement() == QgsMarkerLineSymbolLayerV2::Vertex ) radVertex->setChecked( true ); else if ( mLayer->placement() == QgsMarkerLineSymbolLayerV2::LastVertex ) radVertexLast->setChecked( true ); else if ( mLayer->placement() == QgsMarkerLineSymbolLayerV2::CentralPoint ) radCentralPoint->setChecked( true ); else radVertexFirst->setChecked( true ); updateMarker(); setPlacement(); // update gui }
Vibrato::Vibrato(Score* s) : SLine(s) { _vibratoType = Type::GUITAR_VIBRATO; setPlayArticulation(true); setPlacement(Placement::ABOVE); }
bool Pedal::setProperty(P_ID propertyId, const QVariant& val) { switch (propertyId) { case P_ID::PLACEMENT: if (val != getProperty(propertyId)) { // reverse hooks setBeginHookHeight(-beginHookHeight()); setEndHookHeight(-endHookHeight()); } setPlacement(Placement(val.toInt())); break; case P_ID::LINE_WIDTH: lineWidthStyle = PropertyStyle::UNSTYLED; TextLineBase::setProperty(propertyId, val); break; case P_ID::LINE_STYLE: lineStyleStyle = PropertyStyle::UNSTYLED; TextLineBase::setProperty(propertyId, val); break; default: if (!TextLineBase::setProperty(propertyId, val)) return false; break; } score()->setLayoutAll(); return true; }
bool Fermata::setProperty(Pid propertyId, const QVariant& v) { switch (propertyId) { case Pid::PLACEMENT: { Placement p = Placement(v.toInt()); if (p != placement()) { QString s = Sym::id2name(_symId); bool up = placeAbove(); if (s.endsWith(up ? "Above" : "Below")) { QString s2 = s.left(s.size() - 5) + (up ? "Below" : "Above"); _symId = Sym::name2id(s2); } setPlacement(p); } } break; case Pid::PLAY: setPlay(v.toBool()); break; case Pid::TIME_STRETCH: setTimeStretch(v.toDouble()); score()->fixTicks(); break; default: return Element::setProperty(propertyId, v); } triggerLayout(); return true; }
Fermata::Fermata(Score* s) : Element(s, ElementFlag::MOVABLE | ElementFlag::ON_STAFF) { setPlacement(Placement::ABOVE); _symId = SymId::noSym; _timeStretch = 1.0; setPlay(true); }
void KAdvancedConfig::defaults() { setShadeHover(false); setShadeHoverInterval(250); setPlacement(SMART_PLACEMENT); setHideUtilityWindowsForInactive( true ); emit KCModule::changed(true); }
TempoText::TempoText(Score* s) : Text(s) { _tempo = 2.0; // propertyDefault(P_TEMPO).toDouble(); _followText = false; setPlacement(ABOVE); setTextStyle(s->textStyle(TEXT_STYLE_TEMPO)); }
Trill::Trill(Score* s) : SLine(s) { _trillType = Type::TRILL_LINE; _accidental = 0; _ornamentStyle = MScore::OrnamentStyle::DEFAULT; setPlayArticulation(true); setPlacement(Placement::ABOVE); }
TempoText::TempoText(Score* s) : Text(s) { _tempo = 2.0; // propertyDefault(P_TEMPO).toDouble(); _followText = false; _relative = 1.0; _isRelative = false; setPlacement(Element::Placement::ABOVE); setTextStyleType(TextStyleType::TEMPO); }
StaffText::StaffText(Score* s) : Text(s) { setFlags(ElementFlag::MOVABLE | ElementFlag::SELECTABLE | ElementFlag::ON_STAFF); setTextStyleType(TextStyleType::STAFF); setPlacement(Placement::ABOVE); // default _setAeolusStops = false; _swing = false; clearAeolusStops(); setSwingParameters(MScore::division / 2, 60); }
void Options::syncFromKcfgc() { setShowGeometryTip(m_settings->geometryTip()); setCondensedTitle(m_settings->condensedTitle()); setFocusPolicy(m_settings->focusPolicy()); setNextFocusPrefersMouse(m_settings->nextFocusPrefersMouse()); setSeparateScreenFocus(m_settings->separateScreenFocus()); setRollOverDesktops(m_settings->rollOverDesktops()); setLegacyFullscreenSupport(m_settings->legacyFullscreenSupport()); setFocusStealingPreventionLevel(m_settings->focusStealingPreventionLevel()); #ifdef KWIN_BUILD_DECORATIONS setPlacement(m_settings->placement()); #else setPlacement(Placement::Maximizing); #endif setAutoRaise(m_settings->autoRaise()); setAutoRaiseInterval(m_settings->autoRaiseInterval()); setDelayFocusInterval(m_settings->delayFocusInterval()); setShadeHover(m_settings->shadeHover()); setShadeHoverInterval(m_settings->shadeHoverInterval()); setClickRaise(m_settings->clickRaise()); setBorderSnapZone(m_settings->borderSnapZone()); setWindowSnapZone(m_settings->windowSnapZone()); setCenterSnapZone(m_settings->centerSnapZone()); setSnapOnlyWhenOverlapping(m_settings->snapOnlyWhenOverlapping()); setKillPingTimeout(m_settings->killPingTimeout()); setHideUtilityWindowsForInactive(m_settings->hideUtilityWindowsForInactive()); setInactiveTabsSkipTaskbar(m_settings->inactiveTabsSkipTaskbar()); setAutogroupSimilarWindows(m_settings->autogroupSimilarWindows()); setAutogroupInForeground(m_settings->autogroupInForeground()); setBorderlessMaximizedWindows(m_settings->borderlessMaximizedWindows()); setElectricBorderMaximize(m_settings->electricBorderMaximize()); setElectricBorderTiling(m_settings->electricBorderTiling()); setElectricBorderCornerRatio(m_settings->electricBorderCornerRatio()); setWindowsBlockCompositing(m_settings->windowsBlockCompositing()); }
void Ottava::setOttavaType(Type val) { setEndHook(true); _ottavaType = val; const OttavaDefault* def = &ottavaDefault[int(_ottavaType)]; if (beginTextStyle == PropertyStyle::STYLED) setBeginText(propertyDefault(P_ID::BEGIN_TEXT).toString(), TextStyleType::OTTAVA); if (continueTextStyle == PropertyStyle::STYLED) setContinueText(propertyDefault(P_ID::CONTINUE_TEXT).toString(), TextStyleType::OTTAVA); setEndHookHeight(score()->styleS(StyleIdx::ottavaHook) * def->hookDirection); setPlacement(def->place); _pitchShift = def->shift; }
void KAdvancedConfig::load( void ) { KConfigGroup cg(config, "Windows"); setShadeHover(cg.readEntry(KWIN_SHADEHOVER, false)); setShadeHoverInterval(cg.readEntry(KWIN_SHADEHOVER_INTERVAL, 250)); QString key; // placement policy --- CT 19jan98 --- key = cg.readEntry(KWIN_PLACEMENT); //CT 13mar98 interactive placement // if( key.left(11) == "interactive") { // setPlacement(INTERACTIVE_PLACEMENT); // int comma_pos = key.find(','); // if (comma_pos < 0) // interactiveTrigger->setValue(0); // else // interactiveTrigger->setValue (key.right(key.length() // - comma_pos).toUInt(0)); // iTLabel->setEnabled(true); // interactiveTrigger->show(); // } // else { // interactiveTrigger->setValue(0); // iTLabel->setEnabled(false); // interactiveTrigger->hide(); if( key == "Random") setPlacement(RANDOM_PLACEMENT); else if( key == "Cascade") setPlacement(CASCADE_PLACEMENT); //CT 31jan98 //CT 31mar98 manual placement else if( key == "manual") setPlacement(MANUAL_PLACEMENT); else if( key == "Centered") setPlacement(CENTERED_PLACEMENT); else if( key == "ZeroCornered") setPlacement(ZEROCORNERED_PLACEMENT); else if( key == "Maximizing") setPlacement(MAXIMIZING_PLACEMENT); else setPlacement(SMART_PLACEMENT); // } setHideUtilityWindowsForInactive( cg.readEntry( KWIN_HIDE_UTILITY, true)); emit KCModule::changed(false); }
void VisGlyph::setParameters() { // call OkcViewDisplay::setParameters() to initialize // parameters about dataset OkcViewDisplay::setParameters(); OkcVisualMapResult* okcVMR = getOkcVisualMapResult(); GlyphPlaceResult* placeResult = okcVMR->getGlyphPlaceResult(); m_blocksize = placeResult->blocksize; m_basex = &(placeResult->basex); m_basey = &(placeResult->basey); // Although these two variables are used only in drawSingleData(), // we initialize them within setParameters() to reduce time cost. m_norm.resize(m_dim_size); m_poly.resize(m_dim_size+1); // Call setPlacement after initializing m_dim_size, // because setPlacement needs this value setPlacement(); }
TextLine::TextLine(Score* s) : TextLineBase(s) { initElementStyle(&textLineStyle); setPlacement(Placement::ABOVE); setBeginText(""); setContinueText(""); setEndText(""); setBeginTextOffset(QPointF(0,0)); setContinueTextOffset(QPointF(0,0)); setEndTextOffset(QPointF(0,0)); setLineVisible(true); setBeginHookType(HookType::NONE); setEndHookType(HookType::NONE); setBeginHookHeight(Spatium(1.5)); setEndHookHeight(Spatium(1.5)); resetProperty(Pid::BEGIN_TEXT_PLACE); resetProperty(Pid::CONTINUE_TEXT_PLACE); resetProperty(Pid::END_TEXT_PLACE); }
TextLine::TextLine(Score* s) : TextLineBase(s) { setPlacement(Placement::ABOVE); }
TextLineSegment::TextLineSegment(Score* s) : TextLineBaseSegment(s, ElementFlag::MOVABLE | ElementFlag::ON_STAFF) { setPlacement(Placement::ABOVE); }
Fingering::Fingering(Score* s, Tid tid, ElementFlags ef) : TextBase(s, tid, ef) { setPlacement(Placement::ABOVE); initElementStyle(&fingeringStyle); }
TextLineSegment::TextLineSegment(Score* s) : TextLineBaseSegment(s) { setPlacement(Placement::ABOVE); }
StaffTextBase::StaffTextBase(Score* s, ElementFlags flags) : TextBase(s, flags) { setPlacement(Placement::ABOVE); // default setSwingParameters(MScore::division / 2, 60); }