Skip to content

Commit

Permalink
fix ladspa browser description (unwanted line breaks), add missing la…
Browse files Browse the repository at this point in the history
…bels to instruments' controls
  • Loading branch information
zynskeywolf committed Jan 2, 2024
1 parent 8eba258 commit 4ac2cd2
Show file tree
Hide file tree
Showing 5 changed files with 28 additions and 51 deletions.
4 changes: 2 additions & 2 deletions plugins/BitInvader/BitInvader.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -153,8 +153,8 @@ BitInvader::BitInvader( InstrumentTrack * _instrument_track ) :
Instrument( _instrument_track, &bitinvader_plugin_descriptor ),
m_sampleLength(wavetableSize, 4, wavetableSize, 1, this, tr("Sample length")),
m_graph(-1.0f, 1.0f, wavetableSize, this),
m_interpolation( false, this ),
m_normalize( false, this )
m_interpolation(false, this, tr("Interpolation")),
m_normalize(false, this, tr("Normalize"))
{
m_graph.setWaveToSine();
lengthChanged();
Expand Down
31 changes: 4 additions & 27 deletions plugins/LadspaBrowser/LadspaDescription.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -128,37 +128,14 @@ void LadspaDescription::update( const ladspa_key_t & _key )
name->setText( QWidget::tr( "Name: " ) + manager->getName( _key ) );
layout->addWidget( name );

auto maker = new QWidget(description);
auto makerLayout = new QHBoxLayout(maker);
makerLayout->setContentsMargins(0, 0, 0, 0);
makerLayout->setSpacing( 0 );
auto maker = new QLabel(description);
maker->setText(QWidget::tr("Maker: ") + manager->getMaker(_key));
layout->addWidget( maker );

auto maker_label = new QLabel(maker);
maker_label->setText( QWidget::tr( "Maker: " ) );
maker_label->setAlignment( Qt::AlignTop );
auto maker_content = new QLabel(maker);
maker_content->setText( manager->getMaker( _key ) );
maker_content->setWordWrap( true );
makerLayout->addWidget( maker_label );
makerLayout->addWidget( maker_content, 1 );

auto copyright = new QWidget(description);
auto copyrightLayout = new QHBoxLayout(copyright);
copyrightLayout->setContentsMargins(0, 0, 0, 0);
copyrightLayout->setSpacing( 0 );
auto copyright = new QLabel(description);
copyright->setText(QWidget::tr("Copyright: ") + manager->getCopyright(_key));
layout->addWidget( copyright );

auto copyright_label = new QLabel(copyright);
copyright_label->setText( QWidget::tr( "Copyright: " ) );
copyright_label->setAlignment( Qt::AlignTop );

auto copyright_content = new QLabel(copyright);
copyright_content->setText( manager->getCopyright( _key ) );
copyright_content->setWordWrap( true );
copyrightLayout->addWidget( copyright_label );
copyrightLayout->addWidget( copyright_content, 1 );

auto requiresRealTime = new QLabel(description);
requiresRealTime->setText( QWidget::tr( "Requires Real Time: " ) +
( manager->hasRealTimeDependency( _key ) ?
Expand Down
34 changes: 17 additions & 17 deletions plugins/Nes/Nes.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -482,53 +482,53 @@ void NesObject::updatePitch()

NesInstrument::NesInstrument( InstrumentTrack * instrumentTrack ) :
Instrument( instrumentTrack, &nes_plugin_descriptor ),
m_ch1Enabled( true, this ),
m_ch1Enabled(true, this, tr("Channel 1 enable")),
m_ch1Crs( 0.f, -24.f, 24.f, 1.f, this, tr( "Channel 1 coarse detune" ) ),
m_ch1Volume( 15.f, 0.f, 15.f, 1.f, this, tr( "Channel 1 volume" ) ),

m_ch1EnvEnabled( false, this ),
m_ch1EnvLooped( false, this ),
m_ch1EnvEnabled(false, this, tr("Channel 1 envelope enable")),
m_ch1EnvLooped(false, this, tr("Channel 1 envelope loop")),
m_ch1EnvLen( 0.f, 0.f, 15.f, 1.f, this, tr( "Channel 1 envelope length" ) ),

m_ch1DutyCycle( 0, 0, 3, this, tr( "Channel 1 duty cycle" ) ),

m_ch1SweepEnabled( false, this ),
m_ch1SweepEnabled(false, this, tr("Channel 1 sweep enable")),
m_ch1SweepAmt( 0.f, -7.f, 7.f, 1.f, this, tr( "Channel 1 sweep amount" ) ),
m_ch1SweepRate( 0.f, 0.f, 7.f, 1.f, this, tr( "Channel 1 sweep rate" ) ),

m_ch2Enabled( true, this ),
m_ch2Crs( 0.f, -24.f, 24.f, 1.f, this, tr( "Channel 2 Coarse detune" ) ),
m_ch2Volume( 15.f, 0.f, 15.f, 1.f, this, tr( "Channel 2 Volume" ) ),
m_ch2Enabled(true, this, tr("Channel 2 enable")),
m_ch2Crs( 0.f, -24.f, 24.f, 1.f, this, tr( "Channel 2 coarse detune" ) ),
m_ch2Volume( 15.f, 0.f, 15.f, 1.f, this, tr( "Channel 2 volume" ) ),

m_ch2EnvEnabled( false, this ),
m_ch2EnvLooped( false, this ),
m_ch2EnvEnabled(false, this, tr("Channel 2 envelope enable")),
m_ch2EnvLooped(false, this, tr("Channel 2 envelope loop")),
m_ch2EnvLen( 0.f, 0.f, 15.f, 1.f, this, tr( "Channel 2 envelope length" ) ),

m_ch2DutyCycle( 2, 0, 3, this, tr( "Channel 2 duty cycle" ) ),

m_ch2SweepEnabled( false, this ),
m_ch2SweepEnabled(false, this, tr("Channel 2 sweep enable")),
m_ch2SweepAmt( 0.f, -7.f, 7.f, 1.f, this, tr( "Channel 2 sweep amount" ) ),
m_ch2SweepRate( 0.f, 0.f, 7.f, 1.f, this, tr( "Channel 2 sweep rate" ) ),

//channel 3
m_ch3Enabled( true, this ),
m_ch3Enabled(true, this, tr("Channel 3 enable")),
m_ch3Crs( 0.f, -24.f, 24.f, 1.f, this, tr( "Channel 3 coarse detune" ) ),
m_ch3Volume( 15.f, 0.f, 15.f, 1.f, this, tr( "Channel 3 volume" ) ),

//channel 4
m_ch4Enabled( false, this ),
m_ch4Enabled(false, this, tr("Channel 4 enable")),
m_ch4Volume( 15.f, 0.f, 15.f, 1.f, this, tr( "Channel 4 volume" ) ),

m_ch4EnvEnabled( false, this ),
m_ch4EnvLooped( false, this ),
m_ch4EnvEnabled(false, this, tr("Channel 4 envelope enable")),
m_ch4EnvLooped(false, this, tr("Channel 4 envelope loop")),
m_ch4EnvLen( 0.f, 0.f, 15.f, 1.f, this, tr( "Channel 4 envelope length" ) ),

m_ch4NoiseMode( false, this ),
m_ch4NoiseFreqMode( false, this ),
m_ch4NoiseMode(false, this, tr("Channel 4 noise mode")),
m_ch4NoiseFreqMode(false, this, tr("Channel 4 frequency mode")),
m_ch4NoiseFreq( 0.f, 0.f, 15.f, 1.f, this, tr( "Channel 4 noise frequency" ) ),

m_ch4Sweep( 0.f, -7.f, 7.f, 1.f, this, tr( "Channel 4 noise frequency sweep" ) ),
m_ch4NoiseQuantize( true, this ),
m_ch4NoiseQuantize(true, this, tr("Channel 4 quantize")),

//master
m_masterVol( 1.0f, 0.0f, 2.0f, 0.01f, this, tr( "Master volume" ) ),
Expand Down
8 changes: 4 additions & 4 deletions plugins/SpectrumAnalyzer/SaControlsDialog.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -119,28 +119,28 @@ SaControlsDialog::SaControlsDialog(SaControls *controls, SaProcessor *processor)
auto waterfallButton = new LedCheckBox(tr("Waterfall"), this);
waterfallButton->setToolTip(tr("Display real-time spectrogram"));
waterfallButton->setCheckable(true);
waterfallButton->setMinimumSize(70, 12);
waterfallButton->setMinimumSize(100, 12);
waterfallButton->setModel(&controls->m_waterfallModel);
config_layout->addWidget(waterfallButton, 0, 1);

auto smoothButton = new LedCheckBox(tr("Averaging"), this);
smoothButton->setToolTip(tr("Enable exponential moving average"));
smoothButton->setCheckable(true);
smoothButton->setMinimumSize(70, 12);
smoothButton->setMinimumSize(100, 12);
smoothButton->setModel(&controls->m_smoothModel);
config_layout->addWidget(smoothButton, 1, 1);

auto stereoButton = new LedCheckBox(tr("Stereo"), this);
stereoButton->setToolTip(tr("Display stereo channels separately"));
stereoButton->setCheckable(true);
stereoButton->setMinimumSize(70, 12);
stereoButton->setMinimumSize(100, 12);
stereoButton->setModel(&controls->m_stereoModel);
config_layout->addWidget(stereoButton, 2, 1);

auto peakHoldButton = new LedCheckBox(tr("Peak hold"), this);
peakHoldButton->setToolTip(tr("Display envelope of peak values"));
peakHoldButton->setCheckable(true);
peakHoldButton->setMinimumSize(70, 12);
peakHoldButton->setMinimumSize(100, 12);
peakHoldButton->setModel(&controls->m_peakHoldModel);
config_layout->addWidget(peakHoldButton, 3, 1);

Expand Down
2 changes: 1 addition & 1 deletion plugins/Stk/Mallets/Mallets.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,7 @@ MalletsInstrument::MalletsInstrument( InstrumentTrack * _instrument_track ):
// TODO: m_vibratoModel
m_velocityModel(64.0f, 0.1f, 128.0f, 0.1f, this, tr( "Speed" )),
m_strikeModel( true, this, tr( "Bowed" ) ),
m_presetsModel(this),
m_presetsModel(this, tr("Instrument")),
m_spreadModel(0, 0, 255, 1, this, tr( "Spread" )),
m_randomModel(0.0f, 0.0f, 1.0f, 0.01f, this, tr("Randomness")),
m_versionModel( MALLETS_PRESET_VERSION, 0, MALLETS_PRESET_VERSION, this, "" ),
Expand Down

0 comments on commit 4ac2cd2

Please sign in to comment.