@@ -1365,6 +1365,63 @@ popupGui <- function(dev){
1365
1365
##################################################################################
1366
1366
1367
1367
1368
+ splashScreen <- function() {
1369
+
1370
+ library(png) # For PNG images
1371
+ par(mar=defaultSettings$mar, cex.axis=defaultSettings$cex.axis,
1372
+ cex.main=defaultSettings$cex.main, bg='black')
1373
+ colMain <- '#b4d0f3'
1374
+ colBack <- '#0065ca'
1375
+ plot(0, 0, type='n', xlab='', ylab='', col.axis='black')
1376
+
1377
+ # Load the image and get its dimensions
1378
+ img_path <- system.file("extdata", "DigestRpicture.png", package = "digestR")
1379
+ img <- readPNG(img_path)
1380
+
1381
+ # Define plot area without axis
1382
+ plot(0, 0, type='n', xlab='', ylab='', axes=FALSE, xlim=c(-1.5, 1.5), ylim=c(-1.5, 1.5))
1383
+
1384
+ # Display the image
1385
+ rasterImage(img, 3, 3, 3, 3)
1386
+
1387
+ # Letter positions and modern color scheme for "PANDAS"
1388
+ letters <- c('P', 'A', 'N', 'D', 'A', 'S')
1389
+ x_positions <- c(-0.8, -0.5, -0.2, 0.1, 0.4, 0.7) # Custom X positions for each letter
1390
+ y_positions <- c(0.62, 0.62, 0.62, 0.62, 0.62, 0.62) # Same Y position for all
1391
+ colors <- rep('#4da6ff', 6) # Light blue for all letters
1392
+ cex_values <- rep(5, 6) # Font size for letters
1393
+
1394
+ # Add shadow effect to the letters for depth
1395
+ shadow_col <- '#00000050' # Semi-transparent black shadow
1396
+ for (i in 1:length(letters)) {
1397
+ text(x_positions[i] + 0.02, y_positions[i] - 0.02, letters[i], col=shadow_col, cex=cex_values[i], pos=3)
1398
+ text(x_positions[i], y_positions[i], letters[i], col=colors[i], cex=cex_values[i], pos=3)
1399
+ }
1400
+
1401
+ # Add black shadow for the title "Peptide Analyzer of Naturally Digested Amino acid Sequences"
1402
+ text(0, -0.4, 'Peptide Analyzer of', col='black', cex=1.80, font=2.3) # Black shadow
1403
+ text(0, -0.4, 'Peptide Analyzer of', col='#4da6ff', cex=1.8, font=2) # Main text
1404
+
1405
+ # Shadow for "Naturally Digested Amino acid Sequences"
1406
+ text(0, -0.53, 'Naturally Digested Amino acid Sequences', col='black', cex=1.80, font=2.3) # Black shadow
1407
+ text(0, -0.53, 'Naturally Digested Amino acid Sequences', col='#4da6ff', cex=1.8, font=2) # Main text
1408
+
1409
+ # Version and command text, shifted further downwards
1410
+ text(0, -0.75, paste('version 1.0.0', pkgVar$version), col='#00b3b3', font=2) # Dynamic color
1411
+
1412
+ # Clean, minimal function list with better spacing and shifted downwards
1413
+ text(0, -0.86, 'gp() - Generate New Proteome', col='#00b3b3', cex=1.1, font = 2) # Light blue
1414
+ text(0, -0.94, 'pm() - Process Mascot files', col='#00b3b3', cex=1.1, font = 2) # Light blue
1415
+ text(0, -1.02, 'fo() - Open *.dcf files', col='#00b3b3', cex=1.1, font = 2) # Light blue
1416
+
1417
+ # Force the graphics device to refresh
1418
+ dev.flush()
1419
+ }
1420
+
1421
+ # splashScreen()
1422
+ ##################################################################################
1423
+ # library(png) # For PNG images
1424
+
1368
1425
# splashScreen <- function() {
1369
1426
1370
1427
# library(png) # For PNG images
@@ -1373,19 +1430,19 @@ popupGui <- function(dev){
1373
1430
# colMain <- '#b4d0f3'
1374
1431
# colBack <- '#0065ca'
1375
1432
# plot(0, 0, type='n', xlab='', ylab='', col.axis='black')
1433
+
1434
+ # # Define plot area without axis
1435
+ # plot(0, 0, type='n', xlab='', ylab='', axes=FALSE, xlim=c(-1.5, 1.5), ylim=c(-1.5, 1.5))
1376
1436
1377
1437
# # Load the image and get its dimensions
1378
1438
# img_path <- system.file("extdata", "DigestRpicture.png", package = "digestR")
1379
1439
# img <- readPNG(img_path)
1380
1440
1381
- # # Define plot area without axis
1382
- # plot(0, 0, type='n', xlab='', ylab='', axes=FALSE, xlim=c(-1.5, 1.5), ylim=c(-1.5, 1.5))
1383
-
1384
- # # Display the image
1385
- # rasterImage(img, 3, 3, 3, 3)
1441
+ # # Display the image - fitting it in the entire splash screen area
1442
+ # rasterImage(img, -1.5, -1.5, 1.5, 1.5)
1386
1443
1387
1444
# # Letter positions and modern color scheme for "PANDAS"
1388
- # letters <- c('P', 'A', 'N', 'D', 'A', 'S')
1445
+ # letters <- c('P', 'A', 'N', 'D', 'A', 'S')
1389
1446
# x_positions <- c(-0.8, -0.5, -0.2, 0.1, 0.4, 0.7) # Custom X positions for each letter
1390
1447
# y_positions <- c(0.62, 0.62, 0.62, 0.62, 0.62, 0.62) # Same Y position for all
1391
1448
# colors <- rep('#4da6ff', 6) # Light blue for all letters
@@ -1419,63 +1476,6 @@ popupGui <- function(dev){
1419
1476
# }
1420
1477
1421
1478
# splashScreen()
1422
- ##################################################################################
1423
- library(png) # For PNG images
1424
-
1425
- splashScreen <- function() {
1426
-
1427
- library(png) # For PNG images
1428
- par(mar=defaultSettings$mar, cex.axis=defaultSettings$cex.axis,
1429
- cex.main=defaultSettings$cex.main, bg='black')
1430
- colMain <- '#b4d0f3'
1431
- colBack <- '#0065ca'
1432
- plot(0, 0, type='n', xlab='', ylab='', col.axis='black')
1433
-
1434
- # Define plot area without axis
1435
- plot(0, 0, type='n', xlab='', ylab='', axes=FALSE, xlim=c(-1.5, 1.5), ylim=c(-1.5, 1.5))
1436
-
1437
- # Load the image and get its dimensions
1438
- img_path <- system.file("extdata", "DigestRpicture.png", package = "digestR")
1439
- img <- readPNG(img_path)
1440
-
1441
- # Display the image - fitting it in the entire splash screen area
1442
- rasterImage(img, -1.5, -1.5, 1.5, 1.5)
1443
-
1444
- # Letter positions and modern color scheme for "PANDAS"
1445
- letters <- c('P', 'A', 'N', 'D', 'A', 'S')
1446
- x_positions <- c(-0.8, -0.5, -0.2, 0.1, 0.4, 0.7) # Custom X positions for each letter
1447
- y_positions <- c(0.62, 0.62, 0.62, 0.62, 0.62, 0.62) # Same Y position for all
1448
- colors <- rep('#4da6ff', 6) # Light blue for all letters
1449
- cex_values <- rep(5, 6) # Font size for letters
1450
-
1451
- # Add shadow effect to the letters for depth
1452
- shadow_col <- '#00000050' # Semi-transparent black shadow
1453
- for (i in 1:length(letters)) {
1454
- text(x_positions[i] + 0.02, y_positions[i] - 0.02, letters[i], col=shadow_col, cex=cex_values[i], pos=3)
1455
- text(x_positions[i], y_positions[i], letters[i], col=colors[i], cex=cex_values[i], pos=3)
1456
- }
1457
-
1458
- # Add black shadow for the title "Peptide Analyzer of Naturally Digested Amino acid Sequences"
1459
- text(0, -0.4, 'Peptide Analyzer of', col='black', cex=1.80, font=2.3) # Black shadow
1460
- text(0, -0.4, 'Peptide Analyzer of', col='#4da6ff', cex=1.8, font=2) # Main text
1461
-
1462
- # Shadow for "Naturally Digested Amino acid Sequences"
1463
- text(0, -0.53, 'Naturally Digested Amino acid Sequences', col='black', cex=1.80, font=2.3) # Black shadow
1464
- text(0, -0.53, 'Naturally Digested Amino acid Sequences', col='#4da6ff', cex=1.8, font=2) # Main text
1465
-
1466
- # Version and command text, shifted further downwards
1467
- text(0, -0.75, paste('version 1.0.0', pkgVar$version), col='#00b3b3', font=2) # Dynamic color
1468
-
1469
- # Clean, minimal function list with better spacing and shifted downwards
1470
- text(0, -0.86, 'gp() - Generate New Proteome', col='#00b3b3', cex=1.1, font = 2) # Light blue
1471
- text(0, -0.94, 'pm() - Process Mascot files', col='#00b3b3', cex=1.1, font = 2) # Light blue
1472
- text(0, -1.02, 'fo() - Open *.dcf files', col='#00b3b3', cex=1.1, font = 2) # Light blue
1473
-
1474
- # Force the graphics device to refresh
1475
- dev.flush()
1476
- }
1477
-
1478
- splashScreen()
1479
1479
1480
1480
##################################################################################
1481
1481
0 commit comments